convez.ai
MCP ServerDevOps & InfraestruturaAvançado
vilaca

Factory: Agente de Codificação Multimodal com MCP

vilaca/factory

Agente de IA para codificação com suporte a 16 provedores e fallback automático

Ver no GitHub
BomPluginScore · de 0 a 100

CLI de agente de codificação que funciona com qualquer LLM (local ou cloud, frontier ou 7B) através de 16 provedores. Oferece sessões multi-aba, failover automático de chaves e modelos, modo plan para revisão, suporte MCP nativo e loops de recuperação para modelos instáveis.

Instalação

$npx convez-ai vilaca/factory

1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.

Métricas

Estrelas
2
Forks
0
Acompanhando
0
Saúde
71%
Último commit
há 1 semana
Versão
—
Issues abertas
14
Contribuidores
2

Casos de uso

  • Executar agentes de codificação locais sem depender de APIs cloud pagas
  • Trocar entre modelos diferentes em tempo real com fallback automático quando rate limits são atingidos
  • Revisar ações do agente antes de executar (modo plan)
  • Trabalhar com LLMs que geram código mal-formado através de corretores automáticos

Veredito

Ferramenta sólida e bem-testada para quem precisa de flexibilidade extrema na escolha de modelos de IA para tarefas de codificação. Complexa, mas necessária para pipelines de agentes production-grade com múltiplos provedores.

README

A tradução para o português deste README ainda está na fila.

🏭 factory

Lint Typecheck Unit tests E2E mocks E2E no-mocks E2E headless E2E pty Coverage License Node

A coding agent CLI engineered to make any LLM — local or cloud, frontier or 7B — actually useful.

Why factory

  • Bring your own model. Pick what fits your privacy, cost, and latency. 16 providers on equal footing — local-first (Ollama, llama.cpp) and cloud (Anthropic Claude, Cerebras, Cloudflare Workers AI, Codestral, Cohere, GitHub Copilot, Google AI Studio, Groq, HuggingFace, Mistral, OpenAI, OpenCode Zen, OpenRouter, Vercel AI Gateway).
  • Multi-tab sessions. Each tab is an independent agent with its own conversation, working directory, provider, and model. Run a frontier LLM on a refactor in one tab while a local LLM explores tests in another. Switch with Ctrl+N/Ctrl+P or jump directly with F1–F12.
  • Two-tier rotation. When a key hits a rate limit or auth failure, factory swaps to the next saved key for the same model; when keys for a model are exhausted, it walks a configurable chain of <provider>:<model> fallbacks — frontier → fast → free, automatic.
  • Picker with key management. Startup and in-session pickers support provider → key → model selection, key validation, and saved-key reuse for providers that support multiple API keys.
  • Built for models that don't behave. Text-tool fallback recovers tool calls from prose; an LLM corrector retries malformed calls; an imitation guard strips fabricated tool-result blocks; Bash dedup nudges the model out of spinning loops.
  • Plan mode. Read-only tools execute freely; writes are queued for review. Approve, cancel, or refine before anything touches disk.
  • Cache-aware. Surfaces prompt-cache hit rate per turn and per key for providers that report it. /stats reports session totals, per-turn hit-rate sparkline, compaction events, and the largest tool results.
  • Human or headless. Interactive TUI on a TTY; in scripts and CI it auto-detects no-TTY, reads stdin as a prompt, runs one turn, and streams the result to stdout — same agent, no UI. See docs/headless.md.

Requirements

Quick start

git clone https://github.com/vilaca/factory.git
cd factory
npm install && npm run build && npm link
factory

That's it. factory opens a picker for provider, key, and model the first time (for simple-key providers, it can validate and save keys during the flow). Subsequent runs jump straight into the prompt with the last provider/model you used; pass --pick (or use /model / Ctrl+K mid-session) to choose a different one.

npm link permission errors? It writes a symlink into your npm global prefix; if that's a system path it needs sudo. Either set a user-writable prefix once (npm config set prefix "$HOME/.npm-global" and add $HOME/.npm-global/bin to your PATH), skip linking and run npx factory from the repo, or invoke directly with node /path/to/factory/dist/index.js.

npm install coming soon. A factory-code package will land on npm once the first tagged release ships; until then, build from source.

Documentation

Quick reference

factory --version                                    # print version
factory --help                                       # full flag list
factory                                              # interactive picker
factory -p anthropic -m claude-sonnet-4-6            # one-shot
factory --plan                                       # plan mode
factory --pick                                       # force startup picker
factory --turn-timeout 120                           # auto-abort after 120s
factory --debug                                      # debug logs to stderr
echo "explain src/index.ts" | factory                # headless / non-TTY

Once running, type /help to see the full slash-command list.

Security

Built-in path jail, bash deny list, env scrubbing for subprocess execution, and plan mode for untrusted models. See docs/security.md for what's enforced and how to extend it, and SECURITY.md for the disclosure process.

License

Apache License 2.0 — see LICENSE.

Ver o original no GitHub

Bom para

Relacionados