Lightweight coding agent for local and hosted LLM workflows.
Forge is a local-first coding assistant designed for developers who want transparent tool execution, persistent sessions, and full control over their workflow.
- Multiple providers
- Ollama
- Gemini
- OpenRouter
- Agent and non-agent modes
- Interactive chat sessions
- Persistent SQLite-backed history
- Workspace-aware tools
- File search and editing
- Shell command execution
- Git integration
- Code review command
- Model usage tracking
- Tool execution tracking
- Approval mode for destructive actions
git clone https://github.com/mm4cN/forge.git
cd forge
python -m venv .venv
source .venv/bin/activate
pip install -e .ollama serve
ollama pull qwen2.5-coder:7bexport GEMINI_AUTH_KEY="..."Ask a model:
forge ask "Explain RAII in C++"Run the agent:
forge agent \
"Create a basic CMake project and build it"Interactive chat:
forge chatReview current changes:
forge reviewforge model list
forge model get
forge model use ollama qwen2.5-coder:7b
forge model use gemini gemini-2.5-flashModel usage:
forge usage SESSION_IDTool execution history:
forge tools SESSION_IDForge requires confirmation before executing potentially destructive actions.
Protected tools:
- write_file
- edit_file
- replace_in_file
- run_command
Example:
Tool approval required: write_file
Approve? (y/N):
Enable or disable approval mode:
forge approval true
forge approval falseForge stores its state under:
~/.forge/
Example:
provider = "ollama"
default_model = "qwen2.5-coder:7b"
approval_mode = true- Context size telemetry
- Session summaries
- Context builder
- Read-only review agent
- Project memory embeddings
- Multi-project awareness
- MCP definition
MIT