ai-factory
v2.1.0
Published
CLI tool for automating AI agent context setup in projects
Maintainers
Readme

AI Factory
Stop configuring. Start building.
You want to build with AI, but setting up the right context, prompts, and workflows takes time. AI Factory handles all of that so you can focus on what matters — shipping quality code.
One command. Full AI-powered development environment.
ai-factory initWhy AI Factory?
- Zero configuration — detects your stack, installs relevant skills, configures integrations
- Best practices built-in — logging, commits, code review, all following industry standards
- Spec-driven development — AI follows plans, not random exploration. Predictable, resumable, reviewable
- Community skills — leverage skills.sh ecosystem or generate custom skills
- Works with your stack — Next.js, Laravel, Django, Express, and more
- Multi-agent support — Claude Code, Cursor, Windsurf, Roo Code, Kilo Code, Antigravity, OpenCode, Warp, Zencoder, Codex CLI, GitHub Copilot, Gemini CLI, Junie, Qwen Code, or any agent
Installation
Using npm
npm install -g ai-factoryUsing mise
mise use -g npm:ai-factoryQuick Start
# In your project directory
ai-factory initThis will:
- Ask which AI agent you use
- Detect your project stack
- Install relevant skills
- Configure MCP servers (for supported agents)
Then open your AI agent and start working:
/aifUsage
If the package is installed:
ai-factory initOr running without installation via npx:
npx ai-factory initUpgrading from v1 to v2
# 1) Update the CLI package
npm install -g ai-factory@latest
# 2) Migrate existing skills to v2 naming
ai-factory upgradeai-factory upgrade removes old bare-named skills (commit, feature, etc.) and installs new aif-* prefixed versions. Custom skills are preserved.
Example Workflow
# Plan a feature — creates branch, analyzes codebase, builds step-by-step plan
/aif-plan Add user authentication with OAuth
# Optionally refine the plan with deeper analysis
/aif-improve
# Execute the plan — implements tasks one by one, commits at checkpoints
/aif-implement
# Fix a bug — AI learns from every fix and gets smarter over time
/aif-fix TypeError: Cannot read property 'name' of undefined
# Set up CI pipeline — GitHub Actions or GitLab CI with linting, SA, tests
/aif-ci github
# Generate project documentation — README + docs/ with topics
/aif-docsSee the full Development Workflow with diagram and decision table.
Auto-Generated Documentation
AI Factory can generate and maintain your project docs with a single command:
/aif-docs # Creates README + docs/ structure from your codebase
/aif-docs --web # Also generates a static HTML documentation site- Generates docs from scratch — analyzes your codebase and creates a lean README + detailed
docs/pages by topic - Cleans up scattered files — finds loose CONTRIBUTING.md, ARCHITECTURE.md, SETUP.md in your root and consolidates them into a structured
docs/directory - Keeps docs in sync — integrates with
/aif-implementso documentation is updated automatically after each feature - Builds a docs website —
--webgenerates a static HTML site with navigation and dark mode, ready to host
Documentation
| Guide | Description |
|-------|-------------|
| Getting Started | What is AI Factory, supported agents, CLI commands |
| Development Workflow | Workflow diagram, when to use what, spec-driven approach |
| Reflex Loop | Iterative generate → evaluate → critique → refine workflow |
| Core Skills | All slash commands — feature, task, fix, implement, evolve, docs, and more |
| Plan Files | Plan files, self-improvement patches, skill acquisition |
| Security | Two-level security scanning for external skills |
| Configuration | .ai-factory.json, MCP servers, project structure, best practices |

Links
- Official Website - AI Factory website
- skills.sh - Skill marketplace
- Agent Skills Spec - Skill specification
- Claude Code - Anthropic's AI coding agent
- Cursor - AI-powered code editor
- OpenCode - Open-source AI coding agent
- Roo Code - AI coding agent for VS Code
- Kilo Code - Open-source agentic coding platform
- Windsurf - AI-powered code editor by Codeium
- Warp - Intelligent terminal with AI agent
- Zencoder - AI coding agent for VS Code and JetBrains
- Codex CLI - OpenAI's coding agent
- Gemini CLI - Google's coding agent
- Antigravity - AI coding agent
- Junie - JetBrains' AI coding agent
License
MIT
