Harbor vs Trail-code

Trail-code keeps what you tell it to, in your repo. Harbor learns it for you, and keeps it true.

Trail-code (previously graft) is open-source and runs on your machine: a map of your code built with tree-sitter, plus learnings your agent saves as markdown files in the repo when you ask, shared through git and reviewed in the pull request. Its trail check compares a branch with those learnings before a PR. Harbor learns without being asked, from corrections, review threads and Slack, sets the gate you choose, retires a rule when the code it names is deleted, counts which rules were served and cited, and refuses banned commands. Trail-code is free under MIT. Harbor is hosted.

Free for you and one teammate. No card. No end date. Every line about Trail-code is from its own pages, read on 18 November 2026.

Why teams pick Harbor

Decide what gets in. See what gets used.

Three things Harbor does for the team behind the agents, each beside what Trail-code's own pages say about the same job.

You set the gate

Manual, Hybrid or Auto. Whatever you pick, secrets, install steps and dangerous commands wait for a person.

In Trail-codeA repo learning is a file in your pull request, reviewed like code. The agent saves one only when you ask, and never on its own.

You see what got used

Every rule shows how often it was served and how often an answer cited it.

In Trail-codetrail status shows tokens saved, and a reply says when it started from a teammate’s learning. A team page counting reuse is announced as coming soon.

You block a risky command

Block rules refuse it before it runs, in Claude Code, Cursor, Codex and Copilot.

In Trail-codeAn always follow learning is one the agent is told not to go against, even if asked. It is an instruction to the agent, not a command refused before it runs.

Side by side

Harbor and Trail-code, row by row.

HarborTrail-code
What it isShared memory for a team's coding agents. It learns what your team decides and corrects, and serves the rules that apply to each session.A map of your code (every function and who calls it) and learnings: what you, your agents and your team decided, ruled out and should watch out for.
Where the knowledge comes fromSlack, GitHub, GitLab, Notion, Confluence, Jira, Linear, Google Drive and Granola, plus what agent sessions record.Your conversations, when you ask the agent to save a learning. On day one, what you told Claude in two or more past sessions and review comments from the last 50 merged PRs.
Who decides what gets inYou set the gate. Manual holds everything for a person, Hybrid adds routine rules and holds the important ones, Auto adds everything else. Secrets, install steps and dangerous commands wait in every mode.A repo learning is a file in your pull request, reviewed like code. The agent saves one only when you ask, and never on its own.
How it reaches the agentHooks add the rules that apply to the session before the agent writes a line. The same rules are on an MCP server, the CLI and /harbor in Slack.Each session starts with the repo-wide learnings, and each prompt brings in the ones about the code it touches, with pointers into the code map. Claude Code gets hooks; other agents get a section in their instruction file, and MCP.
When a decision changesWhen a push deletes the file a rule is about, the rule is retired, or flagged if other repos still use it. A rule saved by an agent replaces one it reverses when its author could have retired the old one, with a Restore. Otherwise, and for anything read from a connected source, the pair waits for a person.The agent never edits an existing learning. When it goes against one it says why in the commit, and you delete or edit the file to drop it.
Seeing what was usedEvery rule shows how often it was served and how often an answer cited it.trail status shows tokens saved, and a reply says when it started from a teammate’s learning. A team page counting reuse is announced as coming soon.
Stopping a risky commandBlock rules refuse a command before it runs, in Claude Code, Cursor, Codex and GitHub Copilot, and hand the agent something to run instead.An always follow learning is one the agent is told not to go against, even if asked. It is an instruction to the agent, not a command refused before it runs.
AgentsClaude Code, Cursor, Codex and GitHub Copilot (the CLI and VS Code).Claude Code most deeply, plus Cursor, Codex, Gemini CLI, GitHub Copilot, Windsurf, Kiro, Antigravity and other AGENTS.md or MCP clients.
Open source and hostingThe CLI, harborloop, is MIT licensed on npm. The service is hosted.Open source under MIT, and local: learnings live in the repo and ~/.trail, shared through git. A hosted team workspace is announced as coming soon.
PriceSetup is self-serve and takes two minutes, with no call required. Free costs nothing for up to 2 people on one source, Pro is $24 per person a month billed yearly or $30 monthly, and Premium is $36, or $45 monthly.Free. The CLI is open source.
Best forEngineering teams who want every coding session to start with what the team decided.Developers who want a free, local map of their code and learnings kept as files in git.

Trail-code's side comes from its own pages, read on 18 November 2026: Trail-code on GitHub · trailhq.com/trail-code. Out of date? Tell us.

Which one

Pick the one built for your job.

Pick Harbor if

  • You want lessons saved without anyone asking, from corrections, PR review threads and Slack, not only when someone says "save this".
  • You want a rule retired or flagged when the code it names is deleted, and a newer rule to replace an old one with a Restore.
  • You want to see, rule by rule, which ones agents were served and which ones they used.
  • You want block rules that stop a destructive command before it runs.
Start free

Pick Trail-code if

  • You want everything on your machine and in git, with no account and no server.
  • You want a map of your code that takes the agent straight to the right files and callers.
  • You want learnings as markdown files your team reviews in each pull request.
  • You run agents beyond Claude Code, Cursor, Codex and Copilot, such as Gemini CLI or Windsurf.
Can I run Harbor and Trail-code together?

Yes. Trail-code’s code map tells an agent where things are, which Harbor does not do. Harbor serves the team’s rules to every agent and checks each pull request against them.

Can I start with Harbor today?

Yes. Sign up with Google or email, create your workspace and run npx harborloop init, with no card and no call. Trail-code installs today with npm, with no account.

Is Harbor open source?

The CLI, harborloop, is MIT licensed on npm. The service is hosted. Trail-code: Open source under MIT, and local: learnings live in the repo and ~/.trail, shared through git. A hosted team workspace is announced as coming soon.

Where do the claims about Trail-code come from?

From Trail-code's own public pages, read on 18 November 2026, which are listed under the table. Products move, so if a line is out of date, tell us and we will fix it.

Your team’s rules,
in every agent, checked on every PR.

Nothing to migrate and nothing to write. Every agent starts with what your team settles, and two weeks in you see which rules they cite.

Free for you and one teammate. No card. No end date.