Skip to content

Latest commit

 

History

48 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Forge

Forge

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.

Features

  • 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

Installation

git clone https://github.com/mm4cN/forge.git
cd forge

python -m venv .venv
source .venv/bin/activate

pip install -e .

Ollama

ollama serve
ollama pull qwen2.5-coder:7b

Gemini

export GEMINI_AUTH_KEY="..."

Quick Start

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 chat

Review current changes:

forge review

Model Management

forge model list
forge model get

forge model use ollama qwen2.5-coder:7b
forge model use gemini gemini-2.5-flash

Tracking

Model usage:

forge usage SESSION_ID

Tool execution history:

forge tools SESSION_ID

Safety

Forge 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 false

Configuration

Forge stores its state under:

~/.forge/

Example:

provider = "ollama"
default_model = "qwen2.5-coder:7b"
approval_mode = true

Next

  1. Context size telemetry
  2. Session summaries
  3. Context builder

Future

  • Read-only review agent
  • Project memory embeddings
  • Multi-project awareness

NTH

  • MCP definition

License

MIT

About

Forge is a lightweight local coding agent

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages