No description
  • Scheme 92.3%
  • Shell 2.3%
  • Rust 2%
  • Kotlin 1.4%
  • C 1%
  • Other 1%
Find a file
2026-07-30 15:46:01 -06:00
.jerboa Harden code-agent release evidence privacy 2026-06-25 17:30:59 -06:00
android Add MCP call log and reply timing UI 2026-06-03 10:02:21 -06:00
docs docs: OpenRouter routing, security controls, tool guards 2026-07-24 23:20:54 -06:00
eval/local-model Security hardening and release readiness 2026-06-23 10:49:05 -06:00
scripts Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
src/jcode fix ds4 2026-07-27 14:19:25 -06:00
support fix ds4 2026-07-27 14:19:25 -06:00
test fix ds4 2026-07-27 14:19:25 -06:00
themes tui: salvage glm-5.1 improvements; drop broken/unused code 2026-05-07 20:09:55 -06:00
tools Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
vendor-overrides fix ds4 2026-07-27 14:19:25 -06:00
.build.yml ci: set umask 022 in package/verify tasks too (jerbuild creates group-writable cache dirs during pkg operations) 2026-07-22 13:10:54 -06:00
.gitignore jpkg: add package lock 2026-07-30 15:34:09 -06:00
.jerbuild Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
.jerbuild.freebsd-amd64 Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
.jerbuild.linux-amd64 Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
.jerbuild.linux-arm64 Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
AGENTS.md docs: remove jerboa-emacs restriction 2026-07-30 15:46:01 -06:00
build-jcode-cross.ss Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
build-jcode-freebsd-cross.ss Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
build-jcode-musl.sh Update SQLite repository references 2026-07-19 12:49:25 -06:00
build-jcode-musl.ss Update SQLite repository references 2026-07-19 12:49:25 -06:00
CLAUDE.md CLAUDE.md: act first, read less — stop over-researching before acting 2026-04-29 14:29:33 -06:00
cleanup.md tui: center message layout; add harness fuzzer 2026-07-22 12:15:12 -06:00
jcode-better.md provider: OpenRouter auto-router support + .ss write guard + /security 2026-07-24 21:44:46 -06:00
jerboa.pkg initial pass 2026-04-08 20:19:17 -06:00
jpkg.lock jpkg: add package lock 2026-07-30 15:34:09 -06:00
jpkg.policy.sexp Add jpkg package CI 2026-06-18 16:32:16 -06:00
jpkg.sexp Add jpkg package CI 2026-06-18 16:32:16 -06:00
LICENSE Switch to MIT license 2026-07-21 13:41:54 -06:00
linux-check.ss Update SQLite repository references 2026-07-19 12:49:25 -06:00
main-binary.ss fix ds4 2026-07-27 14:19:25 -06:00
main.ss Security hardening and release readiness 2026-06-23 10:49:05 -06:00
Makefile fix ds4 2026-07-27 14:19:25 -06:00
README.md Security hardening and release readiness 2026-06-23 10:49:05 -06:00
repl-reader.ss Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
rust-toolchain.toml Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
SECURITY.md Harden remote tools and native dependencies 2026-07-11 17:22:54 -06:00
vendor-lock.env Update SQLite repository references 2026-07-19 12:49:25 -06:00

jerboa-code

A portable AI coding agent written in Jerboa Scheme.

jcode is a terminal coding agent — think opencode / aider / Claude Code — that compiles to a standalone binary without a Node or Python runtime. It talks to 14 LLM providers (cloud and local), drives your editor through a real tool loop, and ships a reliability layer that makes even small self-hosted models call tools dependably.

┌────────────────────────────────────────────────────────────────┐
│ jcode                                          BUILD · sonnet    │
│                                                                  │
│   add a --json flag to the status command                       │
│                                                                  │
│  ● read   src/cli.ss                                             │
│  ● edit   src/cli.ss  (+12 1)                                   │
│  ● bash   make test            411 passed, 0 failed              │
│                                                                  │
│  Done — `--json` emits the status block as a JSON object.        │
└────────────────────────────────────────────────────────────────┘

