@zero2webmaster/starter-kit 0.5.2 → 0.5.5

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  # z2w-starter-kit
2
2
 
3
- **Version:** 0.5.2 | **Framework:** 2.13.0
3
+ **Version:** 0.5.5 | **Framework:** 2.13.0
4
4
 
5
5
  > Node CLI to scaffold new Z2W projects from canonical Templates + AGENTS.md.
6
6
 
@@ -99,4 +99,4 @@ For licensing inquiries: kerry@zero2webmaster.com.
99
99
  ---
100
100
 
101
101
  *Scaffolded 2026-05-28 via the [[instantiate-z2w-project]] Claude Code skill v1; reconciled against the consolidated skill v1.1.0 (brief-first + Agent Coordination block) on 2026-05-29.*
102
- *Version: 0.5.2 | Last Updated: 2026-07-22*
102
+ *Version: 0.5.5 | Last Updated: 2026-07-26*
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { writeScaffold } from "./writer.js";
2
2
  import type { ScaffoldFile } from "./scaffolders/common.js";
3
3
  import type { StandardDecision } from "./standards.js";
4
- export declare const version = "0.5.2";
4
+ export declare const version = "0.5.5";
5
5
  export type ProjectType = "wp-plugin" | "cf-worker" | "cf-pages" | "nextjs" | "python-service" | "node-service" | "library" | "protocol-repo";
6
6
  export type BrandPreset = "save-the-frogs" | "bansuri-bliss" | "zero2webmaster" | "custom";
7
7
  export type DbStrategy = "none" | "neon-postgres" | "supabase" | "sqlite" | "mysql-wp" | "other";
package/dist/index.js CHANGED
@@ -21,7 +21,7 @@ import * as path from "node:path";
21
21
  import { Writable } from "node:stream";
22
22
  import { isValidSlug } from "./parse-brief.js";
23
23
  import { writeScaffold } from "./writer.js";
24
- export const version = "0.5.2";
24
+ export const version = "0.5.5";
25
25
  // Canonical enum value-arrays. These live here, next to the type unions they
26
26
  // enumerate, so both the CLI's confirm/wizard flows (which re-export them) and
27
27
  // the programmatic `validateScaffoldInputs` share one source of truth. Keep
@@ -26,6 +26,14 @@ export declare function commonHandoff(inputs: ScaffoldInputs, opts: ScaffolderOp
26
26
  * CLAUDE.md is validated for leftover markers — see writer.ts).
27
27
  */
28
28
  export declare function commonProjectBrief(inputs: ScaffoldInputs, opts: ScaffolderOptions | undefined, spec: BrandPresetSpec): ScaffoldFile | null;
29
+ /**
30
+ * Emit the short coordination-onboarding pointer — but ONLY for a project that
31
+ * participates in the bulletin. Returns null otherwise (a non-participating
32
+ * project has nothing to onboard onto). Approach (a): the file points at the
33
+ * canonical primer in the bulletin repo rather than embedding it, so there is
34
+ * one source of truth. See {@link COORDINATION_ONBOARDING_TEMPLATE}.
35
+ */
36
+ export declare function commonCoordinationOnboarding(inputs: ScaffoldInputs, opts: ScaffolderOptions | undefined, spec: BrandPresetSpec): ScaffoldFile | null;
29
37
  export declare function commonTroubleshooting(inputs: ScaffoldInputs, opts: ScaffolderOptions | undefined, spec: BrandPresetSpec): ScaffoldFile;
30
38
  export declare function commonChangelog(inputs: ScaffoldInputs, opts: ScaffolderOptions | undefined, spec: BrandPresetSpec): ScaffoldFile;
31
39
  export declare function commonMarketing(inputs: ScaffoldInputs, opts: ScaffolderOptions | undefined, spec: BrandPresetSpec): ScaffoldFile;
@@ -659,6 +659,71 @@ export function commonProjectBrief(inputs, opts, spec) {
659
659
  content: `${header}${brief}\n`,
660
660
  };
661
661
  }
