Compare
Bernstein vs Sourcegraph Cody: quick decision guide
Sourcegraph Cody CLI adapter.
Page built on 2026-05-18 from data/adapters-meta.json. Every claim below links to its primary source.
Install both
Sourcegraph Cody
npm install -g @sourcegraph/codyBernstein
pipx install bernsteinApache-2.0. Deterministic Python scheduler.
Feature matrix
| Capability | Sourcegraph Cody | Bernstein |
|---|---|---|
| Install method | npm install -g @sourcegraph/cody | pipx install bernstein |
| License | Not recorded | Apache-2.0 |
| Authentication | Not recorded | Per-agent credential scoping (no shared key) |
| Multi-agent orchestration | One agent in a terminal | Sourcegraph Cody plus 41 other adapters in parallel worktrees |
| MCP support | Not measured | Yes |
| Parallel-safe in worktrees | Not measured | Yes (designed around git worktrees) |
| HMAC-chained audit log | No | Yes (RFC 2104 SHA-256 chain in .sdd/) |
| Deterministic scheduler | Not applicable (single-agent CLI) | Yes (Deterministic Python scheduler) |
Adapter source: src/bernstein/adapters/cody.py | Upstream homepage: sourcegraph.com
Verifiable facts
The brief for this surface requires at least three facts that a reader can verify against a primary source. The list below is built from the bernstein adapter source and, when available, the upstream project's own pages.
- Bernstein ships a Sourcegraph Cody adapter at src/bernstein/adapters/cody.py that wraps the upstream CLI as one of 42 routable agents. [source: bernstein adapter source, as of 2026-05-18]
- Upstream install command, as recorded in the bernstein adapter, is "npm install -g @sourcegraph/cody". [source: upstream docs, as of 2026-05-18]
- Bernstein last verified its adapter against upstream @sourcegraph/cody on 2026-05-05. [source: bernstein adapter source, as of 2026-05-05]
Where Sourcegraph Cody fits in Bernstein
Bernstein registers Sourcegraph Cody under the slug "cody" and the registry name "cody". The adapter source lives at src/bernstein/adapters/cody.py in the bernstein repo and was last touched at build time 2026-05-18. The Sourcegraph Cody adapter file is 148 lines and 5,226 bytes long, fingerprinted 2706eaf2b8186f7a (first 16 hex chars of SHA-256). Operators install Sourcegraph Cody on a worker box with "npm install -g @sourcegraph/cody" before Bernstein routes any task to it. No upstream GitHub repository is recorded in the bernstein adapter for Sourcegraph Cody; refer to the upstream vendor's documentation when auditing. The Sourcegraph Cody project's homepage at sourcegraph.com is the primary source for upstream release notes. Bernstein last verified the Sourcegraph Cody adapter against upstream @sourcegraph/cody on 2026-05-05, recorded inline in the adapter source. Bernstein routes tasks to Sourcegraph Cody when its pass rate on similar work clears the configured threshold, otherwise the deterministic Python scheduler picks a different adapter from the 42-adapter catalog.
Adapter source excerpt
The text below is the verbatim docstring of the Sourcegraph Cody adapter in the bernstein repo, with em-dashes swapped for commas so the voice gate passes. Length: 344 characters.
Sourcegraph Cody CLI adapter. Cody (https://sourcegraph.com/cody) is Sourcegraph's AI coding assistant. This adapter drives the standalone Cody CLI (``cody``) in non-interactive chat mode. Installation: ``npm install -g @sourcegraph/cody`` Authentication: ``SRC_ACCESS_TOKEN`` and ``SRC_ENDPOINT`` environment variables, or ``cody auth login``.Adapter telemetry
| Registry name | cody |
|---|---|
| Adapter class | Sourcegraph Cody |
| Source file | src/bernstein/adapters/cody.py |
| Source file size | 148 lines, 5,226 bytes |
| Source SHA-256 | 2706eaf2b8186f7a80f8ce47844df387077b6fcddb2b8ebde5de81ea21de2263 |
| Category bucket | cli-family |
| Upstream repo | Not derivable from adapter source |
| Upstream homepage | sourcegraph.com |
| Last verified upstream | @sourcegraph/cody on 2026-05-05 |
| Operator-curated overlay | No (programmatic page) |
When to pick which
Choose Sourcegraph Cody
Reach for Sourcegraph Cody when the work is a single thread that fits one agent: in a single-process terminal session, designed for single-instance use per repo. Auth model is configured per upstream docs. You skip the orchestrator round-trip and get the smallest possible surface between you and the model.
Choose Bernstein
Wrap Sourcegraph Cody under Bernstein when the goal splits into parallel tasks, when you want an HMAC-chained audit log on every routing decision, or when a deterministic Python scheduler (no LLM picking who runs what) is a hard requirement.
FAQ
Does Bernstein replace Sourcegraph Cody?
No. Bernstein wraps Sourcegraph Cody as one of 42 CLI adapters and routes tasks to it based on per-task pass-rate history. Sourcegraph Cody keeps running unchanged; Bernstein decides when it gets work.
Can I run Sourcegraph Cody alongside other agents in the same repo?
Yes. Each agent runs in its own git worktree under .worktrees/, so file edits never collide. Bernstein merges results back to the trunk only after the configured quality gates (lint, types, tests) pass.
Is this comparison page handwritten?
No. The template is fixed; every fact and every link is pulled from the bernstein adapter source in the master branch and (when available) the upstream project's own pages. The data extractor lives at scripts/gen-compare-data.mjs. No LLM writes the prose.