bearings 0.2.0 → 0.3.1
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/README.md +10 -12
- package/dist/chunk-VRWQ3OWC.js +654 -0
- package/dist/cli.js +54 -377
- package/dist/update-5F7TZEUH.js +799 -0
- package/package.json +1 -1
- package/templates/AGENTS.md +18 -33
- package/templates/agents/commands/refresh-repo-map.md +161 -0
- package/templates/agents/commands/setup-repo.md +66 -32
- package/templates/agents/skills/commit-convention/SKILL.md +83 -20
- package/templates/agents/skills/defer-work/SKILL.md +2 -2
- package/templates/agents/skills/recording-decisions/SKILL.md +51 -0
- package/templates/agents/skills/resurface-deferred-work/SKILL.md +2 -2
- package/templates/docs/ARCHITECTURE.md +37 -0
- package/templates/docs/CODEBASE_MAP.md +33 -0
- package/templates/docs/DOMAIN.md +33 -0
- package/templates/docs/adr/0000-template.md +12 -0
- package/templates/docs/adr/INDEX.md +6 -0
- package/templates/docs/deferred/INDEX.md +5 -3
- package/templates/agents/commands/current-state.md +0 -163
- package/templates/agents/skills/enforcement-gates/SKILL.md +0 -35
- package/templates/agents/skills/implementing-task/SKILL.md +0 -36
- package/templates/agents/skills/installing-dependencies/SKILL.md +0 -36
- package/templates/agents/skills/repo-navigation/SKILL.md +0 -34
- package/templates/agents/skills/secrets-handling/SKILL.md +0 -36
- package/templates/docs/CURRENT_STATE.md +0 -38
- package/templates/docs/conventions/current-state.md +0 -9
- package/templates/docs/conventions/doc-lifecycle.md +0 -16
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# DOMAIN
|
|
2
|
+
|
|
3
|
+
Answers: why does this system exist? Populated and kept current by `/refresh-repo-map`. Do not hand-edit outside that workflow.
|
|
4
|
+
|
|
5
|
+
## Problem and Outcomes
|
|
6
|
+
|
|
7
|
+
<agent: fill via /refresh-repo-map - the problem this system solves and the outcomes it produces for its users.>
|
|
8
|
+
|
|
9
|
+
## Actors
|
|
10
|
+
|
|
11
|
+
<agent: fill via /refresh-repo-map - users, operators, and other systems that act on or through this system.>
|
|
12
|
+
|
|
13
|
+
## Use Cases
|
|
14
|
+
|
|
15
|
+
<agent: fill via /refresh-repo-map - the business use cases this system supports.>
|
|
16
|
+
|
|
17
|
+
## Workflows
|
|
18
|
+
|
|
19
|
+
<agent: fill via /refresh-repo-map - the end-to-end workflows actors follow to reach an outcome.>
|
|
20
|
+
|
|
21
|
+
## Ubiquitous Language
|
|
22
|
+
|
|
23
|
+
<agent: fill via /refresh-repo-map - canonical domain terms and their precise meaning in this system.>
|
|
24
|
+
|
|
25
|
+
## Domain Rules
|
|
26
|
+
|
|
27
|
+
<agent: fill via /refresh-repo-map - domain rules and invariants that constrain behavior regardless of implementation.>
|
|
28
|
+
|
|
29
|
+
## Boundaries and Non-Goals
|
|
30
|
+
|
|
31
|
+
<agent: fill via /refresh-repo-map - what this system is explicitly not responsible for.>
|
|
32
|
+
|
|
33
|
+
<!-- repo-map-synced: <agent: fill via /refresh-repo-map> -->
|
|
@@ -8,10 +8,22 @@ State whether this decision is proposed, accepted, superseded, or rejected.
|
|
|
8
8
|
|
|
9
9
|
Describe the forces, constraints, and facts that make a decision necessary.
|
|
10
10
|
|
|
11
|
+
## Scope
|
|
12
|
+
|
|
13
|
+
State exactly which domain or technical concerns this decision applies to.
|
|
14
|
+
|
|
11
15
|
## Decision
|
|
12
16
|
|
|
13
17
|
Record the chosen approach and the scope where it applies.
|
|
14
18
|
|
|
19
|
+
## Alternatives
|
|
20
|
+
|
|
21
|
+
List the alternatives considered and why each was rejected.
|
|
22
|
+
|
|
15
23
|
## Consequences
|
|
16
24
|
|
|
17
25
|
List the tradeoffs, follow-up work, and verification impact.
|
|
26
|
+
|
|
27
|
+
## Supersession
|
|
28
|
+
|
|
29
|
+
State whether this ADR supersedes or is superseded by another ADR, and cross-link both records.
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
# Architecture Decision Records
|
|
2
|
+
|
|
3
|
+
An ADR is warranted when a decision constrains future work, has meaningful alternatives or tradeoffs, or is costly to reverse. Recording a decision here requires an approved consequential decision — never invent or record an unapproved entry. Read this index first, then only matching accepted or superseding ADRs; do not scan every ADR.
|
|
4
|
+
|
|
5
|
+
| ID | Decision | Status | Affected concerns | Supersedes | Detail |
|
|
6
|
+
|---|---|---|---|---|---|
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# Deferred Work
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|---|---|---|---|
|
|
3
|
+
This folder is not a general backlog and does not hold permanently rejected work or ordinary code TODOs. Recording an entry here requires explicit developer approval — an agent may suggest deferral but never records it unapproved.
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
| ID | Postponed item | Reason | Revisit trigger | Detail |
|
|
6
|
+
|---|---|---|---|---|
|
|
7
|
+
|
|
8
|
+
Add a `DEF-NNN-topic.md` detail doc per entry. Read this index before planning a new capability, then open only matching detail files. Remove a row once its work is shipped or rejected.
|
|
@@ -1,163 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Generate or refresh docs/CURRENT_STATE.md and, if `docs/diagrams/` exists in this repo, docs/diagrams/c4-component.puml — the source-of-truth source map
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# /current-state
|
|
6
|
-
|
|
7
|
-
Refresh `docs/CURRENT_STATE.md` and, if `docs/diagrams/` exists in this repo, `docs/diagrams/c4-component.puml` when component topology changes. Runs after each committed task, or standalone when the source map has drifted.
|
|
8
|
-
|
|
9
|
-
This command is the **only** writer for `CURRENT_STATE.md` and, if `docs/diagrams/` exists in this repo, `c4-component.puml`. Do not touch either during implementation.
|
|
10
|
-
|
|
11
|
-
## When to run
|
|
12
|
-
|
|
13
|
-
- After a task is implemented and committed — typical use, run in the same thread.
|
|
14
|
-
- Standalone, when the source map has drifted and needs catching up without a task in progress.
|
|
15
|
-
- First time, to seed `CURRENT_STATE.md` for an existing codebase or a freshly-skeletoned project.
|
|
16
|
-
|
|
17
|
-
## Required sections — CURRENT_STATE.md
|
|
18
|
-
|
|
19
|
-
Exactly these headings, in this order. Empty section: keep the heading with `(none)`. Do not remove.
|
|
20
|
-
|
|
21
|
-
```markdown
|
|
22
|
-
# CURRENT_STATE
|
|
23
|
-
|
|
24
|
-
## Purpose
|
|
25
|
-
|
|
26
|
-
<1–2 sentences, caveman: what codebase does, for whom>
|
|
27
|
-
|
|
28
|
-
## Stack
|
|
29
|
-
|
|
30
|
-
<lang ⊕ framework ⊕ key libs; versions only when material>
|
|
31
|
-
|
|
32
|
-
## Shipped capabilities
|
|
33
|
-
|
|
34
|
-
<flat list, 1 line each — only end-user functionality working today>
|
|
35
|
-
|
|
36
|
-
## Source map
|
|
37
|
-
|
|
38
|
-
<folder/file tree, 1-line purpose per node — tech-lead pointer granularity>
|
|
39
|
-
|
|
40
|
-
## Design patterns in use
|
|
41
|
-
|
|
42
|
-
<pattern name → file/dir>
|
|
43
|
-
|
|
44
|
-
## Public interfaces
|
|
45
|
-
|
|
46
|
-
<HTTP routes / UI routes / CLI cmds / events / queues>
|
|
47
|
-
|
|
48
|
-
## Data model digest
|
|
49
|
-
|
|
50
|
-
<link to docs/diagrams/erd.puml ⊕ 1-line table list>
|
|
51
|
-
|
|
52
|
-
## Component diagram
|
|
53
|
-
|
|
54
|
-
<embed of rendered docs/diagrams/rendered/c4-component.svg, if `docs/diagrams/` exists in this repo>
|
|
55
|
-
|
|
56
|
-
## Known debt / TODOs
|
|
57
|
-
|
|
58
|
-
<short, current; deleted once addressed>
|
|
59
|
-
```
|
|
60
|
-
|
|
61
|
-
## Caveman style — whole file
|
|
62
|
-
|
|
63
|
-
- Bullet fragments. Drop articles (`the`, `a`).
|
|
64
|
-
- Symbols: `→` leads-to · `⊕` and-also · `~` approximately · `Δ` change · `&` and-also.
|
|
65
|
-
- `file:line` over prose: `auth/login.ts:42` ✓ · "line 42 of auth/login.ts" ✗.
|
|
66
|
-
- No hedging (`might`, `could`, `perhaps`) — state or omit.
|
|
67
|
-
- No preamble, no meta, no restating the question.
|
|
68
|
-
- 1 line per entry where possible.
|
|
69
|
-
|
|
70
|
-
Example:
|
|
71
|
-
|
|
72
|
-
```
|
|
73
|
-
## Shipped capabilities
|
|
74
|
-
- email/pw signup ⊕ verify
|
|
75
|
-
- JWT auth → 7d refresh
|
|
76
|
-
- profile edit (name, avatar)
|
|
77
|
-
|
|
78
|
-
## Source map
|
|
79
|
-
- src/auth/ — signup, login, JWT issuance
|
|
80
|
-
- login.ts:42 → token mint
|
|
81
|
-
- guards/ — route protection
|
|
82
|
-
- src/users/ — CRUD ⊕ profile
|
|
83
|
-
- src/db/ — Prisma client ⊕ migrations
|
|
84
|
-
```
|
|
85
|
-
|
|
86
|
-
## Inputs
|
|
87
|
-
|
|
88
|
-
Gather these in order — the diff is the truth source; task or issue context describes intent:
|
|
89
|
-
|
|
90
|
-
1. **`docs/CURRENT_STATE.md`** — baseline to preserve.
|
|
91
|
-
2. **If `docs/diagrams/` exists in this repo, `docs/diagrams/c4-component.puml`** — component baseline.
|
|
92
|
-
3. **Task or issue context** — identify from conversation context, linked issue/spec, or `git log -1 --format=%B`. Read named context docs for intended Δ when present.
|
|
93
|
-
4. **Adjacent planning docs** — read only if linked by the task, issue, spec, or commit message.
|
|
94
|
-
5. **`git diff HEAD~1`** — what actually shipped; trust this over intent docs if they diverge.
|
|
95
|
-
|
|
96
|
-
## Procedure A — generate from scratch (no file exists)
|
|
97
|
-
|
|
98
|
-
Covers (a) existing codebase adopting the methodology, (b) new project past design/skeleton phase.
|
|
99
|
-
|
|
100
|
-
1. **Stack** — read manifests: `package.json`, `pyproject.toml`, `go.mod`, `Cargo.toml`, `tsconfig.json`, `vite.config.*`, `next.config.*`, `prisma/schema.prisma`, etc.
|
|
101
|
-
2. **Source map** — walk top-down. Per top-level folder: read `index.*` / `mod.rs` / `__init__.py`, the largest file, any `README.md`. Stop at tech-lead-pointer granularity (deep enough to route a dev to the right file, no deeper). Symbol-level entries only when the symbol _is_ the landmark.
|
|
102
|
-
3. **Public interfaces** — find route registrations (Express/NestJS/FastAPI/Django/etc.), CLI entry points (`bin/`, `cmd/`, `cli.*`), event/queue handlers.
|
|
103
|
-
4. **Data model digest** — read schema + migrations → 1-line table list. Link `docs/diagrams/erd.puml` if it exists; if not, link `prisma/schema.prisma` or equivalent. Do not inline schema.
|
|
104
|
-
5. **Design patterns in use** — recurring shapes by directory naming + import graph (Repository, Service, UseCase, Controller, ...). Pattern → file/dir.
|
|
105
|
-
6. **Shipped capabilities** — user-facing features actually working today. Skip in-flight or planned. If unsure what works, **ask the user**. Do not infer from task files or phase docs.
|
|
106
|
-
7. **Component diagram** — if `docs/diagrams/` exists in this repo and `docs/diagrams/c4-component.puml` does not exist, create a minimal skeleton from the source map's top-level boundaries. Render to SVG via `docker run --rm -v "$PWD:/data" plantuml/plantuml -tsvg docs/diagrams/c4-component.puml`. Embed the rendered SVG path in the section. If `docs/diagrams/` does not exist in this repo, write `(none)` in the section.
|
|
107
|
-
8. **Known debt / TODOs** — grep `TODO|FIXME|HACK|XXX`. Add obvious gaps spotted during the walk.
|
|
108
|
-
9. **Purpose** — 1–2 caveman sentences. If unclear, **ask the user**. Do not guess.
|
|
109
|
-
10. Apply caveman style end-to-end. Re-read once. Cut every word with no signal.
|
|
110
|
-
|
|
111
|
-
After drafting: surface to user, ask for corrections. The first version is a draft, not the answer.
|
|
112
|
-
|
|
113
|
-
## Procedure B — update an existing file
|
|
114
|
-
|
|
115
|
-
Trigger: a task was just committed and `/current-state` is called in the same thread, or standalone drift correction.
|
|
116
|
-
|
|
117
|
-
1. Read `docs/CURRENT_STATE.md` fully — establish the baseline.
|
|
118
|
-
2. If `docs/diagrams/` exists in this repo, read `docs/diagrams/c4-component.puml` — establish the component baseline.
|
|
119
|
-
3. Identify the completed task or issue from conversation context or `git log -1 --format=%B`. Read named context docs for intended Δ when present.
|
|
120
|
-
4. Run `git diff HEAD~1` — confirm what actually shipped. This is the truth source.
|
|
121
|
-
5. Map change to affected sections — most tasks touch 1–3:
|
|
122
|
-
- new dep → **Stack**
|
|
123
|
-
- new user-facing feature working today → **Shipped capabilities**
|
|
124
|
-
- new/renamed/removed file or folder, or purpose shift → **Source map**
|
|
125
|
-
- new endpoint/CLI/event → **Public interfaces**
|
|
126
|
-
- new migration → **Data model digest**
|
|
127
|
-
- new component or container relation → **Component diagram** if `docs/diagrams/` exists in this repo (edit `c4-component.puml`, re-render)
|
|
128
|
-
- new pattern adopted ⊕ old pattern retired → **Design patterns in use**
|
|
129
|
-
- debt resolved → **prune** from Known debt; new debt → add
|
|
130
|
-
- **Purpose** — touch only if scope actually shifted
|
|
131
|
-
6. **Weigh new entries against the existing baseline.** A freshly-shipped task does not automatically replace older, more important entries. If the file is growing past one screen, prune low-signal entries first.
|
|
132
|
-
7. Apply changes with the **Edit tool only** — surgical replacements. Never regenerate the file. Untouched sections stay byte-identical.
|
|
133
|
-
8. **Prune obsolete entries.** File removed → delete source-map line. Pattern retired → delete entry. Debt resolved → delete item. Stale entries are worse than missing ones.
|
|
134
|
-
9. New entries match surrounding density. Caveman throughout.
|
|
135
|
-
10. If `docs/diagrams/` exists in this repo and `c4-component.puml` changed, re-render: `docker run --rm -v "$PWD:/data" plantuml/plantuml -tsvg docs/diagrams/c4-component.puml`. Update the embed path in the Component diagram section if the rendered filename changed.
|
|
136
|
-
11. Re-read after editing. Cut redundancy the diff introduced.
|
|
137
|
-
|
|
138
|
-
After updating: surface the diff of `CURRENT_STATE.md` to the user, flag any conflicts, ask for corrections. Once the user approves (or no corrections are needed), commit with a concise docs message such as:
|
|
139
|
-
|
|
140
|
-
```
|
|
141
|
-
docs: update CURRENT_STATE
|
|
142
|
-
```
|
|
143
|
-
|
|
144
|
-
Include only project-required trailers. Stage only `docs/CURRENT_STATE.md` and, if `docs/diagrams/` exists in this repo and changed, `docs/diagrams/c4-component.puml` plus its rendered SVG.
|
|
145
|
-
|
|
146
|
-
## Conflict handling
|
|
147
|
-
|
|
148
|
-
- **Task file says X, diff shows Y** → trust the diff. Note the divergence to the user.
|
|
149
|
-
- **Manual human edit in `CURRENT_STATE.md` conflicts with new change** → trust the new change but **flag the conflict before overwriting**. The human edit may encode context the agent lacks.
|
|
150
|
-
|
|
151
|
-
## Anti-bloat rules
|
|
152
|
-
|
|
153
|
-
- No narrative. No restating code comments.
|
|
154
|
-
- No planned, in-flight, or "next release" features. Only what works today.
|
|
155
|
-
- No duplication of content that lives elsewhere — link instead (`→ prisma/schema.prisma`, `→ docs/diagrams/erd.puml`).
|
|
156
|
-
- File grows with **source-tree structure**, not task count. Growing per-task → wrong content going in; rework the entry until it describes structure, not the task.
|
|
157
|
-
- No business detail — that lives in `docs/features/`. `CURRENT_STATE.md` is a source map, not a feature catalog.
|
|
158
|
-
- No history — `CURRENT_STATE.md` answers "what is"; `CHANGELOG.md` answers "how we got here". They never overlap.
|
|
159
|
-
|
|
160
|
-
## Out of scope
|
|
161
|
-
|
|
162
|
-
- Appending to `CHANGELOG.md`.
|
|
163
|
-
- Editing unrelated requirements, prototypes, class diagrams, ERDs, context diagrams, or container diagrams.
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Use when a local hook, lint, typecheck, test, build, validation, or CI gate fails.
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Enforcement Gates
|
|
6
|
-
|
|
7
|
-
## Purpose
|
|
8
|
-
|
|
9
|
-
Diagnose failed gates from evidence, fix the underlying issue, and avoid bypassing safety checks.
|
|
10
|
-
|
|
11
|
-
## Triggers
|
|
12
|
-
|
|
13
|
-
- A pre-commit, pre-push, CI, lint, typecheck, test, build, validation, or policy gate fails.
|
|
14
|
-
- You are tempted to skip or weaken a check.
|
|
15
|
-
|
|
16
|
-
## Required Workflow
|
|
17
|
-
|
|
18
|
-
1. Capture the failing command and first relevant error -> identify the gate, not a symptom.
|
|
19
|
-
2. Fix the smallest underlying cause -> keep the gate intact.
|
|
20
|
-
3. Re-run the failed gate -> confirm it passes.
|
|
21
|
-
4. Run adjacent verification if the fix changes behavior -> prevent regressions.
|
|
22
|
-
|
|
23
|
-
## Rules
|
|
24
|
-
|
|
25
|
-
- Do: preserve strict gate settings and cite the command/output in the report.
|
|
26
|
-
- Do not: bypass hooks, lower thresholds, delete tests, or silence errors without a documented reason.
|
|
27
|
-
|
|
28
|
-
## Verification
|
|
29
|
-
|
|
30
|
-
- Run `<agent: fill during handoff — standard gate command>` after fixing any gate failure.
|
|
31
|
-
|
|
32
|
-
## References
|
|
33
|
-
|
|
34
|
-
- `<agent: fill during handoff — CI config path>` - canonical gate list.
|
|
35
|
-
- `<agent: fill during handoff — local hook config path>` - developer gate list.
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Use when implementing planned work from a task, issue, spec, or phase document.
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Implementing Task
|
|
6
|
-
|
|
7
|
-
## Purpose
|
|
8
|
-
|
|
9
|
-
Execute planned work without drifting from scope, skipping verification, or mixing unrelated changes.
|
|
10
|
-
|
|
11
|
-
## Triggers
|
|
12
|
-
|
|
13
|
-
- You are implementing a task/spec/issue with explicit requirements.
|
|
14
|
-
- You are changing code under a feature or phase plan.
|
|
15
|
-
|
|
16
|
-
## Required Workflow
|
|
17
|
-
|
|
18
|
-
1. Read the task source and linked durable docs -> identify exact scope and exclusions.
|
|
19
|
-
2. Write or update the smallest failing test first -> confirm the expected RED failure.
|
|
20
|
-
3. Implement the minimal change -> keep unrelated files untouched.
|
|
21
|
-
4. Run the required verification -> record command and outcome.
|
|
22
|
-
5. Update current-state only through `/current-state` when shipped behavior or source map changed.
|
|
23
|
-
|
|
24
|
-
## Rules
|
|
25
|
-
|
|
26
|
-
- Do: preserve exact values, paths, and commands from the task source.
|
|
27
|
-
- Do not: pull future-phase work forward or silently expand scope.
|
|
28
|
-
|
|
29
|
-
## Verification
|
|
30
|
-
|
|
31
|
-
- Run `<agent: fill during handoff — smallest command that proves a planned task>` before reporting completion.
|
|
32
|
-
|
|
33
|
-
## References
|
|
34
|
-
|
|
35
|
-
- `docs/CURRENT_STATE.md` - current source map.
|
|
36
|
-
- `docs/conventions/doc-lifecycle.md` - durable vs planning document lifecycle.
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Use when adding, removing, or updating dependencies, package-manager metadata, lockfiles, or workspace package links.
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Installing Dependencies
|
|
6
|
-
|
|
7
|
-
## Purpose
|
|
8
|
-
|
|
9
|
-
Keep dependency changes reproducible, scoped to the correct package, and aligned with the project's package manager.
|
|
10
|
-
|
|
11
|
-
## Triggers
|
|
12
|
-
|
|
13
|
-
- Adding, removing, or upgrading an external package.
|
|
14
|
-
- Linking an internal workspace package.
|
|
15
|
-
- Editing package manifests or lockfiles.
|
|
16
|
-
|
|
17
|
-
## Required Workflow
|
|
18
|
-
|
|
19
|
-
1. Identify package manager and workspace shape -> `<agent: fill during handoff — package manager and workspace command rules>`.
|
|
20
|
-
2. Identify the owning package/app -> avoid installing at the wrong level.
|
|
21
|
-
3. Run the package manager command -> update manifest and lockfile together.
|
|
22
|
-
4. Run dependency-sensitive verification -> prove install and imports work.
|
|
23
|
-
|
|
24
|
-
## Rules
|
|
25
|
-
|
|
26
|
-
- Do: use `<agent: fill during handoff — approved package manager command>` for dependency changes.
|
|
27
|
-
- Do not: edit lockfiles by hand or mix unrelated dependency upgrades.
|
|
28
|
-
|
|
29
|
-
## Verification
|
|
30
|
-
|
|
31
|
-
- Run `<agent: fill during handoff — install/build/test command after dependency changes>` when dependency metadata changes.
|
|
32
|
-
|
|
33
|
-
## References
|
|
34
|
-
|
|
35
|
-
- `<agent: fill during handoff — package manifest path>` - dependency owner.
|
|
36
|
-
- `<agent: fill during handoff — lockfile path>` - resolved dependency graph.
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Use when exploring the repo, locating code, or deciding which docs and paths to read before making changes.
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Repo Navigation
|
|
6
|
-
|
|
7
|
-
## Purpose
|
|
8
|
-
|
|
9
|
-
Explore efficiently without crawling irrelevant, archived, generated, or project-specific material.
|
|
10
|
-
|
|
11
|
-
## Triggers
|
|
12
|
-
|
|
13
|
-
- You need to understand where code, docs, commands, or ownership rules live.
|
|
14
|
-
- You are about to do broad repository exploration.
|
|
15
|
-
|
|
16
|
-
## Required Workflow
|
|
17
|
-
|
|
18
|
-
1. Read `docs/CURRENT_STATE.md` -> use it as the first source map.
|
|
19
|
-
2. Read only the paths relevant to the task -> keep exploration proportional.
|
|
20
|
-
3. If the source map is stale -> report the mismatch and continue from direct evidence.
|
|
21
|
-
|
|
22
|
-
## Rules
|
|
23
|
-
|
|
24
|
-
- Do: prefer durable docs, manifests, and entry points before deep file walks.
|
|
25
|
-
- Do not: crawl archived, generated, vendored, or build-output folders unless the task explicitly needs them.
|
|
26
|
-
|
|
27
|
-
## Verification
|
|
28
|
-
|
|
29
|
-
- Run `<agent: fill during handoff — smallest command that proves navigation-sensitive changes>` when exploration changes generated docs or routing metadata.
|
|
30
|
-
|
|
31
|
-
## References
|
|
32
|
-
|
|
33
|
-
- `docs/CURRENT_STATE.md` - source map and current shipped shape.
|
|
34
|
-
- `docs/conventions/current-state.md` - update policy and staleness rules.
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Use when touching credentials, tokens, keys, secret references, config containing secrets, or secret redaction paths.
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Secrets Handling
|
|
6
|
-
|
|
7
|
-
## Purpose
|
|
8
|
-
|
|
9
|
-
Prevent secrets from being committed, logged, exposed through APIs, or stored outside the approved secret store.
|
|
10
|
-
|
|
11
|
-
## Triggers
|
|
12
|
-
|
|
13
|
-
- Storing, reading, rotating, deleting, or displaying credentials.
|
|
14
|
-
- Editing config, environment files, CI secrets, tokens, keys, or redaction logic.
|
|
15
|
-
- Adding a new integration that needs a secret.
|
|
16
|
-
|
|
17
|
-
## Required Workflow
|
|
18
|
-
|
|
19
|
-
1. Identify the secret and owner -> `<agent: fill during handoff — secret store/provider and ownership rule>`.
|
|
20
|
-
2. Store only references in code/config where possible -> keep raw values in the approved store.
|
|
21
|
-
3. Verify redaction boundaries -> responses, logs, errors, docs, and tests must not reveal secret values.
|
|
22
|
-
4. Rotate or revoke exposed values -> treat accidental disclosure as a security incident.
|
|
23
|
-
|
|
24
|
-
## Rules
|
|
25
|
-
|
|
26
|
-
- Do: use `<agent: fill during handoff — approved secret reference pattern>` for secret lookup and storage.
|
|
27
|
-
- Do not: commit raw secrets, print them, include them in snapshots, or expose secret references where the project forbids it.
|
|
28
|
-
|
|
29
|
-
## Verification
|
|
30
|
-
|
|
31
|
-
- Run `<agent: fill during handoff — secret/config validation command>` when secret handling changes.
|
|
32
|
-
|
|
33
|
-
## References
|
|
34
|
-
|
|
35
|
-
- `<agent: fill during handoff — secret management doc/path>` - approved store and redaction contract.
|
|
36
|
-
- `<agent: fill during handoff — config/env schema path>` - allowed secret references.
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
# CURRENT_STATE
|
|
2
|
-
|
|
3
|
-
## Purpose
|
|
4
|
-
|
|
5
|
-
<agent: fill via /current-state>
|
|
6
|
-
|
|
7
|
-
## Stack
|
|
8
|
-
|
|
9
|
-
- <agent: fill via /current-state>
|
|
10
|
-
- <agent: fill via /current-state>
|
|
11
|
-
|
|
12
|
-
## Shipped capabilities
|
|
13
|
-
|
|
14
|
-
- <agent: fill via /current-state>
|
|
15
|
-
|
|
16
|
-
## Source map
|
|
17
|
-
|
|
18
|
-
- `<agent: fill via /current-state>` - <agent: fill via /current-state>
|
|
19
|
-
|
|
20
|
-
## Design patterns in use
|
|
21
|
-
|
|
22
|
-
- <agent: fill via /current-state> -> <agent: fill via /current-state>
|
|
23
|
-
|
|
24
|
-
## Public interfaces
|
|
25
|
-
|
|
26
|
-
- <agent: fill via /current-state> -> <agent: fill via /current-state>
|
|
27
|
-
|
|
28
|
-
## Data model digest
|
|
29
|
-
|
|
30
|
-
- <agent: fill via /current-state> - <agent: fill via /current-state>
|
|
31
|
-
|
|
32
|
-
## Component diagram
|
|
33
|
-
|
|
34
|
-
- <agent: fill via /current-state>
|
|
35
|
-
|
|
36
|
-
## Known debt / TODOs
|
|
37
|
-
|
|
38
|
-
- <agent: fill via /current-state>
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
# Current State Policy
|
|
2
|
-
|
|
3
|
-
## Policy
|
|
4
|
-
|
|
5
|
-
- Agents read it before broad exploration.
|
|
6
|
-
- If it answers the question, agents should not re-crawl the repo.
|
|
7
|
-
- It should be updated only by an explicit command or maintenance workflow.
|
|
8
|
-
- If stale, agents should report staleness instead of silently rewriting it during unrelated work.
|
|
9
|
-
- Only `/current-state` writes `docs/CURRENT_STATE.md`.
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
# Documentation Lifecycle
|
|
2
|
-
|
|
3
|
-
## Common categories
|
|
4
|
-
|
|
5
|
-
| Category | Examples | Lifecycle |
|
|
6
|
-
|---|---|---|
|
|
7
|
-
| Durable | architecture, ADRs, glossary, operations, current-state conventions | Long-lived |
|
|
8
|
-
| Planning | roadmap, phases, feature plans, task docs | Archived or removed after shipped |
|
|
9
|
-
| Runbooks | deployment, rollback, manual checks, provider setup | Updated when operations change |
|
|
10
|
-
| Deferred work | parked plans and revisit triggers | Removed when built or rejected |
|
|
11
|
-
|
|
12
|
-
## Why this matters
|
|
13
|
-
|
|
14
|
-
- Prevents agents from treating stale plans as shipped behavior.
|
|
15
|
-
- Prevents durable docs from depending on soon-archived docs.
|
|
16
|
-
- Gives agents a clear source of truth for scope disputes.
|