Why it exists

  • Portable. One standalone binary. Runs on macOS, Linux, FreeBSD, and Android (via Termux). No Node, no Python, no ecosystem.
  • Provider-agnostic. Anthropic, OpenAI, Google, OpenRouter, DeepSeek, xAI, Groq, Mistral, Together, Cerebras, Perplexity — plus local Ollama and MLX. Switch with /model mid-session.
  • Reliable on small models. A native port of forge plus ATLAS-style verify-and-repair wraps every call: prose-to-tool rescue, step enforcement, verify-gate, and best-of-k. Always on, every provider.
  • Delegation built in. Named sub-agent roles for the task tool — read-only delegate, docs-scoped doc-explorer, gated implementer (BLUEPRINT → approve → EXECUTE) — with enforced write scopes, per-agent model routing via jcode.json, and plan-lifecycle skills (create-plan / resume-plan / generate-handover). See docs/agents.md.
  • A real TUI. termbox-based panels, markdown + syntax highlighting, live diffs, themes, a sidebar with token / cost / GPU stats.

Quickstart

You need a C compiler and Rust/Cargo. make build and make binary use a local Jerboa toolchain when present, otherwise they fetch the configured release bundle into .jerboa/bin. See docs/getting-started.md for the full setup.

git clone https://git.sr.ht/~lisp/jerboa-code && cd jerboa-code

make build          # compile src/ → lib/
make binary         # produce the standalone ./jcode
./jcode keys add anthropic     # store an API key (encrypted)

./jcode              # interactive REPL
./jcode --tui        # full terminal UI
./jcode -p "explain this repo"   # one-shot prompt

Documentation

Doc What's in it
Getting started Prerequisites, building on every platform, configuration, keys, first run.
CLI reference Every subcommand, flag, slash command, and environment variable.
Architecture The agent loop, module map, and how a turn flows through the guardrails.
Providers & models The 14 providers, model registry, per-model sampling, and hardware tiers.
Tools The agent's toolbox (file, bash, web, git, patch, task, MCP) and the safety model.
Named agents & plans Sub-agent roles with enforced write scopes, per-agent models, gated execution, and the plan-lifecycle skills.
Verify-gated runs jcode verified, cookbook-guided local-model runs, MCP tools, write scopes, JSON status, and troubleshooting.
TUI Layout, keybindings, themes, and the rendering features.
Forge & ATLAS reliability Guardrails, workflows, verify-gate, best-of-k, the proxy, and the eval harness.
Remote & Android serve / relay / connect and the thin-client architecture.
Threat model Assets, trust boundaries, controls, and residual risks for production use.
Credential handling API key sources, storage, logging, tracing, and release checks.
FFI boundary Native components, ownership rules, generated artifacts, and audit procedure.
Release evidence SBOM, reproducibility, binary smoke, and release-bundle contents.

See docs/ for the full index.

Build targets

make build · test · audit · sbom · reproducibility-report · release-evidence · run · run-tui · binary · install · linux · linux-amd64 · linux-arm64 · freebsd · android. Run make help for the complete list.

Layout

main.ss              entry point
src/jcode/
  core/       agent loop, config, sessions, guardrails plumbing, ATLAS
  provider/   the 14 LLM providers + per-model sampling
  tool/       file, bash, web, git, patch, task, repomap, lsp
  guardrails/ rescue, validator, step-enforcer, respond, error budget
  proxy/      OpenAI-compatible guardrail proxy
  eval/       deterministic ablation harness
  ui/         cli, tui-*, serve/relay/connect
  mcp/        MCP client

Source is Jerboa .ss, compiled by jerbuild to Chez .sls under lib/. See AGENTS.md for the language reference and CLAUDE.md for contributor conventions.