@archangel70/cosmo 1.7.0 → 1.9.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.
Files changed (39) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +112 -88
  3. package/docs/AGENT-HANDOFF.md +8 -8
  4. package/docs/ARCHITECTURE.md +3 -3
  5. package/docs/CONTENT-QA.md +2 -0
  6. package/docs/COPY-STUDIO.md +154 -0
  7. package/docs/FIRST-PARTY-CAPABILITIES.md +1 -1
  8. package/docs/GENERATION.md +1 -1
  9. package/docs/INTELLIGENCE-PACKS.md +2 -2
  10. package/docs/MULTI-AGENT.md +69 -0
  11. package/docs/PAGE-PRODUCTION.md +2 -0
  12. package/docs/ROADMAP.md +10 -0
  13. package/package.json +9 -3
  14. package/packages/cli/bin/cosmo.mjs +139 -17
  15. package/packages/cli/lib/adoption.mjs +21 -0
  16. package/packages/cli/lib/agent-adapters.mjs +124 -0
  17. package/packages/cli/lib/claude-plugin.mjs +3 -0
  18. package/packages/cli/lib/copy-studio.mjs +355 -0
  19. package/packages/cli/lib/delivery.mjs +4 -2
  20. package/packages/cli/lib/editorial-guidance.mjs +17 -0
  21. package/packages/cli/lib/generation.mjs +6 -2
  22. package/packages/cli/lib/intelligence-audit.mjs +22 -5
  23. package/packages/cli/lib/intelligence.mjs +14 -2
  24. package/packages/cli/lib/project.mjs +2 -0
  25. package/packages/cli/lib/status.mjs +1 -1
  26. package/plugins/agent-skills/cosmo/.cosmo-agent.json +4 -0
  27. package/plugins/agent-skills/cosmo/SKILL.md +68 -0
  28. package/plugins/antigravity/cosmo.md +17 -0
  29. package/plugins/claude-code/cosmo/.claude-plugin/plugin.json +2 -2
  30. package/plugins/claude-code/cosmo/skills/cosmo/SKILL.md +5 -4
  31. package/scripts/postinstall.mjs +10 -8
  32. package/templates/astro-site/.agents/rules/cosmo.md +3 -0
  33. package/templates/astro-site/.agents/skills/cosmo/SKILL.md +18 -0
  34. package/templates/astro-site/.agents/workflows/cosmo.md +3 -0
  35. package/templates/astro-site/.cosmo/workflows/default.json +15 -2
  36. package/templates/astro-site/AGENTS.md +12 -6
  37. package/templates/astro-site/CLAUDE.md +3 -2
  38. package/templates/astro-site/README.md +1 -1
  39. package/templates/astro-site/package.json +1 -1
@@ -2,6 +2,7 @@ import fs from 'node:fs';
2
2
  import path from 'node:path';
3
3
  import crypto from 'node:crypto';
4
4
  import { readProject, writeJson } from './project.mjs';
5
+ import { EDITORIAL_REVIEW_GUIDANCE } from './editorial-guidance.mjs';
5
6
 
6
7
  export class IntelligenceError extends Error {}
7
8
 
@@ -74,7 +75,7 @@ const PACK_DEFINITIONS = [
74
75
  stages: ['brand', 'generate', 'qa'], capability: { id: 'editorial-naturalness-audit', version: 1, status: 'active', stages: ['brand', 'generate', 'qa'] },
75
76
  questions: ['Which owned samples represent the desired voice?', 'Which recurring patterns are genuinely off-brand?', 'What false positives must be allowed?', 'Who approves editorial changes?'],
76
77
  artifact: { stage: 'brand', path: '.cosmo/intelligence/artifacts/editorial-naturalness.json', requiredKeys: ['version', 'voiceSamplePaths', 'reviewOwner', 'clusterThreshold', 'allowedPatterns', 'bannedPatterns', 'preserveFacts'], nonEmptyKeys: ['voiceSamplePaths', 'reviewOwner'], template: { version: 1, voiceSamplePaths: [], reviewOwner: '', clusterThreshold: 3, allowedPatterns: [], bannedPatterns: [], preserveFacts: true } },
77
- guidance: { claude: 'Extract techniques rather than impersonating a named person. Review pattern clusters in context, preserve human irregularity, and never rewrite evidence to sound natural.', codex: 'Report naturalness findings for review; preserve facts, citations, approved terminology, and explicit false-positive allowances.' },
78
+ guidance: { claude: EDITORIAL_REVIEW_GUIDANCE, codex: EDITORIAL_REVIEW_GUIDANCE },
78
79
  },
