@thebassclef/lite 0.1.3 → 1.0.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/dist/cli.cjs +216 -137
- package/dist/cli.js +218 -139
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/lite/.bassclef-source.json +10 -0
- package/dist/lite/.claude/settings.json +212 -0
- package/dist/lite/CLAUDE.md +41 -0
- package/dist/lite/gitignore +58 -0
- package/dist/lite/standards/bassclef-wiring-manifest.json +497 -0
- package/dist/lite/whereami.md +24 -0
- package/package.json +8 -2
- package/substrate/.bassclef/lite-manifest.json +0 -2701
- package/substrate/.claude/agents/architect.md +0 -70
- package/substrate/.claude/agents/builder.md +0 -114
- package/substrate/.claude/agents/designer.md +0 -156
- package/substrate/.claude/agents/reviewer.md +0 -88
- package/substrate/.claude/hooks/artifact-ingestion-gate.sh +0 -357
- package/substrate/.claude/hooks/assert-verify-steering.sh +0 -77
- package/substrate/.claude/hooks/bassclef-source-config-validate.sh +0 -215
- package/substrate/.claude/hooks/bassclef-sync.sh +0 -634
- package/substrate/.claude/hooks/compound-noun-scrub.sh +0 -292
- package/substrate/.claude/hooks/kiss-expansion-inject.sh +0 -69
- package/substrate/.claude/hooks/longrun-prep-compounding-axis-check.sh +0 -492
- package/substrate/.claude/hooks/longrun-prep-compounding-sequence-check.sh +0 -492
- package/substrate/.claude/hooks/plain-english-steering.sh +0 -156
- package/substrate/.claude/hooks/post-skill-friction-check.sh +0 -177
- package/substrate/.claude/hooks/post-skill-telemetry.sh +0 -62
- package/substrate/.claude/hooks/pre-build-gate.sh +0 -511
- package/substrate/.claude/hooks/pre-commit-gate.sh +0 -451
- package/substrate/.claude/hooks/session-end.sh +0 -433
- package/substrate/.claude/hooks/session-reflection.sh +0 -303
- package/substrate/.claude/hooks/skill-body-grade-gate.sh +0 -219
- package/substrate/.claude/hooks/skill-body-intent-drift.sh +0 -107
- package/substrate/.claude/hooks/skill-step-list-check.sh +0 -171
- package/substrate/.claude/hooks/state-validate.sh +0 -271
- package/substrate/.claude/hooks/substrate-clarity-gate.sh +0 -1110
- package/substrate/.claude/hooks/temperance-gate.sh +0 -147
- package/substrate/.claude/hooks/testing-tier-enforce.sh +0 -233
- package/substrate/.claude/hooks/turn-prose-grade-measure.sh +0 -219
- package/substrate/.claude/hooks/turn-prose-kiss-check.sh +0 -463
- package/substrate/.claude/hooks/vocabulary-migration-check.sh +0 -171
- package/substrate/.claude/hooks/whereami-utc-gate.sh +0 -142
- package/substrate/.claude/luminaries/alan-cooper.md +0 -170
- package/substrate/.claude/luminaries/alistair-cockburn.md +0 -140
- package/substrate/.claude/luminaries/amazon-pr-faq.md +0 -34
- package/substrate/.claude/luminaries/ash-maurya.md +0 -121
- package/substrate/.claude/luminaries/bill-buxton.md +0 -210
- package/substrate/.claude/luminaries/charles-sanders-peirce.md +0 -150
- package/substrate/.claude/luminaries/david-ogilvy.md +0 -192
- package/substrate/.claude/luminaries/don-norman.md +0 -173
- package/substrate/.claude/luminaries/edward-tufte.md +0 -179
- package/substrate/.claude/luminaries/eric-evans.md +0 -160
- package/substrate/.claude/luminaries/frederick-brooks.md +0 -50
- package/substrate/.claude/luminaries/gang-of-four.md +0 -157
- package/substrate/.claude/luminaries/glenford-myers.md +0 -230
- package/substrate/.claude/luminaries/hunt-thomas.md +0 -115
- package/substrate/.claude/luminaries/hyrum-wright.md +0 -94
- package/substrate/.claude/luminaries/jason-fried-dhh.md +0 -46
- package/substrate/.claude/luminaries/jesse-james-garrett.md +0 -154
- package/substrate/.claude/luminaries/john-ousterhout.md +0 -94
- package/substrate/.claude/luminaries/karl-popper.md +0 -132
- package/substrate/.claude/luminaries/kent-beck.md +0 -168
- package/substrate/.claude/luminaries/linus-torvalds.md +0 -218
- package/substrate/.claude/luminaries/martin-fowler.md +0 -164
- package/substrate/.claude/luminaries/michael-feathers.md +0 -125
- package/substrate/.claude/luminaries/michael-nygard.md +0 -118
- package/substrate/.claude/luminaries/robert-c-martin.md +0 -164
- package/substrate/.claude/luminaries/saltzer-schroeder.md +0 -194
- package/substrate/.claude/luminaries/sophia-prater.md +0 -193
- package/substrate/.claude/luminaries/stephen-toulmin.md +0 -131
- package/substrate/.claude/luminaries/tony-hoare.md +0 -170
- package/substrate/.claude/luminaries/vaughn-vernon.md +0 -50
- package/substrate/.claude/luminaries/w-edwards-deming.md +0 -158
- package/substrate/.claude/rules/accessor-library-discipline.md +0 -138
- package/substrate/.claude/rules/adr-discipline.md +0 -120
- package/substrate/.claude/rules/api-conventions.md +0 -125
- package/substrate/.claude/rules/artifact-ingestion.md +0 -179
- package/substrate/.claude/rules/assert-only-after-verify.md +0 -137
- package/substrate/.claude/rules/blocked-items.md +0 -146
- package/substrate/.claude/rules/bootstrap-pair-discipline.md +0 -141
- package/substrate/.claude/rules/branching.md +0 -28
- package/substrate/.claude/rules/cold-adopter-harness-discipline.md +0 -129
- package/substrate/.claude/rules/commit-conventions.md +0 -22
- package/substrate/.claude/rules/compounding-axis-fresh-analysis.md +0 -188
- package/substrate/.claude/rules/compounding-sequence-fresh-analysis.md +0 -188
- package/substrate/.claude/rules/context-engineering.md +0 -202
- package/substrate/.claude/rules/context-management.md +0 -85
- package/substrate/.claude/rules/defensive-bash.md +0 -68
- package/substrate/.claude/rules/deferred-actions.md +0 -233
- package/substrate/.claude/rules/destructive-operations.md +0 -69
- package/substrate/.claude/rules/diagnosis.md +0 -38
- package/substrate/.claude/rules/github-issue-flash-tweet.md +0 -156
- package/substrate/.claude/rules/guardrails.md +0 -73
- package/substrate/.claude/rules/hook-wire-on-author.md +0 -103
- package/substrate/.claude/rules/identifier-leak-prevention.md +0 -104
- package/substrate/.claude/rules/iteration-bet-brief-completeness.md +0 -54
- package/substrate/.claude/rules/lite-manifest-schema-change-discipline.md +0 -98
- package/substrate/.claude/rules/longrun-prep-plan-doc-compression.md +0 -89
- package/substrate/.claude/rules/loop-discipline.md +0 -81
- package/substrate/.claude/rules/manual-prod-approval.md +0 -100
- package/substrate/.claude/rules/marker-enrichment-discipline.md +0 -99
- package/substrate/.claude/rules/mobile-ephemeral-session.md +0 -109
- package/substrate/.claude/rules/new-dependency-check.md +0 -51
- package/substrate/.claude/rules/oo-ad-entry-point.md +0 -117
- package/substrate/.claude/rules/operator-facing-prose.md +0 -196
- package/substrate/.claude/rules/option-label-discipline.md +0 -108
- package/substrate/.claude/rules/pattern-annotation.md +0 -100
- package/substrate/.claude/rules/plain-english-discipline.md +0 -156
- package/substrate/.claude/rules/plan-enumeration-needs-value-props.md +0 -211
- package/substrate/.claude/rules/pr-body-shape.md +0 -317
- package/substrate/.claude/rules/pr-strategy.md +0 -167
- package/substrate/.claude/rules/pr-title-shape.md +0 -161
- package/substrate/.claude/rules/prototype-workflow.md +0 -65
- package/substrate/.claude/rules/reserved-skill-names.md +0 -123
- package/substrate/.claude/rules/schema-management.md +0 -49
- package/substrate/.claude/rules/sdlc-gates.md +0 -149
- package/substrate/.claude/rules/security.md +0 -37
- package/substrate/.claude/rules/session-artifacts.md +0 -236
- package/substrate/.claude/rules/skill-composition-declarations.md +0 -124
- package/substrate/.claude/rules/skill-description-clarity.md +0 -247
- package/substrate/.claude/rules/skill-procedure-step-list.md +0 -137
- package/substrate/.claude/rules/state-schema-validation.md +0 -162
- package/substrate/.claude/rules/stuck-signal-diagnostic.md +0 -140
- package/substrate/.claude/rules/substrate-config-schema.md +0 -98
- package/substrate/.claude/rules/test-list-discipline.md +0 -175
- package/substrate/.claude/rules/test-sufficiency.md +0 -210
- package/substrate/.claude/rules/testing-tier-config.md +0 -145
- package/substrate/.claude/rules/testing.md +0 -38
- package/substrate/.claude/rules/turn-estimate-grounding.md +0 -134
- package/substrate/.claude/rules/visual-hierarchy.md +0 -437
- package/substrate/.claude/rules/we-dont-break-adopters.md +0 -126
- package/substrate/.claude/rules/whereami-load-bearing.md +0 -202
- package/substrate/.claude/rules/writing-craft-discipline.md +0 -92
- package/substrate/.claude/rules/wu-sequencing-compounds.md +0 -145
- package/substrate/.claude/skills/build/SKILL.md +0 -640
- package/substrate/.claude/skills/chronicle/SKILL.md +0 -55
- package/substrate/.claude/skills/clean-artifacts/SKILL.md +0 -249
- package/substrate/.claude/skills/decompose/SKILL.md +0 -280
- package/substrate/.claude/skills/diagnose/SKILL.md +0 -297
- package/substrate/.claude/skills/feynman/SKILL.md +0 -90
- package/substrate/.claude/skills/howdoi/SKILL.md +0 -105
- package/substrate/.claude/skills/ia-model/SKILL.md +0 -108
- package/substrate/.claude/skills/interaction-design/SKILL.md +0 -112
- package/substrate/.claude/skills/interpret-input/SKILL.md +0 -180
- package/substrate/.claude/skills/journal/SKILL.md +0 -209
- package/substrate/.claude/skills/kiss/SKILL.md +0 -449
- package/substrate/.claude/skills/launch/SKILL.md +0 -915
- package/substrate/.claude/skills/lean-canvas/SKILL.md +0 -332
- package/substrate/.claude/skills/longrun/SKILL.md +0 -463
- package/substrate/.claude/skills/luminary/SKILL.md +0 -481
- package/substrate/.claude/skills/ogilvy-writing-audit/SKILL.md +0 -177
- package/substrate/.claude/skills/onboard-repo/SKILL.md +0 -1624
- package/substrate/.claude/skills/pattern-review/SKILL.md +0 -99
- package/substrate/.claude/skills/personas/SKILL.md +0 -207
- package/substrate/.claude/skills/promote/SKILL.md +0 -283
- package/substrate/.claude/skills/requirement/SKILL.md +0 -98
- package/substrate/.claude/skills/retro/SKILL.md +0 -117
- package/substrate/.claude/skills/riff/SKILL.md +0 -114
- package/substrate/.claude/skills/roadmap-reconcile/SKILL.md +0 -163
- package/substrate/.claude/skills/session-end/SKILL.md +0 -309
- package/substrate/.claude/skills/session-log/SKILL.md +0 -299
- package/substrate/.claude/skills/skills/SKILL.md +0 -228
- package/substrate/.claude/skills/spec/SKILL.md +0 -105
- package/substrate/.claude/skills/sprint/SKILL.md +0 -392
- package/substrate/.claude/skills/stage/SKILL.md +0 -384
- package/substrate/.claude/skills/state-a-problem/SKILL.md +0 -185
- package/substrate/.claude/skills/temperance/SKILL.md +0 -108
- package/substrate/.claude/skills/use-case/SKILL.md +0 -417
- package/substrate/.claude/skills/user-stories/SKILL.md +0 -268
- package/substrate/.claude/skills/value-prop/SKILL.md +0 -251
- package/substrate/.claude/skills/verify/SKILL.md +0 -160
- package/substrate/.claude/skills/visual-review/SKILL.md +0 -503
- package/substrate/.claude/skills/whats-the-plan/SKILL.md +0 -202
- package/substrate/.claude/skills/whereami/SKILL.md +0 -307
- package/substrate/AGENTS.md +0 -79
- package/substrate/CLAUDE-lite.md +0 -85
- package/substrate/CODE_OF_CONDUCT.md +0 -28
- package/substrate/CONTRIBUTING.md +0 -177
- package/substrate/README.md +0 -173
- package/substrate/SECURITY.md +0 -19
- package/substrate/architecture/decisions/ADR-029-release-pipeline.md +0 -79
- package/substrate/architecture/decisions/ADR-031-non-breaking-changes-adopter-discipline.md +0 -139
- package/substrate/architecture/decisions/ADR-032-adopter-sync-dispatcher-architecture.md +0 -192
- package/substrate/architecture/decisions/ADR-039-release-tagging-scheme.md +0 -145
- package/substrate/architecture/decisions/ADR-040-planning-skill-vocabulary-and-lite-profile.md +0 -155
- package/substrate/architecture/decisions/ADR-044-unified-skill-body-template.md +0 -162
- package/substrate/lib/clean-artifacts-sweep.sh +0 -112
- package/substrate/lib/code-comment-discipline.sh +0 -144
- package/substrate/lib/composer-preflight.sh +0 -459
- package/substrate/lib/hook-inject.sh +0 -255
- package/substrate/lib/luminary-pick.sh +0 -96
- package/substrate/lib/output-discipline.sh +0 -143
- package/substrate/lib/prose-scan-boundary.sh +0 -171
- package/substrate/lib/rewrite-check.sh +0 -214
- package/substrate/lib/state.sh +0 -1372
- package/substrate/lib/telemetry.sh +0 -205
- package/substrate/lib/tier-check.sh +0 -187
- package/substrate/lib/tier-dependency-audit.sh +0 -1088
- package/substrate/presence/install/bassclef-hook-connect.sh +0 -178
- package/substrate/presence/install/bassclef-sync.dispatcher.template.sh +0 -841
- package/substrate/presence/install/bassclef-sync.template.sh +0 -2076
- package/substrate/presence/install/schedule-auto-save.cron.sh +0 -88
- package/substrate/presence/install/schedule-auto-save.taskscheduler.md +0 -122
- package/substrate/scripts/aggregate-telemetry.sh +0 -217
- package/substrate/scripts/analyze-tier-dependencies.sh +0 -239
- package/substrate/scripts/generate-lite-manifest.sh +0 -505
- package/substrate/scripts/generate-tier-manifest.sh +0 -28
- package/substrate/scripts/intent-drift-check.sh +0 -456
- package/substrate/scripts/lite-manifest-drift-check.sh +0 -146
- package/substrate/scripts/render-lite-manifest-doc.sh +0 -150
- package/substrate/standards/adr-template.md +0 -86
- package/substrate/standards/api-conventions/nextjs.md +0 -84
- package/substrate/standards/artifact-composition.md +0 -209
- package/substrate/standards/bash-hook-safety.md +0 -246
- package/substrate/standards/bassclef-configs-schema.md +0 -232
- package/substrate/standards/bassclef-evolution.md +0 -143
- package/substrate/standards/bassclef-internal-jargon.md +0 -244
- package/substrate/standards/bassclef-managed-sentinel.md +0 -96
- package/substrate/standards/bassclef-source-config.md +0 -228
- package/substrate/standards/branch-stacking.md +0 -408
- package/substrate/standards/code-safety-principles.md +0 -176
- package/substrate/standards/composer-prerequisites.md +0 -155
- package/substrate/standards/deferred-actions-schema.md +0 -204
- package/substrate/standards/dependency-discipline/cargo.md +0 -39
- package/substrate/standards/dependency-discipline/gem.md +0 -43
- package/substrate/standards/dependency-discipline/go-mod.md +0 -41
- package/substrate/standards/dependency-discipline/npm.md +0 -42
- package/substrate/standards/dependency-discipline/pip.md +0 -42
- package/substrate/standards/deployment-topology/ec2-tailscale.md +0 -225
- package/substrate/standards/deployment-topology.md +0 -69
- package/substrate/standards/docs-sync-allowlist.md +0 -76
- package/substrate/standards/domain-and-dns.md +0 -145
- package/substrate/standards/frontend-stack.md +0 -67
- package/substrate/standards/frontmatter-schema.md +0 -154
- package/substrate/standards/graceful-exit.md +0 -227
- package/substrate/standards/hook-idempotency.md +0 -102
- package/substrate/standards/hook-injection-discipline.md +0 -202
- package/substrate/standards/hook-install-class.md +0 -215
- package/substrate/standards/input-handler-interface.md +0 -152
- package/substrate/standards/lite-manifest-schema-changes.md +0 -135
- package/substrate/standards/luminary-matching.md +0 -105
- package/substrate/standards/luminary-problem-patterns.md +0 -481
- package/substrate/standards/migration-discipline/active-record.md +0 -50
- package/substrate/standards/migration-discipline/alembic.md +0 -43
- package/substrate/standards/migration-discipline/gorm.md +0 -50
- package/substrate/standards/migration-discipline/prisma.md +0 -53
- package/substrate/standards/migration-discipline/sqlalchemy.md +0 -51
- package/substrate/standards/mobile-ephemeral-session.md +0 -167
- package/substrate/standards/model-routing-discipline.md +0 -160
- package/substrate/standards/ogilvy-writing-rules.md +0 -225
- package/substrate/standards/opener-discipline.md +0 -96
- package/substrate/standards/operator-facing-prose-discipline.md +0 -201
- package/substrate/standards/persona-schema.md +0 -229
- package/substrate/standards/pluggable-luminaries.md +0 -323
- package/substrate/standards/pr-body-discipline.md +0 -115
- package/substrate/standards/preview-state-schema.md +0 -189
- package/substrate/standards/project-directory-layout.md +0 -276
- package/substrate/standards/release-tagging.md +0 -137
- package/substrate/standards/reserved-skill-names.md +0 -120
- package/substrate/standards/scannable-multi-option-output.md +0 -261
- package/substrate/standards/sdlc-compliance.md +0 -286
- package/substrate/standards/sdlc-gates/typescript.md +0 -57
- package/substrate/standards/secrets-lifecycle.md +0 -210
- package/substrate/standards/security-scanner-adapter.md +0 -145
- package/substrate/standards/session-board.md +0 -256
- package/substrate/standards/skill-output-discipline.md +0 -90
- package/substrate/standards/state-spine-contract.md +0 -255
- package/substrate/standards/state-spine.md +0 -511
- package/substrate/standards/steering-hints/kiss-words.md +0 -11
- package/substrate/standards/substrate-config-schema.md +0 -267
- package/substrate/standards/tech-stack-config.md +0 -109
- package/substrate/standards/tier-dependency-analysis.md +0 -167
- package/substrate/standards/tier-runtime-deps/lite.md +0 -57
- package/substrate/standards/tier-tag-schema.md +0 -155
- package/substrate/standards/two-layer-config.md +0 -99
- package/substrate/standards/use-case-format.md +0 -292
- package/substrate/standards/user-story-invest.md +0 -268
- package/substrate/standards/velocity-and-appetite.md +0 -229
- package/substrate/standards/voice-input-pattern.md +0 -119
- package/substrate/standards/whereami-schema.md +0 -301
- package/substrate/standards/worktree-management.md +0 -211
- package/substrate/standards/writing-guide.md +0 -213
- package/substrate/templates/chronicle-template.md +0 -75
- package/substrate/templates/deferred-action-template.md +0 -45
- package/substrate/templates/memory-proposal-template.md +0 -77
- package/substrate/templates/persona-template.md +0 -200
- package/substrate/templates/pr-faq.md +0 -45
- package/substrate/templates/secret-rotation-template.md +0 -162
- package/substrate/templates/spec-template.md +0 -131
- package/substrate/templates/use-case-template.md +0 -194
- package/substrate/templates/user-story-template.md +0 -107
- package/substrate/templates/whereami-template.md +0 -101
|
@@ -1,267 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
tier: lite
|
|
3
|
-
description: substrate.config.md is the single source of truth for external resource references in any bassclef-substrate repo.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Substrate Config Schema
|
|
7
|
-
|
|
8
|
-
`substrate.config.md` is the **single source of truth** for external
|
|
9
|
-
resource references in any bassclef-substrate repo. Functionally, it
|
|
10
|
-
is to bassclef what `.env` is to runtime code — the one place agents
|
|
11
|
-
look for "where is X" without guessing, without consulting memory, and
|
|
12
|
-
without hardcoding.
|
|
13
|
-
|
|
14
|
-
## Why this exists
|
|
15
|
-
|
|
16
|
-
Before this standard: resource references lived in three places —
|
|
17
|
-
`substrate.config.md`, project memory, and hardcoded in skills. Agents
|
|
18
|
-
had to check all three, confused them routinely, and produced wrong
|
|
19
|
-
pushes (drafts pushed to corpus doc, etc.).
|
|
20
|
-
|
|
21
|
-
Single-source-of-truth eliminates the ambiguity. Skills read only from
|
|
22
|
-
`substrate.config.md`. Memory references resources only by field name,
|
|
23
|
-
never by raw ID.
|
|
24
|
-
|
|
25
|
-
## Typed suffix convention
|
|
26
|
-
|
|
27
|
-
Every resource field in `substrate.config.md` uses a typed suffix so
|
|
28
|
-
the agent never has to interpret the value:
|
|
29
|
-
|
|
30
|
-
| Suffix | Meaning | Examples |
|
|
31
|
-
|--------|---------|----------|
|
|
32
|
-
| `*_doc_id` | Google Doc ID (a string that goes after `/document/d/`) | `journal_doc_id`, `changelog_doc_id`, `brand_corpus_doc_id` |
|
|
33
|
-
| `*_sheet_id` | Google Sheets ID | `metrics_sheet_id` |
|
|
34
|
-
| `*_url` | Full URL (http/https) | `staging_url`, `grafana_url`, `langfuse_url` |
|
|
35
|
-
| `*_host` | Host without scheme | `db_host`, `redis_host` |
|
|
36
|
-
| `*_repo` | GitHub repo reference (`owner/name`) | `parent_repo`, `deploy_repo` |
|
|
37
|
-
| `*_repos` | Comma-separated list of GitHub repo references | `bassclef_evolution_child_repos` |
|
|
38
|
-
| `*_path` | Filesystem path (absolute preferred) | `shared_artifacts_path` |
|
|
39
|
-
| `*_channel_id` | Slack/Discord channel | `alerts_channel_id` |
|
|
40
|
-
| `*_project_id` | Linear/Jira/Asana project | `linear_project_id` |
|
|
41
|
-
| `*_token_name` | **Name of env var** holding a secret (never the secret itself) | `gh_token_name`, `anthropic_key_name` |
|
|
42
|
-
| `*_reviewers` | GitHub usernames (comma-separated) for approval gates | `prod_approval_reviewers` |
|
|
43
|
-
| `*_topology` | Architectural choice per `deployment-topology.md` | `staging_topology` |
|
|
44
|
-
|
|
45
|
-
**Secrets NEVER in `substrate.config.md`.** That file is committed to
|
|
46
|
-
git. Secrets live in `.env` (gitignored) or a secret manager. The
|
|
47
|
-
convention stores the *name* of the env var (e.g.,
|
|
48
|
-
`gh_token_name: GH_TOKEN`) so agents know which variable to read at
|
|
49
|
-
runtime.
|
|
50
|
-
|
|
51
|
-
**Secret lifecycle is tracked separately** in `substrate.secrets.md`
|
|
52
|
-
(schema: `standards/state-spine/schemas/substrate-secrets.schema.json`;
|
|
53
|
-
purpose: `standards/secrets-lifecycle.md`). That file holds rotation
|
|
54
|
-
cadence, expiry dates, runbook paths, and health-check commands —
|
|
55
|
-
references and metadata only, never values. The two files cross-reference
|
|
56
|
-
each other; `substrate.config.md` answers *where* a resource lives,
|
|
57
|
-
`substrate.secrets.md` answers *when* a credential expires and *how* to
|
|
58
|
-
rotate it.
|
|
59
|
-
|
|
60
|
-
## Single-source-of-truth rule
|
|
61
|
-
|
|
62
|
-
1. **External resource IDs live ONLY in `substrate.config.md`.** Any
|
|
63
|
-
Google Doc ID, URL, repo reference, or similar pointer is a field
|
|
64
|
-
in this file.
|
|
65
|
-
2. **Project memory references resources ONLY by field name**, never
|
|
66
|
-
by raw value. `brand_corpus_doc_id` is a valid memory reference;
|
|
67
|
-
`1gps7mmEYBCud...` is not.
|
|
68
|
-
3. **Skills and hooks read ONLY from `substrate.config.md`** for
|
|
69
|
-
resource lookups. No hardcoded IDs in skill files, hook scripts,
|
|
70
|
-
or agent definitions.
|
|
71
|
-
4. **If an agent needs a resource that isn't in
|
|
72
|
-
`substrate.config.md`**, the agent prompts the operator to add it
|
|
73
|
-
with a typed field name. Do not hardcode. Do not cache in memory.
|
|
74
|
-
5. **Scaffolding on new repos prompts for each known field** during
|
|
75
|
-
`/autonomous start` setup.
|
|
76
|
-
|
|
77
|
-
## Known fields (extensible)
|
|
78
|
-
|
|
79
|
-
These fields are recognized by bassclef skills. Not all are required;
|
|
80
|
-
uncommented defaults shown.
|
|
81
|
-
|
|
82
|
-
```yaml
|
|
83
|
-
# === Artifacts ===
|
|
84
|
-
journal_doc_id: [per-repo draft Google Doc — pushes from /journal + session-end]
|
|
85
|
-
changelog_doc_id: [per-repo weekly changelog Google Doc — pushes from /release-notes]
|
|
86
|
-
brand_corpus_doc_id: [cross-repo brand team corpus — pushes from /journal-export]
|
|
87
|
-
|
|
88
|
-
# === Environments ===
|
|
89
|
-
deploy_targets:
|
|
90
|
-
local: true # always available
|
|
91
|
-
staging: false # URL when configured
|
|
92
|
-
prod: false # URL when configured (hard gate — human-approved)
|
|
93
|
-
|
|
94
|
-
# === Integrations (optional, per-project) ===
|
|
95
|
-
langfuse_url: [tracing dashboard URL, if used]
|
|
96
|
-
grafana_url: [metrics dashboard URL, if used]
|
|
97
|
-
linear_project_id: [Linear project for ticket sync, if used]
|
|
98
|
-
|
|
99
|
-
# === Bassclef substrate (bassclef repo only) ===
|
|
100
|
-
# Consumer repos scanned by session-reflection for bassclef-evolution
|
|
101
|
-
# issues. Keep in sync with .github/workflows/bassclef-template-sync.yml
|
|
102
|
-
# matrix. Fallback when field absent: poa only.
|
|
103
|
-
bassclef_evolution_child_repos: [comma-separated list of owner/name]
|
|
104
|
-
|
|
105
|
-
# === Budget ===
|
|
106
|
-
budget:
|
|
107
|
-
session_ceiling: [API burst $/session]
|
|
108
|
-
iteration_ceiling: [API burst $/iteration]
|
|
109
|
-
warning_threshold: 75%
|
|
110
|
-
|
|
111
|
-
# === Secret references (names only, not values) ===
|
|
112
|
-
anthropic_key_name: ANTHROPIC_API_KEY # env var name, not the key
|
|
113
|
-
gh_token_name: GH_TOKEN # env var name, not the token
|
|
114
|
-
|
|
115
|
-
# === Hosting platform (REQUIRED in any consumer that ships a UI) ===
|
|
116
|
-
#
|
|
117
|
-
# Drives which deploy_* fields apply AND which adapter `/bind-subdomain`
|
|
118
|
-
# loads. Every consumer running `/preview-build` or shipping production
|
|
119
|
-
# UI MUST set this — the bassclef default is `amplify` per ADR-008
|
|
120
|
-
# (frontend-stack) + POA + quorum precedent (single-provider portfolio
|
|
121
|
-
# reduces operator cognitive load; AWS-native; cheap port to existing
|
|
122
|
-
# AWS auth).
|
|
123
|
-
#
|
|
124
|
-
# Enum values (all five are valid; not all have shipped adapters yet):
|
|
125
|
-
# - amplify: use amplify_app_id + amplify_region + amplify_branch
|
|
126
|
-
# (bassclef-recommended default; adapters live)
|
|
127
|
-
# - ec2-tailscale: use deploy_host + deploy_user + deploy_path (POA pattern)
|
|
128
|
-
# - vercel: adapter not yet shipped — schema reserves the slot
|
|
129
|
-
# - netlify: adapter not yet shipped — schema reserves the slot
|
|
130
|
-
# - cloudflare-pages: adapter not yet shipped — schema reserves the slot
|
|
131
|
-
# - none: consumer explicitly opts out of preview/prototype
|
|
132
|
-
# deployment. `/bind-subdomain` and `/launch-preview`
|
|
133
|
-
# refuse on `none` unless --override given. Use for
|
|
134
|
-
# docs-only repos (e.g., bassclef itself) or repos
|
|
135
|
-
# that ship no UI surface.
|
|
136
|
-
hosting_platform: amplify # bassclef default; pick from enum above
|
|
137
|
-
|
|
138
|
-
# --- Production tier (optional; declare when production differs from prototype) ---
|
|
139
|
-
#
|
|
140
|
-
# Per-tier hosting was added in bassclef#458 to resolve the POA case:
|
|
141
|
-
# POA's prototypes deploy to amplify, but POA's production runs on
|
|
142
|
-
# ec2-tailscale (per ADR-009) and predates the prototype pipeline.
|
|
143
|
-
# Without `production_hosting_platform`, hosting_platform=amplify
|
|
144
|
-
# implies POA's whole app is on amplify — wrong.
|
|
145
|
-
#
|
|
146
|
-
# `production_hosting_platform` is DECLARATIVE. /launch-preview and
|
|
147
|
-
# /bind-subdomain operate on the prototype tier only and do not read
|
|
148
|
-
# this field. It documents the production tier so operators (and
|
|
149
|
-
# future tooling) know the production deploy is a separate concern.
|
|
150
|
-
#
|
|
151
|
-
# When unset, production tier inherits hosting_platform.
|
|
152
|
-
production_hosting_platform: ec2-tailscale # only set when production differs from prototype
|
|
153
|
-
|
|
154
|
-
# --- Amplify-specific (when hosting_platform=amplify) ---
|
|
155
|
-
#
|
|
156
|
-
# `amplify_app_id` is the provisioning-indicator field (bassclef#523).
|
|
157
|
-
# Set by `/provision-deploy-host` on success when the Amplify app is
|
|
158
|
-
# created. Composer pre-flight (lib/composer-preflight.sh Check 6) reads
|
|
159
|
-
# this field to verify provisioning happened — when missing or set to a
|
|
160
|
-
# bracketed placeholder shape, /preview-build is BLOCKED with three-path
|
|
161
|
-
# remediation (run /provision-deploy-host inline / re-dispatch with
|
|
162
|
-
# --no-launch / explicit defer). Replaces the silent-defer-bind class
|
|
163
|
-
# that caused POA's 2026-05-05 mobile session to merge variants but
|
|
164
|
-
# never bind a subdomain.
|
|
165
|
-
amplify_app_id: [e.g., d154l5usyc80nk]
|
|
166
|
-
amplify_region: [e.g., eu-north-1]
|
|
167
|
-
amplify_branch: [branch bound to domain, default: main]
|
|
168
|
-
|
|
169
|
-
# --- EC2 + Tailscale-specific (when hosting_platform=ec2-tailscale) ---
|
|
170
|
-
# See standards/deployment-topology.md for the SENTINEL_bassclef_pattern.
|
|
171
|
-
#
|
|
172
|
-
# `deploy_host` is the provisioning-indicator field (bassclef#523) —
|
|
173
|
-
# Composer pre-flight Check 6 reads it to verify provisioning happened
|
|
174
|
-
# (parallel to amplify_app_id for amplify). Same three-path remediation
|
|
175
|
-
# applies when missing.
|
|
176
|
-
deploy_host: [Tailscale hostname of prod box]
|
|
177
|
-
deploy_user: [SSH user on prod box]
|
|
178
|
-
deploy_path: [absolute path on box, e.g., /opt/poa]
|
|
179
|
-
staging_deploy_host: [same or different Tailscale host]
|
|
180
|
-
staging_deploy_path: [absolute path, e.g., /opt/poa-staging]
|
|
181
|
-
staging_topology: same-box | separate-box # Option A or B
|
|
182
|
-
tailscale_tag: [CI tag, e.g., tag:ci]
|
|
183
|
-
backup_path: [absolute path, e.g., /opt/backups]
|
|
184
|
-
prod_approval_reviewers: [GitHub usernames comma-separated]
|
|
185
|
-
|
|
186
|
-
# === Domain + DNS (when app binds a friendly URL) ===
|
|
187
|
-
# See standards/domain-and-dns.md. Optional — skip if using platform
|
|
188
|
-
# default URL (e.g., *.amplifyapp.com). Binding is automated via the
|
|
189
|
-
# /bind-subdomain skill.
|
|
190
|
-
subdomain: [e.g., myapp.apps.example.com]
|
|
191
|
-
dns_provider: [cloudflare | route53] # v1 supports cloudflare
|
|
192
|
-
dns_zone: [e.g., example.com]
|
|
193
|
-
cloudflare_token_env: [env var name holding CF API token, e.g., CLOUDFLARE_API_TOKEN]
|
|
194
|
-
```
|
|
195
|
-
|
|
196
|
-
## Migration from anti-patterns
|
|
197
|
-
|
|
198
|
-
### Anti-pattern 1: raw IDs in project memory
|
|
199
|
-
|
|
200
|
-
**Before**:
|
|
201
|
-
```markdown
|
|
202
|
-
# memory/reference_brand_corpus.md
|
|
203
|
-
The brand team corpus lives at 1gps7mmEYBCud462Pn_DNf2mXa5Bj58NMjXUUDqWGIh0.
|
|
204
|
-
```
|
|
205
|
-
|
|
206
|
-
**After**:
|
|
207
|
-
```markdown
|
|
208
|
-
# memory/reference_brand_corpus.md
|
|
209
|
-
The brand team corpus is configured as `brand_corpus_doc_id` in
|
|
210
|
-
substrate.config.md. Agents should always read from there, never
|
|
211
|
-
reference the raw ID directly.
|
|
212
|
-
```
|
|
213
|
-
|
|
214
|
-
### Anti-pattern 2: hardcoded IDs in skills
|
|
215
|
-
|
|
216
|
-
**Before** (in `.claude/skills/journal-export/SKILL.md`):
|
|
217
|
-
```bash
|
|
218
|
-
npx tsx scripts/push-to-gdoc.ts \
|
|
219
|
-
--file docs/journal-corpus/corpus.md \
|
|
220
|
-
--doc-id 1gps7mmEYBCud462Pn_DNf2mXa5Bj58NMjXUUDqWGIh0
|
|
221
|
-
```
|
|
222
|
-
|
|
223
|
-
**After**:
|
|
224
|
-
```bash
|
|
225
|
-
DOC_ID=$(grep "^brand_corpus_doc_id:" substrate.config.md | awk '{print $2}')
|
|
226
|
-
npx tsx scripts/push-to-gdoc.ts \
|
|
227
|
-
--file docs/journal-corpus/corpus.md \
|
|
228
|
-
--doc-id "$DOC_ID"
|
|
229
|
-
```
|
|
230
|
-
|
|
231
|
-
Or equivalently, skills document the field name in prose and require
|
|
232
|
-
the agent to look it up at runtime:
|
|
233
|
-
|
|
234
|
-
```markdown
|
|
235
|
-
## Step 7: Push to Google Docs
|
|
236
|
-
|
|
237
|
-
Push to `brand_corpus_doc_id` from `substrate.config.md`:
|
|
238
|
-
|
|
239
|
-
\`\`\`bash
|
|
240
|
-
npx tsx scripts/push-to-gdoc.ts --file docs/journal-corpus/corpus.md \
|
|
241
|
-
--doc-id $(grep "^brand_corpus_doc_id:" substrate.config.md | awk '{print $2}')
|
|
242
|
-
\`\`\`
|
|
243
|
-
```
|
|
244
|
-
|
|
245
|
-
### Anti-pattern 3: scattered fields
|
|
246
|
-
|
|
247
|
-
If an app repo adds a new resource (e.g., a Retool dashboard URL)
|
|
248
|
-
and stores it in a README comment, an inline skill comment, or a
|
|
249
|
-
hook variable — that's the anti-pattern. All such values go in
|
|
250
|
-
`substrate.config.md` with the typed suffix.
|
|
251
|
-
|
|
252
|
-
## Related rules
|
|
253
|
-
|
|
254
|
-
- `.claude/rules/substrate-config-schema.md` — enforces this standard
|
|
255
|
-
at agent behavior level (read from config, don't hardcode, don't
|
|
256
|
-
cache in memory)
|
|
257
|
-
- `.claude/skills/autonomous/SKILL.md` — prompts for each known field
|
|
258
|
-
during scaffold
|
|
259
|
-
- `.claude/skills/substrate-check/SKILL.md` — validates substrate.config.md
|
|
260
|
-
has required fields for the repo type
|
|
261
|
-
|
|
262
|
-
## Versioning
|
|
263
|
-
|
|
264
|
-
When bassclef adds a new known field type, the schema here is the
|
|
265
|
-
authoritative list. App repos update their `substrate.config.md` to
|
|
266
|
-
add the new field during next `/autonomous start` scaffold pass (the
|
|
267
|
-
skill surfaces missing fields and prompts for values).
|
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
tier: lite
|
|
3
|
-
description: "The tech_stack: block inside .claude/bassclef-configs.jsonc declares the adopter's primary tech stack."
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Tech Stack Configuration
|
|
7
|
-
|
|
8
|
-
The `tech_stack:` block inside `.claude/bassclef-configs.jsonc` declares the adopter's primary tech stack. Stack-bound rules + standards in bassclef read this block to pick the right per-stack discipline.
|
|
9
|
-
|
|
10
|
-
Without `tech_stack:`, stack-bound rules fall back to their default (which is operator's stack — TypeScript + Next.js + Prisma + EC2-Tailscale). Non-matching adopters then see false-fires: Prisma rules at SQLAlchemy adopters, Next.js API conventions at FastAPI adopters, etc. The tech_stack block is what stops the bleed.
|
|
11
|
-
|
|
12
|
-
Schema source: `standards/state-spine/schemas/tech-stack.schema.json`. This file documents the semantics; the schema documents the shape.
|
|
13
|
-
|
|
14
|
-
## When this block is read
|
|
15
|
-
|
|
16
|
-
| Surface | What it does with the block |
|
|
17
|
-
|---|---|
|
|
18
|
-
| `.claude/rules/schema-management.md` | Reads `tech_stack.orm:` to load the matching sibling under `standards/migration-discipline/<orm>.md` |
|
|
19
|
-
| `.claude/rules/api-conventions.md` | Frontmatter `tech_stack_match: { frontend: nextjs }`; rule fires only when matched |
|
|
20
|
-
| `.claude/rules/sdlc-gates.md` | Frontmatter `tech_stack_match: { lang: typescript }`; rule fires only when matched |
|
|
21
|
-
| `.claude/rules/new-dependency-check.md` | Reads `tech_stack.pkg_manager:` to load the matching sibling under `standards/dependency-discipline/<pkg_manager>.md` |
|
|
22
|
-
| `standards/frontend-stack.md` (now thin pointer) | Reads `tech_stack.frontend:` to direct adopter to the matching `standards/stack-patterns/<stack>.md` |
|
|
23
|
-
| `standards/deployment-topology.md` (now thin pointer) | Reads `tech_stack.deploy:` to direct adopter to the matching `standards/deployment-topology-patterns/<deploy>.md` |
|
|
24
|
-
| `/onboard-repo` Phase 2.x | Auto-detects + asks; writes the block |
|
|
25
|
-
| `/demo` first dispatch | If block absent, prompts the operator (bassclef#1126 / #1127) |
|
|
26
|
-
| `/launch` Phase -1 Check 7 | Refuses dispatch when block absent — `/launch` needs real stack tokens to produce real decompositions |
|
|
27
|
-
|
|
28
|
-
## Fields
|
|
29
|
-
|
|
30
|
-
All fields are optional at the schema level; specific rules fail open (or fall back to operator's default) when their referenced field is absent. Adopters declare what they need.
|
|
31
|
-
|
|
32
|
-
| Field | Enum | Notes |
|
|
33
|
-
|---|---|---|
|
|
34
|
-
| `lang` | typescript / python / go / ruby / java / rust / none | Primary language family. Drives sdlc-gates Path B. |
|
|
35
|
-
| `frontend` | nextjs / react-vite / sveltekit / vue / svelte / django / rails / fastapi / none | Frontend framework. Drives api-conventions Path B + frontend-stack routing. |
|
|
36
|
-
| `backend` | nodejs / python / ruby / go / rust / deno / none | Backend runtime. Drives sdlc-gates Path B. |
|
|
37
|
-
| `orm` | prisma / sqlalchemy / gorm / alembic / active-record / drizzle / none | ORM. Drives schema-management Path A routing. |
|
|
38
|
-
| `pkg_manager` | npm / pnpm / yarn / pip / poetry / cargo / gem / go-mod | Package manager. Drives new-dependency-check Path A routing. |
|
|
39
|
-
| `deploy` | ec2-tailscale / vercel / netlify / fly / render / gcp-cloud-run / amplify / none | Deploy topology. Drives deployment-topology Path C routing. |
|
|
40
|
-
| `declared_at` | ISO 8601 date | Provenance — last declared. |
|
|
41
|
-
| `declared_via` | onboard-repo / demo-prompt / manual / migrated | Provenance — how declared. |
|
|
42
|
-
| `rationale` | string | Optional operator-narrative; one paragraph why. |
|
|
43
|
-
|
|
44
|
-
## Auto-detection at `/onboard-repo`
|
|
45
|
-
|
|
46
|
-
When `/onboard-repo` runs, it inspects the adopter repo for stack signals and pre-fills the block:
|
|
47
|
-
|
|
48
|
-
| File present | Suggests |
|
|
49
|
-
|---|---|
|
|
50
|
-
| `package.json` with `"next"` dep | `frontend: nextjs`, `lang: typescript` (if tsconfig.json), `pkg_manager: npm/pnpm/yarn` (detect lockfile) |
|
|
51
|
-
| `package.json` with `"prisma"` dep | `orm: prisma` |
|
|
52
|
-
| `package.json` with `"drizzle-orm"` dep | `orm: drizzle` |
|
|
53
|
-
| `requirements.txt` or `pyproject.toml` | `lang: python` |
|
|
54
|
-
| pyproject.toml with `sqlalchemy` | `orm: sqlalchemy` |
|
|
55
|
-
| pyproject.toml with `alembic` | `orm: alembic` |
|
|
56
|
-
| `Gemfile` | `lang: ruby`, `pkg_manager: gem` |
|
|
57
|
-
| `Gemfile` with `rails` | `frontend: rails`, `backend: ruby`, `orm: active-record` |
|
|
58
|
-
| `go.mod` | `lang: go`, `pkg_manager: go-mod` |
|
|
59
|
-
| `Cargo.toml` | `lang: rust`, `pkg_manager: cargo` |
|
|
60
|
-
| `vercel.json` or `.vercelignore` | `deploy: vercel` |
|
|
61
|
-
| `netlify.toml` | `deploy: netlify` |
|
|
62
|
-
| `fly.toml` | `deploy: fly` |
|
|
63
|
-
| `render.yaml` | `deploy: render` |
|
|
64
|
-
| `app.yaml` (App Engine) or `cloudbuild.yaml` | `deploy: gcp-cloud-run` |
|
|
65
|
-
| `amplify.yml` | `deploy: amplify` |
|
|
66
|
-
| `infrastructure/` with terraform + EC2 + Tailscale | `deploy: ec2-tailscale` |
|
|
67
|
-
|
|
68
|
-
When auto-detection is ambiguous (e.g., monorepo with multiple stacks), the operator picks. When auto-detection finds nothing recognized, the block stays empty and stack-bound rules fall back to operator defaults.
|
|
69
|
-
|
|
70
|
-
## Recommended defaults
|
|
71
|
-
|
|
72
|
-
For operators starting fresh (no existing repo), bassclef recommends:
|
|
73
|
-
|
|
74
|
-
```jsonc
|
|
75
|
-
{
|
|
76
|
-
"tech_stack": {
|
|
77
|
-
"lang": "typescript",
|
|
78
|
-
"frontend": "nextjs",
|
|
79
|
-
"backend": "nodejs",
|
|
80
|
-
"orm": "prisma",
|
|
81
|
-
"pkg_manager": "pnpm",
|
|
82
|
-
"deploy": "vercel",
|
|
83
|
-
"declared_at": "2026-06-18",
|
|
84
|
-
"declared_via": "demo-prompt"
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
Rationale: bassclef's most-tested portfolio stack. Cleanest path through `/launch` chain, the existing rule + standard set, and the bassclef-sync ergonomics. Operators on other stacks override at `/onboard-repo` time.
|
|
90
|
-
|
|
91
|
-
## What this block does NOT carry
|
|
92
|
-
|
|
93
|
-
- **Queue / cache / auth / email infrastructure** — those are follow-on triggers per bassclef#1127; `/spec` detects need from use-case language and prompts at spec-time.
|
|
94
|
-
- **Build tooling specifics** (webpack vs turbopack, etc.) — too granular; rules don't yet route on this.
|
|
95
|
-
- **Runtime / version pins** (Node 20 vs 22, Python 3.11 vs 3.12) — `package.json engines` and equivalent files hold this.
|
|
96
|
-
|
|
97
|
-
## Distinct from
|
|
98
|
-
|
|
99
|
-
- **`substrate.config.md`** — that holds resource references (Google Doc IDs, URLs, env-var names). Tech stack lives in `bassclef-configs.jsonc` because it's an *adoption* setting that controls bassclef's rule routing.
|
|
100
|
-
- **`standards/bassclef-platform.yml`** — org-baseline platform-engineering config (AWS account, IAM roles, etc.). Per-repo tech stack is finer-grained.
|
|
101
|
-
- **`design/object-model.md` Stack object** — that's about the *runtime* (which agents, which deploy target). This block is about *language + framework + ORM* — the discipline-routing dimension.
|
|
102
|
-
|
|
103
|
-
## Refs
|
|
104
|
-
|
|
105
|
-
- bassclef#1127 — parent ticket (tech_stack discovery in /onboard-repo + this schema)
|
|
106
|
-
- bassclef#1133 — ARCH-T0 stack-leakage audit (the failure mode this block stops)
|
|
107
|
-
- bassclef#1126 — `/demo` skill split (first-dispatch prompt surface)
|
|
108
|
-
- WU-2 of bet `docs/iteration-bets/2026-06-18a-public-adopter-leverage-longrun.md` — ships this primitive
|
|
109
|
-
- Composes with: standards/bassclef-configs-schema.md (parent config), all WU-5 through WU-10 rewrites in bet 2026-06-18a
|
|
@@ -1,167 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
tier: lite
|
|
3
|
-
description: Reference doc for the tier-dependency-audit subsystem.
|
|
4
|
-
---
|
|
5
|
-
<!-- andon-allow: operator-private -->
|
|
6
|
-
<!-- andon-allow: bassclef-upstream -->
|
|
7
|
-
|
|
8
|
-
# Tier dependency analysis
|
|
9
|
-
|
|
10
|
-
Reference doc for the tier-dependency-audit subsystem. Sister to `standards/tier-tag-schema.md` — that standard names the `tier:` field per file; this standard names the graph walk that audits whether every legitimate `<tier>` dependency carries the tag AND whether every file in the release matches the graph.
|
|
11
|
-
|
|
12
|
-
## Purpose
|
|
13
|
-
|
|
14
|
-
The release script (`scripts/release-to-bassclef.sh`) walks `ALLOWED_PATHS` and applies a tier check on `.md` and `.sh` files inside primitive surfaces (L466-505). Two branches ship files without a tier check:
|
|
15
|
-
|
|
16
|
-
- **L507-513** — non-md/sh files inside primitive surfaces (JSON, TXT, fixtures, subdir READMEs)
|
|
17
|
-
- **L514-518** — non-primitive paths (top-level files, CLAUDE.md, top-level manifests)
|
|
18
|
-
|
|
19
|
-
These two branches allow accidental leaks. Prior release attempt (release-2026-08-15-83778faf) shipped 61 cache binaries and one `.DS_Store` via one of these branches. Adopter public bassclef now carries 827 tracked orphan files.
|
|
20
|
-
|
|
21
|
-
This subsystem replaces the exempt-list patch pattern (Parnas information hiding of *what* to exclude) with an inclusion graph (Nygard fail-safe: only what the graph says is legit ships).
|
|
22
|
-
|
|
23
|
-
## Reusable across tiers
|
|
24
|
-
|
|
25
|
-
One subsystem serves all tiers. The tier arg picks which root set + adopter-runtime dependency list to use. The walk algorithm is the same. Build it once for `lite`. Add tier-runtime dependency lists for `standard`, `standard-pro`, `ultra`, `upstream` as those tiers mature.
|
|
26
|
-
|
|
27
|
-
## Input contract
|
|
28
|
-
|
|
29
|
-
```
|
|
30
|
-
scripts/analyze-tier-dependencies.sh <tier>
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
- `<tier>` — one of `lite | standard | standard-pro | ultra | upstream`
|
|
34
|
-
- Reads sources from bassclef-upstream working tree
|
|
35
|
-
- Reads adopter-runtime dependency list from `standards/tier-runtime-deps/<tier>.md`
|
|
36
|
-
- Reads release-script include set from `scripts/release-to-bassclef.sh --dry-run`
|
|
37
|
-
- Exits 0 on classification complete; exit 2 on malformed input; exit 3 on missing tier-runtime-deps file
|
|
38
|
-
|
|
39
|
-
## Output contract
|
|
40
|
-
|
|
41
|
-
`docs/dependency-audits/<YYYY-MM-DD>-<tier>.md` — markdown table with 5 buckets (Bucket 2 splits into 2a + 2b per ADR-043 D1 + canvas 2026-07-19-bassclef-lite.md L76):
|
|
42
|
-
|
|
43
|
-
| Bucket | Meaning | Fix action |
|
|
44
|
-
|---|---|---|
|
|
45
|
-
| 1. Tagged | File has `tier: <tier>` frontmatter or header. Ships correctly. | None |
|
|
46
|
-
| 2a. Missing tag | File has NO tier tag at all AND is a legit `<tier>` dep per graph walk. Safe mechanical add. | Add `tier: <tier>` frontmatter or header via helper `scripts/apply-bucket2-tier-tags.sh` |
|
|
47
|
-
| 2b. Chain-snap risk | File has a tier tag for a DIFFERENT tier BUT graph walk says `<tier>` depends on it. This is canvas L76's "chain snaps at every hop" — bassclef-lite fetch would break if this file is missing. | Per-file cure per canvas Q1+Q2: (i) promote the file to `<tier>` standalone, (ii) inline it into the calling `<tier>` file per Ousterhout deep modules, OR (iii) determine the graph walk over-included (reference in doc but not runtime dep). |
|
|
48
|
-
| 3. Accidental leak | File currently ships but is not in the graph. | Remove from bassclef-upstream + extend .gitignore |
|
|
49
|
-
| 4. Missing from release | File is in the graph but not in the release-script include set. | Extend release script `ALLOWED_PATHS` or fix a filter |
|
|
50
|
-
|
|
51
|
-
Each bucket lists the affected files with one-line reasons. The doc also carries a summary count per bucket and a recommended fix order (bucket 4 first if any, then 2a mechanical, then 2b per-file review, then 3).
|
|
52
|
-
|
|
53
|
-
### Why the 2a/2b split matters
|
|
54
|
-
|
|
55
|
-
Before the split, bucket 2 conflated two distinct classes. Files tagged `tier: standard` that are legit `<lite>` deps per graph walk landed in bucket 2 alongside files with no tag. Bulk "add `tier: lite`" would retag `standard` files as `lite` — a maturity signal shift that bloats bassclef-lite (defeats the slimmed-down goal for Sam/Louis/Adam Sharpe per canvas Stage 1).
|
|
56
|
-
|
|
57
|
-
Per ADR-043 D1:
|
|
58
|
-
- `tier: lite` = explicit inclusion in bassclef-lite npm ship
|
|
59
|
-
- `tier: standard` = deliberate exclusion from bassclef-lite
|
|
60
|
-
|
|
61
|
-
A file tagged `standard` is deliberately non-lite. When the graph walk from a lite root set discovers such a file as a dep, that's a chain-snap risk that needs per-file operator judgment — not a bulk retag.
|
|
62
|
-
|
|
63
|
-
## Walk algorithm
|
|
64
|
-
|
|
65
|
-
Four data sources; union → compare against actual release set.
|
|
66
|
-
|
|
67
|
-
**Source 1 — root set (tagged).** Files that already carry `tier: <tier>` frontmatter or `# tier: <tier>` header. Seed for the walk.
|
|
68
|
-
|
|
69
|
-
**Source 2 — reference walk (BFS from root set).** For each file in the queue, extract references to other files. Add each new discovery to the queue. Repeat until queue empty.
|
|
70
|
-
|
|
71
|
-
Reference shapes to extract:
|
|
72
|
-
|
|
73
|
-
- `composes_with:` frontmatter — other skills or rules named
|
|
74
|
-
- `source lib/<name>.sh` in hook headers — lib files sourced
|
|
75
|
-
- `additionalDirectories:` in settings.json — paths the adopter loads
|
|
76
|
-
- Cross-file grep `bash scripts/<name>.sh` in hook bodies — scripts invoked
|
|
77
|
-
- `@luminary <slug>` refs — luminary files
|
|
78
|
-
- `see standards/<name>.md` refs — standard files
|
|
79
|
-
- `see .claude/rules/<name>.md` refs — rule files
|
|
80
|
-
|
|
81
|
-
**Source 3 — adopter-runtime dependencies (tier-specific).** Files the adopter needs at runtime that don't fall out of the reference walk. Lives at `standards/tier-runtime-deps/<tier>.md`. For lite:
|
|
82
|
-
|
|
83
|
-
- `CLAUDE.md`
|
|
84
|
-
- `bassclef-configs.jsonc`
|
|
85
|
-
- `.bassclef-source.json` template
|
|
86
|
-
- `.claude/settings.json` template
|
|
87
|
-
- `presence/install/*.template.sh`
|
|
88
|
-
- `LICENSE`
|
|
89
|
-
- `README.md`
|
|
90
|
-
- `.github/workflows/bassclef-*.yml`
|
|
91
|
-
- `lite-manifest.json`
|
|
92
|
-
- `bassclef-wiring-manifest.json`
|
|
93
|
-
|
|
94
|
-
**Source 4 — release-script include set (ACTUAL).** Runs `scripts/release-to-bassclef.sh --dry-run` and parses the `INCLUDE_LIST` output.
|
|
95
|
-
|
|
96
|
-
## Classification rule
|
|
97
|
-
|
|
98
|
-
Let `INTENDED = Source 1 ∪ Source 2 ∪ Source 3`.
|
|
99
|
-
|
|
100
|
-
Let `ACTUAL = Source 4`.
|
|
101
|
-
|
|
102
|
-
- `INTENDED ∩ ACTUAL, has tag` → Bucket 1 (Tagged)
|
|
103
|
-
- `INTENDED ∩ ACTUAL, no tag` → Bucket 2 (Missing tag)
|
|
104
|
-
- `ACTUAL \ INTENDED` → Bucket 3 (Accidental leak)
|
|
105
|
-
- `INTENDED \ ACTUAL` → Bucket 4 (Missing from release)
|
|
106
|
-
|
|
107
|
-
## Combined-tier mode
|
|
108
|
-
|
|
109
|
-
Single-tier audit surfaces one problem: bucket 3 (accidental leak) mixes true leaks with files legit-tagged for OTHER tiers. A `standard` file shipping in the actual release set is not a `lite` leak — it belongs in the release for standard adopters. Single-tier audit calls it bucket 3 anyway because the file is `ACTUAL \ INTENDED_lite`.
|
|
110
|
-
|
|
111
|
-
Combined-tier mode fixes the class. The script accepts a special arg `all` (or a comma list like `lite,standard,upstream`):
|
|
112
|
-
|
|
113
|
-
```
|
|
114
|
-
scripts/analyze-tier-dependencies.sh all
|
|
115
|
-
scripts/analyze-tier-dependencies.sh lite,standard
|
|
116
|
-
```
|
|
117
|
-
|
|
118
|
-
**Classification under combined-tier:**
|
|
119
|
-
|
|
120
|
-
Let `INTENDED_ALL = INTENDED_lite ∪ INTENDED_standard ∪ INTENDED_standard-pro ∪ INTENDED_ultra ∪ INTENDED_upstream` (or the user-supplied subset).
|
|
121
|
-
|
|
122
|
-
- `INTENDED_ALL ∩ ACTUAL, has any tier tag` → Bucket 1 (Tagged)
|
|
123
|
-
- `INTENDED_ALL ∩ ACTUAL, no tag` → Bucket 2 (Missing tag; carries per-tier reason for which tier each file belongs to)
|
|
124
|
-
- `ACTUAL \ INTENDED_ALL` → Bucket 3 (True accidental leak — belongs in no tier's graph)
|
|
125
|
-
- `INTENDED_ALL \ ACTUAL` → Bucket 4 (Missing from release; carries per-tier reason)
|
|
126
|
-
|
|
127
|
-
**When to use which mode:**
|
|
128
|
-
|
|
129
|
-
| Mode | Use case |
|
|
130
|
-
|---|---|
|
|
131
|
-
| Single-tier | Curate one tier's manifest; find lite deps missing tag; produce bucket 2 for one tier's tagging pass |
|
|
132
|
-
| Combined-tier | Identify true accidental leaks safe to remove from bassclef-upstream; produce bucket 3 for cleanup |
|
|
133
|
-
|
|
134
|
-
Bucket 2 outputs from single-tier and combined-tier agree for that tier's legit missing tags. Bucket 3 differs — single-tier over-counts leaks; combined-tier gives the honest count.
|
|
135
|
-
|
|
136
|
-
**Output naming:**
|
|
137
|
-
|
|
138
|
-
- Single-tier: `docs/dependency-audits/<YYYY-MM-DD>-<tier>.md`
|
|
139
|
-
- Combined-tier: `docs/dependency-audits/<YYYY-MM-DD>-combined-<tier-list>.md` (e.g., `2026-08-17-combined-all.md`)
|
|
140
|
-
|
|
141
|
-
## Composition
|
|
142
|
-
|
|
143
|
-
- Sister to `standards/tier-tag-schema.md` — that standard names *what* the tag is; this standard names *how* to audit tag coverage per tier
|
|
144
|
-
- Consumed by `.claude/skills/tier-dependency-audit/SKILL.md` — user-invocable wrapper
|
|
145
|
-
- Composed with `scripts/release-to-bassclef.sh` — the ACTUAL set comes from `--dry-run`
|
|
146
|
-
- Composed with `.claude/rules/we-dont-break-adopters.md` (ADR-031) — the audit surfaces adopter-observable classes for careful handling
|
|
147
|
-
- Composed with `.claude/rules/mechanism-fidelity.md` (standard tier) — the subsystem IS the mechanism paired with tier-tag-schema
|
|
148
|
-
|
|
149
|
-
## Anchor luminaries
|
|
150
|
-
|
|
151
|
-
- `@luminary david-parnas` — information hiding: consumers see tier arg + classified manifest, not the walk algorithm
|
|
152
|
-
- `@luminary john-ousterhout` — deep module: one script, many tier callers
|
|
153
|
-
- `@luminary michael-nygard` — fail-safe default: the graph says what's legit; L514 tightening rejects untagged by default after buckets 2+3 clear
|
|
154
|
-
- `@luminary michael-feathers` — characterization tests: fixture graph pins subsystem behavior in Tier 0 test
|
|
155
|
-
|
|
156
|
-
## Refs
|
|
157
|
-
|
|
158
|
-
- Goal doc `docs/iteration-bets/2026-08-17a-tier-dependency-audit-subsystem.md`
|
|
159
|
-
- Sister `standards/tier-tag-schema.md`
|
|
160
|
-
- ADR-029 release pipeline
|
|
161
|
-
- ADR-031 we-dont-break-adopters
|
|
162
|
-
- ADR-037 release pipeline integrity check
|
|
163
|
-
- ADR-035 substrate-as-system
|
|
164
|
-
|
|
165
|
-
## Retirement condition
|
|
166
|
-
|
|
167
|
-
This standard retires only if the tier system itself retires. Walk sources may extend (new reference shapes as substrate evolves); the four-bucket classification and BFS shape survive any specific source extension.
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
tier: lite
|
|
3
|
-
description: Per standards/tier-dependency-analysis.md Source 3.
|
|
4
|
-
---
|
|
5
|
-
<!-- andon-allow: operator-private -->
|
|
6
|
-
<!-- andon-allow: bassclef-upstream -->
|
|
7
|
-
|
|
8
|
-
# Tier runtime deps — lite
|
|
9
|
-
|
|
10
|
-
Per `standards/tier-dependency-analysis.md` Source 3. Files the lite adopter needs at runtime that do not fall out of the reference walk from the root set.
|
|
11
|
-
|
|
12
|
-
Consumed by `scripts/analyze-tier-dependencies.sh lite` when computing the INTENDED set.
|
|
13
|
-
|
|
14
|
-
## Files
|
|
15
|
-
|
|
16
|
-
The subsystem parses the fenced code block below. One relative path per line. Blank lines and lines starting with `#` are comments.
|
|
17
|
-
|
|
18
|
-
```
|
|
19
|
-
CLAUDE.md
|
|
20
|
-
LICENSE
|
|
21
|
-
README.md
|
|
22
|
-
bassclef-configs.jsonc
|
|
23
|
-
lite-manifest.json
|
|
24
|
-
bassclef-wiring-manifest.json
|
|
25
|
-
substrate.config.md
|
|
26
|
-
.bassclef-source.json.template
|
|
27
|
-
.claude/settings.json.template
|
|
28
|
-
presence/install/bassclef-sync.dispatcher.template.sh
|
|
29
|
-
presence/install/bassclef-sync.template.sh
|
|
30
|
-
.github/workflows/bassclef-pr-ci.yml
|
|
31
|
-
.github/workflows/bassclef-s3-publish.yml
|
|
32
|
-
.github/workflows/bassclef-docs-sync.yml
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
## Rationale per file
|
|
36
|
-
|
|
37
|
-
- **CLAUDE.md** — session-start context load for the adopter agent
|
|
38
|
-
- **LICENSE** — Apache 2.0 per ADR-045
|
|
39
|
-
- **README.md** — first-touch doc for cold adopters
|
|
40
|
-
- **bassclef-configs.jsonc** — adopter-editable config surface
|
|
41
|
-
- **lite-manifest.json** — tier snapshot for `bassclef-cli`
|
|
42
|
-
- **bassclef-wiring-manifest.json** — hook wiring reference per ADR-051 rename
|
|
43
|
-
- **substrate.config.md** — external resource references per `standards/substrate-config-schema.md`
|
|
44
|
-
- **.bassclef-source.json.template** — source pointer for consumer repos
|
|
45
|
-
- **.claude/settings.json.template** — hook wiring template
|
|
46
|
-
- **presence/install/*.template.sh** — install and dispatcher templates per ADR-032
|
|
47
|
-
- **.github/workflows/bassclef-*.yml** — CI + publish + docs-sync workflows adopters inherit
|
|
48
|
-
|
|
49
|
-
## Extending this list
|
|
50
|
-
|
|
51
|
-
When a new lite runtime dep lands, add the path plus a one-line rationale. The subsystem re-parses on next audit run. No code change needed.
|
|
52
|
-
|
|
53
|
-
## Refs
|
|
54
|
-
|
|
55
|
-
- Parent standard `standards/tier-dependency-analysis.md`
|
|
56
|
-
- Goal doc `docs/iteration-bets/2026-08-17a-tier-dependency-audit-subsystem.md`
|
|
57
|
-
- Sister future: `standards/tier-runtime-deps/{standard,standard-pro,ultra,upstream}.md` as those tiers mature
|