Context
Follow-up to AgentWorkforce/burn#373.
AgentWorkforce should provide default-on persona cost attribution without requiring users to install burn separately and without routing launches through burn run. Burn remains domain-neutral; AgentWorkforce writes generic enrichment tags and burn reports on tags.
Blocked by
Desired changes
- Depend on
@relayburn/sdk 2.x only. Do not use deprecated TS 1.x burn packages.
- Keep AgentWorkforce as the direct launcher for
claude, codex, and opencode; do not use burn run.
- Preserve persona source metadata during resolution so launches can stamp
personaSource and, for local personas, enough debug context to identify the source layer.
- Compute
personaVersion from the effective resolved persona spec after cascade/extends merge and before runtime input substitution:
- stable-key canonical JSON
- SHA-256 full hex hash
- optional 12-character short form for display only
- Wrap existing harness launch with burn bookkeeping:
- before spawn, call
sdk.writePendingStamp(...) with generic enrichment tags
- while child runs, periodically call
sdk.ingest({ harness })
- after exit/error, stop polling and run one final ingest
- preserve the harness exit code exactly
- Stamp at least these tags:
agentworkforce=1
persona=<id>
personaTier=<tier>
personaVersion=<full sha256>
personaSource=<cwd|user|dir:n|library>
- Add opt-out controls:
agentworkforce agent --no-burn <persona>[@tier]
AGENTWORKFORCE_BURN=0
- Update docs to show generic burn queries after burn#373 lands, e.g.
burn summary --tag persona=code-reviewer and burn summary --group-by-tag persona.
Acceptance criteria
- A normal persona launch writes burn attribution tags by default once burn#373 is available.
- Users do not need a separately installed
burn binary for this attribution path.
--no-burn and AGENTWORKFORCE_BURN=0 skip stamp writing, periodic ingest, final ingest, and burn summary output.
- Periodic/final ingest is attempted on success, nonzero exit, and spawn error; child exit code is preserved.
- Persona hash is stable under object key reordering and changes when effective persona content changes.
- Unit tests cover default tracking, opt-out, tag payload, version hashing, and exit-code preservation.
Notes
The burn side should stay generic. Do not add burn summary --persona; use tag filtering/grouping from burn#373.
Context
Follow-up to AgentWorkforce/burn#373.
AgentWorkforce should provide default-on persona cost attribution without requiring users to install
burnseparately and without routing launches throughburn run. Burn remains domain-neutral; AgentWorkforce writes generic enrichment tags and burn reports on tags.Blocked by
@relayburn/sdk2.x pending-stamp primitives and genericburn summary --tag/--group-by-tagreporting.Desired changes
@relayburn/sdk2.x only. Do not use deprecated TS 1.x burn packages.claude,codex, andopencode; do not useburn run.personaSourceand, for local personas, enough debug context to identify the source layer.personaVersionfrom the effective resolved persona spec after cascade/extends merge and before runtime input substitution:sdk.writePendingStamp(...)with generic enrichment tagssdk.ingest({ harness })agentworkforce=1persona=<id>personaTier=<tier>personaVersion=<full sha256>personaSource=<cwd|user|dir:n|library>agentworkforce agent --no-burn <persona>[@tier]AGENTWORKFORCE_BURN=0burn summary --tag persona=code-reviewerandburn summary --group-by-tag persona.Acceptance criteria
burnbinary for this attribution path.--no-burnandAGENTWORKFORCE_BURN=0skip stamp writing, periodic ingest, final ingest, and burn summary output.Notes
The burn side should stay generic. Do not add
burn summary --persona; use tag filtering/grouping from burn#373.