code-puppy
Code generation agent
What it is and what it does
Code Puppy is a terminal-based AI code agent that acts as an alternative to commercial code editors. It connects to multiple LLM providers (OpenAI, Anthropic, Google, and others via models.dev) and uses tool calling to read files, execute shell commands, and generate code interactively. The agent understands programming tasks, generates code, and explains its reasoning in a conversational interface.
You interact with Code Puppy through a command-line REPL with slash commands (e.g., `/add_model` to browse and configure new LLM providers, `/meta-auth` for Meta OAuth, `/dbos` for optional durable execution). It supports custom commands via markdown files in project directories and can optionally checkpoint agent state to a database for crash recovery. The package is designed to be lightweight and scriptable, with low install friction via pure-Python distribution.
Use it for:
- Generate and refactor code interactively by describing tasks to an AI agent with access to your project files and shell.
- Experiment with multiple LLM providers and models without switching tools, using the integrated models.dev browser.
- Run long-running code-generation tasks with automatic crash recovery by enabling optional DBOS durable execution.
- Extend Code Puppy with custom slash commands by dropping markdown files into project directories.
- Use as a scriptable alternative to GUI-based code editors for CI/CD pipelines or headless environments.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Code Puppy is an AI-powered code generation agent that understands programming tasks, generates code, and explains its reasoning by integrating with multiple LLM providers and executing code through shell and file tools.
Yes, if you want a lightweight, open-source AI code agent with multi-provider LLM support and low install friction. The active maintenance, permissive MIT license, and broad provider integration make it a viable alternative to commercial tools. Install with caution on Android (Termux) due to compilation time and missing browser tools. Verify that your preferred LLM provider is supported and that you have valid API credentials before committing to it as your primary coding assistant.
Install
code-puppy on PyPI
pip
pip install code-puppyuv
uv add code-puppypoetry
poetry add code-puppyInstalling code-puppy
Before you install
Low install friction with a pure-Python wheel distribution. Active maintenance as of 2026-08-14 with 787 repository stars. Requires Python 3.11–3.14 and 23 runtime dependencies including anthropic, openai, boto3, and playwright, which may add setup time on first install.
License in practice
MIT license permits commercial and private use with minimal restrictions. You may use, modify, and distribute this package freely provided you retain the license notice.
Quickstart
# Install via UV (recommended)
uvx code-puppy -i
# Or via pip
pip install code-puppy
# Run interactively
code-puppy
# Then configure an API key (e.g., OpenAI):
# export OPENAI_API_KEY="sk-..."
# and use /add_model to browse and add models from providers
Requires Python 3.11 or later. First run may compile native dependencies (especially on Android/Termux). Playwright-backed browser tools are not available on Android. API keys for at least one LLM provider (OpenAI, Anthropic, etc.) are required to generate code.
Verify before relying
- How many providers are actually available through models.dev integration and which are thoroughly tested versus experimental.
- Performance and stability when running multiple concurrent agent instances.
- Whether the optional DBOS durable-execution plugin is production-ready and what database backends are recommended.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (<3.15,>=3.11) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 23 — agent-client-protocol, anthropic, azure-identity, boto3, code-puppy-core-plugins, httpx, json-repair, keyring, mcp, openai, pillow, playwright, prompt-toolkit, pydantic-ai-slim, pydantic, pyfiglet, python-dotenv, rapidfuzz, requests, rich, ripgrep, termflow-md, typer |
| Maintenance | actively maintained — 0 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 74,003/month — #14,891 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: code_puppy-0.0.718-py3-none-any.whl
Tags
More Code Generators packages
Proto Plus wraps protocol buffers to provide…
permissive · top 1,000 on PyPI
CythonCython is a source code translator that…
permissive · top 1,000 on PyPI
asttokensAnnotates Python abstract syntax trees with the…
permissive · top 1,000 on PyPI
beartypeBeartype is a runtime type checker that…
permissive · top 1,000 on PyPI
llvmlitellvmlite provides a lightweight Python binding…
permissive · top 1,000 on PyPI
astorastor converts Python abstract syntax trees…
permissive · top 5,000 on PyPI
trinity-agentTrinity orchestrates multiple AI coding agents…
permissive · top 15,000 on PyPI
opencode-agent-hubCoordinates communication between multiple AI…
agpl · top 15,000 on PyPI
ouroboros-aiOuroboros is an Agent OS that turns vague AI…
permissive · top 15,000 on PyPI
deepagents-codeA terminal-based AI coding agent that works…
permissive · top 15,000 on PyPI
mini-swe-agentAn AI agent that solves software engineering…
permissive · top 5,000 on PyPI
graphifyyParses code, docs, PDFs, images, and video into…
permissive · top 5,000 on PyPI
skillsawA linter for AI agent instruction files that…
permissive · top 15,000 on PyPI
agentopsAgentOps provides observability and monitoring…
permissive · top 15,000 on PyPI
headroom-aiCompresses LLM prompts and agent outputs before…
permissive · top 15,000 on PyPI
sembleSemble is a code search library that indexes…
permissive · top 15,000 on PyPI