modus-lisp

Operandi — AI skill for Claude Code

AI community

A Lisp-native ReAct agent loop — Claude Code in Common Lisp.

How to install Operandi

This entry records only its repository, not the path inside it, so there is no exact command to give. Open modus-lisp/operandi and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Operandi does

A Lisp-native ReAct agent loop — Claude Code in Common Lisp. Local or frontier model drives a tool-calling loop (files, shell, web, and live Lisp eval), architected for self-improvement.

Alternatives in AI

  • Artifacts Builder — Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web tech 97.5k ★
  • Sentrux — Real-time architectural sensor that helps AI agents close the feedback loop, enabling recursive self-improveme 2.9k ★
  • Vllm Mlx — High-performance OpenAI and Anthropic compatible LLM inference server for Apple Silicon 1.5k ★

README

operandi

A Lisp-native ReAct agent loop — "Claude Code in Common Lisp."

A small local LLM (llama.cpp) or a frontier model (via OpenRouter) drives a tool-calling loop against the OpenAI-compatible `/v1/chat/completions` protocol. The agent reads/writes/edits files, runs shell commands, searches code and the web — and, the sharp edge, **evaluates arbitrary Common Lisp in the running SBCL image**, so it can call straight into whatever domain packages the host application has loaded.

Quick start

`bin/operandi` is the entry point. It dumps a **core image** with operandi baked in and launches from it with the init files skipped, so a run costs ~20 ms of launcher overhead instead of ~16 s of Quicklisp loading (the model preflight adds a network round-trip on top). The core (`operandi.core`, gitignored) is built on first run and rebuilt automatically whenever a source file changes.

bin/operandi                                      # interactive TUI (the default)
bin/operandi "summarize what's in this directory" # one-shot task
bin/operandi -p "summarize this directory"        # same, prompt spelled out
bin/operandi --openrouter deepseek/deepseek-v4-flash "task"
bin/operandi --openrouter deepseek/deepseek-v4-flash --effort low --repl

With no prompt at all, `bin/operandi` opens the TUI. The default backend is a local llama.cpp on `http://localhost:9931`; `--openrouter` switches to OpenRouter (token at `~/.operandi/openrouter.token`).

`--local ADDR` names that backend explicitly and points it at another server: llama.cpp, ds4, `illatio --serve`, anything that speaks `/v1/chat/completions` (`--llama` is an older name for it). ADDR is the server's address, not a model — a local server usually has exactly one model loaded, so there is nothing to name:

bin/operandi --local :9931 "task"                   # localhost:9931
bin/operandi --local localhost:9931 "task"          # same thing, spelled out
bin/operandi --local http://box:9931 "task"         # anoth