About this project
Mica Code (MICA — Minimal, Intelligent, Cache-first Agent) is a lightweight, terminal-native AI coding agent whose core design goal is to reuse context and maintain a high cache hit rate.
Key features:
- Prefix stability, cache-first: sessions are append-only by default, locking the system/history prefix as much as possible so long conversations can still maintain a high cache hit rate.
- Terminal-native: an Ink-based TUI, keyboard-first, with multiple agents, background tasks, and status displayed in a centralized view.
- File references: typing @ searches files in the current workspace; use arrow keys to select and Enter or Tab to insert.
- Role as workflow: /role replaces the entire system prompt, allowing different personas to be configured for coding, review, and planning.
- Composable tools: built-in file, search, shell, web, skills, and other tools, with support for connecting personal scripts and team services via MCP.
- Rewindable, compactable, schedulable: /rewind returns to a historical conversation node and can restore files when file checkpoints exist; /compact by default only replaces tool results with placeholders, while /compact llm uses model summarization; /loop can execute tasks repeatedly at fixed intervals.
Installation and configuration:
You can install via the install.sh script from GitHub Releases and run mica. On first run, ~/.mica/config.json is created; use /config to open the configuration page. Configuration supports multiple providers, with protocol options openai_chat_completions or openai_responses; you can configure get_model_url to dynamically fetch the model list, or directly configure a static models array; mcpServers is also supported.
Command-line interface:
- mica exec: one-shot headless execution, with a protocol aligned with OpenAI Codex, supporting --json output of ThreadEvent JSONL, --thinking, --no-save, --session, --dir, --mcp-init-timeout-ms, and other parameters.
- mica compact: performs context compaction on an existing session, supporting --force, --prune-only, --tool-results-only, and outputs JSON containing token estimates and compaction ratios.
- mica commit: reuses the deterministic analysis logic of the interactive /commit, sends only one request to the model to generate a commit message, then executes git add/commit/push and outputs JSON.
- mica app-server: a persistent session process that exposes a subset of the Codex v2 App Server protocol and supports iterative injection via turn/steer.
This project is suitable for developers who want to use an AI coding assistant within the terminal and care about context cache efficiency and scriptable invocation.
Comments
0 Rating appears after 10 ratings
Sign in to join the discussion.