cogit

Git for the intent behind agent-written code: every message becomes a thought commit your commits point back to.

Source repo
erensrtky/cogit
Stars
★ 222
Last updated
1d ago
FARS reviewed
Nov 28, 2026
License
MIT
Primary language
TypeScript

At a glance

Works with
Platform-specificCodex · Claude Code
You'll need
Node.js 22.13+git repositoryClaude Code 2.1.275+ or Codex CLI 0.167+Shell / CLINetwork accessLocal filesystem
Typical use
A developer juggling 5-10 concurrent agent sessions across 2-3 repositories who loses track of where a decision landed: open the map, read the branches and the left off here marker, and use Resume.
Main limitation
Recording depends on the hook systems of Claude Code or Codex CLI; no other editor or agent has a documented integration.
Maintenance
Commits in the last 30 dayslast commit 2026-11-28
Source review
75/100 · Good

What does this agent do, and when should you use it?

cogit is a TypeScript CLI (npm package @cogit/cli) that also installs as a plugin into Claude Code and Codex CLI. Running through the agent's hooks, it records each message you send as a thought commit — the request, what came of it, decisions with their reasons, the options rejected, and which earlier message it continues — written while you work rather than reconstructed from the diff. Every code commit carries a Thought: trailer, so cogit show <sha>, cogit blame, cogit why, cogit log and cogit search walk from a line of code back to why it exists. cogit open . writes a local page that draws sessions as a git graph with branches, a Your turn inbox and Resume/Fork buttons, and opens a landed message as Intent, Shape and Code tabs plus a Tasks panel and per-file history. cogit pr composes pull-request descriptions from goals, decisions and rejected options instead of raw chat, and cogit pr --install-action adds a GitHub Action that posts them. It runs entirely on your machine with no server and no account; team sharing is opt-in and travels through your own git remote, outside your branches.

After installation, cogit receives session events through Claude Code or Codex CLI hooks and, while you work, writes each message as a thought commit: the question, the outcome, decisions with their reasons, rejected options, and the earlier message it continues. Each code commit gets a Thought: trailer, and cogit show <sha>, cogit blame, cogit why, cogit log and cogit search follow that chain from code back to cause. cogit open . renders the record as a read-only local page: sessions as a git graph with branches, commit chips, a left off here marker, a Your turn inbox and Resume/Fork buttons; a message that landed commits opens as Intent (why it happened), Shape (a diagram, before/after or interface table, an example, or plain steps) and Code (the diff); the Files view lists every message that touched a changed file along with each message's reason and the option it rejected. When a session closes, a small model turns unfinished work into a few Tasks items you accept, dismiss or close (cogit captures, off by default, enabled with cogit config set captures true). cogit pr writes the goal, decisions and rejected options into a PR description, and cogit pr --install-action installs a GitHub Action that posts it on every pull request. By default the model the session ran on reopens the whole conversation at the end and corrects the record; Economical leaves it all to the small model. Records stay local, key and token patterns are redacted, cogit prune deletes old sessions, and if you opt into team sharing during cogit init, titles, decisions and reasons are pushed with git push to your own repository outside your branches, so they never appear in a pull request or git status.

  1. A developer juggling 5-10 concurrent agent sessions across 2-3 repositories who loses track of where a decision landed: open the map, read the branches and the left off here marker, and use Resume.
  2. A reviewer who sees the diff but not the reasoning: read the Intent/Shape/Code tabs for why the change happened and what shape it takes, or run cogit why on a line.
  3. A team that wants PR descriptions stating the goal and the rejected options: generate them with cogit pr and post them automatically via cogit pr --install-action.
  4. Someone reopening a file months later: the Files view shows every message that touched it, the reason behind each, and the option that was rejected.
  5. A team using git as the sharing channel: after a pull, teammates' sessions appear on the map with who ran them and what changed most.
  6. Automated runs such as claude -p loops or sandboxed agents: bring them into the same thought-commit record.

Key setup facts