79
80
  {
80
81
  id: 'branded-language', title: 'Branded language', description: 'Creates and governs useful proprietary vocabulary without renaming generic ideas or claiming borrowed concepts.',
@@ -128,6 +129,15 @@ export function intelligenceCatalog() {
128
129
  return { packs: structuredClone(PACK_DEFINITIONS), profiles: structuredClone(PROFILE_DEFINITIONS) };
129
130
  }
130
131
 
132
+ export function guidanceForAgent(pack, agent = 'build') {
133
+ const guidance = pack?.guidance ?? {};
134
+ const requested = String(agent || 'build').trim().toLowerCase().replace(/[-_ ]+/g, '');
135
+ if (guidance[requested]) return guidance[requested];
136
+ if (['codex', 'review', 'reviewer'].includes(requested)) return guidance.review ?? guidance.default ?? guidance.codex ?? guidance.claude ?? '';
137
+ if (requested === 'antigravity') return guidance.antigravity ?? guidance.default ?? guidance.build ?? guidance.claude ?? guidance.codex ?? '';
138
+ return guidance.build ?? guidance.default ?? guidance.claude ?? guidance.codex ?? '';
139
+ }
140
+
131
141
  export function validateIntelligencePack(value) {
132
142
  assert(value && value.version === 1, 'Intelligence pack version must be 1.');
133
143
  assert(Object.keys(value).every((key) => ['version', 'id', 'title', 'description', 'stages', 'capability', 'questions', 'artifact', 'guidance', 'checks'].includes(key)), 'Intelligence pack contains unsupported fields.');
@@ -141,7 +151,9 @@ export function validateIntelligencePack(value) {
141
151
  assert(typeof value.artifact.path === 'string' && !path.isAbsolute(value.artifact.path) && !value.artifact.path.split(/[\\/]/).includes('..'), `Intelligence pack ${value.id} artifact path is unsafe.`);
142
152
  assert(Array.isArray(value.questions) && value.questions.length > 0, `Intelligence pack ${value.id} needs questions.`);
143
153
  assert(value.artifact.template && typeof value.artifact.template === 'object' && !Array.isArray(value.artifact.template), `Intelligence pack ${value.id} needs an artifact template.`);
144
- assert(value.guidance && Object.keys(value.guidance).every((key) => ['claude', 'codex'].includes(key)), `Intelligence pack ${value.id} guidance contains unsupported fields.`);
154
+ assert(value.guidance && typeof value.guidance === 'object' && !Array.isArray(value.guidance), `Intelligence pack ${value.id} needs agent guidance.`);
155
+ assert(Object.keys(value.guidance).length > 0 && Object.keys(value.guidance).every(idPattern), `Intelligence pack ${value.id} guidance keys must be agent or role ids.`);
156
+ assert(Object.values(value.guidance).every((entry) => typeof entry === 'string' && entry.trim()), `Intelligence pack ${value.id} guidance entries must be non-empty text.`);
145
157
  assert(value.checks === undefined || Array.isArray(value.checks), `Intelligence pack ${value.id} checks must be an array.`);
146
158
  validateDeclarativeChecks(value);
147
159
  return value;
@@ -75,6 +75,8 @@ export function copyStarter(templateDir, targetDir) {
75
75
  || portable === '.cosmo/evidence.json'
76
76
  || portable === '.cosmo/brand'
77
77
  || portable.startsWith('.cosmo/brand/')
78
+ || portable === '.cosmo/copy'
79
+ || portable.startsWith('.cosmo/copy/')
78
80
  || portable === '.cosmo/capabilities'
79
81
  || portable.startsWith('.cosmo/capabilities/')
80
82
  || portable === '.cosmo/intelligence'
@@ -16,7 +16,7 @@ export function collectProjectStatus(projectDir) {
16
16
  const lock = readIntelligenceLock(projectDir).data;
17
17
  const plan = json(path.join(projectDir, '.cosmo', 'build-plan.json'));
18
18
  const progress = json(path.join(projectDir, '.cosmo', 'progress.json'));
19
- const reportNames = ['integrity-check', 'content-check', 'intelligence-check', 'site-check', 'browser-check'];
19
+ const reportNames = ['integrity-check', 'content-check', 'intelligence-check', 'site-check', 'browser-check', ...(fs.existsSync(path.join(projectDir, '.cosmo', 'copy', 'strategy.json')) ? ['copy-check'] : [])];
20
20
  const qa = Object.fromEntries(reportNames.map((name) => {
21
21
  const report = json(path.join(projectDir, '.cosmo', 'reports', `${name}.json`));
22
22
  return [name, report ? { passed: report.passed, checkedAt: report.checkedAt ?? report.auditedAt ?? null } : null];
@@ -0,0 +1,4 @@
1
+ {
2
+ "name": "cosmo",
3
+ "version": "1.9.0"
4
+ }
@@ -0,0 +1,68 @@
1
+ ---
2
+ name: cosmo
3
+ description: Start, adopt, resume, build, review, or release a Cosmo-managed Astro website. Use whenever the user says Cosmo, asks to build a site with Cosmo, or opens an existing Cosmo project.
4
+ ---
5
+
6
+ # Cosmo conversational launcher
7
+
8
+ Act as the conversational front door to Cosmo. The user should not need to know its command-line interface.
9
+
10
+ ## Operating contract
11
+
12
+ - Treat repository files as the source of truth, regardless of which agent worked on the project previously.
13
+ - Never overwrite a non-empty directory with `cosmo init`.
14
+ - Never invent business facts, evidence, service coverage, audience observations, credentials, testimonials, results, research, or approval.
15
+ - Never approve an artifact for the user or weaken a gate to make a check pass.
16
+ - Keep secrets in environment variables or an ignored runtime environment file.
17
+ - Explain the immediate decision in plain language instead of exposing the whole internal pipeline.
18
+ - Treat design as an independent creative problem. Claude Design may be used when available, but is never required; another design authority or the current agent can satisfy the same repository-owned contract.
19
+
20
+ ## Verify and classify
21
+
22
+ Run `cosmo --version`, then inspect the current directory without changing it:
23
+
24
+ 1. `.cosmo/project.json` exists: resume an existing Cosmo project.
25
+ 2. Astro is declared in `package.json` or `astro.config.*` exists: offer to adopt the existing Astro site.
26
+ 3. The directory is empty except for `.git`: offer to create a new site here.
27
+ 4. Otherwise: ask for a new child-directory name. Never overwrite unrelated files.
28
+
29
+ ## Resume a Cosmo project
30
+
31
+ Run `cosmo doctor .` and `cosmo status . --json`. Read `HANDOFF.md` when present, then read the current workflow, project, intelligence, brand, evidence, copy, design, plan, page-work, QA, release, and deployment artifacts that apply to the active stage.
32
+
33
+ - For status-only requests, report the current stage, blockers, and exact next action.
34
+ - If a workflow is active, run `cosmo workflow resume .` and `cosmo intelligence guide <stage> .`, then continue that stage.
35
+ - If no workflow exists, explain the default workflow and ask before starting it.
36
+ - Preserve approved contracts and handoff decisions from every prior agent.
37
+
38
+ ## Adopt an Astro site
39
+
40
+ Inventory the existing Astro configuration, routes, content, source, public files, and build command. Explain that adoption adds Cosmo governance without replacing the site. After explicit confirmation, collect the brand, site URL, capability profile, and design mode, then run `cosmo adopt`, install dependencies if needed, run `cosmo doctor .`, and start discovery. Do not restructure existing code before the user approves a plan.
41
+
42
+ ## Create a new site
43
+
44
+ Collect the target, brand, known URL, business, audience, goal, genuine location scope, justified page count, capability profile, and design mode. Recommend `growth-site` for a typical lead-generation site; use a specialist profile only when the project warrants it. Confirm the summary before initialization, then run `cosmo init`, install dependencies, diagnose the project, start the workflow, and conduct brand and copy discovery.
45
+
46
+ Do not mark discovery, strategy, plan, copy briefs, design, or final review approved until the user explicitly approves the presented artifact. Use Cosmo workflow commands to record submission and approval.
47
+
48
+ ## Work stage by stage
49
+
50
+ For every stage:
51
+
52
+ 1. Read the stage contract and selected intelligence guidance.
53
+ 2. State the immediate outcome and decisions needed.
54
+ 3. Create or edit repository-owned artifacts.
55
+ 4. Run the relevant deterministic checks.
56
+ 5. Present approval-stage results and wait for explicit approval.
57
+
58
+ Before page writing, run `cosmo copy guide <page-id> .`. Keep supplied, observed, inferred, and unknown information distinct. Do not imitate living writers, reproduce source language, fabricate reader psychology, or make unsupported attacks on alternatives. Explore at least three genuinely different visual directions and store the approved choice in `DESIGN-DIRECTION.md`, tokens, components, and Cosmo design artifacts.
59
+
60
+ Advance generation one state at a time. After two failed repair cycles, leave the page for human review. For release, run the build plus Copy Studio, content, intelligence, integrity, static, browser, and release checks. Deploy production only when the exact current release reports READY.
61
+
62
+ ## Switching agents
63
+
64
+ Any supported agent may continue the project. Before switching, run appropriate checks and create `cosmo handoff create . --from <current-agent> --to <next-agent> --note "<completed work and open decisions>"`. The receiving agent must recover intent from the repository rather than prior chat history.
65
+
66
+ ## Help
67
+
68
+ When asked what Cosmo can do, briefly describe new Astro builds, existing-site adoption, resumable workflows, Copy Studio, intelligence profiles, independent design direction, research provenance, production QA, agent handoffs, and Cloudflare/SFTP/FTPS/FTP deployment.
@@ -0,0 +1,17 @@
1
+ <!-- cosmo-agent-version: 1.9.0 -->
2
+ # Cosmo
3
+
4
+ Use the Cosmo website-building workflow in the current workspace.
5
+
6
+ First, look for `.agents/skills/cosmo/SKILL.md` and follow it completely when present. If it is absent, apply these minimum rules:
7
+
8
+ - Run `cosmo --version` and inspect the directory before changing anything.
9
+ - Resume when `.cosmo/project.json` exists.
10
+ - Offer adoption when an Astro project exists without `.cosmo/project.json`.
11
+ - Initialize only an empty directory; never overwrite unrelated files.
12
+ - Treat repository state as authoritative across agents.
13
+ - Never invent evidence or approval, bypass a gate, or place credentials in tracked files.
14
+ - Use `cosmo doctor .` and `cosmo status . --json` to identify the next safe action.
15
+ - Explain decisions conversationally so the user does not need to know Cosmo commands.
16
+
17
+ If this is not yet a Cosmo project, guide the user through the smallest set of questions needed to start or adopt it. If it is already managed by Cosmo, continue the active stage and preserve every approved contract and handoff.
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "cosmo",
3
- "version": "1.1.0",
3
+ "version": "1.9.0",
4
4
  "description": "Conversational launcher for starting, adopting, and resuming local-first Cosmo Astro website builds.",
5
5
  "author": {
6
6
  "name": "Cosmo"
7
7
  },
8
8
  "license": "UNLICENSED",
9
- "keywords": ["astro", "website-builder", "claude", "cosmo"]
9
+ "keywords": ["astro", "website-builder", "claude", "multi-agent", "cosmo"]
10
10
  }
@@ -49,7 +49,7 @@ cosmo doctor .
49
49
  cosmo status . --json
50
50
  ```
51
51
 
52
- Then read, when present: `HANDOFF.md`, `.cosmo/project.json`, `.cosmo/workflow-state.json`, `.cosmo/intelligence/selection.json`, current selected pack manifests/artifacts, `.cosmo/brand/discovery.json`, `BRAND-BRIEF.md`, `DESIGN-DIRECTION.md`, `.cosmo/build-plan.json`, and the current page workspace.
52
+ Then read, when present: `HANDOFF.md`, `.cosmo/project.json`, `.cosmo/workflow-state.json`, `.cosmo/intelligence/selection.json`, current selected pack manifests/artifacts, `.cosmo/brand/discovery.json`, `BRAND-BRIEF.md`, `.cosmo/copy/strategy.json`, `DESIGN-DIRECTION.md`, `.cosmo/build-plan.json`, and the current page workspace including `copy-brief.json`.
53
53
 
54
54
  - If the user requested only status, summarize the current stage, blockers, and exact next action.
55
55
  - If no workflow exists, offer to start the default workflow, then run `cosmo workflow start .` after confirmation.
@@ -100,9 +100,10 @@ cosmo intake <target> --niche "<niche>" --audience "<audience>" --goal "<goal>"
100
100
  cosmo workflow submit intake <target>
101
101
  cosmo intelligence scaffold <target>
102
102
  cosmo intelligence guide brand <target>
103
+ cosmo copy init <target>
103
104
  ```
104
105
 
105
- Then conduct brand discovery conversationally. Ask a small coherent group of questions at a time, record the answers in `.cosmo/brand/discovery.json`, synthesize the brand inputs, and present them for explicit human approval. Do not set `approved: true` until the user approves.
106
+ Then conduct brand and copy-strategy discovery conversationally. Ask a small coherent group of questions at a time. Record the brand answers in `.cosmo/brand/discovery.json`, and record the reader's current alternative, starting belief, desired belief, ability and motivation to change, meaningful benefit, credible difference, category distinction, voice techniques, proof bridge, and ethical comparison policy in `.cosmo/copy/strategy.json`. Present both for explicit human approval. Do not set either `approved` value to true until the user approves.
106
107
 
107
108
  ## Stage behavior
108
109
 
@@ -115,8 +116,8 @@ At every stage:
115
116
  5. Present approval-stage results and wait.
116
117
  6. Submit and approve only through Cosmo CLI commands.
117
118
 
118
- For design, explore at least three genuinely distinct directions and preserve the selected direction in repository artifacts. For generation, advance one page gate at a time and respect repair limits. For QA, run integrity, content, intelligence, static, and browser checks. For production, require the exact current release to be READY.
119
+ For design, explore at least three genuinely distinct directions and preserve the selected direction in repository artifacts. After the page plan is approved, run `cosmo copy brief --all . --replace`, complete each flexible annotated section contract, and obtain approval. Before drafting a page, run `cosmo copy guide <page-id> .` and follow its separate grounding, drafting, evidence, editorial, reader, and final passes. Never imitate a living writer, import private Lyra files, reproduce copyrighted source wording, fabricate reader psychology, or use unsupported attacks on an alternative. For generation, advance one page gate at a time and respect repair limits. For QA, run `cosmo copy check .` with integrity, content, intelligence, static, and browser checks. For production, require the exact current release to be READY.
119
120
 
120
121
  ## Help mode
121
122
 
122
- If the user asks what Cosmo can do, summarize new builds, Astro adoption, workflow resume, first-party intelligence profiles, Claude Design handoff, research snapshots, production QA, Claude-to-Codex handoff, and Cloudflare/SFTP/FTPS/FTP deployment. Keep the answer concise and offer to start or resume.
123
+ If the user asks what Cosmo can do, summarize new builds, Astro adoption, workflow resume, first-party intelligence profiles, Copy Studio, Claude Design handoff, research snapshots, production QA, Claude-to-Codex handoff, and Cloudflare/SFTP/FTPS/FTP deployment. Keep the answer concise and offer to start or resume.
@@ -1,14 +1,16 @@
1
- import { installClaudePlugin } from '../packages/cli/lib/claude-plugin.mjs';
1
+ import { agentInvocation, installAgent, SUPPORTED_AGENTS } from '../packages/cli/lib/agent-adapters.mjs';
2
2
 
3
3
  const globalInstall = process.env.npm_config_global === 'true' || process.env.COSMO_POSTINSTALL_FORCE === '1';
4
4
 
5
5
  if (globalInstall) {
6
- try {
7
- const result = installClaudePlugin({ replace: true, validate: false });
8
- console.log(`Cosmo is ready for Claude at ${result.target}`);
9
- console.log('Restart Claude, open a website folder, and type: cosmo');
10
- } catch (error) {
11
- console.warn(`Cosmo installed, but automatic Claude setup could not finish: ${error.message}`);
12
- console.warn('After resolving the issue, run: cosmo setup');
6
+ for (const agent of SUPPORTED_AGENTS) {
7
+ try {
8
+ const result = installAgent(agent, { replace: true, validate: false });
9
+ console.log(`Cosmo is ready for ${agent} at ${result.target}`);
10
+ console.log(`Start: ${agentInvocation(agent)}`);
11
+ } catch (error) {
12
+ console.warn(`Cosmo installed, but automatic ${agent} setup could not finish: ${error.message}`);
13
+ console.warn(`After resolving the issue, run: cosmo setup --agent ${agent}`);
14
+ }
13
15
  }
14
16
  }
@@ -0,0 +1,3 @@
1
+ # Cosmo project rule
2
+
3
+ This workspace is managed by Cosmo. Repository files are authoritative across Claude, Codex, Antigravity, and human editing. Follow `.agents/skills/cosmo/SKILL.md` for Cosmo work. Preserve approvals, evidence boundaries, design decisions, workflow state, and handoffs. Never fabricate facts or approval, bypass a failed gate, or store credentials in tracked files.
@@ -0,0 +1,18 @@
1
+ ---
2
+ name: cosmo
3
+ description: Start, adopt, resume, build, review, or release this Cosmo-managed Astro website. Use whenever the user says Cosmo or asks to work on this site with Cosmo.
4
+ ---
5
+
6
+ # Cosmo project workflow
7
+
8
+ Treat the repository—not previous chat history—as the source of truth. Run `cosmo doctor .` and `cosmo status . --json`, read `HANDOFF.md` when present, then recover the active stage from `.cosmo` before changing the site.
9
+
10
+ Never invent business facts, audience observations, evidence, research, credentials, testimonials, results, service coverage, or approval. Never weaken a policy or edit runtime state to make a gate pass. Keep secrets in environment variables or an ignored runtime environment file.
11
+
12
+ If `.cosmo/project.json` is absent, inspect before acting: offer `cosmo adopt` for an existing Astro site, use `cosmo init` only in an empty directory, and never overwrite unrelated files.
13
+
14
+ At each stage, read the contract and selected intelligence guidance, explain the immediate decision, create repository-owned artifacts, run the relevant checks, and wait for explicit user approval where required. Use `cosmo copy guide <page-id> .` before page writing. Keep facts, observations, inferences, and unknowns distinct. Explore at least three genuinely different visual directions; Claude Design is optional, and any capable design authority may satisfy the same repository-owned design contract.
15
+
16
+ Advance generation one state at a time. After two unsuccessful repair cycles, leave the page for human review. Require the exact release to report READY before production deployment.
17
+
18
+ When switching tools, create a durable handoff with `cosmo handoff create . --from <current-agent> --to <next-agent> --note "<summary and open decisions>"`. The next agent must continue from repository state.
@@ -0,0 +1,3 @@
1
+ # Cosmo
2
+
3
+ Start or resume Cosmo in this workspace. Read and follow `.agents/skills/cosmo/SKILL.md`, classify the project safely, recover any existing `.cosmo` state and `HANDOFF.md`, then guide the user through the exact next decision without requiring them to know command-line instructions.
@@ -50,6 +50,13 @@
50
50
  "path": ".cosmo/evidence.json",
51
51
  "kind": "json",
52
52
  "requiredKeys": ["version", "entityId", "claims", "proofs"]
53
+ },
54
+ {
55
+ "path": ".cosmo/copy/strategy.json",
56
+ "kind": "json",
57
+ "requiredKeys": ["version", "approved", "audience", "positioning", "competitiveTransition", "voice", "governance"],
58
+ "equals": { "approved": true },
59
+ "nonEmptyKeys": ["audience.primary", "audience.startingBelief", "audience.desiredBelief", "positioning.meaningfulBenefit", "positioning.differentiation", "governance.owner"]
53
60
  }
54
61
  ]
55
62
  },
@@ -104,7 +111,7 @@
104
111
  "id": "generate",
105
112
  "type": "core",
106
113
  "title": "Structured page generation",
107
- "instructions": "Move every page through briefed, sourced, outlined, drafted, edited, verified, and done gates. Keep page workspaces auditable, limit automated repairs to two cycles, and escalate unresolved work to a human.",
114
+ "instructions": "Create and approve a flexible Copy Studio brief for every page, then move each page through briefed, sourced, outlined, drafted, edited, verified, and done gates. Use the staged writing guide, keep page workspaces auditable, limit automated repairs to two cycles, and escalate unresolved work to a human.",
108
115
  "approval": false,
109
116
  "expects": [
110
117
  {
@@ -119,9 +126,15 @@
119
126
  "id": "qa",
120
127
  "type": "core",
121
128
  "title": "Production QA",
122
- "instructions": "Run semantic content, production-build, and rendered-browser checks. Remediate blocking findings without relaxing policy or inventing proof, then submit all passing reports for approval.",
129
+ "instructions": "Run Copy Studio, semantic content, production-build, and rendered-browser checks. Remediate blocking findings without relaxing policy or inventing proof, then submit all passing reports for approval.",
123
130
  "approval": true,
124
131
  "expects": [
132
+ {
133
+ "path": ".cosmo/reports/copy-check.json",
134
+ "kind": "json",
135
+ "requiredKeys": ["passed", "summary.pages", "summary.blocking", "summary.warnings"],
136
+ "equals": { "passed": true }
137
+ },
125
138
  {
126
139
  "path": ".cosmo/reports/content-check.json",
127
140
  "kind": "json",
@@ -1,22 +1,28 @@
1
- # Codex Project Guide
1
+ # Cosmo Project Guide
2
2
 
3
- This is a Cosmo-managed Astro project, commonly created in Claude and edited later in Codex. The repository—not prior chat history—is the source of truth.
3
+ This is a Cosmo-managed Astro project. It may be created or edited in Claude, Codex, Google Antigravity, another capable coding agent, or by a person. The repository—not previous chat history—is the source of truth.
4
+
5
+ When the user says `cosmo`, asks to start, continue, review, or release the site, follow `.agents/skills/cosmo/SKILL.md`. Do not require the user to know command-line instructions.
4
6
 
5
7
  Before editing:
6
8
 
7
9
  1. Read `HANDOFF.md` when present.
8
- 2. Run `cosmo doctor .`, `cosmo status .`, `cosmo workflow resume .`, `cosmo plan check .`, and `cosmo generate status .` when their state files exist.
9
- 3. Read `.cosmo/brand/discovery.json`, `BRAND-BRIEF.md`, `.cosmo/brand/entity-canon.json`, `.cosmo/brand/voice-profile.json`, `.cosmo/evidence.json`, `.cosmo/intelligence/selection.json`, every selected pack manifest and artifact, the relevant page brief, sources, outline, and editorial report, `DESIGN-DIRECTION.md`, `src/styles/tokens.css`, and the relevant typed content entries.
10
+ 2. Run `cosmo doctor .` and `cosmo status . --json`. Resume the active workflow and generation state when present.
11
+ 3. Read the project, brand, evidence, copy, intelligence, design, plan, page-work, QA, release, and deployment artifacts relevant to the active stage.
10
12
  4. Run `cosmo intelligence guide <stage> .` before selected-pack work. The first-party capability library is self-contained; do not depend on Lyra or Sonic files being present.
11
- 5. Preserve approved signature design elements unless the requested change explicitly revises the design direction.
13
+ 5. Preserve approved evidence, positioning, copy, and signature design elements unless the requested change explicitly revises them.
14
+
15
+ Never bypass workflow approvals, manufacture completion, invent business facts or evidence, fabricate reader psychology, imitate a living writer, or alter identity, intent, link, claim, and proof ids to evade a gate. Run `cosmo copy guide <page-id> .` before material copy work. Components should remain shared and semantic, but page compositions do not need to follow a Cosmo house style.
12
16
 
13
- Do not bypass workflow approvals, edit generated progress to manufacture completion, convert unsupported claims into plausible prose, invent demand, or alter identity, intent, link, claim, and proof ids to evade a gate. Components should remain shared and semantic; create a new component only for a genuinely new visual or behavioral pattern.
17
+ Claude Design is an optional creative authority, not a runtime requirement. When it is unavailable, use another capable design process while satisfying the same repository-owned exploration, responsive, accessibility, token, component, and design-handoff contracts.
14
18
 
15
19
  Verify changes in proportion to their scope. For a production handoff, run:
16
20
 
17
21
  ```bash
18
22
  npm run build
23
+ cosmo integrity check .
19
24
  cosmo check . --no-build
25
+ cosmo copy check .
20
26
  cosmo content check .
21
27
  cosmo intelligence check .
22
28
  cosmo browser check . --no-build
@@ -5,12 +5,12 @@ This is a Cosmo-managed Astro project. Use Claude for discovery, strategy, conte
5
5
  Before changing the site:
6
6
 
7
7
  1. Run `cosmo doctor .`, `cosmo status .`, and `cosmo workflow resume .` when a workflow is active.
8
- 2. Read `.cosmo/brand/discovery.json`, `BRAND-BRIEF.md`, `.cosmo/brand/entity-canon.json`, `.cosmo/brand/voice-profile.json`, `.cosmo/evidence.json`, `.cosmo/intelligence/selection.json`, every selected pack manifest and artifact, `DESIGN-DIRECTION.md`, `.cosmo/build-plan.json`, and the current page's brief, sources, outline, and editorial report when present.
8
+ 2. Read `.cosmo/brand/discovery.json`, `BRAND-BRIEF.md`, `.cosmo/brand/entity-canon.json`, `.cosmo/brand/voice-profile.json`, `.cosmo/evidence.json`, `.cosmo/copy/strategy.json`, `.cosmo/intelligence/selection.json`, every selected pack manifest and artifact, `DESIGN-DIRECTION.md`, `.cosmo/build-plan.json`, and the current page's brief, copy brief, sources, outline, and editorial report when present.
9
9
  3. Run `cosmo intelligence guide <stage> .` before doing selected-pack work. Audience, differentiation, search/community, conversion, naturalness, branded-language, authority, local, editorial, regulated, research, image, and Claude Design guidance is built into Cosmo; do not assume Lyra or Sonic is installed.
10
10
  4. Treat the starter appearance as replaceable. Do not let its components or visual motifs constrain Claude Design exploration.
11
11
  5. Once a direction is approved, express it in repository-owned Astro components, `src/styles/tokens.css`, and `DESIGN-DIRECTION.md`.
12
12
 
13
- Never invent credentials, testimonials, locations, results, statistics, demand, or business evidence. Keep missing evidence and demand confidence explicit. Attributed first-person material must remain attributed and must never become the principal's voice. Do not create a new page when its intent belongs as a section or overlaps an existing route without a defensible boundary. Use `cosmo generate complete` only after the page agrees with its plan-derived brief and every carried proof is verified in the evidence ledger.
13
+ Never invent credentials, testimonials, locations, results, statistics, demand, reader psychology, or business evidence. Keep missing evidence and demand confidence explicit. Attributed first-person material must remain attributed and must never become the principal's voice. Do not imitate a living writer or copy source phrasing. Do not create a new page when its intent belongs as a section or overlaps an existing route without a defensible boundary. Before drafting, run `cosmo copy guide <page-id> .`; use `cosmo generate complete` only after the page agrees with its approved copy brief and every carried proof is verified in the evidence ledger.
14
14
 
15
15
  Advance generation one state at a time with `cosmo generate advance`. Do not manufacture completion by editing `.cosmo/progress.json`. After two repair cycles, stop automated rewriting and leave the page in human review.
16
16
 
@@ -18,6 +18,7 @@ Before handing the project to another agent, run the relevant checks and create
18
18
 
19
19
  ```bash
20
20
  cosmo check .
21
+ cosmo copy check .
21
22
  cosmo content check .
22
23
  cosmo intelligence check .
23
24
  cosmo browser check .
@@ -8,7 +8,7 @@ npm run dev
8
8
  npm run build
9
9
  ```
10
10
 
11
- Cosmo adds local workflow, generation, design-handoff, and QA contracts under `.cosmo/`. Read `CLAUDE.md` for Claude-led builds, `AGENTS.md` for later Codex work, and `HANDOFF.md` when one agent has explicitly handed the project to another.
11
+ Cosmo adds local workflow, generation, design-handoff, and QA contracts under `.cosmo/`. Use `.agents/skills/cosmo/SKILL.md` in Codex or Antigravity, `CLAUDE.md` in Claude, `AGENTS.md` as the cross-agent project guide, and `HANDOFF.md` when one agent has explicitly handed the project to another.
12
12
 
13
13
  The initial home and about routes are neutral, `noindex` scaffolds. The build plan is a valid draft, not an approval to generate or publish. Replace the placeholder entity, evidence, voice, page plan, content, and design direction through the Cosmo workflow before changing indexability.
14
14
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cosmo/astro-starter",
3
- "version": "1.7.0",
3
+ "version": "1.9.0",
4
4
  "private": true,
5
5
  "type": "module",
6
6
  "scripts": {