agent-concepts 0.0.0-stage → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +771 -2
- package/concepts/bc-brainstorming/body/SKILL.md +43 -0
- package/concepts/bc-code-review/body/SKILL.md +120 -0
- package/concepts/bc-codebase-design/body/SKILL.md +54 -0
- package/concepts/bc-codebase-docs/body/SKILL.md +150 -0
- package/concepts/bc-council-audit-security/body/SKILL.md +72 -0
- package/concepts/bc-council-chain/body/SKILL.md +71 -0
- package/concepts/bc-council-challenge-plan/body/SKILL.md +78 -0
- package/concepts/bc-council-find-bugs/body/SKILL.md +70 -0
- package/concepts/bc-council-improve-architecture/body/SKILL.md +52 -0
- package/concepts/bc-council-mode/body/SKILL.md +56 -0
- package/concepts/bc-council-mode/body/examples/agents/README.md +11 -0
- package/concepts/bc-council-mode/body/examples/agents/council-change.md +14 -0
- package/concepts/bc-council-mode/body/examples/agents/council-compat.md +14 -0
- package/concepts/bc-council-mode/body/examples/agents/council-risk.md +14 -0
- package/concepts/bc-council-mode/body/references/pass-contracts.md +133 -0
- package/concepts/bc-delegate-investigation/body/SKILL.md +119 -0
- package/concepts/bc-delegate-investigation/body/examples/pi-settings-snippet.json +8 -0
- package/concepts/bc-delegate-investigation/body/pi.md +168 -0
- package/concepts/bc-design/body/SKILL.md +49 -0
- package/concepts/bc-design/body/design-framework.md +39 -0
- package/concepts/bc-design/body/existing-app.md +9 -0
- package/concepts/bc-design/body/new-work.md +22 -0
- package/concepts/bc-design/body/principles.md +34 -0
- package/concepts/bc-design/body/surfaces.md +13 -0
- package/concepts/bc-diagnosing-bugs/body/SKILL.md +83 -0
- package/concepts/bc-dispatching-parallel-agents/body/SKILL.md +63 -0
- package/concepts/bc-domain-modeling/body/SKILL.md +40 -0
- package/concepts/bc-executing-plans/body/SKILL.md +50 -0
- package/concepts/bc-explain-visually/body/SKILL.md +167 -0
- package/concepts/bc-find-bugs/body/SKILL.md +90 -0
- package/concepts/bc-finishing-development-branch/body/SKILL.md +73 -0
- package/concepts/bc-grilling/body/SKILL.md +22 -0
- package/concepts/bc-handoff/body/SKILL.md +104 -0
- package/concepts/bc-handoff/body/pickup.md +107 -0
- package/concepts/bc-handoff/body/writing.md +217 -0
- package/concepts/bc-improve-codebase-architecture/body/SKILL.md +101 -0
- package/concepts/bc-json-canvas/body/SKILL.md +40 -0
- package/concepts/bc-json-canvas/body/references/EXAMPLES.md +71 -0
- package/concepts/bc-json-canvas/body/references/SPEC.md +55 -0
- package/concepts/bc-json-canvas/body/references/VALIDATION.md +26 -0
- package/concepts/bc-minimal-solution-ladder/body/SKILL.md +120 -0
- package/concepts/bc-obsidian-bases/body/SKILL.md +59 -0
- package/concepts/bc-obsidian-bases/body/references/EXAMPLES.md +80 -0
- package/concepts/bc-obsidian-bases/body/references/FUNCTIONS.md +49 -0
- package/concepts/bc-obsidian-bases/body/references/SYNTAX.md +82 -0
- package/concepts/bc-obsidian-bases/body/references/TROUBLESHOOTING.md +41 -0
- package/concepts/bc-obsidian-markdown/body/SKILL.md +47 -0
- package/concepts/bc-obsidian-markdown/body/references/CALLOUTS.md +40 -0
- package/concepts/bc-obsidian-markdown/body/references/EMBEDS.md +35 -0
- package/concepts/bc-obsidian-markdown/body/references/PROPERTIES.md +37 -0
- package/concepts/bc-optimize-code/body/SKILL.md +41 -0
- package/concepts/bc-performance-guardrails/body/SKILL.md +53 -0
- package/concepts/bc-performance-guardrails/body/measuring.md +29 -0
- package/concepts/bc-performance-guardrails/body/targets.md +20 -0
- package/concepts/bc-pipeline-to-done/body/SKILL.md +205 -0
- package/concepts/bc-pipeline-to-done/body/agents/bc-drain-auditor.md +19 -0
- package/concepts/bc-pipeline-to-done/body/agents/bc-drain-reviewer.md +19 -0
- package/concepts/bc-pipeline-to-done/body/agents/bc-drain-worker.md +19 -0
- package/concepts/bc-pipeline-to-done/body/execute-issue.md +71 -0
- package/concepts/bc-pipeline-to-done/body/recovery-bundle.md +79 -0
- package/concepts/bc-pipeline-to-done/body/review-contract.md +105 -0
- package/concepts/bc-pipeline-to-done/body/roles.md +13 -0
- package/concepts/bc-pipeline-to-done/body/scripts/publish-check.py +172 -0
- package/concepts/bc-pipeline-to-done/body/source-issues.md +86 -0
- package/concepts/bc-pipeline-to-done/body/source-work-items.md +76 -0
- package/concepts/bc-plain-language/body/SKILL.md +134 -0
- package/concepts/bc-plan-slicing/body/SKILL.md +56 -0
- package/concepts/bc-plan-to-pipeline/body/SKILL.md +89 -0
- package/concepts/bc-prd-drafting/body/SKILL.md +43 -0
- package/concepts/bc-prompting-agents/body/SKILL.md +278 -0
- package/concepts/bc-prototype/body/SKILL.md +40 -0
- package/concepts/bc-qmd/body/SKILL.md +64 -0
- package/concepts/bc-research/body/SKILL.md +26 -0
- package/concepts/bc-security-audit/body/AI-AND-LLM.md +25 -0
- package/concepts/bc-security-audit/body/ATTACK-CLASSES.md +35 -0
- package/concepts/bc-security-audit/body/DESKTOP-MOBILE-AND-LOCAL-IPC.md +28 -0
- package/concepts/bc-security-audit/body/RECONNAISSANCE.md +49 -0
- package/concepts/bc-security-audit/body/SKILL.md +117 -0
- package/concepts/bc-security-audit/body/SUPPLY-CHAIN-AND-RELEASE.md +28 -0
- package/concepts/bc-security-audit/body/VALIDATION-AND-REPORTING.md +124 -0
- package/concepts/bc-security-audit/body/WEB-PROTOCOL-AND-AUTH.md +27 -0
- package/concepts/bc-security-audit/body/validate_audit.py +151 -0
- package/concepts/bc-self-improve/body/SKILL.md +104 -0
- package/concepts/bc-seo/body/CITATIONS.md +23 -0
- package/concepts/bc-seo/body/IMAGE-SEO.md +350 -0
- package/concepts/bc-seo/body/SKILL.md +453 -0
- package/concepts/bc-setup-project/body/SKILL.md +252 -0
- package/concepts/bc-setup-project/body/scaffold.py +2751 -0
- package/concepts/bc-setup-project/body/starter-items.md +157 -0
- package/concepts/bc-setup-project/body/work-data.md +114 -0
- package/concepts/bc-setup-project/body/work_index.py +626 -0
- package/concepts/bc-setup-project/body/work_spent.py +220 -0
- package/concepts/bc-subagent-driven-development/body/SKILL.md +61 -0
- package/concepts/bc-tdd/body/SKILL.md +184 -0
- package/concepts/bc-tdd/body/formal.md +77 -0
- package/concepts/bc-tdd/body/mocking.md +49 -0
- package/concepts/bc-tdd/body/properties.md +59 -0
- package/concepts/bc-tdd/body/refactoring.md +12 -0
- package/concepts/bc-tdd/body/scripts/confirm-red.py +136 -0
- package/concepts/bc-tdd/body/tests.md +59 -0
- package/concepts/bc-teach/body/GLOSSARY-FORMAT.md +36 -0
- package/concepts/bc-teach/body/LEARNING-RECORD-FORMAT.md +60 -0
- package/concepts/bc-teach/body/MISSION-FORMAT.md +34 -0
- package/concepts/bc-teach/body/RESOURCES-FORMAT.md +53 -0
- package/concepts/bc-teach/body/REVIEW-FORMAT.md +48 -0
- package/concepts/bc-teach/body/SKILL.md +281 -0
- package/concepts/bc-teach/body/WIKI-FORMAT.md +58 -0
- package/concepts/bc-teach/body/scripts/due.py +65 -0
- package/concepts/bc-to-spec/body/SKILL.md +21 -0
- package/concepts/bc-to-tickets/body/SKILL.md +21 -0
- package/concepts/bc-triage/body/AGENT-BRIEF.md +38 -0
- package/concepts/bc-triage/body/OUT-OF-SCOPE.md +51 -0
- package/concepts/bc-triage/body/SKILL.md +81 -0
- package/concepts/bc-unslop/body/SKILL.md +269 -0
- package/concepts/bc-using-git-worktrees/body/SKILL.md +91 -0
- package/concepts/bc-wiki-maintain/body/SKILL.md +361 -0
- package/concepts/bc-wiki-maintain/body/runner/README.md +552 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-lint.service +24 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-lint.timer +15 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-maintain-all.service +29 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-maintain-all.timer +16 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-maintain.service +28 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-maintain.timer +12 -0
- package/concepts/bc-wiki-maintain/body/runner/bc-wiki-notify@.service +15 -0
- package/concepts/bc-wiki-maintain/body/runner/notify-failure.sh +92 -0
- package/concepts/bc-wiki-maintain/body/runner/run-lint.sh +69 -0
- package/concepts/bc-wiki-maintain/body/runner/run-promotion-all.sh +103 -0
- package/concepts/bc-wiki-maintain/body/runner/run-promotion.sh +270 -0
- package/concepts/bc-wiki-maintain/body/wiki_lint.py +958 -0
- package/concepts/bc-wiki-maintain/body/wiki_search.py +206 -0
- package/concepts/bc-work-sync/body/PLAN.md +46 -0
- package/concepts/bc-work-sync/body/SKILL.md +71 -0
- package/concepts/bc-writing-plans/body/SKILL.md +79 -0
- package/package.json +130 -4
- package/packages/agent-kernel-pi/AGENT-KERNEL.md +109 -0
- package/packages/agent-kernel-pi/index.js +8 -0
- package/packages/agent-kernel-pi/package.json +12 -0
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
# Starter items
|
|
2
|
+
|
|
3
|
+
Setup offers these follow-up items in its init plan. The first four are for a project that already has source code; the last two are for a new or empty project, where the checks and design notes are cheapest to set up before the first code lands. Each section heading is the item's filename slug; copy only the fenced text into the work item. Replace `{{stage}}` with a stage from the project's `Stages:` line and `{{date}}` with the setup date (`YYYY-MM-DD`). Every item here is already planned by this reference, so `work_index.py --check` does not ask for `bc-plan-to-pipeline`; only the two ready items carry `Ready for agent: yes`, because the owner-led items wait on the owner's own command.
|
|
4
|
+
|
|
5
|
+
## design-inventory
|
|
6
|
+
|
|
7
|
+
Applies when: the survey finds a user-facing UI or CLI, for example a front-end framework, UI templates or styles, or a CLI entry point with user-facing output.
|
|
8
|
+
|
|
9
|
+
```markdown
|
|
10
|
+
# Inventory the existing design
|
|
11
|
+
|
|
12
|
+
Why: The project's existing design is not recorded, so new work can duplicate controls or introduce a second theme.
|
|
13
|
+
Done when: The current design has a documented reuse path and text-search checks catch new departures without failing on existing ones.
|
|
14
|
+
Stage: {{stage}}
|
|
15
|
+
Blocked by: nothing
|
|
16
|
+
Kind: design
|
|
17
|
+
Source: bc-setup-project
|
|
18
|
+
Planned: bc-setup-project {{date}}
|
|
19
|
+
Ready for agent: yes
|
|
20
|
+
|
|
21
|
+
## Steps
|
|
22
|
+
|
|
23
|
+
- [ ] Inventory the current surfaces following `bc-design`'s `existing-app.md` and `design-framework.md`. Record the existing themes, tokens by role, control kinds and where to reuse them on design pages linked under Pages in `docs/design/README.md`. Done when the pages point to the current implementations and distinguish shared controls from one-offs. Out of scope: redesigning surfaces, adding tokens or replacing existing controls.
|
|
24
|
+
- [ ] For control rules that can be checked by text search, add checks to the project's own test runner and list them under Checks in `docs/design/README.md`. Name the part to reuse and the design-page rule in each diagnostic; record current hits in a per-file baseline that may only fall. Done when the checks pass at the recorded baseline and catch a new violation. Out of scope: fixing baseline hits or encoding visual-only judgments as text rules.
|
|
25
|
+
|
|
26
|
+
## Outcome
|
|
27
|
+
|
|
28
|
+
_To be filled when finished or dropped._
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## guardrails-setup-checks
|
|
32
|
+
|
|
33
|
+
Applies when: the survey finds project source code.
|
|
34
|
+
|
|
35
|
+
```markdown
|
|
36
|
+
# Add guardrails setup checks
|
|
37
|
+
|
|
38
|
+
Why: Known problems for this stack can creep in without a check, but existing shortfalls should not block unrelated work.
|
|
39
|
+
Done when: Each selected stack risk has a sourced check in the project gate with a limit based on the project's measured starting point.
|
|
40
|
+
Stage: {{stage}}
|
|
41
|
+
Blocked by: nothing
|
|
42
|
+
Kind: performance
|
|
43
|
+
Source: bc-setup-project
|
|
44
|
+
Planned: bc-setup-project {{date}}
|
|
45
|
+
Ready for agent: yes
|
|
46
|
+
|
|
47
|
+
## Steps
|
|
48
|
+
|
|
49
|
+
- [ ] Follow `bc-performance-guardrails`' Setup checks: choose checks for known problems of this stack that have an official source, published guideline or past project bug. Measure the current value before setting each limit and record the source, measure, command and baseline in `docs/guardrails/README.md`. Done when every proposed check has a source and a reproducible current measurement. Out of scope: unsourced checks, invented budgets and performance fixes.
|
|
50
|
+
- [ ] Run the checks inside `./scripts/gate` and ratchet each at today's measured value. Record how to tighten the limit as the measure improves. Done when the new checks pass at baseline and fail on a controlled regression. Out of scope: optimizing the code or raising a limit to hide a regression; file improvements separately for `bc-optimize-code`.
|
|
51
|
+
|
|
52
|
+
## Outcome
|
|
53
|
+
|
|
54
|
+
_To be filled when finished or dropped._
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## architecture-review
|
|
58
|
+
|
|
59
|
+
Applies when: the survey finds project source code. The owner can leave this out when a review is not needed.
|
|
60
|
+
|
|
61
|
+
```markdown
|
|
62
|
+
# Review the codebase architecture
|
|
63
|
+
|
|
64
|
+
Why: An existing codebase may have structural friction worth reviewing before taking on larger changes.
|
|
65
|
+
Done when: The owner has reviewed the architecture and recorded which findings, if any, to take forward.
|
|
66
|
+
Stage: {{stage}}
|
|
67
|
+
Blocked by: nothing
|
|
68
|
+
Kind: architecture
|
|
69
|
+
Needs owner: Run `/bc-improve-codebase-architecture` when ready to lead the review.
|
|
70
|
+
Source: bc-setup-project
|
|
71
|
+
Planned: bc-setup-project {{date}}
|
|
72
|
+
|
|
73
|
+
## Steps
|
|
74
|
+
|
|
75
|
+
- [ ] Owner starts the interactive review and decides what to take forward.
|
|
76
|
+
|
|
77
|
+
## Outcome
|
|
78
|
+
|
|
79
|
+
_To be filled when finished or dropped._
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## issue-triage
|
|
83
|
+
|
|
84
|
+
Applies when: the survey confirms open GitHub issues with `gh issue list`. If `gh` is unavailable or the listing fails, do not infer that the project has open issues.
|
|
85
|
+
|
|
86
|
+
```markdown
|
|
87
|
+
# Triage the open GitHub issues
|
|
88
|
+
|
|
89
|
+
Why: Existing issues need decisions about what belongs in the project's work queue.
|
|
90
|
+
Done when: The owner has triaged the open issues and recorded their dispositions.
|
|
91
|
+
Stage: {{stage}}
|
|
92
|
+
Blocked by: nothing
|
|
93
|
+
Kind: none
|
|
94
|
+
Needs owner: Run `/bc-triage` when ready to decide which issues to take forward.
|
|
95
|
+
Source: bc-setup-project
|
|
96
|
+
Planned: bc-setup-project {{date}}
|
|
97
|
+
|
|
98
|
+
## Steps
|
|
99
|
+
|
|
100
|
+
- [ ] Owner starts interactive triage and decides what to do with the open issues.
|
|
101
|
+
|
|
102
|
+
## Outcome
|
|
103
|
+
|
|
104
|
+
_To be filled when finished or dropped._
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
## guardrails-for-new-project
|
|
108
|
+
|
|
109
|
+
Applies when: the survey finds no project source code yet (a new or empty project).
|
|
110
|
+
|
|
111
|
+
```markdown
|
|
112
|
+
# Plan guardrails checks for the first code
|
|
113
|
+
|
|
114
|
+
Why: Known problems for the planned stack are cheapest to catch from the first commit, before any shortfall builds up.
|
|
115
|
+
Done when: Each chosen stack risk has a sourced check in the project gate, with a limit measured on the project's first code.
|
|
116
|
+
Stage: {{stage}}
|
|
117
|
+
Blocked by: nothing
|
|
118
|
+
Kind: performance
|
|
119
|
+
Source: bc-setup-project
|
|
120
|
+
Planned: bc-setup-project {{date}}
|
|
121
|
+
Ready for agent: yes
|
|
122
|
+
|
|
123
|
+
## Steps
|
|
124
|
+
|
|
125
|
+
- [ ] Follow `bc-performance-guardrails`' Setup checks for the planned stack: choose checks for its known problems that have an official source or published guideline, and list each with its source and the command that will measure it in `docs/guardrails/README.md`, marked as having no limit yet. Done when every chosen check has a source and a measuring command. Out of scope: limits, since there is no code yet to measure, and unsourced checks.
|
|
126
|
+
- [ ] Once the project has its first working code, add the checks to `./scripts/gate`, measure today's value and set each limit there. If there is no code yet, leave this step open; it does not block any other item. Done when the checks pass at the measured limit and fail on a controlled regression. Out of scope: optimizing code or raising a limit to hide a regression.
|
|
127
|
+
|
|
128
|
+
## Outcome
|
|
129
|
+
|
|
130
|
+
_To be filled when finished or dropped._
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
## design-for-new-project
|
|
134
|
+
|
|
135
|
+
Applies when: the survey finds no project source code yet and the owner plans a user-facing UI or CLI.
|
|
136
|
+
|
|
137
|
+
```markdown
|
|
138
|
+
# Record the intended design before the first UI
|
|
139
|
+
|
|
140
|
+
Why: Writing down the intended look and controls before the first screen keeps later work from inventing a second theme or a duplicate control.
|
|
141
|
+
Done when: The intended design is recorded on design pages and text-search checks catch departures from it once there is UI code.
|
|
142
|
+
Stage: {{stage}}
|
|
143
|
+
Blocked by: nothing
|
|
144
|
+
Kind: design
|
|
145
|
+
Source: bc-setup-project
|
|
146
|
+
Planned: bc-setup-project {{date}}
|
|
147
|
+
Ready for agent: yes
|
|
148
|
+
|
|
149
|
+
## Steps
|
|
150
|
+
|
|
151
|
+
- [ ] Follow `bc-design`'s `new-work.md` and `design-framework.md` to record the intended themes, tokens by role and the kinds of control the project will use, on design pages linked under Pages in `docs/design/README.md`. Done when the pages name each theme, token role and control kind, marked as the agent's choice the owner may change. Out of scope: building screens or controls.
|
|
152
|
+
- [ ] Once the project has UI or CLI code, add text-search checks for the recorded control rules to the project's own test runner and list them under Checks in `docs/design/README.md`; name the part to reuse and the design-page rule in each failure message. If there is no code yet, leave this step open; it does not block any other item. Done when the checks pass and catch a new violation. Out of scope: visual-only judgments as text rules.
|
|
153
|
+
|
|
154
|
+
## Outcome
|
|
155
|
+
|
|
156
|
+
_To be filled when finished or dropped._
|
|
157
|
+
```
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# Work data: the `work_index.py --json` fields
|
|
2
|
+
|
|
3
|
+
`python3 .bc-agent/scripts/work_index.py --json [work-dir]` prints one JSON object describing every work item in `work/1-planned/`, `work/2-active/`, `work/3-done/` and `work/4-dropped/` (month folders included). It writes no files, so a dashboard can run it as often as it likes. This page lists every field, where it comes from, and whether you can rely on it.
|
|
4
|
+
|
|
5
|
+
- **Stable**: the field exists in every output with this format version, and its meaning does not change. A missing source line gives `null` (or an empty list), never a missing key.
|
|
6
|
+
- **Best-effort**: the field is read from text people and agents write by hand, so it can be missing, stale or loosely formatted. Show it, but do not build logic that breaks when it is odd.
|
|
7
|
+
|
|
8
|
+
`format_version` changes only on a breaking change (a field removed, renamed or given a new meaning). New fields are added without a version change, so ignore keys you do not know.
|
|
9
|
+
|
|
10
|
+
## Top level
|
|
11
|
+
|
|
12
|
+
| Field | Source | Reliability |
|
|
13
|
+
|---|---|---|
|
|
14
|
+
| `format_version` | the script (currently `1`) | stable |
|
|
15
|
+
| `stages` | the `Stages:` line in `.bc-agent/AGENTS.md` (default `now, next, later, unscheduled`) | stable |
|
|
16
|
+
| `items` | one entry per item file or folder, ordered planned, active, done, dropped, then by folder and name | stable |
|
|
17
|
+
|
|
18
|
+
## Per item
|
|
19
|
+
|
|
20
|
+
| Field | Source | Reliability |
|
|
21
|
+
|---|---|---|
|
|
22
|
+
| `number` | the first three digits of the item name (`025`) | stable |
|
|
23
|
+
| `slug` | the item name after the number (`dashboard-data`) | stable |
|
|
24
|
+
| `name` | the full item name (`025-dashboard-data`) | stable |
|
|
25
|
+
| `folder` | the lifecycle folder: `planned`, `active`, `done` or `dropped` | stable |
|
|
26
|
+
| `path` | the item file relative to `work/` (`2-active/025-dashboard-data/plan.md`) | stable |
|
|
27
|
+
| `title` | the first `# ` heading | best-effort |
|
|
28
|
+
| `header` | the header lines below (an object) | stable keys, best-effort values |
|
|
29
|
+
| `steps` | the `- [ ]` / `- [x]` lines under `## Steps` (a list) | stable keys, best-effort values |
|
|
30
|
+
| `outcome` | the text under `## Outcome`, trimmed; `null` when the section is missing or empty (may still be the template placeholder) | best-effort |
|
|
31
|
+
| `history` | folder moves and step ticks, oldest first, from one `git log --follow` on the item file (renames followed); `[]` when the file is uncommitted, outside a git repository or git is missing. Uncommitted moves and ticks are not shown yet | best-effort |
|
|
32
|
+
| `held_by` | the `Held by:` line parsed (below); `null` when the item has none | best-effort |
|
|
33
|
+
| `spent` | the `Spent:` line in the Outcome, parsed (below); `null` when the Outcome has none | best-effort |
|
|
34
|
+
|
|
35
|
+
## Header lines (`header`)
|
|
36
|
+
|
|
37
|
+
Each value is the text after the label on its line, trimmed, or `null` when the line is absent or empty. The values are the raw text, not validated; the non-JSON run of the script and `--check` validate open items.
|
|
38
|
+
|
|
39
|
+
| Field | Line | Reliability |
|
|
40
|
+
|---|---|---|
|
|
41
|
+
| `why` | `Why:` | best-effort |
|
|
42
|
+
| `done_when` | `Done when:` | best-effort |
|
|
43
|
+
| `stage` | `Stage:` | stable for open items (the script rejects unknown stages); best-effort otherwise |
|
|
44
|
+
| `blocked_by` | `Blocked by:` (comma-separated item names or `nothing`) | stable for open items; best-effort otherwise |
|
|
45
|
+
| `kind` | `Kind:` | best-effort |
|
|
46
|
+
| `needs_owner` | `Needs owner:` (what the owner must decide or do, and when) | best-effort |
|
|
47
|
+
| `changes_ui` | `Changes UI:` (what the user will see change) | best-effort |
|
|
48
|
+
| `source` | `Source:` | best-effort |
|
|
49
|
+
| `planned` | `Planned:` | best-effort |
|
|
50
|
+
| `ready_for_agent` | `Ready for agent:` (`yes` when set) | best-effort |
|
|
51
|
+
| `waiting_on_owner` | `Waiting on owner:` (the owner question) | best-effort |
|
|
52
|
+
| `held_by` | `Held by:` (the raw line; parsed in the item's `held_by` field) | best-effort |
|
|
53
|
+
|
|
54
|
+
## Held by (`held_by`)
|
|
55
|
+
|
|
56
|
+
`Held by: <tool> <session> since <YYYY-MM-DD HH:MM> <UTC or +HH:MM>` names the agent working on the item: its tool (`pi`, `claude-code`, `codex`, ...), its session name or id (no spaces), and when it started, in UTC or local time with its offset (`Held by: pi swift-otter since 2026-11-25 14:05 +01:00`). The agent writes it when it starts or resumes the item and removes it when it stops or the item closes, so a crashed agent leaves a stale line; judge staleness from the age.
|
|
57
|
+
|
|
58
|
+
| Field | Source | Reliability |
|
|
59
|
+
|---|---|---|
|
|
60
|
+
| `tool`, `session`, `since` | the parts of the line; all `null` when the line does not match the format (`--check` warns) | best-effort |
|
|
61
|
+
| `committed` | committer date (ISO 8601) of the last commit that added or removed this exact line, from `git log -S`; `null` when the line is uncommitted or there is no git | best-effort |
|
|
62
|
+
| `age_seconds` | seconds from `committed` to now; `null` with it | best-effort |
|
|
63
|
+
|
|
64
|
+
## History events (`history[]`)
|
|
65
|
+
|
|
66
|
+
Every event has `event`, `date` (the commit's committer date, ISO 8601) and `commit` (the full SHA). Read from git, so a squashed or rewritten history shows fewer events, and a commit that splits a file below git's rename similarity breaks the trail.
|
|
67
|
+
|
|
68
|
+
| `event` | Extra fields | Meaning |
|
|
69
|
+
|---|---|---|
|
|
70
|
+
| `created` | `folder` | the commit that first added the item file |
|
|
71
|
+
| `moved` | `from`, `to` (lifecycle folders) | a commit that moved the item to another lifecycle folder (a move between month folders is not an event) |
|
|
72
|
+
| `ticked` | `step` (the first line of the step, without inline Notes) | a commit that turned `- [ ]` into `- [x]` for that step; ticks already present when the file was added are not events |
|
|
73
|
+
|
|
74
|
+
## Steps (`steps[]`)
|
|
75
|
+
|
|
76
|
+
| Field | Source | Reliability |
|
|
77
|
+
|---|---|---|
|
|
78
|
+
| `text` | the step line and its indented continuation lines (joined with newlines), without the `Notes:` part | best-effort |
|
|
79
|
+
| `checked` | `[x]` or `[X]` is `true`, `[ ]` is `false` | stable |
|
|
80
|
+
| `notes` | the text after `Notes:`, inline in the step or on an indented line below it; `null` when there is none | best-effort |
|
|
81
|
+
| `review` | the `Review:` lines in the Notes, parsed (below); `[]` when there are none | stable keys, best-effort values |
|
|
82
|
+
| `gate` | the `Gate:` lines in the Notes, parsed (below); `[]` when there are none | stable keys, best-effort values |
|
|
83
|
+
|
|
84
|
+
## Review and Gate (`steps[].review[]`, `steps[].gate[]`)
|
|
85
|
+
|
|
86
|
+
Each result is one line in the step's Notes, starting its own line (an indented line under the step, or right after `Notes:`), oldest first; a later round adds a line rather than replacing one.
|
|
87
|
+
|
|
88
|
+
- `Review: <approved | changes requested> by <reviewer> <YYYY-MM-DD>`: a review verdict and who gave it (a reviewer agent or role, or `owner`), for example `Review: approved by reviewer 2026-11-25`.
|
|
89
|
+
- `Gate: <pass | fail> <command> at <commit> <YYYY-MM-DD>`: one run of the project's check command as run, and the short or full SHA the checked tree was built on, for example `Gate: pass make check at 3f2a9c1 2026-11-25`.
|
|
90
|
+
|
|
91
|
+
| Field | Source | Reliability |
|
|
92
|
+
|---|---|---|
|
|
93
|
+
| `review[].result`, `reviewer`, `date` | the parts of a `Review:` line; all `null` when it does not match the format (`--check` warns) | best-effort |
|
|
94
|
+
| `gate[].result`, `command`, `commit`, `date` | the parts of a `Gate:` line; all `null` when it does not match the format (`--check` warns) | best-effort |
|
|
95
|
+
| `text` (both) | the line after its label, trimmed | best-effort |
|
|
96
|
+
|
|
97
|
+
## Spent (`spent`)
|
|
98
|
+
|
|
99
|
+
`Spent: <active time> active, <tokens> tokens, <cost> (estimated; <sources>)` is the last line of a finished item's `## Outcome`, for example `Spent: 2h 10m active, 3.4M tokens, $5.20 (estimated; pi 3 sessions, claude-code no files, codex 0 sessions; other tools not counted)`. The agent that finishes the item pastes it from `python3 .bc-agent/scripts/work_spent.py <item-name>` (`--json` lists the counted sessions). When no session is counted, the line is `Spent: not measured (no agent session for this item was found)` instead of zeros; its `spent` fields are `null`, with the line in `text`, and `--check` accepts it.
|
|
100
|
+
|
|
101
|
+
The script takes the item's active period from its history (first move into `2-active/` to its move out, or now) and counts every session with an entry in that period whose working folder is the project or one of its git worktrees and whose file mentions the item name. Active time sums the gaps between a session's entries in the period, each capped at 15 minutes, so parallel sessions add up. Tokens include cache reads and writes. It reads Pi (`~/.pi/agent/sessions`, with cost), Claude Code (`~/.claude/projects`, tokens only) and Codex (`~/.codex/sessions`, tokens only); `<sources>` gives each tool's session count, or `no files` when its folder is missing, and other tools are not counted. A session that mentions the item only in passing is counted; a worktree removed before the item closes is not matched, but a Pi child (subagent) session, kept under its parent's folder (`<parent-id>/.../*.jsonl` beside `<parent-id>.jsonl`), counts when its parent counts, whatever its folder and whether or not it names the item, as long as it has an entry in the period; a child that matches on its own is counted once, and `--json` gives each session's `via` (`match` or `child of <parent file>`). `WORK_SPENT_PI_SESSIONS`, `WORK_SPENT_CLAUDE_SESSIONS` and `WORK_SPENT_CODEX_SESSIONS` override the folders.
|
|
102
|
+
|
|
103
|
+
Read the estimate as a rough size, not a bill. Its known limits:
|
|
104
|
+
|
|
105
|
+
- **Parallel sessions add up.** Two sessions working at the same time count twice, so active time can be longer than the time that passed.
|
|
106
|
+
- **Child sessions count whole.** A child (subagent) session of a counted session is counted for its time in the period, even if that child worked on a different item.
|
|
107
|
+
- **Some sessions are missed or counted wrongly.** A session that only mentions the item in passing is counted; a session in a git worktree that was removed before the item closed is not found (unless it is a child of a counted session); Claude Code and Codex give no cost; other tools are not read at all.
|
|
108
|
+
|
|
109
|
+
| Field | Source | Reliability |
|
|
110
|
+
|---|---|---|
|
|
111
|
+
| `active`, `tokens`, `cost`, `sources` | the parts of the line as written (`1h 5m`, `2.5M`, `$3.10` or `cost unknown`, the text after `estimated; `); all `null` when it does not match the format (`--check` warns) | best-effort |
|
|
112
|
+
| `text` | the line after its label, trimmed | best-effort |
|
|
113
|
+
|
|
114
|
+
Why the records live in work-item lines and git history rather than in a separate store: the agent-concepts repository's decision record `docs/decisions/0003-work-data-lives-in-work-item-lines.md`.
|