gen-code
Health Pass
- License — License: Apache-2.0
- Description — Repository has a description
- Active repo — Last push 0 days ago
- Community trust — 12 GitHub stars
Code Fail
- rm -rf — Recursive force deletion command in install.sh
Permissions Pass
- Permissions — No dangerous permissions requested
An open-source AI coding assistant that runs in your terminal, supporting multiple LLM providers, MCP integration, and sub-agent orchestration.
Security Assessment
Overall risk: Medium. The agent features built-in tools like Bash, meaning it is explicitly designed to execute shell commands and edit files based on AI outputs. It also connects to external APIs (Anthropic, OpenAI, etc.) using environment variables for keys. No hardcoded secrets or overly broad system permissions were found, which is good. However, the automated installation script flags a critical warning: it contains a recursive force deletion command (`rm -rf`). Piping `curl` directly to `bash` is always risky, and destructive commands in such scripts can cause severe system damage if poorly handled or maliciously altered. Using the Go install method is significantly safer.
Quality Assessment
The project is quite new but actively maintained, with recent repository pushes. It uses the permissive and standard Apache-2.0 license. As an emerging tool, community trust is currently low, reflected by only 12 GitHub stars. The Go Report Card integration suggests a baseline standard of code quality and testing.
Verdict
Use with caution — consider bypassing the risky install script by building from source, and carefully monitor the tool's automated shell execution during active coding sessions.
Open-source AI agent. Lives in your terminal.
Gen Code
< GEN ✦ />
Open-source AI coding assistant for the terminal
Open-source AI coding assistant for the terminal built with Go. Multi-provider LLM support, event-driven multi-agent orchestration, and full compatibility with Claude Code extensions, plugins, and project instructions.
Features
- Multi-provider — Anthropic, OpenAI, Google, Moonshot, Alibaba, MiniMax — switch with
/model - Tools & MCP — Built-in tools (Edit, Bash, Glob, Grep, WebSearch, etc.) + MCP integration
- Skills, Subagents & Plugins — Claude Code compatible format, marketplace install
- Event-driven multi-agent — Parallel agent execution with decoupled event-based coordination
- Hooks — Lifecycle extensibility via shell, LLM, agent, or HTTP hooks
- Session — Auto-persist, resume, fork, auto-compact
- Performance — Minimal context injection, fast response, low token consumption
- Other — Prompt prediction, configurable thinking effort, scheduled loops, permission control, etc.
Providers
| Provider | Models | Environment Variables |
|---|---|---|
| Anthropic | Claude Opus 4.6, Sonnet 4.6 | ANTHROPIC_API_KEY or Vertex AI |
| OpenAI | GPT-5.2, GPT-5, o3, o4-mini, Codex | OPENAI_API_KEY |
| Gemini 3 Pro/Flash, 2.5 Pro/Flash | GOOGLE_API_KEY |
|
| Moonshot | Kimi K2.5, K2 Thinking | MOONSHOT_API_KEY |
| Alibaba | Qwen3.5 Plus, Qwen3 Max/Plus/Flash, QwQ, DeepSeek-V3/R1 | DASHSCOPE_API_KEY |
| MiniMax | M2.7, M2.7 Highspeed, M2.5, M2.5 Highspeed, M2.1, M2.1 Highspeed, M2 | MINIMAX_API_KEY |
Installation
curl -fsSL https://raw.githubusercontent.com/genai-io/gen-code/main/install.sh | bash
Re-run to upgrade. To uninstall:
curl -fsSL https://raw.githubusercontent.com/genai-io/gen-code/main/install.sh | bash -s uninstall
Other methods
Go Install
go install github.com/genai-io/gen-code/cmd/gen@latest
Build from Source
git clone https://github.com/genai-io/gen-code.git
cd gen-code
go build -o gen ./cmd/gen
mkdir -p ~/.local/bin && mv gen ~/.local/bin/
Usage
# Interactive mode
gen
# Non-interactive mode
gen "explain this function"
cat main.go | gen "review this code"
# Resume previous session
gen --continue # Resume most recent
gen --resume # Select from list
Quick Start
- Run
gento start interactive mode - Use
/modelto connect a provider and select a model - Start chatting!
Commands
/model /tools /skills /agents /mcp /plugin /compact /think /search /loop /resume /fork /clear /init /memory — type /help for details.
Keyboard: Shift+Tab toggle permission mode, Ctrl+O expand tool details, Ctrl+C cancel, Ctrl+D exit.
Configuration
Gen Code stores configuration in ~/.gen/:
~/.gen/
├── providers.json # Provider connections and current model
├── settings.json # User settings (permissions, hooks, env)
├── skills.json # Skill states
├── projects/ # Project-scoped session transcripts + indexes
├── skills/ # Custom skill definitions
├── agents/ # Custom agent definitions
├── commands/ # Custom slash commands
└── plugins/ # Installed plugins
Project Instructions
Place a GEN.md (or CLAUDE.md) in your project root to provide project-specific instructions. These are automatically loaded into the system prompt. Project-level settings can also be placed in .gen/settings.json.
Benchmark: Gen Code vs Claude Code
Compared with Claude Code v2.1.112 on Apple Silicon, same model (claude-sonnet-4-6):
| Metric | Gen Code | Claude Code | Advantage |
|---|---|---|---|
| Download size | 12 MB | 63 MB (+ Node.js 112 MB) | 5x smaller |
| Disk footprint | 38 MB | 175 MB | 4.6x smaller |
| Startup time | ~0.01s | ~0.20s | 20x faster |
| Startup memory | ~32 MB | ~189 MB | 5.8x less |
| Simple task | ~2.4s / 39 MB | ~10.4s / 286 MB | 4.3x faster, 7.3x less memory |
| Tool-use task | ~3.3s / 39 MB | ~26.0s / 285 MB | 7.9x faster, 7.2x less memory |
Both tools have comparable features (hooks, skills, plugins, session, MCP, etc.). The performance gap comes from Go's native compilation, minimal architecture design, and lean prompt engineering — vs Node.js V8/JIT/GC runtime overhead.
See full details: docs/benchmark-gencode-vs-claudecode.md
Related Projects
- Claude Code — Anthropic's AI coding assistant
- Aider — AI pair programming in terminal
- Continue — Open-source AI code assistant
Contributing
Contributions welcome! See CONTRIBUTING.md for guidelines.
License
Apache License 2.0 - see LICENSE for details.
Reviews (0)
Sign in to leave a review.
Leave a reviewNo results found