662
+ // Emitted ONLY for projects that participate in the coordination bulletin
663
+ // (`participateInBulletin === true`) — a SHORT pointer at the canonical,
664
+ // project-agnostic onboarding primer owned by the bulletin repo
665
+ // (`COORDINATION_ONBOARDING.md` at the root of zero2webmaster/z2w-agent-coordination,
666
+ // generalized 2026-07-22 from the leaderboard pilot). Approach (a) per the
667
+ // 2026-07-22 z2w-agent-coordination ask: point at the single source of truth
668
+ // rather than freezing a copy in every project — the same reasoning the
669
+ // scaffolder already uses to stamp the Agent Coordination block from the live
670
+ // AGENT_PROTOCOL.md fingerprint rather than a paraphrase. Keep this file to one
671
+ // screen; the depth lives in the canonical primer it links.
672
+ const COORDINATION_ONBOARDING_TEMPLATE = `# Coordination Onboarding — {{slug}}
673
+
674
+ > **Read this first if you're a fresh agent on \`{{slug}}\`.** This is a short
675
+ > pointer, not the full guide. \`{{slug}}\` participates in the Z2W cross-project
676
+ > coordination bulletin, and the canonical, always-current onboarding primer lives
677
+ > in the bulletin repo — **not here** — so there is a single source of truth.
678
+
679
+ ## Where the canonical primer lives
680
+
681
+ Read **\`COORDINATION_ONBOARDING.md\`** at the root of the coordination bulletin repo
682
+ (\`zero2webmaster/z2w-agent-coordination\`), cloned locally at one of:
683
+
684
+ - \`~/Desktop/Zero2Webmaster/AI/Cursor Projects/z2w-agent-coordination/COORDINATION_ONBOARDING.md\` (primary), or
685
+ - \`~/.cache/z2w-coordination/COORDINATION_ONBOARDING.md\` (fallback clone)
686
+
687
+ \`git pull --ff-only\` first, then read it. It orients you to the three core Z2W
688
+ systems (the coordination bulletin, the Skill Vault, and the starter-kit + Templates)
689
+ and walks you through joining the bulletin as \`{{slug}}\`.
690
+
691
+ ## The one rule that must not drift
692
+
693
+ When you install the \`## Agent Coordination\` participation block into this project's
694
+ \`CLAUDE.md\` / \`AGENTS.md\`, **always copy it verbatim from the live \`AGENT_PROTOCOL.md\`**
695
+ in the bulletin repo — it carries the current
696
+ \`<!-- z2w-agent-coordination canonical-block vX.Y.Z -->\` fingerprint. **Never** copy a
697
+ version-frozen block from another project or from a primer snapshot; that is exactly
698
+ how canonical-block drift happens.
699
+
700
+ ## Your bulletin file
701
+
702
+ This project's bulletin file is \`projects/{{slug}}.md\`. Read it in protocol order at
703
+ session start (\`## Incidents\` → \`## Inbox from Kerry\` → \`## Open questions\` →
704
+ \`## Heads-ups\`), then \`global.md\`. Rewrite \`## Current focus\` at session end.
705
+
706
+ ---
707
+
708
+ *Pointer emitted at scaffold time by \`@zero2webmaster/starter-kit\` (mirrors
709
+ [[instantiate-z2w-project]]). The canonical primer it links is owned by
710
+ \`z2w-agent-coordination\` — improve it THERE, never fork a per-project copy.*
711
+ `;
712
+ /**
713
+ * Emit the short coordination-onboarding pointer — but ONLY for a project that
714
+ * participates in the bulletin. Returns null otherwise (a non-participating
715
+ * project has nothing to onboard onto). Approach (a): the file points at the
716
+ * canonical primer in the bulletin repo rather than embedding it, so there is
717
+ * one source of truth. See {@link COORDINATION_ONBOARDING_TEMPLATE}.
718
+ */
719
+ export function commonCoordinationOnboarding(inputs, opts, spec) {
720
+ if (!inputs.participateInBulletin)
721
+ return null;
722
+ return {
723
+ path: "COORDINATION_ONBOARDING.md",
724
+ content: sub(COORDINATION_ONBOARDING_TEMPLATE, inputs, opts, spec),
725
+ };
726
+ }
662
727
  export function commonTroubleshooting(inputs, opts, spec) {
663
728
  return {
664
729
  path: "TROUBLESHOOTING.md",
@@ -712,6 +777,18 @@ export function commonDirective(inputs, opts, spec) {
712
777
  * (contact-registry, 2026-07-12). Ignoring it gives every
713
778
  * generated tree a clean `git status` — every file either
714
779
  * tracked or ignored, nothing present-but-untracked.
780
+ * - `.claude/settings.local.json` — Claude Code's MACHINE-LOCAL settings
781
+ * (per-machine permission allowlists, which routinely name
782
+ * absolute paths and one-off commands). Its sibling
783
+ * `.claude/settings.json` is the SHARED project settings file
784
+ * and must stay committable — so ignore the one file, never
785
+ * the whole `.claude/` directory. Added 2026-07-26 after
786
+ * `audit-engine`'s first sweep found it missing in 11 of 12
787
+ * Live repos. Kerry's machine happens to be covered by a
788
+ * global ignore (`~/.config/git/ignore`), but a global ignore
789
+ * does not travel with the repo — CI, a second machine, a
790
+ * contractor, or a licensee gets no protection at all. The
791
+ * repo-level line is the one that ships.
715
792
  *
716
793
  * Per the 2026-06-11 z2w-member-match near-miss (live DATABASE_URL +
717
794
  * RESEND_API_KEY staged on a fresh repo) and matching asks from
@@ -725,6 +802,9 @@ const GITIGNORE_SECRET_SCRATCH_BLOCK = `
725
802
  .specstory/
726
803
  # Cursor's own index-management file — local, auto-created; keeps git status clean
727
804
  .cursorindexingignore
805
+ # Claude Code machine-local settings (permission allowlists, absolute paths).
806
+ # NOTE: .claude/settings.json is the SHARED project file — keep it committable.
807
+ .claude/settings.local.json
728
808
  `;
729
809
  /**
730
810
  * Per-type `.gitignore` body. Sources: skill's "Inline mini-templates"
@@ -857,6 +937,11 @@ export function commonBaseFiles(inputs, opts, perTypeNarrative) {
857
937
  const briefFile = commonProjectBrief(inputs, opts, spec);
858
938
  if (briefFile)
859
939
  files.push(briefFile);
940
+ // Short pointer at the canonical coordination-onboarding primer — only for a
941
+ // project that participates in the bulletin (see commonCoordinationOnboarding).
942
+ const onboardingFile = commonCoordinationOnboarding(inputs, opts, spec);
943
+ if (onboardingFile)
944
+ files.push(onboardingFile);
860
945
  return files;
861
946
  }
862
947
  /* ─────────────────────────── Email wiring (opt-in) ─────────────────────────
@@ -82,19 +82,26 @@ const PACKAGE_JSON_TEMPLATE = `{
82
82
  `;
83
83
  const NEXT_CONFIG_TEMPLATE = `/** @type {import('next').NextConfig} */
84
84
 
85
- // SEO: redirect the auto-assigned PRODUCTION *.vercel.app alias to the custom
86
- // domain so it is not crawled as an indexable duplicate of the whole site
87
- // (Z2W standing heads-up 2026-06-29; recipe = [[portable-stack]] §14 rule 5b).
85
+ // SEO: redirect EVERY auto-assigned PRODUCTION *.vercel.app alias to the custom
86
+ // domain so none is crawled as an indexable duplicate of the whole site
87
+ // (Z2W standing heads-up 2026-06-29; recipe = [[portable-stack]] §24).
88
88
  // It lives in-repo (portable — survives a move off Vercel) and self-disables:
89
- // - The alias host defaults to "{{slug}}.vercel.app" (Vercel's default
90
- // project domain); override with VERCEL_ALIAS_HOST if your project's
91
- // production alias differs.
89
+ // - It matches ANY "*.vercel.app" host (regex), so it covers all of Vercel's
90
+ // production aliases at once — the default project alias, the random-suffixed
91
+ // <project>-<word> form Vercel actually assigns, and the git-<branch> alias —
92
+ // and it survives Vercel reassigning them. No host is hardcoded or kept in
93
+ // sync (an earlier VERCEL_ALIAS_HOST default guessed a single host that in
94
+ // practice never matched the real alias, so the redirect shipped inert).
95
+ // - It is gated on VERCEL_ENV === "production", read at BUILD time. Preview
96
+ // deployments build with VERCEL_ENV="preview", so the rule is ABSENT from
97
+ // their config entirely — a per-deployment PREVIEW URL (also *.vercel.app)
98
+ // can never be redirected to production. This build-time gate is what makes
99
+ // the broad *.vercel.app regex safe.
92
100
  // - The redirect only fires once NEXT_PUBLIC_SITE_URL is a REAL custom domain.
93
101
  // While it is blank, the *.example.com placeholder, or itself a *.vercel.app
94
- // host, the redirect list is empty — so a fresh scaffold never self-redirects.
95
- // - It matches ONLY the exact production alias, never per-deployment PREVIEW
96
- // URLs (e.g. {{slug}}-<hash>.vercel.app), which stay reachable + noindex'd.
97
- const vercelAliasHost = process.env.VERCEL_ALIAS_HOST || "{{slug}}.vercel.app";
102
+ // host, the redirect list is empty — so a fresh scaffold never self-redirects,
103
+ // and the custom domain (not *.vercel.app) never matches the regex → no loop.
104
+ const isVercelProduction = process.env.VERCEL_ENV === "production";
98
105
 
99
106
  function canonicalHost() {
100
107
  const raw = process.env.NEXT_PUBLIC_SITE_URL || "";
@@ -113,11 +120,13 @@ const nextConfig = {
113
120
  reactStrictMode: true,
114
121
  async redirects() {
115
122
  const host = canonicalHost();
116
- if (!host) return [];
123
+ // Only in production, and only once a real custom domain is configured.
124
+ if (!host || !isVercelProduction) return [];
117
125
  return [
118
126
  {
119
127
  source: "/:path*",
120
- has: [{ type: "host", value: vercelAliasHost }],
128
+ // Match ANY *.vercel.app host — covers every production alias at once.
129
+ has: [{ type: "host", value: "(?<alias>.*\\\\.vercel\\\\.app)" }],
121
130
  destination: \`https://\${host}/:path*\`,
122
131
  permanent: true,
123
132
  },
@@ -51,7 +51,7 @@ export interface StandardsResolution {
51
51
  * family — the safe default for anything else with `has_web_ui=true`.
52
52
  */
53
53
  export declare function fathomEnvVarFor(projectType: ProjectType): string;
54
- export declare const CANONICAL_COORDINATION_BLOCK_VERSION = "v0.1.14";
54
+ export declare const CANONICAL_COORDINATION_BLOCK_VERSION = "v0.1.15";
55
55
  /**
56
56
  * Resolve which standards apply to `inputs` and render the standards markdown
57
57
  * body suitable for `.replace()`-ing into the `<!-- STANDARDS_BLOCK -->`
package/dist/standards.js CHANGED
@@ -311,7 +311,7 @@ const NEON_CAREFUL_BODY = `### Neon-careful (Neon Postgres)
311
311
  // `zero2webmaster/z2w-agent-coordination`'s AGENT_PROTOCOL.md when the embedded
312
312
  // block's mechanics change (drift-detection Signal A greps for this exact token).
313
313
  // When you sync a newer canonical block below, bump this to match its comment.
314
- export const CANONICAL_COORDINATION_BLOCK_VERSION = "v0.1.14";
314
+ export const CANONICAL_COORDINATION_BLOCK_VERSION = "v0.1.15";
315
315
  /**
316
316
  * The Agent Coordination section, emitted as its own TOP-LEVEL `## Agent
317
317
  * Coordination` section (NOT a `###` standards subsection). The bulk is the
@@ -338,7 +338,8 @@ This project participates in the Z2W cross-project coordination bulletin.
338
338
  **At session start:**
339
339
  1. If a workspace clone exists at \`~/.cache/z2w-coordination\` OR at \`~/Desktop/Zero2Webmaster/AI/Cursor Projects/z2w-agent-coordination/\`, use it (\`cd\` there + \`git pull --ff-only\`). Otherwise: \`git clone --depth 1 git@github.com:zero2webmaster/z2w-agent-coordination.git ~/.cache/z2w-coordination\`. (See §8.3.) **Then set the bot commit identity for the clone (v0.1.12):** \`bash scripts/set-bulletin-commit-identity.sh\` — idempotent, sets \`user.name\`/\`user.email\` **locally for this clone only** (global identity untouched) so your bulletin commits author as \`Z2W Bulletin Bot\`, not Kerry. The bulletin is coordination traffic (~40 agents push here); attributing it to Kerry's personal GitHub contribution graph skews his real-work count. Existing shared clones already have this set; run it after any FRESH clone.
340
340
  2. Read \`projects/{this-project-slug}.md\` IN THIS ORDER:
341
- a. **\`## Incidents\`** FIRST, if the section exists (v0.1.13). Any incident whose latest status line is \`open\` (i.e. no \`↳ resolved\` under it) means something is broken in production RIGHT NOW. Surface every open incident to Kerry before anything else, and prefer triaging it over new feature work — **a production incident outranks Kerry's inbox.** If the section is absent, there are no incidents; move on. (Incidents are written by the observability bridge or by an agent that spots a live problem — see §8.8 for the schema, dedup key, status lifecycle, and PII-strip rule.)
341
+ a0. **\`## 📥 Needs attention\`** — the triage index, if the section exists (v0.1.15). It is pinned at the very top of the file and carries **one line per still-unhandled item addressed to this project**, each pointing at the section the full item lives in. Read it first as your routing table: it tells you *what* is waiting and *where*, so you don't have to scan several long sections hoping to spot an ask aimed at you. Handle \`ACTION\` items before \`Q\` before \`FYI\`. **As you handle each item, delete its line** — the block is a queue, not a log (the full item + your \`↳\` reply stay in their own section; git keeps the history). Absent or empty section = nothing addressed to you is outstanding. Schema in §8.11. *(An open incident in \`## Incidents\` still outranks everything here — see a. next.)*
342
+ a. **\`## Incidents\`** — if the section exists (v0.1.13). Any incident whose latest status line is \`open\` (i.e. no \`↳ resolved\` under it) means something is broken in production RIGHT NOW. Surface every open incident to Kerry before anything else, and prefer triaging it over new feature work — **a production incident outranks Kerry's inbox.** If the section is absent, there are no incidents; move on. (Incidents are written by the observability bridge or by an agent that spots a live problem — see §8.8 for the schema, dedup key, status lifecycle, and PII-strip rule.)
342
343
  b. Then **\`## Inbox from Kerry\`**. Any entry without a \`↳ received\` line is unread. For each unread entry: surface it to Kerry, ACK by appending \`↳ received {YYYY-MM-DD HH:MM}, session {id}\` immediately, and move the work into \`## Open follow-ups owned by this project\` so it survives this session.
343
344
  c. Then \`## Open questions\` — surface any \`[→ this-project]\` asks AND your OWN un-replied \`[→ Kerry]\` items. **Proactively open the session WITH your pending \`[→ Kerry]\` decisions, in plain English** (v0.1.9): e.g. *"I'm up to speed. Pending your input: (1) {one-line ask}, (2) {one-line ask}. Want to handle any now?"* A \`[→ Kerry]\` item is a genuine "blocked on you" flag — don't let it sit silently on the dashboard while Kerry is right here in the session.
344
345
  d. Then \`## Heads-ups for other agents\` (un-ACK'd) and other-session entries in \`## Active sessions\`.
@@ -347,25 +348,57 @@ This project participates in the Z2W cross-project coordination bulletin.
347
348
  **During session:**
348
349
  - If a coordination need surfaces (cross-project question, important heads-up), append to the relevant section in memory and persist on session end.
349
350
  - If a question to another project's agent surfaces, append to THEIR project file's \`## Open questions\` section with \`[→ {their-project}]\` prefix.
351
+ - **Whenever you write ANYTHING addressed to another project, also append one line to THEIR \`## 📥 Needs attention\` block (v0.1.15).** This is the send-side half of the triage index above, and it costs you one line. Create the section (directly under the file's header block, above \`## Inbox from Kerry\`) if it isn't there yet. Tag the item's disposition so the recipient — and the \`agents.z2w.us\` renderer — can sort it without reading the body:
352
+ - **\`ACTION\`** — you need them to *do* something (a change, a trim, a build, a re-sync).
353
+ - **\`Q\`** — you need an answer/decision, but no work.
354
+ - **\`FYI\`** — informational; nothing is expected back.
355
+
356
+ Fixed field order, \` · \` (middot) delimiter, closed uppercase vocabulary — the renderer parses on position, so don't reorder or invent tags:
357
+ \`\`\`
358
+ - 2026-07-25 · z2w-starter-kit · ACTION · Trim your bulletin file — it's over the 256 KB read-cap · §Open questions
359
+ \`\`\`
360
+ Applies to every inbound form: a \`[→ {them}]\` question, a heads-up you filed in their file, or a maintainer directive. **The recipient deletes the line when they handle it**, so leaving it un-deleted is the signal that the item is still live. *(Adopted 2026-07-25 from \`z2w-starter-kit\`'s 2026-07-15 proposal on Kerry's observation that finding messages addressed to a project was too hard — one session had to grep a 705 KB file across three sections to find a directive aimed at it — and \`z2w-agent-command-center\`'s independent endorsement after the same failure bit it. The Command Center renders this block as the phone-first "addressed to you" queue.)*
350
361
  - If a decision is genuinely waiting on Kerry, append a \`[→ Kerry]\` entry to your OWN file's \`## Open questions\` section — same syntax as cross-agent asks. Do NOT bury "waiting on Kerry" items in Heads-ups; the dashboard reads \`[→ Kerry]\` entries to show Kerry what's blocked on him.
351
- - **\`[→ Kerry]\` entries MUST be human-readable to Kerry, not agent jargon (v0.1.9).** Lead every \`[→ Kerry]\` entry with a short **bold plain-English title** + a one-sentence "what Kerry needs to decide or do," then any detail below (a \`<details>\` block is fine for depth). The dashboard at \`agents.z2w.us\` surfaces these to Kerry directly; if the title buries the ask, the dashboard has to guess. Optionally add a machine-readable \`<!-- ask: {one-line ask} -->\` marker (the dashboard prefers it over derived text) and a blocking/non-blocking hint.
352
- - **A cross-agent question AND all its replies live in the askee's (target's) project file** — the same file you just filed the \`[→ {their-project}]\` question in. Do NOT mirror-and-reply in your own file, and do NOT park the question in your own file first (that fragments discovery). The asker may keep a lightweight pointer in their own file if they want one, but the canonical thread (question + every \`↳\` reply) stays in the askee's file.
353
- - **"Posted to the bulletin" is ambiguous — name the FILE + SECTION, and route to a specific agent if a specific agent must see it (v0.1.12).** \`global.md\` is the ONLY file every agent reads at session start. A reply/entry under a project's section in \`projects/{x}.md\` is seen by that project's agent + anyone who opens that file — NOT automatically by other agents. To guarantee a specific other agent sees something, append a \`[→ {their-project}]\` entry to THEIR file's \`## Open questions\`. So when you say you "posted" something, say which file and section.
362
+ - **\`[→ Kerry]\` entries MUST be human-readable to Kerry, not agent jargon (v0.1.9).** Lead every \`[→ Kerry]\` entry with a short **bold plain-English title** + a one-sentence "what Kerry needs to decide or do," then any detail below (a \`<details>\` block is fine for depth). The dashboard at \`agents.z2w.us\` surfaces these to Kerry directly; if the title buries the ask, the dashboard has to guess. Optionally add a machine-readable \`<!-- ask: {one-line ask} -->\` marker (the dashboard prefers it over derived text) and a blocking/non-blocking hint. Example:
363
+ \`\`\`
364
+ - **[→ Kerry]** (2026-06-13, by \`file-server\`) — **Create the STF Backblaze bucket so I can onboard the tenant.** Non-blocking for other work; blocks STF tenant go-live. <!-- ask: create STF Backblaze bucket -->
365
+ <details>… full context …</details>
366
+ \`\`\`
367
+ Scope: \`[→ Kerry]\` items specifically. Cross-agent \`[→ {project}]\` asks and Open follow-ups MAY adopt the same lead-with-a-title shape but are not required to.
368
+ - **Optionally qualify a \`[→ Kerry]\` item as \`decide\` or \`do\` (v0.1.15).** Kerry answers these from two different places: some are a judgment call he can settle from his phone in one line; others need him at a workstation (mint a token, run a migration, upload a plugin, click through a provider console). When you *know* which kind yours is, say so — \`[→ Kerry: decide]\` or \`[→ Kerry: do]\`:
369
+ - **\`decide\`** — answerable in a sentence, from anywhere. A preference, a go/no-go, a pick-one-of-two.
370
+ - **\`do\`** — requires hands on a machine or a third-party console. Even a one-minute task counts if it can't be done from a phone.
371
+
372
+ **Closed vocabulary (\`decide\` | \`do\` only), fixed position immediately after \`Kerry\`.** The bare \`[→ Kerry]\` form stays fully valid — omit the qualifier when it's genuinely mixed or you're unsure, and the Command Center's classifier infers it as it does today. Purely additive: every parser matching \`Kerry\` inside the arrow already reads \`[→ Kerry: do]\` as Kerry-targeted. *(Adopted 2026-07-25 from \`z2w-agent-command-center\`'s 2026-07-18 proposal — its \`/decisions\` view already splits "Decide" from "Do — needs Kerry at a workstation" using a Haiku classifier; a durable tag makes that split exact and free.)*
373
+ - **A cross-agent question AND all its replies live in the askee's (target's) project file** — the same file you just filed the \`[→ {their-project}]\` question in. Do NOT mirror-and-reply in your own file, and do NOT park the question in your own file first (that fragments discovery, surfaced as a Step 7 gap on 2026-05-28). The asker may keep a lightweight pointer in their own file if they want one, but the canonical thread (question + every \`↳\` reply) stays in the askee's file. *(v0.1.11 clarification: the prior wording said "the asker's project file," which contradicted the rule one line up that files the question in the askee's file.)*
374
+ - **"Posted to the bulletin" is ambiguous — name the FILE + SECTION, and route to a specific agent if a specific agent must see it (v0.1.12).** The bulletin is many files with different audiences, so "I sent it to the bulletin" tells neither Kerry nor another agent where to look — and worse, it can imply broadcast when the write was actually local. Know the visibility model and state it:
375
+ - **\`global.md\`** is the ONLY file every agent reads at session start → the one place to put something *all* agents must see.
376
+ - A reply/entry **under a project's \`## Open questions\` (or any section) in \`projects/{x}.md\`** is seen by **that project's agent + anyone who opens that file** — it is NOT seen automatically by other agents. Posting your own analysis as a reply in your *own* project file does NOT notify anyone else.
377
+ - To **guarantee a specific other agent sees something**, append a \`[→ {their-project}]\` entry to **their** file's \`## Open questions\` (the sanctioned cross-project signal) — a plain mention in your own file won't reach them.
378
+
379
+ So when you tell Kerry (or another agent) you "sent" / "posted" / "shared" something, **say which file and section** (e.g. "posted the verdict under its Open question in \`projects/z2w-ai-suite.md\`" — not "sent it to the bulletin"), and if a named agent needs it, confirm you routed a \`[→ {them}]\` entry into *their* file. (Surfaced by Kerry 2026-06-22 after a code-audit verdict posted only in the author's own project file was assumed to be visible to the partner agent it concerned.)
354
380
 
355
381
  **At session end (or when the end is near):**
356
- - **Re-read \`## Inbox from Kerry\` (v0.1.9).** A dispatch from Kerry can land *mid-session* — invisible to an agent that only checked at boot. Re-read the inbox; ACK and handle any entry that arrived since session start.
357
- - **Re-check your OWN un-replied \`[→ Kerry]\` items (v0.1.9).** If any are still pending and Kerry is reachable, raise them one more time before closing.
358
- - **Re-check \`## Open questions\` for new \`[→ this-project]\` entries that arrived since session start (v0.1.10).** A dedicated message from another agent lands here. Reply (\`↳\` under the question) and, if it needs more than this session has room for, move it into \`## Open follow-ups owned by this project\` so it survives. (You do NOT need to re-read \`global.md\` at session end.)
382
+ - **Re-read \`## Inbox from Kerry\` (v0.1.9).** A dispatch from Kerry can land *mid-session* — invisible to an agent that only checked at boot. Re-read the inbox; ACK (append \`↳ received {YYYY-MM-DD HH:MM}, session {id}\`) and handle any entry that arrived since session start. Near-zero cost; catches late dispatches before they sit unread until this project's next session.
383
+ - **Re-check your OWN un-replied \`[→ Kerry]\` items (v0.1.9).** If any are still pending and Kerry is reachable, raise them one more time before closing — same plain-English framing as session start.
384
+ - **Re-check \`## Open questions\` for new \`[→ this-project]\` entries that arrived since session start (v0.1.10).** A *dedicated message from another agent* lands here — the cross-agent analogue of Kerry's inbox dispatch. It's in your OWN already-loaded project file, so the cost is near-zero. Reply (\`↳\` under the question) and, if the ask needs more than this session has room for, move it into \`## Open follow-ups owned by this project\` so it survives. (You do NOT need to re-read \`global.md\` at session end — broadcast heads-ups are a session-*start* read; this end-of-session check is deliberately scoped to your own lean project file, not the large shared \`global.md\`.)
359
385
  - **Updating the bulletin at session end is a MANDATORY standing wrap step — never a question you put to Kerry (v0.1.11).** It ranks with committing your code, not with optional extras. Do NOT end a session by asking *"want me to update the bulletin too?"* or *"that wasn't in your wrap list — say the word"* — decide with the two tiers below and just do it. The one and only time you skip is a purely read-only / conversational session that changed no files and no project state — and even then you **skip silently, you do not ask**. (Kerry, 2026-07-05: *"they should know to either do it or not do it"* — this rule is that decision, made once, so no agent defers it back to him.)
360
- - **Tier 1 — ALWAYS (any session that did real work on this project):** rewrite \`## Current focus\` in place — one short paragraph (or 1–3 bullets) of what this project is working on right now, stamped with the current date + session id — and add/close your \`## Active sessions\` entry. It is the field the \`agents.z2w.us\` dashboard reads: a stale timestamp signals "agent ran but said nothing."
361
- - **Tier 2 — ADDITIONALLY, only if the session shipped code or changed project state:** add a \`## Recent commits\` entry and append any new heads-ups / \`[→ {project}]\` / \`[→ Kerry]\` items.
386
+ - **Tier 1 — ALWAYS (any session that did real work on this project):** rewrite \`## Current focus\` in place — one short paragraph (or 1–3 bullets) of what this project is working on right now, stamped with the current date + session id — and add/close your \`## Active sessions\` entry. Cheap, and it is the field the \`agents.z2w.us\` dashboard reads: a stale timestamp signals "agent ran but said nothing," which reads differently from "no agent ran," and an empty/stale Current focus erodes Kerry's trust in the dashboard.
387
+ - **Tier 2 — ADDITIONALLY, whenever the session produced anything another agent or Kerry would act on:** add a \`## Recent commits\` entry (if you shipped) and append any new heads-ups / \`[→ {project}]\` / \`[→ Kerry]\` items — plus the \`## 📥 Needs attention\` line in each recipient's file.
388
+ **The trigger is "carries cross-project signal," NOT "committed code" (v0.1.15).** A decision, a heads-up, a capability→home mapping, a naming or scope change, a new build-target, an answered question, a discovered gotcha — all qualify, and **synthesis, audit, and planning sessions routinely commit zero code yet carry the highest cross-project value.** An agent that gates Tier 2 on \`git log\` says nothing exactly when it has the most to say. Skip Tier 2 only when the session genuinely produced nothing anyone else would act on (pure local exploration with no outcome) — and Tier 1 still runs even then. *(Adopted 2026-07-25 from \`z2w-starter-kit\`'s 2026-07-11 ask on Kerry's instruction, after a zero-commit \`z2w-forms\` extraction audit generated a new build-target, a Kerry decision, a delivery model, a naming fix, and heads-ups landing on three other projects — none of which a code-gated wrap-up would have published.)*
362
389
  - **Keep \`## Integrations\` + your Live status current — a never-ask standing step, exactly like \`## Current focus\` (v0.1.14).** If this session changed how this project relates to another Z2W app — it started consuming an engine/service, stopped using one, or became a provider another app now depends on — update your file's \`## Integrations\` edges. If the project's lifecycle changed — scaffolded → live in prod, went dormant, retired — update the **Live status** line and its date. This is the capture mechanism behind the ecosystem dependency map + live-status badges on \`agents.z2w.us\`; a stale edge or status silently misleads every other agent (real 2026-07-20 miss: an audit called a LIVE engine "unbuilt" because no single place recorded its status). Decide and do it — do not ask. Absent section = nothing to report yet; create it lazily the first time you have an edge or a status to record. Schema + conventions in §8.10.
363
- - **Size discipline (v0.1.11):** before appending, if \`projects/{this-project}.md\` is approaching ~200 KB, trim FIRST — archive old \`## Active sessions\` and \`## Recent commits\` entries and resolved \`## Open questions\` threads into \`projects/{this-project}-archive.md\` (a separate, commit-flagged operation). \`## Current focus\` is rewritten in place (never appended).
364
- - \`git commit -m "{this-project}: {summary}"\` (see §8.2 for agent-identifier format) and \`git push\`.
365
- - If push fails due to concurrent write from another session: \`git pull --rebase\`, resolve any conflicts, retry push.
390
+ - **Size discipline (v0.1.11):** before appending, if \`projects/{this-project}.md\` is approaching ~200 KB (the point where agents can no longer \`Read\` it in one call), trim FIRST — archive old \`## Active sessions\` and \`## Recent commits\` entries and resolved \`## Open questions\` threads into \`projects/{this-project}-archive.md\` (a separate, commit-flagged operation). Keep your live file readable whole. \`## Current focus\` is rewritten in place (never appended), which is the main thing that keeps a project file from growing without bound — never let a single field accumulate a multi-session history.
391
+ - \`git commit -m "{this-project}: {summary}"\` (see §8.2 for agent-identifier format in commit messages and session entries) and \`git push\`.
392
+ - If push fails due to concurrent write from another session: \`git pull --rebase\`, resolve any conflicts (they should be rare — append-only within sections), retry push.
366
393
  - **Local auto-push hooks:** if your project has a post-commit hook that auto-pushes, expect it to race your explicit \`git push\` and grab the ref lock first. The commit still lands — verify with \`git log origin/main\` rather than re-pushing.
394
+ - **A background sync can DISCARD your uncommitted work — commit in tight increments (v0.1.15).** Separately from the ref-lock race above, a background sync may run \`git pull --rebase\` + \`reset\` on the shared clone **mid-session** and **wipe your uncommitted edits to tracked files** (untracked new files survive; only working-tree changes to already-tracked files are lost). There is no commit to recover from, so the natural flow of "edit several bulletin files, commit at the end" can silently lose all of it. **Therefore: make each edit + \`git add\` + commit one tight sequence, and stage only your own files** — a concurrent sync can leave other projects' \`M\` files in the tree, so \`git commit -a\` would sweep up work that isn't yours. *(Reported by \`backup-engine\` 2026-07-22 after a mid-session sync — confirmed in the clone's reflog — discarded its edits to two tracked files and cost real rework. The clone has no git hooks and nothing in crontab/LaunchAgents, so the sync is driven out-of-band by the harness or a concurrent session: no single project owns it, and it can bite any agent writing to the bulletin.)*
367
395
 
368
- **Inbox-section authority (v0.1.8):** Only the orchestrator identity \`kerry-phone\` (the phone-first command center at \`agents.z2w.us\`) writes to \`## Inbox from Kerry\`. Project agents only READ and ACK there — never write. Never edit another project's \`## Inbox from Kerry\` section.
396
+ **Inbox-section authority (v0.1.8):** Only the orchestrator identity \`kerry-phone\` (the phone-first command center hosted at \`agents.z2w.us\`) writes to \`## Inbox from Kerry\`. Project agents only READ and ACK there — never write. Never edit another project's \`## Inbox from Kerry\` section. This is a clarification of Hard Rule #3, not an exception — same principle, applied to a new section dedicated to human-to-agent dispatch.
397
+
398
+ **Conflict resolution:**
399
+ - Append-only writes within distinct sections rarely conflict.
400
+ - Two agents writing the same section: rebase merges both appends. Markdown order may differ from intent; the timestamps disambiguate.
401
+ - Two agents trimming the same expired entry: rebase keeps either, no harm done.
369
402
 
370
403
  **Hard rules (read first):**
371
404
  - **No secrets, ever.** Operational metadata only. Detect-and-redact on \`sk_*\`, \`pk_*\`, \`rk_*\`, \`whsec_*\`, \`xoxb-*\`, \`tbl[A-Za-z0-9]{14}\`, \`pat_*\`, etc.
@@ -431,7 +464,13 @@ const TEXT_SIZE_BODY = `### Text size (always)
431
464
  > **Readability:** per Z2W standing org rule, all public-facing pages and documents use large, easy-to-read type. Body text 18px+ baseline; headings proportionally larger; line-height ≥ 1.5.`;
432
465
  const TEST_COUNT_BODY = `### Test-count reporting (always — at session end)
433
466
 
434
- > **Report your test count at session end.** Per Zero2Webmaster standing org rule (2026-06-20), every session that touches code states how many tests pass on a stable, machine-greppable line: \`Tests: {n} passing\` — use the literal word \`Tests:\`, the running total your suite reports, and the word \`passing\`. Put that line in your session-end recap AND, if this project participates in the cross-project bulletin, in the \`## Recent commits\` entry you append (e.g. **\`Tests: 534 passing\`**). The phone-first command center greps this line across every project to display a portfolio-wide tally ("we've run N tests across the portfolio") — a real sales asset, and the uniform one-line format is what makes the total cheap to compute. If this project has no test suite yet, say so explicitly with \`Tests: none yet\` rather than omitting the line.`;
467
+ > **Report your test count at session end.** Per Zero2Webmaster standing org rule (2026-06-20), every session that touches code states how many tests pass on a stable, machine-greppable line: \`Tests: {n} passing\` — use the literal word \`Tests:\`, the running total your suite reports, and the word \`passing\`. Put that line in your session-end recap AND, if this project participates in the cross-project bulletin, in the \`## Recent commits\` entry you append (e.g. **\`Tests: 534 passing\`**). The phone-first command center greps this line across every project to display a portfolio-wide tally ("we've run N tests across the portfolio") — a real sales asset, and the uniform one-line format is what makes the total cheap to compute. If this project has no test suite yet, say so explicitly with \`Tests: none yet\` rather than omitting the line.
468
+ >
469
+ > Three rules that keep the tally honest — each one exists because a real report was silently mis-read (all three confirmed by \`z2w-agent-command-center\`, 2026-07-26):
470
+ >
471
+ > 1. **\`Tests:\` is for YOUR OWN count only.** If your entry mentions another project's suite — one you scaffolded, audited, or depend on — describe it in prose, never with the literal token: \`Scaffolded audit-engine (its suite: none yet). Tests: 720 passing.\` A newest-wins reader takes the first \`Tests:\` it finds, so a second project's count in your entry gets filed as yours. This is exactly how the portfolio's largest suite was once recorded as having no tests.
472
+ > 2. **\`Tests: none\` and \`Tests: none run\` mean different things.** \`none\` (or \`none yet\`) = this repo has no suite. \`none run\` = a suite exists but this session didn't run it, so a reader should keep looking back rather than record a zero — \`Tests: none run (docs-only)\` is the established form. Never report \`none\` for a session that merely skipped the tests: that turns a real suite into a zero.
473
+ > 3. **Always include the literal \`Tests:\` token, even on a multi-suite line.** Write \`Tests: 156 pytest / 289 Vitest / build clean\`, not \`156 pytest / 289 Vitest\`. Dropping the token makes the tally fall back to an older entry, so a project reporting MORE work gets counted for LESS — the worst-shaped failure of the three, because nothing looks wrong.`;
435
474
  const BODIES = {
436
475
  "skill-vault": SKILL_VAULT_BODY,
437
476
  "portable-stack": PORTABLE_STACK_BODY,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zero2webmaster/starter-kit",
3
- "version": "0.5.2",
3
+ "version": "0.5.5",
4
4
  "description": "Node CLI to scaffold new Z2W projects from canonical Templates + AGENTS.md.",
5
5
  "author": {
6
6
  "name": "Dr. Kerry Kriger",