Pulled from the install and usage notes below. The project README has the current values.

Install / run
  • npm install -g @cogit/cli
Runtime
Node.js 22.13+

How do you install or deploy this agent?

Requires Node 22.13+, an existing git repository, and Claude Code 2.1.275+ or Codex CLI 0.167+. Install the CLI globally from npm:

npm install -g @cogit/cli

In Claude Code, install the plugin from the marketplace:

/plugin install cogit --marketplace erensrtky/cogit

For plugin updates on their own, turn on auto-update once via /plugin → Marketplaces → cogit → Enable auto-update (Claude Code leaves it off for marketplaces outside its own).

In Codex, from a terminal:

codex plugin marketplace add erensrtky/cogit --sparse .agents
codex plugin add cogit@cogit

Then start Codex in a project and accept the hooks review it shows; Codex asks again after every cogit update. If the map stays empty, run cogit doctor.

How do you use this agent?

Initialise inside the project where you already work with your agent:

cd your-project
cogit init

init asks a few questions (git, transcript retention, team setup, language). Work with Claude Code or Codex as usual — recording needs nothing from you — then open the map:

cogit open .

Follow a commit or a line back to its reason:

cogit why
cogit blame
cogit show <sha>
cogit log
cogit search

Enable the optional end-of-session task capture (off by default):

cogit config set captures true

Generate a pull-request description with decisions and rejected options, and optionally install the GitHub Action:

cogit pr
cogit pr --install-action

Safety boundaries, hardening & integrations

Operational blast radius, source-verified safety controls, and first-run hardening steps before connecting this agent to real workspaces.

Declared capability surface (blast radius)

Local shell command execution

Can run terminal commands; pair with approval gates or container/OS sandboxing.

Local filesystem read/write

Modifies local files; work on a clean Git branch or dedicated worktree.

Outbound network access

Makes outbound requests; verify telemetry settings and model data routing on private repos.

FARS trust-control audit

Verified present in source (3/3)
  • data-flow disclosure
  • verifiable attribution

What are this agent's strengths and limitations?

Pros
  • A complete lineage from code to cause: a Thought: trailer on every commit plus cogit why, blame, show, log and search to follow it.
  • Recording happens through the agent's hooks while you work, so decisions, rejected options and continuation links survive instead of being reverse-engineered from a diff.
  • Local-first: no server, no account, chats stay on your machine, key and token patterns are redacted, cogit prune removes old sessions, and sharing needs explicit consent in init.
  • Team sharing does not pollute the repository: the record is pushed to your own remote outside your branches, so it never shows in a pull request or git status.
  • Two runtimes supported out of the box, each with a documented install path: a Claude Code plugin and a Codex CLI plugin.
  • Explicit cost controls: a background small model writes the record, and Economical mode measured under 2 cents per 20 messages by the author.
Limitations
  • Recording depends on the hook systems of Claude Code or Codex CLI; no other editor or agent has a documented integration.
  • Hard prerequisites: Node 22.13+ and a git repository, so work outside git cannot be recorded.
  • Codex re-asks for the hooks review after every cogit update, requiring manual re-approval.
  • By default the session's own model reopens the whole conversation to correct the record, adding token cost; Economical mode trades that quality for the small model.
  • Young project with a single maintainer, and Claude Code keeps auto-update off for third-party marketplaces, so you must enable it manually.

How does this agent compare with similar options?

Key facts side by side with the most closely related agents.

Agent Source review Form / cost Stars Updated Language Full support on
cogit This agent 75 · Good — ★ 222 1d ago TypeScript Codex · Claude Code
OSS Autopilot 80 · Good Agent plugin / skillFree ★ 30 today TypeScript Claude Code · Claude.ai
Claude Council 73 · Some gaps Agent plugin / skillFree + model costs ★ 969 11d ago Shell Claude Code · OpenAI API · Claude API
Claude Octopus 71 · Some gaps Agent plugin / skillFree + model costs ★ 4.5k today Shell Codex · Claude Code · OpenAI API · Claude API

