Claude Code
docs/backends.md · main
Dark Matter runs agents on the command-line tools you already have. It does not ship a model, hold a model credential of its own, or route your work through a server of ours: every session is a process on your Mac, started from your own seat, spending on your own subscription or key.
What the app looks for
Two commands, on the PATH a session would actually get:
| Backend | Command | Where its model lineup is read from |
|---|---|---|
| Claude Code | claude | ~/.claude/settings.json, and the repository's own .claude/settings.json and .claude/settings.local.json |
| Codex | codex | ~/.codex/config.toml |
The app looks for an executable file rather than running anything, so a picker opening on a machine that is already running six agents does not start a seventh process to ask each CLI its version.
Codex is wired and not yet proven. Its adapter is written against the documented
codex exec --json stream, and every fixture for it is hand-authored from that documentation
rather than recorded from a live run, because no machine this product has run on has had codex
installed with a seat behind it. It is registered as a named gap. If you have one, the Floor will
offer it; if it misbehaves, that is the gap and not your install.
The PATH a session gets
An app opened from Finder inherits launchd's environment, whose PATH is /usr/bin:/bin:/usr/sbin: /sbin and nothing else — no Homebrew, no nvm, no ~/.local/bin, no ~/.claude/bin. So the app
asks your login shell for its PATH once at startup and hands that to every process it spawns.
It asks an interactive login shell ($SHELL -ilc), because a PATH set in .zshrc rather than
.zprofile is only there for an interactive one — and nvm, mise and asdf all put theirs
there. A shell that does not answer within two seconds is not a reason to refuse to launch: the app
falls back to its own PATH widened by /usr/local/bin, /opt/homebrew/bin, ~/.local/bin and
~/.claude/bin, which reaches Homebrew, which is where most installs are.
To see what the app will see:
$SHELL -ilc 'which claude codex git'
If that finds nothing, the app will not find it either. Install the CLI, or add its directory to your shell profile.
The same check is a row in pnpm dm:doctor (agent-cli). It is never red: a machine without
either CLI is a fact about a computer, not a defect, so the row says which it found and where, or
that Attach on the Floor has nothing to offer.
What a session is given
An agent's environment is cut from yours rather than inherited whole. It gets PATH, HOME, the
user and shell variables git and the CLI need, and the locale — and nothing else from the app's
own process. HOME is the seat: it is where the CLI's own credentials, its settings and your
.gitconfig live, and it is why a session commits as you and spends as you.
Each session runs in its own worktree, cut beside your repository — never inside it — so the tree you are working in is never the tree an agent is writing to.
How many at once. Six sessions may run at a time by default, and eight is the ceiling no
setting may exceed; six agent CLIs on a laptop is already most of it. DM_MAX_SESSIONS changes
the default, up to that ceiling.
Models
Nothing in Dark Matter names a model version. The picker on a session is built from the files the
CLI itself reads — your curated lineup where you have written one, the aliases the CLI documents
(sonnet, opus, haiku, fable) otherwise — so the day the next model ships, the picker is
already right and no release happened. The effort control passes --effort through and lets the
CLI clamp it to what the chosen model supports.
The optional key
The Chief of Staff — the assistant that answers questions in the app — runs on this machine's Claude Code seat unless you give it a key of its own. The key is optional. When you enter one under Settings → This machine, it is held by this Mac's keychain and read only by Dark Matter itself: never sent to the Brain, never written to a database, and never printed in a log. Where the keychain cannot be reached, the app says so and stores nothing.
What leaves the machine
Nothing about your seat. The app's server holds the work ledger, the board and the decisions; it never sees a model credential, a session's environment, or the contents of your keychain. Model spend is yours end to end.