Connect your coding agent¶
Step 6 of 7
This page is step 6 of the path. A coding agent is a program such as Claude Code, Codex, Cursor, Gemini CLI or Kiro that we talk to in plain words and that works on our code. One command adds sfe to every coding agent on the Mac, so the agent can look into our systems the same way we do in the Terminal. We look at what the command would change before we run it, then we run it ourselves, because this one is a step for a person to type.
Video, about three minutes, with narration and captions.
Before you start¶
- sfe is installed, and our pack is on (Turn on your pack).
- At least one coding agent is on the Mac. The ones sfe knows are Claude Code, Codex, Cursor, Gemini CLI and Kiro.
- The agent is not in the middle of a task. We restart it at the end.
What each agent gets¶
Connecting adds these to each agent.
| What it adds | What it is | What it does |
|---|---|---|
| The MCP server | MCP is a standard way for a coding agent to call a program as a tool. The sfe server is a small program that starts when the agent does | Every sfe command becomes a tool the agent can use, with the same narration we see in the Terminal. The tools used most (status, search, recall, investigate and run) are there from the first turn, and the server tells the agent which topics the team's notes cover |
| A skill | A page of instructions the agent reads when it needs them | It tells the agent what our systems are and how to use sfe |
| A guard hook | A hook is a check an agent runs before it uses a tool. The guard is sfe's check | It looks at each shell command and each edit before it runs, and refuses a change nobody allowed |
| The notes index (Claude Code) | A hook that runs when a session starts | It hands the agent one line for each note a person approved: its title and its id. The agent then asks sfe for the note it needs instead of guessing. It only reads, and it never stops a session |
In a test with eight real questions, these took Claude Code from about four sfe calls per question to one or two, with every answer right. An install made before sfe 0.1.1 gets the notes index the next time we run sfe agent install.
An agent reads our systems freely. It never changes one on its own: a change waits for a person to say yes.
Steps¶
1. See which agents are on this Mac¶
The command only reads. It prints one row for each agent.

| Column | What it says |
|---|---|
agent |
The agent's name |
present |
yes when the agent is on this Mac |
mcp, skill, guard |
Whether sfe has added that thing. no everywhere means nothing is connected yet |
rules |
Whether the agent has a rule that approves sfe's read tools by themselves. none until a pack is on |
config |
The agent's own settings file that sfe would change |
The last lines print the command to use, sfe agent install --for all. Some agents cannot run a hook. The list marks them via the PATH shield, and says that agents without hooks are covered by sfe shield on.
Screens and video
The screens in this step and the next come from a recorded session in a test home folder, with an empty folder for each of the five agents so that they show as present. The test home has no pack, which is why sfe prints its line about a pack at the top. Everything else is real output. The screens of the install itself, and of the agent running an sfe question, are still to be added.
2. See what the install would change¶
A dry run shows every change and writes nothing. We use --for claude here, to keep the answer short. --for all does the same for every agent.
The answer is long, because it lists every line of every file that would be added, each with a + in front. The top of it shows the first two things.

The first file is the agent's list of MCP servers, and the new entry starts the sfe server with node. The second file is the skill, written into the agent's own skills folder.
If we scroll on, the third thing is the guard hook, in the agent's settings file. It runs before every shell command and every edit the agent makes.

The last lines say that nothing was written, and where a real install would keep its record.

The record lets sfe agent uninstall take out exactly what the install added, and nothing else. An install changes only what it wrote, and a second install changes nothing.
3. Run the real install ourselves¶
This is a step for a person to type, in our own Terminal window. An agent does not run it, on purpose. The install changes the agent's own settings, including the guard that watches the agent, and the thing being guarded should not install its own guard.
It lists what it changed in each agent. We read the list, and check that it names the agents we use.
Screens and video
There is no picture of the real install on this page. It writes into our real agent settings, so it is not shown here. A picture of the Terminal and Claude Code side by side answering the same sfe question is still to be added. Until then, the dry run above shows the same files.
4. Restart the agent and check¶
We quit the coding agent and open it again, so that it starts the sfe server and sees every sfe tool. Then we run the list again:
The mcp, skill and guard columns now say yes for the agents we connected.
In the agent, we can ask in plain words, for example "what does sfe say about ticket ENG27-6254?". The agent calls the sfe tools and shows the same narrated answer the Terminal shows.
What we should see¶
sfe agent listwithpresent: yesfor our agents before the install, andyesundermcp,skillandguardafter it and a restart.- A dry run that ends with
Nothing was written (a dry run).
Troubleshooting¶
| What we see | Likely cause | What to do |
|---|---|---|
| The agent does not show the sfe tools | The agent was not restarted, or sfe is not in it | Run sfe agent list. If the columns say no, run sfe agent install --for all. Then quit the agent and open it again |
present says no for an agent we use |
sfe did not find the agent's folder on this Mac | Open the agent once, so that it makes its folder, and run sfe agent list again |
A GUARD GONE line in sfe's output |
The guard hook is not in the agent's settings | A person runs sfe agent install --for claude (or the agent named) in their own Terminal, and restarts the agent |
| We want sfe out of an agent | sfe agent uninstall --for claude takes out exactly what the install added |
|
| The agent says a change is refused | The guard did its job: nobody allowed that change | Nothing to fix. Changes go through a person, see Making changes |
Next¶
- Step 7 of the path: Check that it works.
- Using sfe from an agent: Using sfe with a coding agent.
Last reviewed: 2026-12-01