How does FollowAgents rate this agent?

FollowAgents source review · FARS-2.1
Good
75/ 100 5-point scale 3.8 / 5
Trust 21/29
Reliability 9/14
Adaptability 15/18
Convention 14/18
Effectiveness 10/13
Verifiability 6/8
Why each dimension lost points
Trust21 / 29 · 3.6/5

Least privilege: SKILL.md narrows the skill with allowed-tools to node dist/cli.js plus Edit under .cogit/inbox, and server.ts binds 127.0.0.1 only, validates the Host header, gates /api/config behind a per-server token, caps the body at 4096 bytes and serves only registry-listed project paths (pageTarget/registeredRoot) — real, visible narrowing. Deducted because init by default auto-allows the cogit skill permission and writes .claude/settings.json, i.e. default privilege expansion. User confirmation: init defaults sharing, transcript retention and graph building to no with --yes/--no-* overrides, and prune asks first; deducted because the permission grant and project-settings write happen without asking. Data-flow transparency: privacy.md enumerates every network call (side model, closing pass, one daily npm version query), what is recorded, what stays local, and what sharing pushes via refs/cogit/, and states plainly that hidden is not private — full marks. Sensitive data: secretlint recommended rules plus custom CLI-password patterns, shareConversations off by default with a public-repo warning; deducted because the doc itself calls redaction a safety net, not a guarantee, and unknown secret shapes pass through. Dependency security: only root devDependencies with caret ranges are visible; no lockfile, audit, dependency review or runtime dependency list in the packet, so supply-chain control is unproven — 1. External effects: installs git hooks, pushes to refs/cogit/, optionally installs a GitHub Action, makes a daily npm query and runs a local server on 4747; all documented and sharing is opt-in, but hook installation and post-share pushes sit on the default path — 2. Rollback: COGIT_DISABLE, cogit hooks uninstall, removing .cogit/, prune confirmation, plus the interrupted-session mark and backfill recovery; deducted because prune is irreversible, copies on teammates' machines persist, and a wrong record has no undo — 2. Source attribution: the Thought: trailer links commits to messages, author/authorEmail stamping is implemented and tested (sameAuthor), and this is the product's core — 3.

Reliability9 / 14 · 3.2/5

Self-consistency: README and getting-started claim Codex CLI support with install steps and the tests reference AGENTS.codex, yet faq.md states 'Does it work with agents other than Claude Code? Not yet.' That is a directly pointable contradiction between shipped docs — 1. Dependency availability: Node >=22.13, npm global install, and a tag-triggered CI job that builds the plugin branch are all clear; deducted because the marketplace points at a movable plugin branch and no lockfile evidence is in the packet — 2. Failure messages: troubleshooting.md covers empty maps, nothing recorded, port conflicts, EALLOWREMOTE and sandbox-lost settings; cogit doctor prints ok/warn/fail with a fix command and exits 1 for scripting; SKILL.md requires quoting sessionError and stopping — 3.

Adaptability15 / 18 · 4.2/5

Audience and scenarios: solo use, team sharing, PR review, and headless loops/sandboxes/agent factories each have dedicated documentation — 3. Capability boundaries: the README's 'cogit isn't' list separates it from memory tools, token savers, code maps, orchestrators and review bots, and the FAQ admits the removed per-edit note and the unresolved conflict-reasoning gap — 3. Trigger precision: the SKILL.md description and its 'Check first' branches (initialized/sessionError/newMessages) are explicit, but recording is mostly hook- and background-model-driven and the user-facing trigger conditions are thin — 2. Environment fit: Windows process-tree limitation with COGIT_RECORD=1, sandbox/container persistence of .cogit and the Claude directory, COGIT_HOME, cache dirs and configurable port are all documented; deducted because Windows and volume-less containers are genuine functional gaps — 2.

Convention14 / 18 · 3.9/5

