1420079678-ctrl/agent-body ↗★ 9

agent-body

为智能体提供器官化插件层与自愈机制 适合需要长期记忆、反射弧和闭环自愈能力的智能体系统构建者。

套件
agent-body
相容性
待驗證
版本
0.1.0
授權
MIT
最近更新
2026年9月25日

安裝

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:1420079678-ctrl/agent-body

English · 中文

Agent-Body — plugins as organs: 26 curated organs across 8 systems, one heartbeat, 84.7% of tool-schema tokens gated away, 0 chronic wounds

Agent‑Body

An organ‑based plugin layer for DeepSeek Harness: organs, nerve impulses, a heartbeat, reflex arcs, long‑term memory, and closed‑loop self‑healing.

26 organ identities · 84.7% of tool-schema tokens gated · 200+ offline assertions · MIT

Agent-Body turns a plugin list into an organism. Every plugin declares itself an organ; a nerve bus routes your command to the organs that should handle it, a heartbeat circulates state between them, reflex arcs fire without a single model call, and every failure is attributed by cause before anything retries.

Try it in 30 seconds — no install, no host, no API key. The core imports nothing outside Node built-ins, so a fresh clone runs the real end-to-end chain offline:

git clone https://github.com/1420079678-ctrl/agent-body && cd agent-body
npm run demo     # command → impulse → dispatch → execute → attribute → reflex fires
npm run check    # the gate CI runs: constant tables, catalog, tests, benchmark — all offline

Already running DeepSeek Harness? One command installs the body kernel, the memory organ and the context engine:

$rel = "https://cdn.jsdelivr.net/gh/1420079678-ctrl/agent-body@v0.1.2/dist"
dsh plugin --profile web add "$rel/dsh-external-dsh-organism-0.1.1.tgz" "$rel/dsh-external-dsh-cortex-0.1.1.tgz" "$rel/dsh-external-dsh-zero-residence-0.1.0.tgz"

Restart the harness and body_status lists the organs. The claim you can check for yourself: the tool-schema block of the prompt drops 84.7% across 48 representative commands, and npm run bench:check fails the build if that number drifts. The scope of the number is stated wherever it appears — tool-schema tokens only, not the whole prompt.

⭐ Star the repository if you want it to keep tracking the host closely — it is a one-person project and the stars are how the next DSH user finds it.


Organs Plugins Schema gating Benchmark Regressions Node License GitHub stars GitHub issues dshfind

Architecture · Organ Catalog · Benchmark · Roadmap · 中文文档

Official DSH discussion — Show Your Plugins! · the channel the harness CONTRIBUTING points plugin authors to

v0.1.1 · MIT · Windows-first (Node 22.19 / 24) · 26 organ identities in the catalog, realised by 24 plugin packages in this repository · release notes

Live vitals replay — recorded from a real install

▶ Open the live demo — a recorded replay of a real install: the heartbeat, the organs, the pulse stream, the healing ledger and the token gate, with nothing installed. It is generated from the runtime files (vitals.json, bloodstream.json, pulse.jsonl), not retyped from screenshots.

Contents · Where it's listed · Install in one line · Why this exists · What makes it different · The five biological layers · Architecture at a glance · Organ catalog · Quick start · Write your own organ · Verify it yourself · When not to use this · FAQ · Repository layout · Contributing · Roadmap


Where it's listed

Checked, not claimed — every entry below resolves today:

ListingWhat it is
awesome-dsh-plugin · 16.7k ★the main DSH plugin directory; both dsh-organism and dsh-cortex are indexed as separate entries
dshfindDSH plugin search engine, with a per-repository page
imsai-sh/awesome-deepseek-harness-pluginsplugin hub with machine-readable catalogue entries
bruc3van/awesome-dsh-plugindaily-crawled DSH plugin list, human-reviewed
billLiao/awesome-dsh-plugincurated list, memory category
unStone/dsh-xraydeclared-capabilities scanner; carries a page for this repository
linny006/agent-framework-radar · llmops-radarlive indexes of newly shipping agent frameworks and LLMOps tooling

