Documentation
¶
Overview ¶
Package fasttools is a stdio MCP server that does in one call what an agent otherwise takes many turns for: several searches at once (batch_search), several files' outlines and line ranges (read_slices), every edit of a change, checked before any is written and verified after (apply_edits), and independent checks run side by side (run_checks).
It is given to Antigravity (agy, and the Antigravity app, which read the same ~/.gemini/config/plugins) as a plugin of its own (plugin.go), with a SessionStart hook that tells a new conversation where it is (session.go), so its first turns aren't spent finding out. In agy a turn costs seconds before the model says anything, and much of a session is turns of one search or one edit each: one call doing several saves those turns.
Index ¶
- Constants
- Variables
- func Dir(home string) string
- func Keep(home, exe string) error
- func On(home string) bool
- func Outline(path string, lines []string) []string
- func Remove(home string) error
- func Run(args []string) error
- func SessionStart(in io.Reader, out io.Writer)
- func Snapshot(dir string) string
- func Write(home, exe string) error
Constants ¶
const PluginName = "fast-tools"
PluginName is the plugin's folder under Antigravity's plugins.
const ServerName = "fast"
ServerName is the MCP server's name in the plugin; agy names its tools mcp_<plugin>_<server>_<tool>.
Variables ¶
var ErrNotOurs = errors.New("a plugin named " + PluginName + " that magpie didn't write is there already")
ErrNotOurs: a plugin of this name that magpie didn't write is there.
Functions ¶
func Dir ¶
Dir is the plugin's folder: Antigravity's global customization folder, ~/.gemini/config, shared by its CLI and IDE, finds a plugin in plugins/<name> by its plugin.json.
func Keep ¶
Keep writes the plugin again when it is on but starts a magpie that is no longer there (magpie was moved, or reinstalled at another path), or was written by an older magpie. One that starts another magpie still there is left as it is: two magpies (a build of one's own beside the app) would otherwise each take it back on every start. It never turns the plugin on.
func Outline ¶
Outline is the declarations of the file at path, one line each with its line number; nil for a kind of file with no outliner.
func Run ¶
Run is `magpie fast-tools …`: mcp serves the tools on stdin and stdout; session-start is the SessionStart hook.
func SessionStart ¶
SessionStart is the SessionStart hook: it reads the hook's input from in and writes what a new conversation is told of its workspace to out — its folder, its git state, what kind of project it is and what is at its top — so the first turns aren't spent finding out. Anything it can't read is left out; with nothing to say it writes {}, which changes nothing, so a hook that fails never stops a conversation.
Types ¶
This section is empty.