Information architecture: README plus topic-split docs/guide plus docs/format.md is clearly layered — 3. Install notes: separate Claude Code and Codex paths, split update flows, version requirements and the EALLOWREMOTE migration are all written down — 3. Naming stability: cli.ts shows a silent codelineage-to-cogit migration, so a rename did occur; it is handled, but naming has not been stable — 2. Examples and FAQ: screenshots, a clickable demo, quick start and a substantial FAQ — 3. Known limitations: FAQ, the 'What cogit cannot cover' section, the redaction caveat and the Windows note — 3. License: MIT LICENSE file matches the badge — 3. Versioning/changelog: no CHANGELOG in the packet, only an npm badge, v* tags and scattered 0.18/0.19 notes in troubleshooting — 1. Maintenance responsibility: a named owner, an issue link and CI exist, but the publisher is unverified by FollowAgents, there is no SECURITY/CONTRIBUTING/governance file, and it is a single maintainer — 1.

Effectiveness10 / 13 · 3.8/5

Output usability: a static map.html, cogit why/blame/show/search, the Intent/Shape/Code layering and cogit pr producing a paste-ready PR body — 3. Marginal value: differentiation from adjacent tools is argued and the FAQ honestly says the gain is smaller if your own log already covers it; deducted because the value case rests on the author's own account with no independent comparison — 2. Cost/benefit: self-reported figures (about one extra message in Quality mode, under 2 cents per 20 messages in Economical) are given, but without measurement method or data — 2.

Verifiability6 / 8 · 3.8/5

Claim traceability: most claims point at specific documents (why.md, privacy.md, format.md), but cost and benefit numbers are only 'in our measurement' with no data behind them — 2. Cross-source corroboration: README, guides, tests (agents.test.ts, author.test.ts, backfill.test.ts) and server.ts corroborate many behaviours; deducted because Codex support is contradicted between the FAQ and the README/tests — 2. Fact/inference separation: the docs repeatedly separate recorded fact from model inference ('a model's reading of the conversation', Shape drawn from the diff rather than the reasoning, redaction as a safety net not a guarantee) — 3.

Risks and how to mitigate them
  • The FAQ states cogit does not yet work with agents other than Claude Code, directly contradicting the README, getting-started Codex instructions and the AGENTS.codex references in tests; confirm the real Codex support status before adopting.
  • The publisher is unverified by FollowAgents and the project is single-maintainer with no SECURITY/CONTRIBUTING or governance file; supply-chain and security-response capability are unknown.
  • No lockfile, dependency audit or runtime dependency list is visible in the packet, so dependency security cannot be confirmed from the evidence.
  • cogit init auto-allows the cogit skill permission and writes .claude/settings.json by default — a default privilege expansion; --no-allow-skill / --no-project-settings turn it off, but only if chosen.
  • Shared records are pushed on refs/cogit/, and the docs themselves say hidden is not private: anyone who can read the repository can download titles, decisions and reasons, so a public repo means a public record.
  • Redaction is best-effort (secretlint plus custom patterns) and the docs admit unknown secret shapes get through; do not treat cogit as a secret-leak control.
  • Windows does not read the process tree and volume-less containers discard the record — documented but real functional gaps.
  • There is no CHANGELOG; version history must be inferred from tags and scattered version notes in troubleshooting.
Evidence confidence: Low Reviewed Nov 28, 2026 Reviewed revision 56b5d828dda7
See the full review method →
Maintain this project? Add the FARS badge to your README

The badge shows the current review score and verdict and links back to this page. It refreshes about once an hour after a re-review.

FARS

[![FARS review](https://followagents.com/badge/cogit.svg)](https://followagents.com/en/agents/cogit)
<a href="https://followagents.com/en/agents/cogit"><img src="https://followagents.com/badge/cogit.svg" alt="FARS review"></a>
Was this page helpful?
View on GitHub ↗ Install ↓

Host ecosystems

Compare agents like this one

The same FARS review applied across the shortlist this agent qualifies for.

Related concepts