It is also the subject of the harness's official showcase thread — Show Your Plugins! discussion #7555.


Install in one line

Two supported paths — start with the first, switch to the second if your network blocks github.com.

Path 1 — GitHub release assets

Versioned assets built by CI. releases/latest/download/ always resolves to the newest release, so this command does not need editing when a version is bumped.

$rel = "https://github.com/1420079678-ctrl/agent-body/releases/latest/download"
dsh plugin --profile web add `
  "$rel/dsh-external-dsh-organism-0.1.1.tgz" `
  "$rel/dsh-external-dsh-cortex-0.1.1.tgz" `
  "$rel/dsh-external-dsh-zero-residence-0.1.0.tgz"
rel=https://github.com/1420079678-ctrl/agent-body/releases/latest/download
dsh plugin --profile web add \
  "$rel/dsh-external-dsh-organism-0.1.1.tgz" \
  "$rel/dsh-external-dsh-cortex-0.1.1.tgz" \
  "$rel/dsh-external-dsh-zero-residence-0.1.0.tgz"

Path 2 — served from this repository over jsDelivr

The same tarballs, committed under dist/ and served by a CDN with mainland nodes. Reach for this when Path 1 hangs: those URLs 302-redirect to objects.githubusercontent.com, a hop that is blocked on some networks. The symptom is fetch failed with downloaded 0 while dependency resolution succeeds — the download hop is the problem, not the packages.

$rel = "https://cdn.jsdelivr.net/gh/1420079678-ctrl/agent-body@v0.1.2/dist"
dsh plugin --profile web add `
  "$rel/dsh-external-dsh-organism-0.1.1.tgz" `
  "$rel/dsh-external-dsh-cortex-0.1.1.tgz" `
  "$rel/dsh-external-dsh-zero-residence-0.1.0.tgz"
rel=https://cdn.jsdelivr.net/gh/1420079678-ctrl/agent-body@v0.1.2/dist
dsh plugin --profile web add \
  "$rel/dsh-external-dsh-organism-0.1.1.tgz" \
  "$rel/dsh-external-dsh-cortex-0.1.1.tgz" \
  "$rel/dsh-external-dsh-zero-residence-0.1.0.tgz"

dsh plugin forwards its arguments to pnpm add inside the profile, so several packages install in one command. Restart the harness afterwards; body_status should list the organs. The other organs in the catalog are one tarball each — see Quick start.

If neither path works — install fully offline

Every tarball built by CI is committed under dist/, and dist/agent-body-offline-kit.zip bundles all ten plus a one-command installer. Download it from any machine that can reach this repository, copy it across, then:

Expand-Archive .\agent-body-offline-kit.zip -DestinationPath .
pwsh .\install-agent-body.ps1

Why not npm install yet. These packages are not published to the npm registry — the names above return 404 from registry.npmjs.org today, and nothing here pretends otherwise. That is the next step and it is tracked as an open issue: once they are on npm, dsh plugin add @dsh-external/dsh-organism becomes a single short command. Until then, the paths above are the supported ones.

Start with the evidence

If you want…Open…What you can check
to see it run without installing anythingnpm run demoa real command → impulse → dispatch → execute → attribute → reflex chain, offline, no key
fewer tool schemas in your promptbenchmarks/results/REPORT.md · npm run bench:check84.71% of tool-schema tokens gated away on 48 commands (cold-start, reproducible); 74.25% with history
failures to stop repeatingbody_healattribution before retry: tool_missing / arg_error / permission / timeout / network / not_found / conflict. Measured on a development install: 198 healed, 0 open, 99% heal rate
to know the system is still alivebody_status · body_heart43 organs, 332/332 capabilities claimed, beat #1121, architecture integrity 6/6 (development install)
to lose an organ without losing the bodybody_organ action=integritythe six core pieces depend on no single organ; body_call compensates from the organ that overlaps most
to write your own organdocs/ORGAN_SDK.mddefineOrgan() validates at declaration and throws with a field path; npm run check gates the whole repository

