Harness Forge
Harness Forge enhances AI coding agents by continuously improving their performance and visibility.
<!-- LAYER 1: What is this? (5 seconds) --> <table> <tr> <td align="center" width="33%">
π Scans & Equips
Your AI agent gets your repo's languages, frameworks, and patterns from the first prompt
</td> <td align="center" width="33%">π Self-Improves
A closed feedback loop learns what works, tunes itself, and gets smarter every session
</td> <td align="center" width="33%">π Full Visibility
Real-time dashboard shows every decision, token spend, and compaction β no black boxes
</td> </tr> </table> <br />| Without Harness Forge | With Harness Forge | |
|---|---|---|
| π§ Context | Agent guesses at project structure | Agent knows your languages, frameworks, boundaries |
| β‘ Performance | Starts fresh every session | Self-improves over time via the Living Loop |
| π Visibility | Black box β no idea what the agent decided | Real-time dashboard with 20 live panels |
| π° Cost | Wasted tokens on retries and wrong paths | Compaction + auto-tuning saves 20-40% |
| π€ Portability | Stuck on one machine, one setup | Export & import learned patterns as .hfb bundles |
<!-- LAYER 2: The differentiators (15 seconds) -->
π The Living Loop β Your Harness Gets Smarter
<p align="center">Most tools configure once and forget. Harness Forge keeps learning.
ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββββ
β π β β π§ β β β‘ β β π€ β β π₯ β
β OBSERVE βββββΆβ LEARN βββββΆβ ADAPT βββββΆβ SHARE βββββΆβ IMPORT β
β β β β β β β β β β
β Tracks β β Finds β β Auto- β β Export β β Bootstrapβ
β sessions β β patterns β β tunes β β bundles β β anywhere β
ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββββ
β² β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
</p>
<table>
<tr>
<td width="50%">
π Day 1 β You install
npx @harness-forge/cli
Scans your repo. Installs skills, rules, knowledge packs. Default settings. Everything works out of the box.
</td> <td width="50%">π Day 3 β After ~10 sessions
π§ Pattern found: "Summarize" saves 40% more tokens
than "Trim" in this repo (confidence: 82%)
β‘ Auto-tuned: compaction threshold 75% β 65%
Result: 20% fewer budget warnings
</td>
</tr>
<tr>
<td width="50%">
π Day 5 β Share with your team
hforge export --bundle my-team.hfb
# Send to a teammate β
hforge import my-team.hfb
# They get your learned patterns instantly
</td>
<td width="50%">
π Ongoing β Dashboard shows it all
hforge dashboard
Loop health ring, effectiveness scores, pattern list, tuning log β live in your browser.
</td> </tr> </table><details> <summary><strong>π‘οΈ Guardrails β auto-tuning is safe</strong></summary>The more you use it, the better it gets. After ~10 sessions, Harness Forge has learned your repo's patterns and tuned itself for optimal performance. No manual configuration needed.
- Every tunable parameter has hard min/max bounds β the tuner can't go wild
- Every change is logged with before/after values and the pattern that triggered it
- If the next 3 sessions score worse, the tuning is automatically reverted
- Your manual config overrides are sacred β the tuner won't touch them
- The dashboard shows every tuning with a one-click revert button
π Real-Time Dashboard
<p align="center"> <img src="./assets/dashboard.jpeg" alt="Harness Forge Dashboard" width="700" /> </p> <p align="center"> <img src="https://img.shields.io/badge/π_dashboard-20_live_panels-6C3FC5?style=for-the-badge" alt="20 panels" /> <img src="https://img.shields.io/badge/π_notifications-desktop_alerts-2ea44f?style=for-the-badge" alt="notifications" /> <img src="https://img.shields.io/badge/π_connection-websocket_realtime-0070f3?style=for-the-badge" alt="realtime" /> </p> <table> <tr> <td align="center" width="25%">
hforge dashboardβ see everything, live in your browser.
π Loop Ring
Live status of each loop stage with health score
</td> <td align="center" width="25%">π Effectiveness
Session score trend β are things getting better?
</td> <td align="center" width="25%">π§ Insights
Discovered patterns with confidence bars
</td> <td align="center" width="25%">β‘ Tuning Log
Policy changes with one-click revert
</td> </tr> </table> <details> <summary><strong>π All 20 dashboard panels</strong></summary>| Panel | What it shows |
|---|---|
| π’ KPI Cards | Total events, tokens, enforcement level, budget gauge |
| π Event Timeline | Scatter plot of all events over time, color-coded by category |
| πΎ Memory Pressure | Token usage line chart with threshold marklines |
| π Budget Breakdown | Donut chart of budget allocation (hot-path, output, tools, safety) |
| π Live Event Feed | Searchable, expandable table of every harness decision |
| π€ Subagent Briefs | Delegated tasks, their context, and outcomes |
| π Brief Metrics | Subagent activity summary and success rates |
| π Suppression Gauge | How many duplicate context items were removed |
| πͺ Expansion Gate | History access requests β granted vs denied |
| βοΈ Config Editor | Edit memory-policy, context-budget, load-order live |
| π Loop Health Ring | Self-improvement cycle status with stage counts |
| π Effectiveness Trend | Session score sparkline (last 20 sessions) |
| π§ Insights Panel | Discovered patterns with confidence and "NEW" badges |
| β‘ Tuning Log | Policy changes with before/after and revert button |
| π Event Distribution | Bar chart of top event types |
| β±οΈ Event Rate | Events per minute over time |
| πΊοΈ Event Heatmap | Category Γ time heatmap |
| π° Tokens Saved | Running counter of tokens saved by compaction |
| π Profile Distribution | Output profile selection breakdown |
| βΉοΈ Session Info | Session ID, uptime, version, connection status |
π Desktop notifications for critical events β budget exceeded, memory rotation, tuning applied, pattern discovered.
π’ Multi-project support β switch between projects in one dashboard. Your project list is saved in the browser.
<!-- LAYER 3: Getting started and daily use (1 minute) -->
π Get Started in 60 Seconds
<table> <tr> <td width="55%">npx @harness-forge/cli
The CLI walks you through:
- π― Which AI targets (Codex, Claude Code, or both)
- π How deep (
quick/recommended/advanced) - π Preview of exactly what gets created
- β One confirmation and you're done
Then make hforge available on your PATH:
npx @harness-forge/cli shell setup --yes
</td>
<td width="45%" align="center">
One-liner for CI / scripts:
hforge init \
--root . \
--agent codex \
--agent claude-code \
--setup-profile recommended \
--yes
Verify everything is healthy:
hforge doctor --root . --json
</td>
</tr>
</table>
β¨οΈ Your Daily Workflow
Commands organized by when you use them β not alphabetically.
π Starting a session
| Command | What it does | |
|---|---|---|
| π‘ | hforge next | Recommends the single most useful action right now |
| π₯ | hforge doctor | Full health check with evidence |
| π | hforge refresh | Regenerate runtime after code changes |
| π | hforge status | Review what's installed |
π While working
| Command | What it does | |
|---|---|---|
| π | hforge dashboard | Open the real-time browser dashboard |
| π | hforge score | Show recent session effectiveness scores |
| π§ | hforge insights | Browse learned patterns with confidence |
| β‘ | hforge adapt | View/manage auto-tunings |
| π | hforge trace | View recent session traces |
| π | hforge loop | Living Loop health summary |
π€ Sharing & maintenance
| Command | What it does | |
|---|---|---|
| π¦ | hforge export --bundle team.hfb | Export tuned harness as portable bundle |
| π₯ | hforge import team.hfb | Bootstrap from a shared bundle |
| π§ | hforge update | Update harness to latest version in place |
| π¬ | hforge audit | Verify install integrity |
| π | hforge diff-install | Check what drifted since last install |
| π§Ή | hforge prune | Clean up unused artifacts |
𧬠Advanced
| Command | What it does | |
|---|---|---|
| πΊοΈ | hforge cartograph | Map repo structure and boundaries |
| π | hforge recommend | Evidence-backed setup recommendations |
| 𧬠| hforge recursive plan "..." | Structured recursive analysis for hard problems |
| π― | hforge target compare codex claude-code | Side-by-side target comparison |
π‘ Real-World Scenarios
<table> <tr> <td width="50%">π "Just cloned a repo, want AI help"
cd my-project
npx @harness-forge/cli
# Done β AI assistant understands this project
</td>
<td width="50%">
π€ "I use both Codex and Claude Code"
hforge init --agent codex --agent claude-code --yes
hforge target compare codex claude-code
Both agents share .hforge/ but get their own config bridges.
π "Coming back to a project after a break"
hforge next
# Tells you: refresh runtime, review stale artifacts
</td>
<td width="50%">
π₯ "Standardize AI setup across my team"
hforge export --bundle our-team.hfb
# Teammate runs:
hforge import our-team.hfb
# Same learned patterns, instant bootstrap
</td>
</tr>
</table>
π― Supported Targets
<p align="center"> <img src="https://img.shields.io/badge/Codex-full_support-2ea44f?style=for-the-badge" alt="Codex" /> <img src="https://img.shields.io/badge/Claude_Code-full_support-6C3FC5?style=for-the-badge" alt="Claude Code" /> <img src="https://img.shields.io/badge/Cursor-partial-f97316?style=for-the-badge" alt="Cursor" /> <img src="https://img.shields.io/badge/OpenCode-partial-f97316?style=for-the-badge" alt="OpenCode" /> </p> <table> <tr> <td width="50%">| Codex | Claude Code | |
|---|---|---|
| Runtime | β Full | β Full |
| Maintenance | β Full | β Full |
| Hooks | π Docs-driven | β Native |
| Plugins | π Manual | β Native |
Shared .hforge/ | β Yes | β Yes |
Use both together β they share the same .hforge/ runtime.
hforge target compare codex claude-code
</td>
</tr>
</table>
π¦ What's Included
<p align="center"> <img src="https://img.shields.io/badge/π_languages-14-0070f3?style=for-the-badge" alt="14 languages" /> <img src="https://img.shields.io/badge/ποΈ_frameworks-12-2ea44f?style=for-the-badge" alt="12 frameworks" /> <img src="https://img.shields.io/badge/π οΈ_skills-45+-f97316?style=for-the-badge" alt="45+ skills" /> </p> <details> <summary><strong>π 14 Language packs</strong></summary>TypeScript, Python, Java, Go, Kotlin, Rust, C++, .NET, PHP, Perl, Swift, Shell, Lua, PowerShell
</details> <details> <summary><strong>ποΈ 12 Framework packs</strong></summary>React, Next.js, Vite, Express, FastAPI, Django, ASP.NET Core, Spring Boot, Laravel, Symfony, Gin, Ktor
</details> <details> <summary><strong>π οΈ 45+ Skills</strong></summary>Language engineering, workflow orchestration, operational helpers, and specialized skills like incident triage, dependency upgrades, API contract review, database migration review, release readiness, and token-budget-optimizer for context-aware compaction.
</details>βοΈ How It Works Under the Hood
<details> <summary><strong>ποΈ What gets created in your repo</strong></summary>Your Repo
β
βββ AGENTS.md β AI agents read this first
βββ .agents/skills/ β Discoverable skills
βββ .codex/ or .claude/ β Target-specific config
βββ .hforge/ β Hidden canonical runtime
βββ library/ β Skills, rules, knowledge packs
βββ runtime/ β State, indexes, traces, insights
βββ generated/ β Command catalog, launchers
βββ templates/ β Workflow templates
Visible bridges where AI agents need discovery. Hidden canonical layer where runtime content stays authoritative.
</details>β FAQ
<details> <summary><strong>Do I need to install anything globally?</strong></summary>No. npx @harness-forge/cli runs directly. For the shorter hforge command, run hforge shell setup --yes once.
Never. Harness Forge only creates its own files (AGENTS.md, .agents/, .hforge/, .codex/, .claude/). Your application code is untouched.
Yes. Add --yes for non-interactive and --json for machine-readable output:
hforge init --root . --agent codex --setup-profile recommended --yes
hforge doctor --root . --json
</details>
<details>
<summary><strong>How do I remove it?</strong></summary>
Delete: .hforge/, .agents/, .codex/, .claude/, AGENTS.md. Your project is back to normal.
No. Everything stays local under .hforge/. Nothing is ever sent to the internet. Inspect, delete, or back up anytime.
Node.js 22 or newer. Check with node --version.
π Project Activity
<p align="center"> <a href="https://star-history.com/#ldilov/harness-forge&Date"> <img src="https://api.star-history.com/svg?repos=ldilov/harness-forge&type=Date" alt="Star History Chart" width="700" /> </a> </p>π€ Contributing
See CONTRIBUTING.md for development setup and guidelines.
π Acknowledgements
Harness Forge was inspired by github/spec-kit. Credit to the GitHub team for shaping cleaner workflow models.
π License
GPL-3.0 β see LICENSE.
<p align="center"> <strong>Your AI agent deserves a better harness.</strong> <br /> <code>npx @harness-forge/cli</code> </p>