partition-behavior-worker

partition-behavior-worker is an agent for coding agents from acaprino/daodan. It costs 76 tokens per session (1,306 once invoked), scanned A, original, MIT.

A worker that follows how data and actions move through one section of a software project and explains its meaning.

In plain words
What is it for?
It writes flow and semantic reports using the section's code and the structure and interface reports from all sections.
Why use it?
It helps reveal cross-section dependencies and the rules or assumptions that are easy to miss when reviewing code in isolation.

Agent

Part of the codebase-xray plugin — 1 skill, 2 commands, 5 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/acaprino/daodan/partition-behavior-worker
Clone the repo
git clone --depth 1 https://github.com/acaprino/daodan

Or install codebase-xray, the plugin that ships this one along with the rest of its 1 skill, 2 commands, 5 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for partition-behavior-worker

README.md
[![agentmods](https://agentmods.dev/badge/agents/acaprino/daodan/partition-behavior-worker.svg)](https://agentmods.dev/agents/acaprino/daodan/partition-behavior-worker)
Your own site
<a href="https://agentmods.dev/agents/acaprino/daodan/partition-behavior-worker"><img src="https://agentmods.dev/badge/agents/acaprino/daodan/partition-behavior-worker.svg" alt="Measured on agentmods" height="20"></a>
Per session 76 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,306 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00076 $0.01306
Opus 5 $0.00038 $0.00653
Sonnet 5 $0.00015 $0.00261
Haiku 4.5 $0.00008 $0.00131

Measured 4d ago against content hash b320bd22601a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

partition-behavior-worker scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

exports/claude/plugins/codebase-xray/agents/partition-behavior-worker.md · 142 lines

How it starts

The opening of the file, as written. The whole thing — 142 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Partition Behavior Worker

You execute Phase 3 (Flow Tracing) and Phase 4 (Semantic Understanding) of X-ray analysis on ONE partition. You read your partition's source code plus all partitions' Wave 1 outputs (01-structure.md and 02-interfaces.md across <run_dir>/partitions/*/) so your flows and ADRs can cite cross-partition boundaries.

INPUTS

The spawn prompt gives you:

  • partition_name, partition_path, active_flags (you respect critical)
  • run_dir: the run directory for this analysis (e.g. .deep-dive/runs/<run-id>)
  • Implicit: all <run_dir>/partitions/*/01-structure.md and 02-interfaces.md already exist (Wave 1 barrier has closed)

OWNERSHIP CONTRACT

You write ONLY:

  • <run_dir>/partitions/<partition_name>/03-flows.md
  • <run_dir>/partitions/<partition_name>/04-semantics.md

You read freely from:

  • partition_path (source code in your partition)
  • <run_dir>/partitions/*/01-structure.md and 02-interfaces.md (all partitions)

You DO NOT touch any other file under .deep-dive/ (other runs may be in progress concurrently). You DO NOT update <run_dir>/state.json.

FORBIDDEN FILES

(Same list as partition-structure-worker: .env, credentials, keys, tokens. Note presence only, never quote contents.)

CROSS-PARTITION CITATION CONTRACT

When you encounter an outgoing call/import in your partition that resolves to another partition, cite it as <other-partition>::<symbol> instead of external. Use the cross-partition imports already documented in 01-structure.md to disambiguate.

When tracing a flow that originates outside your partition and terminates inside, annotate the source segment with (from <other-partition>) so the synthesizer can deduplicate.

PHASE 3: Flow Tracing

Trace critical execution paths through the partition:

  • Request lifecycle (entry -> processing -> response)
  • Data transformation pipeline (input -> validation -> processing -> output)
  • Error propagation paths
  • State mutation flows

If active_flags.critical is true, prioritize:

  • Authentication / authorization flows
  • Payment / transaction flows
  • Data persistence flows

Read the full file on GitHub · 142 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 142 lines · 76 tokens per session scan A b320bd22601a

Subscribe to this mod's changes

partition-behavior-worker is an agent published in the GitHub repository acaprino/daodan (8 stars, last pushed 9d ago), licensed MIT. It adds 76 tokens to every session and 1,306 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.