Forge: The Industrial-Scale Autonomous Software Engineer

Forge is a fire-and-forget autonomous software engineering system designed to transform high-level project descriptions into complete, production-ready codebases with zero human intervention during the build phase. It implements the "Ralph Loop"—Plan, Build, Learn, Repeat—at industrial scale, utilizing parallelized agents, isolated cloud sandboxes, and immutable execution graphs.

Demo: https://drive.google.com/drive/folders/15brC1kQkHiU9ry3KKzuLCv95Sgk_7UQW


1. The Core Philosophy: Fire-and-Forget

Unlike traditional AI assistants that require constant prompting and "babysitting," Forge is designed for autonomy. The user interacts with Forge only once: during a deep, interactive planning interview. Once the plan is approved, the system operates as a closed-loop factory until the project is delivered.

2. The Workflow (The Ralph Loop)

Forge operates in three distinct, interconnected phases:

Phase I: Plan (The Captain)

The Captain is a specialized planning agent. It doesn't just write code; it researches and architect's.

  • The Interview: The Captain conducts a technical interview with the user to elicit requirements, tech stack preferences, and architectural constraints.
  • Deep Research: Using Exa AI, the Captain researches documentation and libraries. Using just-bash simulation, it prototypes directory structures and config files.
  • The Output: The Captain produces a set of Immutable Artifacts: a comprehensive technical Spec, a library of Task files, and a DAG (Directed Acyclic Graph) that defines the exact order of execution.

Phase II: Build (The Executor & Agents)

The Executor is the factory manager. it reads the DAG and determines which tasks are "ready" (dependencies completed).

  • Agent Hierarchy: Forge uses a tiered system of workers:
    • Type 1 (Throwaway): Handles fine-grained, mechanical tasks.
    • Type 2 (Worker): Executes complex features and can delegate to Type 1s.
    • Type 3 (Sub-executor): Manages its own internal task lists for massive architectural components.
  • Total Isolation: Every agent runs in its own E2B Sandbox—a dedicated, isolated cloud VM. They work on unique Git branches (forge/<taskId>/<attemptId>), ensuring no two agents ever collide in the same environment.

Phase III: Learn & Integrate (The Refinery)

The Refinery is the quality gate. It is a specialized agent placed at integration points in the DAG.

  • Automatic Merging: It collects branches from parallel workers and merges them.
  • Validation: It runs the full project test suite.
  • Adaptive Replanning: If the Refinery discovers a plan-level flaw (e.g., an API mismatch), it emits a Change Request (CR). This pauses the loop and re-invokes the Captain to "mini-replan" and overlay the DAG with new tasks to fix the issue.

3. Technical Architecture

Forge is built on a "Brutalist" stack designed for reliability and transparency:

  • LLM Agnostic: Powered by forge-ai (a fork of pi-ai), Forge supports 20+ providers (OpenAI, Anthropic, Google, DeepSeek, etc.) via a unified API.
  • Atomic Artifacts: All state is persisted as JSON and Markdown in a centralized Artifact Store. Every write is atomic (write → fsync → rename), preventing partial reads by the Executor or UI.
  • NDJSON Streaming: The entire system state is broadcast via a real-time event stream. Clients can connect, disconnect, and "replay" history using monotonic sequence numbers.
  • Git-as-State: Forge uses Git not just for version control, but as the primary mechanism for parallel state management between agents.

4. The Operator Interface

The Forge web interface follows a Brutalist Industrial Design. Eschewing gradients and rounded corners for a sharp "control panel" aesthetic, it prioritizes high information density:

  • The Dashboard: A real-time visualization of the Task DAG. Nodes pulse orange while running and turn green upon success.
  • Character-by-Character Streaming: Watch every agent think and work in real-time across multiple panes.
  • The "Pause All" Button: A prominent Forge Orange emergency control that immediately halts the entire factory.

5. Summary

Forge represents a shift from "AI as a tool" to "AI as a workforce." By combining immutable planning with isolated, parallel execution and an adaptive refinery loop, Forge handles the complexity of software engineering so humans can focus on the vision.

Plan once. Build autonomously. Forge the future.

Built With

Share this project:

Updates