Why this exists

Every agent framework eventually becomes the same thing: a pile of tools, a growing list in the system prompt, and an agent that forgets everything between sessions.

It re-reads the same failure twice before learning it exists. It cannot tell you which of its own capabilities are broken. It has no idea that a plugin it depends on went offline — it just calls it and fails. And you keep paying tokens for tool schemas nobody calls.

Agent‑Body takes the opposite bet: treat the plugin system as an organism.

Every plugin declares itself an organ — with capabilities, senses, and reflexes. Everything else is physiology: a nervous system that routes your commands to the right organ, a heart that pumps state through the whole body on a rhythm, reflex arcs that fire without a single model call, and a healing loop that attributes every failure before it even thinks about retrying.

The result is a system that gets measurably better the more you use it, and that stays standing when you rip parts of it out.


What makes it different

🫀 It has a heartbeat, not a loop

A real pacemaker runs at a 1s base clock with a variable interval — 3× faster on critical alerts, 2× on fatigue, 2× slower when the body has been silent for a long while. Every beat packages the current operator directives, the body's proprioception and the homeostasis warnings into a blood packet, writes it to bloodstream.json, and broadcasts it as organism/heartbeat. Any organ can hook the circulation with one line:

ctx.on('organism/heartbeat', (blood) => { /* your organ now has a pulse */ })

Circulation is a loop, not a firehose: organs return blood through organism/venous, and newly learned knowledge is oxygenated (organism/oxygenated) before it is pumped system‑wide.

🧠 Your sentence becomes a nerve impulse

You type a command. Before the model even reasons about it, agent/pre-step converts it into an impulse, deterministically innervates the organs that should handle it, and broadcasts on organism/impulse — telling each organ which of its capabilities to use.

Then the body learns the route. When an innervated organ actually delivers, a Hebbian synapse strengthens "this kind of command → that organ"; when it fails, the weight decays. Dispatch order reorders itself from experience, persisted in synapses.json.

you:  "抓取这个站点并抽取结构化数据"
impulse → sensory(web-crawl) · executive(plan) · immune(verify)
        → each organ told which capability to fire

🩹 Self‑healing is a closed loop, not a slogan

failure → deterministic attribution → prescription → RE‑CHECK

Attribution is not guessing: tool_missing / arg_error / permission / timeout / network / not_found / conflict / unknown. The prescription table decides the response — read‑only remedies execute automatically, side‑effecting ones wait for the brain to rule, and arg_error is never auto‑retried (retrying a wrong argument just amplifies the mistake).

The wound only closes when that organ next succeeds — the system does not declare itself healed. Anything still open after 5 minutes is marked chronic and stops spinning.

Measured on the development install: 21 wounds healed · 100% heal rate · 0 chronic. An arg_error wound closed 3.5s after the underlying fix landed.

🌱 It trains itself — and forgets on purpose

Three learning channels run continuously, none of them requiring you to teach anything:

  1. Synaptic learning — success reinforces "command class → organ", failure weakens it.
  2. Reflex self‑authoring — the same tool × cause failing 3 times makes the system write its own reflex arc (R-auto--), which then fires automatically on the next occurrence.
  3. Chain crystallization — any cross‑organ chain that completes with ≥3 steps is fixed into a replayable skill.

Forgetting is equally deliberate: synapses decay on a 30‑minute half‑life and get pruned below `|w| title > body, multiplied by weight — and the most relevant cards are injected into context. Unused cards decay on a 168‑hour half‑life and archive instead of being deleted.

🪶 Zero‑residence context

Instead of lossy LLM summarization, the engin