kunglao-agent
An autonomous reverse-engineering agent that runs for hours unattended, verifies every conclusion independently, and converges only when every answer survives a mechanical oracle verdict.

🧠 plans its own route · 🔬 every claim machine-checked · ⚖️ blind verification on everything · 📈 the loop measures itself
📖 Introduction · 🖥️ Showcase · ✨ Core technology · 🧠 kunglao × Claude Code · 🎛️ Online RL: the loop gets better while it works · 📋 Requirements · Quick start · Subcommands · What a run looks like · 📖 Stating the task · 🧰 The run you watch · 📚 Case studies · 🧪 Evaluation and measured results · 🏗️ Architecture · Bring your own environment · MCP servers · 🗓️ Roadmap · ❓ FAQ · 🔐 Safety · 🧪 Development · 📝 License
English · 简体中文
[!WARNING]
v0.1.6 is the last Claude Code-native release line. The next
milestone (v0.2) migrates the runtime wholesale to the PI Agent base —
same loop, same ledgers, new engine substrate. See the roadmap.
📖 Introduction
You point kunglao-agent at a target and state the questions; it plans the
route, dispatches specialist workers, verifies every conclusion independently,
and stops only when each answer is settled by a mechanical check instead of a
model's say-so.
The target spectrum is the full one — Windows/Linux native binaries, Android
APKs (including native .so layers), web/JS, protocol recovery, firmware —
static-first by design, driving whichever execution channel your environment
already has (VMware, ssh, docker, adb, or none at all for static-only work).
It runs inside Claude Code as a plugin:
Claude Code is the conversation surface; the product is the loop and the fact
base it produces.
[!NOTE]
Every number the loop reports — win rates, posteriors, budgets — traces to a
row on an append-only ledger. Nothing is self-declared.
🖥️ Showcase
The orchestrator at work — a convergence decision, a budgeted worker
dispatch with live facts landing, and a blind red-team verdict promoting a
claim to PROVEN; the statusline HUD keeps the whole engagement readable at
a glance:

The loop measuring itself — the round strategy composed from settlements,
the discounted-Thompson posterior store with censored-outcome tiebreaking,
the discovery layer admitting a genuinely novel arm (and refusing a renamed
retry), and the win-rate curve:

✨ Core technology
kunglao-agent is an act-level RL controller around Claude Code: Claude
Code reasons inside each act; kunglao decides the next act, verifies it,
prices it, learns from it. Deep design: docs/design/.
- Mechanical oracle. The completion criterion derives from your task
statement as runnable checks (byte-exact replay, held-out probes). Reward
is priced in oracle verdicts — lying about progress earns nothing.
- Blind verification. An independent verifier re-derives every claim
without seeing the maker's reasoning; worker self-sign-off caps at
STAMP, never PROVEN. Facts cite artifacts (sha256) and carry
reproduce: commands.
- The loop learns, the model stays frozen. Every act lands on an
append-only ledger; a Thompson-sampling policy reorders method families
by measured cost-adjusted success per feature-keyed state.
- Unattended, resumable. Hours-long runs, dead workers replaced, full
state on disk, every reported number traces to a ledger row.
🧠 kunglao × Claude Code