whatisgithub

What is agent-ftw?

jgauffin/agent-ftw — explained in plain English

Analysis updated 2026-05-18

1TypeScriptAudience · developerComplexity · 3/5Setup · moderate

In one sentence

A TypeScript framework for building AI agents as a series of structured phases with schema-enforced handoffs instead of one long open-ended loop.

Mindmap

A visual breakdown will appear here once this repo is fully enriched.

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Build a multi-step AI agent pipeline where each phase must produce validated, typed output before continuing.

USE CASE 2

Mix a paid frontier model for hard phases with a free local model for cheap verification steps.

USE CASE 3

Add a quality-check phase that judges another phase's output before accepting it.

What is it built with?

TypeScriptNode.jsOpenAI APIClaude SDKOllama

How does it compare?

jgauffin/agent-ftw0xkinno/neuralvault0xmayurrr/ai-contractauditor
Stars111
LanguageTypeScriptTypeScriptTypeScript
Setup difficultymoderatehardeasy
Complexity3/54/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires Node.js 22 or newer, optional adapters installed separately for specific model providers.

So what is it?

agent-ftw is a TypeScript framework for building AI agents that work in structured, sequential phases rather than as a single open-ended loop. The core idea is that you define an agent as a series of phases, each with its own prompt, a JSON schema describing exactly what output it must produce, and an optional turn budget (a cap on how many back-and-forth exchanges the model gets before the phase must either succeed or fail). When a phase finishes, only its structured output carries forward to the next phase, the raw conversation history is discarded, so the context doesn't balloon over a long pipeline. This schema-enforced handoff between phases is the main differentiator the README emphasizes. Because each phase is required to emit output that matches a defined structure before it can end, the next phase always receives clean, typed data rather than hoping the model remembered to include a field. You can also route different phases to different model backends: a paid frontier model for the phases where quality matters, and a free local model (via Ollama, LM Studio, or vLLM) for cheaper verification steps. An optional checklist feature runs a second model as a quality judge on a phase's output before accepting it. Sub-agents and scoped detours ("side quests") are also supported, each still ending with a typed deliverable. It works with any OpenAI-compatible endpoint and with the Claude SDK, so you can mix providers across phases. The runtime has minimal dependencies: it requires Node.js 22 or newer and a TypeScript toolchain, and the Anthropic SDK adapters are optional and installed separately only if you need them.

Copy-paste prompts

Prompt 1
Show me how to define a multi-phase agent-ftw pipeline with a JSON schema for each phase.
Prompt 2
Help me set up a phase that routes to a local Ollama model for verification and a frontier model for generation.
Prompt 3
Explain how agent-ftw discards conversation history between phases while keeping structured output.
Prompt 4
Walk me through adding a sub-agent or side quest to an existing agent-ftw pipeline.

Frequently asked questions

What is agent-ftw?

A TypeScript framework for building AI agents as a series of structured phases with schema-enforced handoffs instead of one long open-ended loop.

What language is agent-ftw written in?

Mainly TypeScript. The stack also includes TypeScript, Node.js, OpenAI API.

How hard is agent-ftw to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is agent-ftw for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.