When it fires
Reach forxysq-goal when the answer needs coverage, not a quick lookup:
How it works
Given a goal, the agent runs a loop instead of a single query:- Decompose the goal into a handful of checkable subgoals. That set is the success condition.
- Seed the search from the names and IDs in the goal.
- Walk the vault, interleaving three moves: search broadly for what’s relevant, enumerate a slice completely so nothing is missed, and follow the connections between memories. It reads a memory in full only when that memory matters.
- Check coverage. When a branch runs dry, the agent asks which subgoals still lack support and goes looking specifically for those, rather than stopping early.
- Synthesize the gathered context, grouped by subgoal, and answers the goal from it, only from what your vault actually holds.
The goal loop answers only from your memory. The more you capture, the more ground it can cover, and the fewer gaps it has to report.
The primitives behind it
The loop is built on three memory tools your agent gets through the xysq connection. They’re useful on their own, too:| Tool | What it’s for |
|---|---|
| vault_search | Ranked, fuzzy retrieval, “find memories about X”. The discovery move. |
| vault_find | Complete, filtered enumeration, “give me every memory matching this filter” (a source, a kind like decisions or blockers, a time window, a connected entity). The coverage move. |
| vault_get | Pull one memory in full. The read-deep move. |
vault_search ranks and is great for discovery; vault_find is the one that lets the agent trust it has seen everything in a slice. The goal loop interleaves all three.
Using it in Claude Code
The goal loop ships in the xysq plugin for Claude Code, the same plugin that provides the xysq connection and the standard skill. If you already have the plugin, update it:Verifying it loaded
Inside Claude Code, run/skills. Alongside xysq, the recall skills, you should see xysq-goal. If it’s missing, run /plugin update xysq and start a fresh session.
Related
- Recall skills - the single-query micro skills (recap, decisions, blockers, prep, actionables) the goal loop builds on
- Standard skill - the core retain and recall protocol
- Connect your agent - install the plugin that ships these skills