Self-evolving second brain with 35 AI skills, 10 agents, and people CRM. Closed-loop harness: a V-model verification lifecycle where the worker never grades its own homework. Plus paired anti-slop design skills for marketing and product UI. Works with Claude Code, Cursor, Kiro, Gemini CLI, Codex.
Python agent-loopagent-pluginsagent-skillsagenticai-agentsclaude-codeclosed-loopcursorgarry-tangbraingstackknowledge-managementloop-engineeringobsidianpeople-crmproductivitysecond-brainself-evolvingverification-harnessworker-agents
feat: adopt the Agent Plugins standard (v3.10.0)
Huy Tieub85236931e8d
diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.jsonindex ce1fd66..363ba1a 100644--- a/.claude-plugin/plugin.json+++ b/.claude-plugin/plugin.json@@ -1,6 +1,6 @@{"name": "cog-second-brain",- "version": "3.9.0",+ "version": "3.10.0","description": "Self-evolving second brain with 33 AI agent skills, 10 agents, and people CRM. Closed-loop harness release: a V-model verification lifecycle (spec to evidence, criterion-traced checkpoints), read-only verifier agents that observe artifacts instead of trusting worker summaries, risk lanes, multi-session ultragoals with a north-star acceptance gate, plus craft skills for writing, visual work, and a paired anti-slop design system for marketing and product UI. Inspired by Garry Tan's gstack specialist sessions, gbrain knowledge patterns, and dwarves-kit closed-loop execution. Works with Claude Code, Antigravity, Cursor, Kiro, Gemini CLI, Codex, and any markdown-reading agent.","author": {"name": "Huy Tieu",diff --git a/.cursor-plugin/plugin.json b/.cursor-plugin/plugin.jsonindex 6e37f55..6499309 100644--- a/.cursor-plugin/plugin.json+++ b/.cursor-plugin/plugin.json@@ -1,7 +1,7 @@{"name": "cog-second-brain","displayName": "COG: Agentic Second Brain",- "version": "3.8.1",+ "version": "3.10.0","description": "Self-evolving second brain powered by AI agents, Obsidian markdown, and Git. 33 skills, 10 agents (6 workers + 4 read-only verifiers), people CRM with tiered enrichment. Closed-loop harness release: V-model verification lifecycle with criterion-traced evidence, risk lanes, multi-session ultragoals with a north-star acceptance gate, craft skills for writing and visuals, and paired anti-slop design skills for marketing and product UI. Works with Claude Code, Cursor, Kiro, Gemini CLI, and Codex.","author": {"name": "Huy Tieu",diff --git a/CHANGELOG.md b/CHANGELOG.mdindex dd2c3fb..d79c67c 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -2,6 +2,21 @@All notable changes to COG (Cognition + Obsidian + Git) will be documented in this file.+## [3.10.0] - 2026-08-07++### Added++#### Agent Plugins standard adoption+COG now conforms to the [Agent Plugins specification 1.0.0](https://agent-plugins.org) — the open, vendor-neutral plugin format governed by a Technical Steering Committee with representatives from Amazon, Cursor, Microsoft, OpenAI, and Vercel. Any standard-conformant client can load COG as a plugin directly from a checkout.++- **`plugin.json`** at the repo root: the standard manifest, validated against the published 1.0.0 schema.+- **`skills/`** at the repo root: generated mirror of `.claude/skills/` (the spec's fixed skill location; skills follow the [Agent Skills](https://agentskills.io) format). `.claude/skills/` stays canonical — regenerate with `./scripts/build-agent-plugin.sh`, never edit `skills/` by hand.+- **`scripts/build-agent-plugin.sh`**: one-command mirror rebuild, wired into `cog-update.sh` so framework updates regenerate the surface automatically.+- **Validator coverage**: `validate-agent-surface.sh` now checks the manifest declares the 1.0.0 schema, the mirror matches `.claude/skills/` exactly, and the version is aligned across all four packaging manifests.++### Changed+- Version alignment check now spans `.claude-plugin/plugin.json`, `plugin.json`, `marketplace-entry.json`, and `COG-VERSION`.+## [3.9.0] - 2026-07-29### Addeddiff --git a/COG-VERSION b/COG-VERSIONindex a5c4c76..30291cb 100644--- a/COG-VERSION+++ b/COG-VERSION@@ -1 +1 @@-3.9.0+3.10.0diff --git a/README.md b/README.mdindex e993bf6..4893625 100644--- a/README.md+++ b/README.md@@ -59,6 +59,7 @@ COG ships a **full Claude Code surface**, a **full Antigravity surface**, plus *|---|---|---|| Claude Code | 33 native skills + 10 agents (6 workers + 4 verifiers) | Full first-class surface || Antigravity | 33 skills + 10 agents (pointer-stub format) | Full surface — thin stubs in `.agents/` delegate to the `.claude/` playbooks, which stay authoritative |+| [Agent Plugins](https://agent-plugins.org) standard | Root `plugin.json` + `skills/` (33 skills) | Spec 1.0.0 conformant — any standard-aware client loads COG as a plugin || Cursor | Plugin manifest + rules | `.cursor-plugin/plugin.json` + `.cursorrules` || Kiro | 7 native powers | Core workflows today || Gemini CLI | 7 native commands | Core workflows today |diff --git a/cog-update.sh b/cog-update.shindex 68830a6..fa68046 100755--- a/cog-update.sh+++ b/cog-update.sh@@ -178,6 +178,8 @@ FRAMEWORK_FILES=(".cursor-plugin/plugin.json"".cursorrules""marketplace-entry.json"+ "plugin.json"+ "scripts/build-agent-plugin.sh"# Git infrastructure".gitignore"@@ -290,6 +292,14 @@ warn_if_dirty() {fi}+# Regenerate the Agent Plugins standard mirror (root skills/) after framework+# updates so it never drifts from the updated .claude/skills/.+rebuild_agent_plugin() {+ if [[ -x "scripts/build-agent-plugin.sh" ]]; then+ ./scripts/build-agent-plugin.sh || warn "Agent plugin mirror rebuild failed; run ./scripts/build-agent-plugin.sh manually"+ fi+}+run_validator() {if [[ -x "$VALIDATOR_SCRIPT" ]]; thenecho ""@@ -427,6 +437,7 @@ main() {echo ""ok "Updated ${updated} file(s) to v${uv}"info "Backups saved as *.backup-YYYYMMDD-HHMMSS alongside originals"+ rebuild_agent_pluginrun_validator || trueexit 0fi@@ -505,6 +516,7 @@ main() {echo ""if [[ $updated -gt 0 ]]; then+ rebuild_agent_pluginrun_validator || trueinfo "Review changes with ${BOLD}git diff${RESET}, then commit when ready:"echo " git add -A && git commit -m \"Update COG framework to v${uv}\""diff --git a/docs/AGENT-SUPPORT.md b/docs/AGENT-SUPPORT.mdindex 3762ccc..17b77e0 100644--- a/docs/AGENT-SUPPORT.md+++ b/docs/AGENT-SUPPORT.md@@ -10,6 +10,7 @@ This document is the packaging contract: it tells contributors and maintainers w|---|---|---:|---|| Claude Code | `.claude/skills/*/SKILL.md` | 33 skills | Full native surface || Antigravity | `.agents/skills/*/SKILL.md` + `.agents/agents/*.md` | 33 skills + 10 agents | Full surface (pointer-stub format — delegates to `.claude/`, which stays authoritative) |+| [Agent Plugins](https://agent-plugins.org) standard | Root `plugin.json` + `skills/` (generated mirror) | 33 skills | Spec 1.0.0 conformant; rebuild with `scripts/build-agent-plugin.sh` || Universal agent docs | `AGENTS.md` | 17 commands | Full documented fallback || Kiro | `.kiro/powers/*/POWER.md` | 7 powers | Core workflows only || Gemini CLI | `.gemini/commands/*.toml` + `.gemini/skills/*.md` | 7 commands | Core workflows only |diff --git a/marketplace-entry.json b/marketplace-entry.jsonindex fe4b9f8..9cbce94 100644--- a/marketplace-entry.json+++ b/marketplace-entry.json@@ -7,7 +7,7 @@"url": "https://github.com/huytieu"},"description": "Self-evolving second brain with 33 AI skills, 10 agents, and people CRM. Closed-loop harness release: V-model verification lifecycle with criterion-traced evidence, read-only verifier agents, risk lanes, multi-session ultragoals with a north-star acceptance gate, craft skills for writing and visuals, and paired anti-slop design skills for marketing and product UI. Inspired by Garry Tan's gstack and gbrain, and dwarves-kit. Works with Claude Code, Antigravity, Cursor, Kiro, Gemini CLI, Codex.",- "version": "3.9.0",+ "version": "3.10.0","keywords": ["second-brain","garry-tan",diff --git a/plugin.json b/plugin.jsonnew file mode 100644index 0000000..6b327dd--- /dev/null+++ b/plugin.json@@ -0,0 +1,32 @@+{+ "$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json",+ "name": "cog-second-brain",+ "version": "3.10.0",+ "description": "Self-evolving second brain with 33 AI agent skills, 10 agents, and people CRM. Closed-loop harness: a V-model verification lifecycle (spec to evidence, criterion-traced checkpoints), read-only verifier agents that observe artifacts instead of trusting worker summaries, risk lanes, multi-session ultragoals with a north-star acceptance gate, plus craft skills for writing, visual work, and a paired anti-slop design system for marketing and product UI. Works with Claude Code, Cursor, Kiro, Gemini CLI, Codex, and any Agent Plugins conformant client.",+ "author": {+ "name": "Huy Tieu",+ "email": "[email protected]",+ "url": "https://github.com/huytieu"+ },+ "homepage": "https://github.com/huytieu/COG-second-brain",+ "repository": "https://github.com/huytieu/COG-second-brain",+ "license": "MIT",+ "keywords": [+ "second-brain",+ "knowledge-management",+ "obsidian",+ "ai-agents",+ "productivity",+ "people-crm",+ "claude-code",+ "cursor",+ "kiro",+ "gemini-cli",+ "codex",+ "closed-loop",+ "verification-harness",+ "ultragoal",+ "no-ai-slop",+ "agent-plugins"+ ]+}diff --git a/scripts/build-agent-plugin.sh b/scripts/build-agent-plugin.shnew file mode 100755index 0000000..00fb4de--- /dev/null+++ b/scripts/build-agent-plugin.sh@@ -0,0 +1,27 @@+#!/usr/bin/env bash+# build-agent-plugin.sh — regenerate the Agent Plugins standard surface.+#+# COG conforms to the Agent Plugins specification 1.0.0 (https://agent-plugins.org):+# a root plugin.json manifest plus a root skills/ directory. The canonical skills+# live in .claude/skills/ (that is what the distill and update flows write); this+# script mirrors them to skills/ so any standard-conformant client can load COG+# as a plugin. Run it after adding or editing any skill, then commit the result.+#+# skills/ is GENERATED — never edit it by hand. The packaging validator+# (scripts/validate-agent-surface.sh) fails if the two trees drift.++set -euo pipefail++ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"+cd "$ROOT_DIR"++if [[ ! -d .claude/skills ]]; then+ echo "✗ .claude/skills not found — run from a COG checkout" >&2+ exit 1+fi++rm -rf skills+cp -R .claude/skills skills++count=$(find skills -name SKILL.md | wc -l | tr -d ' ')+echo "✓ Mirrored .claude/skills → skills/ ($count skills, Agent Plugins spec 1.0.0)"diff --git a/scripts/validate-agent-surface.sh b/scripts/validate-agent-surface.shindex d4e51bd..b02be22 100755--- a/scripts/validate-agent-surface.sh+++ b/scripts/validate-agent-surface.sh@@ -47,6 +47,27 @@ elserecord_failure "marketplace-entry.json is not valid JSON"fi+# Agent Plugins standard surface (agent-plugins.org, spec 1.0.0):+# root plugin.json manifest + root skills/ mirror of .claude/skills/.+if python3 - <<'PY' >/dev/null 2>&1+import json+with open('plugin.json') as f:+ data = json.load(f)+assert data['$schema'] == 'https://agent-plugins.org/schemas/1.0.0/plugin.schema.json'+assert data['name'] == 'cog-second-brain'+PY+then+ ok "plugin.json is valid JSON and declares the Agent Plugins 1.0.0 schema"+else+ record_failure "plugin.json is missing, invalid JSON, or missing \$schema/name (Agent Plugins spec 1.0.0)"+fi++if [[ -d skills ]] && diff -r .claude/skills skills >/dev/null 2>&1; then+ ok "skills/ mirror matches .claude/skills (Agent Plugins surface in sync)"+else+ record_failure "skills/ mirror is missing or drifted from .claude/skills — run ./scripts/build-agent-plugin.sh"+fi+manifest_tmp="$(mktemp)"python3 - <<'PY' > "$manifest_tmp"import json@@ -96,11 +117,17 @@ with open('marketplace-entry.json') as f:PY)cog_version=$(tr -d '[:space:]' < COG-VERSION)+agent_plugin_version=$(python3 - <<'PY'+import json+with open('plugin.json') as f:+ print(json.load(f)['version'])+PY+)-if [[ "$plugin_version" == "$marketplace_version" && "$plugin_version" == "$cog_version" ]]; then- ok "Version is aligned across plugin.json, marketplace-entry.json, and COG-VERSION ($cog_version)"+if [[ "$plugin_version" == "$marketplace_version" && "$plugin_version" == "$cog_version" && "$plugin_version" == "$agent_plugin_version" ]]; then+ ok "Version is aligned across .claude-plugin/plugin.json, plugin.json, marketplace-entry.json, and COG-VERSION ($cog_version)"else- record_failure "Version mismatch: plugin.json=$plugin_version marketplace-entry.json=$marketplace_version COG-VERSION=$cog_version"+ record_failure "Version mismatch: .claude-plugin/plugin.json=$plugin_version plugin.json=$agent_plugin_version marketplace-entry.json=$marketplace_version COG-VERSION=$cog_version"fiif rg -n "agents\.md" README.md SETUP.md CONTRIBUTING.md .github/MARKETPLACE.md >/dev/null 2>&1; thendiff --git a/skills/auto-research/SKILL.md b/skills/auto-research/SKILL.mdnew file mode 100644index 0000000..978af3e--- /dev/null+++ b/skills/auto-research/SKILL.md@@ -0,0 +1,234 @@+---+name: auto-research+description: Deep strategic research engine — decomposes questions into parallel research threads, spawns multiple agents, and synthesizes into actionable strategic analysis+roles: [product-manager, engineering-lead, founder, all]+integrations: []+---++# COG Auto Research Skill++## When to Invoke+- User asks a strategic question requiring deep research+- User says "research", "auto-research", "investigate", "strategic analysis", "deep dive into [topic]"+- User wants to understand market forces, competitive dynamics, technology trajectories, or strategic options+- User needs evidence-based analysis with real sources to support decision-making++Inspired by Karpathy's autoresearch — but for strategic thinking instead of ML training.++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use the full parallel agent execution strategy (5-7 agents). This skill benefits massively from team mode.+- If `agent_mode: solo` — run 2-3 sequential research passes with WebSearch/WebFetch, produce a lighter analysis without the full multi-thread structure.++## Command: `/auto-research`++## Input+The user provides a strategic question or topic as the command argument. Examples:+- "If foundation models commoditize, what happens to LLM wrapper companies like Katalon/Scout?"+- "Future of the testing industry as AI capabilities expand"+- "Should we build vs buy vs partner for our AI layer?"+- "What are the strategic options for Scout if OpenAI launches a testing product?"++---++## Execution Strategy++### Phase 1: Question Decomposition (Orchestrator — 2 minutes)++Break the user's strategic question into 5-7 **research threads** that together will provide a comprehensive answer. Each thread should be:+- **Independent** — can be researched in parallel+- **Specific** — has a clear research objective+- **Complementary** — together they cover the full strategic landscape++**Decomposition framework:**+1. **Market forces** — what macro trends drive this question?+2. **Historical precedent** — has this pattern played out before in other industries?+3. **Player analysis** — who are the key players and what are they doing?+4. **Technology trajectory** — where is the underlying tech heading?+5. **Customer behavior** — what do end-users actually want/do?+6. **Economic model** — what are the unit economics and value capture dynamics?+7. **Emerging tech & architectures** — what concepts, projects, or frameworks are still in development/discussion (pre-mainstream) that could be foundational? Research open-source projects, research papers, GitHub repos, Discord/forum discussions, conference talks, and early-stage tools that are relevant. Examples: novel agent architectures, new testing paradigms, experimental frameworks. These may not have polished docs — dig into READMEs, GitHub issues, Twitter/X threads, blog posts from builders, and academic preprints.+8. **Contrarian view** — what's the strongest argument against the consensus?++Not all threads apply to every question. Pick the 5-7 most relevant. **Thread 7 (Emerging tech) should ALWAYS be included** — the user specifically wants to stay ahead of concepts that aren't mainstream yet.++**Before spawning agents:**+1. Read relevant files from the vault for existing context:+ - `05-knowledge/` for existing frameworks and mental models+ - `04-projects/` for project-specific context if relevant+ - Recent braindumps for the user's existing thinking on this topic+2. State the decomposition to the user so they can course-correct before agents launch++### Phase 2: Parallel Deep Research (Spawn 5-7 Agents Simultaneously)++**CRITICAL: Launch ALL agents in a single message.** Use `run_in_background: true` for all agents.++Each agent gets a detailed prompt following this template:++```+You are a strategic research analyst investigating a specific thread of a larger strategic question.++MAIN QUESTION: [user's original question]+YOUR THREAD: [specific research thread]+EXISTING CONTEXT: [any relevant vault context]++RESEARCH METHODOLOGY:+1. WebSearch for 8-12 high-quality sources (prioritize: research reports, expert analyses, company filings, academic papers, industry publications — NOT listicles or superficial blog posts)+2. For each source found, WebFetch to read the full content and extract key arguments, data points, and frameworks+3. Look for CONFLICTING viewpoints — don't just confirm one narrative+4. Identify specific data points, statistics, and concrete examples+5. Note the credibility and potential bias of each source+6. FOR EMERGING TECH THREADS: Go beyond polished sources. Search GitHub repos (README, issues, discussions), Twitter/X threads from builders, Discord/forum discussions, conference talk summaries, arXiv preprints, and early blog posts. The goal is to surface concepts that are pre-mainstream but technically promising. For each concept found, assess: maturity level, technical approach, relevance to the user's use case, and what it would take to adopt/integrate.++OUTPUT FORMAT (return ALL of this):++## Thread: [thread name]++### Key Findings (3-5 bullet points)+- Finding with source attribution++### Evidence & Data Points+- Specific statistics, market data, examples with sources++### Expert/Notable Perspectives+- Named perspectives from credible voices++### Implications for [user's context]+- What this means specifically for the user's situation++### Confidence Level+- HIGH / MEDIUM / LOW with reasoning++### Sources+- Numbered list of actual URLs consulted+```++**Agent naming convention:** `research-[thread-slug]` (e.g., `research-market-forces`, `research-historical-precedent`)++### Phase 3: Synthesis (Orchestrator — after all agents complete)++Once all agents return, synthesize into a single strategic analysis document:++#### Document Structure:++```markdown+---+type: strategic-research+domain: [auto-detect from question]+date: YYYY-MM-DD+question: "[original question]"+threads: [list of research threads]+confidence: [overall confidence HIGH/MEDIUM/LOW]+tags:+ - auto-research+ - strategy+ - [topic tags]+status: complete+---++# [Strategic Question as Title]++## Executive Summary+3-5 sentences capturing the core insight. Lead with the answer, not the process.++## The Strategic Landscape+Synthesized view across all research threads. Not a thread-by-thread dump — weave findings together into a coherent narrative.++## Key Forces at Play+The 3-4 most important dynamics shaping this question, with evidence from multiple threads.++## Scenarios+### Scenario A: [Most Likely] — X% confidence+What happens, timeline, implications++### Scenario B: [Optimistic/Alternative]+What happens, timeline, implications++### Scenario C: [Worst Case/Disruption]+What happens, timeline, implications++## Emerging Tech & Architectures to Watch+Concepts, projects, and frameworks that are still in development/discussion but could be foundational. For each:+- **What it is:** One-paragraph explanation+- **Maturity:** Pre-alpha / Alpha / Early adoption / Growing community+- **Technical approach:** How it works architecturally+- **Relevance to our use case:** Why it matters for us specifically+- **Adoption path:** What it would take to integrate/adopt — effort, risks, dependencies+- **Key links:** GitHub repo, paper, discussion thread++## Strategic Options+For each option:+- **Description:** What this means concretely+- **Pros:** With evidence+- **Cons:** With evidence+- **Prerequisites:** What needs to be true+- **Timeline:** When to decide/act+- **Emerging tech leverage:** Which emerging concepts from above could strengthen this option++## Recommended Actions+Prioritized, concrete, time-bound action items. Not vague "consider X" — specific "do X by Y because Z."+Include a separate "Tech Bets" subsection: which emerging projects to start experimenting with now, even if they're not production-ready.++## Contrarian View+The strongest argument against the consensus/recommended path. What could make all of this wrong?++## Confidence & Gaps+- What we're confident about and why+- What we couldn't determine and what additional research would help+- Key assumptions that should be monitored++## Sources+Consolidated, deduplicated list of all sources across threads.+```++### Phase 4: Save & Deliver++1. Save the full analysis to `05-knowledge/research/YYYY-MM-DD-[slug].md`+2. If the analysis is long (>3000 words), also create a brief 1-page summary at `05-knowledge/research/YYYY-MM-DD-[slug]-summary.md`+3. Present the Executive Summary + Recommended Actions to the user directly in chat++---++## Quality Standards++- **No hallucinated sources.** Every claim must trace to a real WebSearch/WebFetch result.+- **Recency matters.** Prioritize sources from the last 6 months. Flag anything older.+- **Bias awareness.** Note when sources have obvious commercial incentives.+- **Specificity over generality.** "The testing tools market is $XX.XB and growing at YY% CAGR" beats "the market is growing."+- **Actionability.** The output should help the user make a decision, not just understand a topic.+- **Intellectual honesty.** If the research is inconclusive, say so. Don't manufacture false confidence.++## Example Decomposition++**Question:** "If generic LLM models get better over time, what's the future for LLM wrapper companies like Katalon or Scout?"++**Threads:**+1. **Foundation model trajectory** — How fast are GPT/Claude/Gemini improving at code understanding, test generation, bug detection? What's the capability curve?+2. **Historical precedent: platform commoditization** — What happened to companies built on top of AWS, iOS, Salesforce, etc. when the platform absorbed their features? Who survived and why?+3. **Testing industry structure** — Current market map, value chain, where margin lives, what buyers actually pay for+4. **Wrapper company strategies** — How are current AI wrapper companies (Jasper, Copy.ai, Cursor, etc.) adapting? What's working?+5. **Enterprise buying behavior** — Do enterprises buy "AI" or do they buy "solutions"? What's the procurement reality?+6. **Emerging tech & architectures** — What pre-mainstream concepts could reshape the landscape? (e.g., novel agent frameworks, new testing paradigms, computer-use agents, browser automation architectures). Search GitHub repos, arXiv, Twitter/X builder threads, Discord communities, conference talks.+7. **Defensibility analysis** — What moats exist for testing-specific AI companies? Data, workflow, integration, brand, switching costs?+8. **Contrarian: wrappers win** — Arguments for why vertical AI companies might actually INCREASE in value as models commoditize++## Runtime Expectations+- Phase 1: ~2 minutes (decomposition + user confirmation)+- Phase 2: ~5-10 minutes (parallel research, longest agent determines total time)+- Phase 3: ~3-5 minutes (synthesis)+- Total: ~10-15 minutes for a comprehensive strategic analysis++## Error Handling++- If a research thread returns low-quality results, note this in the synthesis rather than fabricating depth+- If WebSearch/WebFetch fails for a thread, retry once with alternative search terms, then document the gap+- The user may interrupt during Phase 2 to redirect or add threads+- The skill can be run multiple times on related questions — reference previous research files from `05-knowledge/research/`++## Fallback Behavior++This skill requires WebSearch and WebFetch tools. If these are unavailable:+- Fall back to vault-only analysis using existing `05-knowledge/` content+- Clearly state that no live web research was performed+- Recommend the user run the skill again when web tools are availablediff --git a/skills/braindump/SKILL.md b/skills/braindump/SKILL.mdnew file mode 100644index 0000000..8557505--- /dev/null+++ b/skills/braindump/SKILL.md@@ -0,0 +1,354 @@+---+name: braindump+description: Quick capture of raw thoughts with intelligent domain classification and competitive intelligence extraction+roles: [all]+integrations: []+---++# COG Braindump Skill++## Purpose+Transform raw thoughts into strategic intelligence through quick capture, systematic analysis, pattern recognition, and domain-aware insight extraction with minimal user friction.++## When to Invoke+- User wants to capture stream-of-consciousness thoughts+- User says "braindump", "brain dump", "capture thoughts", or "write down ideas"+- User has ideas they want to quickly record+- User mentions wanting to get thoughts out of their head++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — delegate research, analysis, and writing subtasks to specialist sub-agents (e.g., use Task tool to delegate deep analysis, competitive intel extraction, or pattern recognition to separate agents). Combine results before presenting to user.+- If `agent_mode: solo` (default) — handle everything directly in the conversation. No delegation.++## Pre-Flight Check++**Before executing, check for user profile:**++1. Look for `00-inbox/MY-PROFILE.md` in the vault+2. If NOT found:+ ```+ Welcome to COG! It looks like this is your first time.++ Before we start, let's quickly set up your profile (takes 2 minutes).++ Would you like to run onboarding first, or should I proceed with default settings?+ ```+3. If found:+ - Read the profile to get user's name and active projects+ - If user has active projects listed, offer them as domain options+ - Use user's name for friendly communication+ - Read `03-professional/COMPETITIVE-WATCHLIST.md` if it exists for competitive intelligence detection++**Get current timestamp (REQUIRED before generating any files):**++1. Run `date '+%Y-%m-%d %H:%M'` using Bash to get the actual current date and time+2. Store this value and use it for ALL timestamp fields (`created:` frontmatter AND filename `HHMM` component)+3. NEVER guess or fabricate the time — always use the value returned by the `date` command++## Process Flow++### 1. User Interaction & Input Collection+- Greet user warmly (use their name from MY-PROFILE.md if available)+- Ask: "What's on your mind?" or "Ready for a brain dump?"+- Collect their stream-of-consciousness input (can be long, rambling, voice-to-text, etc.)+- Accept any format - no judgment, no filtering++### 2. Domain Classification+Ask user to classify or auto-detect based on content:++**If user profile exists with projects:**+- **Personal:** Individual growth, relationships, wellness+- **Professional:** Work, leadership, career development+- **Project-Specific:** Related to specific projects+ - If MY-PROFILE.md lists projects, offer: "Which project? [list project names]"+ - Example: "Which project? (1) SaaS Product, (2) Book Writing, (3) Health App"+- **Mixed/Unclear:** Spans multiple areas++**If no profile:** Use standard personal/professional/mixed classification++### 3. Content Analysis and Processing++Apply the comprehensive analysis framework directly:++#### Phase 1: Content Ingestion+Analyze the input to understand:+- **Content Type:** [voice-transcript|written-notes|mixed]+- **Length:** [word-count]+- **Energy Level:** [high|medium|low]+- **Emotional Tone:** [excited|frustrated|curious|concerned|neutral|mixed]+- **Context:** [situational-background]++#### Phase 2: Structural Analysis+Extract and identify:+- **Main Themes:** [3-5 primary topics]+- **Supporting Ideas:** [related concepts and details]+- **Questions Raised:** [explicit and implicit questions]+- **Decisions Contemplated:** [choices being considered]+- **Action Items:** [tasks and commitments identified]++#### Phase 3: Domain Classification (with confidence)+Determine:+- **Primary Domain:** [personal|professional|project-specific] with confidence level+- **Secondary Domains:** [if content spans multiple areas]+- **Cross-Domain Elements:** [themes that apply across domains]+- **Privacy Considerations:** [sensitive content requiring protection]++#### Phase 4: Strategic Insight Extraction+Identify:+- **Key Insights:** [3-5 most important realizations]+- **Pattern Recognition:** [connections to previous thoughts/decisions]+- **Strategic Implications:** [what this means for goals and priorities]+- **Decision Framework:** [how this informs future choices]++#### Phase 5: Competitive Intelligence Detection+If COMPETITIVE-WATCHLIST.md exists:+- Scan braindump content for mentions of tracked companies/people+- Extract competitive intelligence to separate files+- Create cross-references back to original braindump++### 4. Generate Structured Output++Create braindump file with this structure:++```markdown+---+type: "braindump"+domain: "[personal|professional|project-specific|mixed]"+project: "[project-name]" # Only if project-specific+date: "YYYY-MM-DD"+created: "YYYY-MM-DD HH:MM"+themes: ["theme1", "theme2", "theme3"]+tags: ["#braindump", "#raw-thoughts", "#domain-tag"]+status: "captured"+energy_level: "[high|medium|low]"+emotional_tone: "[primary-emotion]"+confidence: "[high|medium|low]"+---++# Braindump: [Auto-generated descriptive title]++## Raw Thoughts+[Original user content preserved exactly as provided]++## Content Analysis++### Main Themes+1. **Theme 1:** [description and significance]+2. **Theme 2:** [description and significance]+3. **Theme 3:** [description and significance]++### Supporting Ideas+- [Supporting concept 1]+- [Supporting concept 2]+- [Supporting concept 3]++### Questions Raised+- [Question 1 for deeper exploration]+- [Question 2 requiring consideration]++### Decisions Contemplated+- [Decision 1 being considered with options]+- [Decision 2 under evaluation]++## Strategic Intelligence++### Key Insights+1. **Insight 1:** [description and implications]+2. **Insight 2:** [description and implications]+3. **Insight 3:** [description and implications]++### Pattern Recognition+- **Connection to Previous Thinking:** [links to earlier braindumps or frameworks]+- **Recurring Patterns:** [themes that keep appearing]+- **Evolution:** [how thinking has developed]++### Strategic Implications+- [How this affects goals]+- [Impact on current projects]+- [Decision-making considerations]++## Action Items++**Note:** Calculate actual due dates from today's date and append Obsidian Tasks emoji format.++### Immediate (24-48 hours)+- [ ] [specific action] 📅 [YYYY-MM-DD = tomorrow's date]++### Short-term (1-2 weeks)+- [ ] [specific action] 📅 [YYYY-MM-DD = date +1 week from today]++### Strategic Considerations+- [longer-term implications and considerations]++## Connections+- **Related Braindumps:** [[link1]], [[link2]]+- **Relevant Projects:** [[project1]], [[project2]]+- **Knowledge Base:** [[insight1]], [[framework1]]++## Domain Classification+- **Primary Domain:** [domain] ([confidence]%)+- **Reasoning:** [why this classification]+- **Cross-Domain Elements:** [if applicable]+- **Privacy Level:** [public|private|confidential]++## Processing Notes+### Emotional Context+- **Energy Level:** [assessment]+- **Emotional Tone:** [assessment]+- **Implications:** [what this suggests]++### Confidence Assessment+- **Overall Analysis:** [percentage] - [reasoning]+- **Domain Classification:** [percentage] - [reasoning]+- **Strategic Insights:** [percentage] - [reasoning]+- **Areas Requiring Clarification:** [specific questions if needed]++---++*Processed by COG Brain Dump Analyst*+```++Save to appropriate location:+- **Personal:** `02-personal/braindumps/braindump-YYYY-MM-DD-HHMM-<slug>.md`+- **Professional:** `03-professional/braindumps/braindump-YYYY-MM-DD-HHMM-<slug>.md`+- **Project:** `04-projects/[project-slug]/braindumps/braindump-YYYY-MM-DD-HHMM-<slug>.md`+- **Mixed:** `00-inbox/braindump-YYYY-MM-DD-HHMM-<slug>.md`++### 5. Competitive Intelligence Extraction++If competitive intelligence detected (mentions of companies/people from watchlist):++Create/update: `04-projects/[project]/competitive/[company-slug].md`++```markdown+---+type: "competitive-intelligence"+company: "[Company Name]"+project: "[project-name]"+last_updated: "YYYY-MM-DD"+sources: ["braindump"]+tags: ["#competitive", "#intelligence", "#[company-slug]"]+---++# Competitive Intelligence: [Company Name]++## Latest Update - [Date]+**Source:** [[braindump-file-reference]]++[Extracted competitive intelligence from braindump]++## Previous Intelligence+[Historical intel from earlier braindumps]++## Strategic Implications+[Analysis of what this means for the project]++## Action Items+- [ ] [Follow-up actions based on intel] 📅 [YYYY-MM-DD = calculated due date]++---++*Auto-extracted by COG Brain Dump Analyst*+```++### 6. Confirm Completion+- Confirm file was created+- Show user: "Braindump saved to [file path]"+- Show quick summary of main themes identified+- If competitive intel extracted, mention: "Also extracted competitive intelligence to [file path]"++## YAML Formatting Requirements++**CRITICAL:** All YAML frontmatter must use proper Obsidian-compatible formatting:+- All string values MUST be quoted with double quotes+- Arrays MUST use quoted strings: `["item1", "item2", "item3"]`+- Boolean values should NOT be quoted: `true` or `false`+- Numbers should NOT be quoted unless they are string identifiers+- Ensure proper YAML syntax to prevent parsing errors in Obsidian++**Examples:**+```yaml+# CORRECT+type: "braindump"+themes: ["automation", "testing", "ui-improvements"]+analysis_needed: true++# INCORRECT+type: braindump+themes: [automation, testing, ui-improvements]+analysis_needed: "true"+```++## Verification Protocols++### Content Accuracy+- **Interpretation Verification:** Confirm understanding matches intent+- **Context Validation:** Ensure situational context is accurately captured+- **Emotional Accuracy:** Verify emotional tone and energy level assessment+- **Completeness Check:** Confirm all major themes are identified++### Domain Classification Verification+- **Boundary Clarity:** Ensure domain classification is clear and defensible+- **Privacy Protection:** Verify personal content is properly protected+- **Cross-Domain Value:** Confirm cross-domain insights are valuable and appropriate+- **Classification Confidence:** State confidence level for domain assignments++### Strategic Insight Validation+- **Evidence-Based:** Ensure insights are supported by content evidence+- **Actionability:** Verify recommendations are specific and implementable+- **Priority Accuracy:** Confirm priority assessments align with stated goals+- **Timeline Realism:** Ensure recommended timelines are achievable++## Uncertainty Handling++### When to Request Clarification+- **Ambiguous Domain Classification:** Content could belong to multiple domains+- **Unclear Strategic Implications:** Insights have multiple possible interpretations+- **Conflicting Information:** Content contains contradictory elements+- **Missing Context:** Important background information seems to be missing++### Confidence Indicators+- **High Confidence (90%+):** Clear content with obvious domain and implications+- **Medium Confidence (70-89%):** Generally clear with some ambiguous elements+- **Low Confidence (50-69%):** Significant ambiguity requiring user input+- **Very Low Confidence (<50%):** Major uncertainty requiring clarification++Always explicitly state confidence levels and reasoning in the processing notes.++## Integration with Other Skills++### Immediate Follow-up+After braindump, suggest:+- Review patterns across multiple braindumps+- Weekly check-in to reflect on themes+- Knowledge consolidation to build frameworks++### Competitive Intelligence+If competitive mentions detected:+- Automatically update competitive files+- Mention this in the output+- Provide link to competitive intelligence file++## Success Metrics+- Speed of capture (minimize user friction)+- Accurate domain classification+- File saved to correct location+- User feels heard and understood+- Competitive intel auto-extracted when relevant+- High confidence in analysis accuracy++## Learning and Adaptation++### Pattern Learning+- Learn user's thinking patterns and communication style+- Understand user's specific domain separation preferences+- Recognize what types of insights user finds most valuable+- Learn which recommendations user typically implements++### Continuous Improvement+- Track accuracy of insights and recommendations over time+- Monitor user engagement with and implementation of recommendations+- Improve speed and accuracy of analysis through learning+- Refine analysis frameworks based on effectivenessdiff --git a/skills/closed-loop/SKILL.md b/skills/closed-loop/SKILL.mdnew file mode 100644index 0000000..2717dad--- /dev/null+++ b/skills/closed-loop/SKILL.md@@ -0,0 +1,117 @@+---+name: closed-loop+description: >+ V-model execute: CP-2 plan → CP-3 build → CP-3v component verify →+ CP-4 integration verify (full) → CP-5 acceptance. Worker never grades+ its own homework; evidence rows trace back to AC-n. Use via /execute.+---++# Closed-loop execute (V-model right arm)++Mechanical verification pipeline. Every verify step emits **evidence rows** tied to acceptance criterion IDs (`AC-n`).++## When to use++- `/execute <task>` or `/execute <spec-path>`+- Any skill at `normal`+ lane after implementation+- Code changes, deploys, multi-step vault deliverables++## Phase 0 — Lane + run folder++```bash+bash .claude/lib/lane-classify.sh explain "<task>"+bash .claude/lib/checkpoint.sh init 04-projects/harness/runs/<YYYY-MM-DD-HHmm>+```++| Lane | Checkpoints |+|---|---|+| `tiny` | CP-3 → CP-5 (if mutating) |+| `normal` | CP-1 → CP-2 → CP-3 → CP-3v → CP-5 |+| `full` | + CP-4 + claim-verifier + CP-6 |+| `bug` | root-cause ledger (CP-0) before CP-3 |++Record: `checkpoint.sh record <run-dir> CP-0 PASS|SKIP "<lane>"`++## Phase 1 — CP-1 Spec (acceptance criteria)++If spec exists, use its `## Acceptance criteria` + traceability matrix. Else write:++`04-projects/harness/runs/<id>/criteria.md` using `04-projects/harness/templates/SPEC-template.md` (criteria + matrix only).++Each criterion: **falsifiable** + `AC-n` ID + verify method.++Record: `checkpoint.sh record <run-dir> CP-1 PASS "N criteria"`++## Phase 2 — CP-2 Plan++Map tasks → AC IDs in `evidence/CP-2-plan.md`. Update matrix status to `pending`.++Record: `checkpoint.sh record <run-dir> CP-2 PASS`++## Phase 3 — CP-3 Build++Worker implements. Returns deliverable path only.++## Phase 4 — CP-3v Component verify++```+retry=0+loop:+ spawn task-verifier (fresh context, read-only)+ merge EVIDENCE rows into evidence/ledger.md+ if PASS → break+ if FAIL:escalate → record CP-3v FAIL, escalate+ if FAIL:fixable && retry < 2 → fix-agent → retry+++ else → escalate+```++Copy verifier EVIDENCE rows into `evidence/CP-3v-component.md`.++Record: `checkpoint.sh record <run-dir> CP-3v PASS|FAIL`++## Phase 5 — CP-4 Integration verify (`full` or multi-task)++Spawn `integration-verifier` (read-only). Append rows to ledger.++Skip for single-task `normal`.++Record: `checkpoint.sh record <run-dir> CP-4 PASS|SKIP`++## Phase 6 — CP-5 Acceptance (post-condition)++For each mutation, observe artifact (curl, screenshot, re-fetch). Emit:++`EVIDENCE AC-n | CP-5 | PASS | <observation> | <artifact>`++**UI/UX flow changes:** the post-condition is *visual*. Capture with browser-harness (`evidence_shot` per state; `FlowRecorder`→`.save_gif()` for a flow; `pixel_diff` against the intended/prior state), then read the image and confirm no overflow/misalignment/clipping/wrong-color/broken-responsive before PASS. The Observation must describe what you saw; the artifact is the screenshot/GIF in `evidence/`. Fix any visual defect and re-capture. See CLAUDE.md → Visual Verification.++Write `evidence/CP-5-acceptance.md`. **Traceability closure**: every AC in matrix has ≥1 PASS row in ledger.++Record: `checkpoint.sh record <run-dir> CP-5 PASS|FAIL`++## Phase 7 — Record + handoff++- Append to `.claude/logs/loop-ledger.tsv`+- Update spec traceability matrix statuses to `verified`+- **`full` lane / big task:** generate an HTML rollup from `04-projects/harness/templates/report.html` → `04-projects/harness/runs/<id>/report.html`, filled from `criteria.md` + `evidence/ledger.md` (criteria, AC traceability, verifier verdicts, post-condition observations). Self-contained; `SendUserFile` it or publish as an Artifact. Skip for `normal`/`tiny`.+- Suggest `/retro <run-dir>` for CP-7++## Integration++| Skill | Lane | CP-4 |+|---|---|---|+| ultragoal | `full` per phase (never downgraded) | integration-verifier + north-star acceptance |+| team-brief | full | claim-verifier |+| dogfood-release | full | Playwright cross-verify |+| blog-publish | normal | skip |+| content-factory | normal | skip |++## Escalation template++```+ESCALATED — <task>+Lane: <lane> | Last CP: <CP-n>+Evidence bundle: 04-projects/harness/runs/<id>/evidence/+Open AC IDs: <list without PASS rows>+Decision needed: <one question>+```diff --git a/skills/comprehensive-analysis/SKILL.md b/skills/comprehensive-analysis/SKILL.mdnew file mode 100644index 0000000..d244d67--- /dev/null+++ b/skills/comprehensive-analysis/SKILL.md@@ -0,0 +1,351 @@+---+name: comprehensive-analysis+description: Deep-dive 7-day analysis across all data sources for weekly reviews, board prep, and strategic planning+roles: [product-manager, engineering-lead, founder]+integrations: [github, linear, slack, posthog]+---++# COG Comprehensive Analysis Skill++## When to Invoke+- User wants a weekly review or retro prep+- User says "weekly analysis", "comprehensive review", "board prep", "deep dive"+- User needs analysis across a longer time period (7+ days)+- User wants a full picture of team/product health++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use the full parallel agent execution strategy below (5 agents). This skill benefits greatly from team mode.+- If `agent_mode: solo` — run a lighter version: collect GitHub + Linear data sequentially, skip PostHog deep analysis, produce a single combined report instead of 3 documents.++## Purpose+Generate a deep-dive analysis across all data sources for weekly reviews, board prep, strategic planning, or any time you need the full picture. Unlike the team brief (which optimizes for speed and daily relevance), this skill intentionally pulls more data and spends more time synthesizing.++**Use this when:**+- Weekly team review / retro prep+- Board meeting or leadership update prep+- Strategic planning sessions+- Investigating a specific problem across all data sources+- Monthly/quarterly health check++**Don't use this daily** — it takes 8-12 minutes and pulls heavy payloads. Use `/daily-brief` for everyday intel.++## Command: `/comprehensive-analysis`++## Voice & Tone++Same as the daily brief — direct, opinionated, teammate energy. But with more depth and nuance. You're writing for a product leader who needs to make decisions, not just stay informed.++---++## Execution Strategy++### Phase 1: Deep Data Collection (~3-5 min)++**Launch ALL agents in parallel using the Task tool with `run_in_background: true`.**++#### Agent 1: "github-deep-analyst" (subagent_type: general-purpose)+```+Deep GitHub analysis for [CUSTOMIZE: your-org/your-repo].+Analysis period: last 7 days (from [7_DAYS_AGO] to [TODAY]).++Collect:+1. ALL PRs merged in the last 7 days:+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state merged --search "merged:>=[7_DAYS_AGO]" --json number,title,author,mergedAt,labels,additions,deletions --limit 100++2. ALL open PRs with full detail:+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state open --json number,title,author,createdAt,reviewDecision,labels,updatedAt,additions,deletions --limit 100++3. Contributor activity breakdown:+ For each contributor, count: PRs merged, PRs opened, commits, review comments given.+ gh api repos/[CUSTOMIZE: your-org/your-repo]/stats/contributors++4. Code frequency (additions/deletions per week):+ gh api repos/[CUSTOMIZE: your-org/your-repo]/stats/code_frequency++5. Commit activity by day:+ gh api repos/[CUSTOMIZE: your-org/your-repo]/stats/commit_activity++6. ALL PR review comments from the last 7 days:+ gh api repos/[CUSTOMIZE: your-org/your-repo]/pulls/comments --paginate --jq '[.[] | select(.created_at >= "[7_DAYS_AGO]")]'++DEEP ANALYSIS:+A) **Contributor Velocity Matrix**: For each contributor — PRs merged, lines changed, review comments given/received. Who's shipping? Who's reviewing? Who's doing both?+B) **Code Churn**: Are we rewriting the same files repeatedly? Flag files with >3 PRs touching them in one week.+C) **PR Lifecycle**: Average time from PR open → first review → merge. Where's the bottleneck?+D) **Review Quality**: Are reviews substantive (comments with suggestions) or rubber stamps (approved with no comments)?+E) **Week-over-Week Trends**: Compare this week's velocity to last week. Accelerating or decelerating?+F) **Technical Debt Signals**: Large PRs with no tests, PRs that touch >10 files, dependency-only PRs.++Return structured data AND insights.+```++#### Agent 2: "slack-deep-monitor" (subagent_type: general-purpose)+*Only spawn if Slack MCP is available*+```+Deep Slack analysis for last 7 days across key channels.+Analysis period: [7_DAYS_AGO] to [TODAY].++Instructions:+1. Use ToolSearch to load Slack tools+2. Read messages from [CUSTOMIZE: your-team-channel] for the full 7-day window+3. If you have access, also check: [CUSTOMIZE: additional-channels] (e.g., #general, #engineering, #product)++For EACH significant thread (>3 replies or involving decisions):+- Full topic summary+- Key participants+- Decision reached (or explicitly: "no decision reached")+- Action items with owners+- Sentiment (positive/negative/neutral/heated)+- Links to external resources shared++DEEP ANALYSIS:+A) **Communication Patterns**: Who's driving discussions? Who's mostly silent? Any asymmetry?+B) **Decision Velocity**: How many decisions were made vs. how many discussions ended without resolution?+C) **Topic Clustering**: Group discussions by theme (product, engineering, bugs, strategy, etc.)+D) **Unresolved Threads**: List all discussions that need follow-up — no decision, open question, blocked waiting for someone+E) **Sentiment Map**: Overall team mood. Are discussions constructive or frustrated?+F) **External Intel**: All links shared (articles, competitor news, tools) — categorize by relevance++Return structured data AND insights.+```++#### Agent 3: "linear-deep-tracker" (subagent_type: general-purpose)+*Only spawn if Linear MCP is available*+```+Deep Linear analysis for last 7 days.+Analysis period: [7_DAYS_AGO] to [TODAY].++Instructions:+1. Use ToolSearch to load ALL Linear tools+2. Collect comprehensive data:++ a) All issues updated in last 7 days (mcp__claude_ai_Linear__list_issues)+ b) All issues created in last 7 days+ c) All issues completed in last 7 days+ d) All blocked issues (any date)+ e) Full initiative list with projects (mcp__claude_ai_Linear__list_initiatives)+ f) Detailed status for each initiative (mcp__claude_ai_Linear__get_initiative)+ g) All active cycles (mcp__claude_ai_Linear__list_cycles)+ h) All milestones for active projects (mcp__claude_ai_Linear__list_milestones)+ i) All projects with progress (mcp__claude_ai_Linear__list_projects)+ j) Recent status updates (mcp__claude_ai_Linear__get_status_updates) for each initiative++DEEP ANALYSIS:+A) **Initiative Trajectory**: For each initiative, model whether current velocity will hit the target date. Use issues_completed_per_week vs. issues_remaining / weeks_remaining.+B) **Cycle History**: Compare current cycle progress to previous cycles. Are we improving?+C) **Scope Creep Quantified**: How many issues were added mid-cycle vs. planned at start?+D) **Priority Drift**: Issues that changed priority during the week. Why?+E) **Assignee Load Balance**: Distribution of issues across team members. Overloaded? Underutilized?+F) **Stale In-Progress**: Issues marked "In Progress" for >5 days with no status change.+G) **Dependency Map**: Issues that block other issues. What's the critical path?+H) **Label/Project Distribution**: Where is effort being spent? Does it align with initiative priorities?++Return structured data AND insights.+```++#### Agent 4: "posthog-deep-analyst" (subagent_type: general-purpose)+*Only spawn if PostHog MCP is available*++> **WARNING: PostHog can return very large payloads.** This agent is intentionally heavy — it's the reason this skill takes longer than the daily brief. Scope queries carefully.++```+Deep PostHog analysis for last 7 days.+Project ID: [CUSTOMIZE: your-posthog-project-id].+Analysis period: [7_DAYS_AGO] to [TODAY].++Instructions:+1. Use ToolSearch to load PostHog tools (search "+posthog")+2. Run these analyses:++ === CORE METRICS (7-day window) ===++ a) Daily visitors, sign-ups, and core events — broken out by day:+ Use mcp__posthog__query-run with HogQL:+ SELECT toDate(timestamp) as day, count(DISTINCT person_id) as unique_users, count() as events+ FROM events WHERE event = '$pageview' AND timestamp >= '[7_DAYS_AGO]'+ GROUP BY day ORDER BY day++ b) Same for sign-ups and core value events (separate queries)++ c) Week-over-week comparison:+ Compare [7_DAYS_AGO to TODAY] vs [14_DAYS_AGO to 7_DAYS_AGO]++ === FUNNEL ANALYSIS ===++ d) Key funnel (sign-up → first core action → repeat):+ Use mcp__posthog__insight-query or HogQL to build a funnel:+ - Step 1: user_signed_up+ - Step 2: [CUSTOMIZE: your_core_event] (first time)+ - Step 3: [CUSTOMIZE: your_core_event] (second time, >24h later)+ Compare this week's funnel to last week's.++ === FEATURE ADOPTION ===++ e) Feature usage matrix:+ SELECT event, count() as uses, count(DISTINCT person_id) as unique_users+ FROM events WHERE timestamp >= '[7_DAYS_AGO]' AND event NOT LIKE '$%'+ GROUP BY event ORDER BY unique_users DESC LIMIT 25++ f) New vs returning user behavior:+ Compare event types for users whose first_seen is within last 7 days vs. older users.++ === ERROR ANALYSIS ===++ g) Error trends:+ Use mcp__posthog__list-errors for the period. Group by error type.++ h) Error-to-deploy correlation:+ For each error spike, check the timestamp against known deploy times (from GitHub merged PR data).++DEEP ANALYSIS:+A) **Growth Trajectory**: At current rate, where will key metrics be in 30/60/90 days?+B) **Funnel Health**: Where do users drop off? Has it improved or degraded vs last week?+C) **Feature Value Matrix**: Which features correlate with retention? (users who use feature X come back more)+D) **New User Experience**: First-session behavior patterns. What do new users do? Where do they get stuck?+E) **Error Impact**: Which errors affect the most users? Which are increasing fastest?+F) **Engagement Segments**: Power users vs casual vs churned. How big is each segment?++Return structured data AND insights with trends.+```++#### Agent 5: "meeting-deep-reviewer" (subagent_type: general-purpose)+```+Review ALL meeting notes from the last 7 days.+Analysis period: [7_DAYS_AGO] to [TODAY].++Instructions:+1. Glob for ALL meeting files in [CUSTOMIZE: path/to/meetings/] from the last 7 days+2. Also check [CUSTOMIZE: path/to/checkins/] for daily checkins+3. Read all found files++For EACH meeting, extract the same items as the daily brief agent.++DEEP ANALYSIS:+A) **Action Item Completion Rate**: Of all action items assigned in meetings this week, how many have corresponding GitHub/Linear activity?+B) **Decision Log**: Comprehensive list of every decision made this week, with context and who made it.+C) **Priority Shifts**: Did priorities change during the week? Track what was said Monday vs. Friday.+D) **Commitment Tracking**: Did people do what they said they'd do? (Cross-reference with GitHub/Linear data)+E) **Meeting Effectiveness**: Are meetings producing decisions and action items, or just discussion?++Return structured data AND insights.+```++### Phase 2: Deep Synthesis (~2-3 min)++After all agents complete, the orchestrator performs deep cross-referencing:++1. **All 23 cross-reference patterns from the daily brief** (see daily-brief.md)++2. **Additional comprehensive patterns:**+ - **Week-over-week velocity trend**: Is the team accelerating or decelerating? Why?+ - **Initiative trajectory modeling**: At current pace, will each initiative hit its target? What needs to change?+ - **Team capacity assessment**: Based on actual output this week, what's realistic for next week?+ - **Risk register**: Compile all risks from all sources into a unified risk register with severity/likelihood/owner+ - **Strategic alignment check**: Is what the team is building aligned with what leadership discussed in meetings?+ - **Product-market signal synthesis**: Combine PostHog data + Slack user feedback + meeting customer discussions into a coherent product signal++3. **Generate three output documents:**++#### Output 1: Executive Summary (for leadership)+- 1-page max+- Key metrics with trends+- Initiative health dashboard+- Top 3 risks+- Top 3 wins+- Recommendation for next week's focus++#### Output 2: Team Report (for engineering)+- What shipped this week (celebrate!)+- Velocity and contributor stats+- Review health (bottlenecks, rubber stamps)+- Stale PRs and blocked issues+- Technical debt signals+- Next week's priorities from meetings++#### Output 3: Product Report (for stakeholders)+- User metrics with trends+- Funnel analysis+- Feature adoption+- Customer feedback synthesis (from Slack)+- Growth trajectory+- Product risks and opportunities++4. **Save** all three to `[CUSTOMIZE: path/to/briefs/]`:+ - `comprehensive-analysis-YYYY-MM-DD.md` (full report)+ - `executive-summary-YYYY-MM-DD.md` (leadership version)+ - `product-report-YYYY-MM-DD.md` (stakeholder version)++### Phase 3: Output & Distribution (~1-2 min)++1. Present the executive summary to the user+2. Offer to publish to HackMD (same pattern as daily brief Phase 3.7)+3. Offer to post highlights to Slack (same pattern as daily brief Phase 4)++---++## Metadata Template++```yaml+---+type: comprehensive-analysis+domain: shared+date: YYYY-MM-DD+analysis_period:+ start: YYYY-MM-DD+ end: YYYY-MM-DD+ days: 7+created: YYYY-MM-DD HH:MM+tags:+ - comprehensive-analysis+ - weekly-review+ - team-intelligence+data_sources:+ github: true+ slack: true/false+ linear: true/false+ posthog: true/false+ meetings: true/false+ braindumps: true/false+metrics:+ prs_merged: X+ prs_opened: X+ commits: X+ active_contributors: X+ issues_completed: X+ issues_created: X+ visitors: X+ visitors_wow_change_pct: X+ signups: X+ core_events: X+ new_errors: X+initiatives:+ - name: "[CUSTOMIZE: Initiative 1]"+ health: on_track / at_risk / off_track+ progress_pct: X+ trajectory: will_hit / at_risk / will_miss+ days_remaining: X+team_velocity:+ this_week: X # PRs merged+ last_week: X+ trend: accelerating / stable / decelerating+risks:+ - severity: high/medium/low+ description: ""+ owner: ""+ source: ""+---+```++## Fallback Behavior++Same as daily brief — each data source is optional. The analysis degrades gracefully.++The minimum useful configuration is **GitHub only** — you'll still get velocity analysis, PR lifecycle metrics, contributor stats, and code churn detection.++## Error Handling++Same safety rules as the daily brief, with one addition:++- **Context overflow protection**: If any agent returns data that seems too large (>50k tokens estimated), log a warning and ask the agent to summarize more aggressively. This is most likely to happen with PostHog (large dashboard dumps) or Jira (broad JQL queries).diff --git a/skills/content-factory/SKILL.md b/skills/content-factory/SKILL.mdnew file mode 100644index 0000000..3aec376--- /dev/null+++ b/skills/content-factory/SKILL.md@@ -0,0 +1,91 @@+---+name: content-factory+description: Autonomous content pipeline - scout announcements in your field, triage by trend momentum and personal angle, produce posts/blogs/videos in your voice with ledger-based dedup, hard volume caps, and screenshot-verified publishing+roles: [all]+integrations: [web-search, web-fetch]+---++# COG Content Factory Skill++## Purpose++Act as the user's autonomous content creator: scout what just happened in their field, pick what is genuinely trending, and turn it into content in their voice — with zero duplicates, hard volume caps, and verification before anything counts as published. Designed to run unattended on a schedule (nightly) and to be safely re-runnable: **an empty run is a valid run; a low-quality post is not.**++## When to Invoke++- `/content-factory` / "run the content factory"+- Scheduled runs (e.g. 2-4 times a night via cron/launchd)+- "Turn today's news into content"++## Prerequisites++Reads the user's voice and beats from `00-inbox/MY-PROFILE.md` and topics from `00-inbox/MY-INTERESTS.md`. Publishing targets come from `00-inbox/MY-INTEGRATIONS.md` — skip disabled channels silently.++## State Files (read FIRST, update LAST — this is the dedup backbone)++- `04-projects/content-factory/ledger.md` — everything ever covered/published (topic slug, source URL, formats, links, date). NEVER cover a topic or source URL already in the ledger unless there is genuinely NEW news (a follow-up release counts; rephrasing the same launch does not).+- `04-projects/content-factory/tonight-<YYYY-MM-DD>.md` — tonight's run log (create on first run of the night). Records what earlier runs scouted, parked, produced, and published, plus the remaining volume budget.+- `04-projects/content-factory/sources.md` — the watchlist. Add sources you find valuable; prune dead ones.++## Volume Budget (across ALL runs of one night, hard caps)++| Channel | Max/night | Notes |+|---------|-----------|-------|+| Short social posts/threads | 2 | the volume channel; a thread counts as 1 |+| Blog post | 1 | only when substance justifies it |+| Short video | 1 | only if the idea is visual/demo-able |+| Long-form professional post | 1 | only for a strong professional angle |+| Long video / deep essay | 0 | never autonomous; propose in the run log |++Track the budget in the tonight file. Later runs inherit what is left. Adjust caps to taste — the invariant is that caps exist and are enforced across runs, not per run.++## Phase 1 — SCOUT (every run)++1. Web-search for last-24h announcements across the user's watchlist topics, plus anything already trending.+2. Fetch the watchlist blogs/changelogs in `sources.md`.+3. If a browser integration is available, skim the user's social feeds for engagement signals — raw engagement numbers are the best trend signal.+4. Timebox scouting to ~20 minutes of work.++## Phase 2 — TRIAGE (score, don't vibe)++Score each candidate 1-5 on:+- **(a) trend momentum** — are major accounts and aggregators talking about it NOW?+- **(b) beat fit** — does it fit one of the user's beats (from MY-PROFILE.md)?+- **(c) unique angle** — can we add something ONLY this user can add (an experiment, a practitioner take, a contrarian read) — not a summary anyone could write?++Sum ≥11 → produce. 8-10 → park in the tonight file for a later run to re-score. <8 → ignore.++Dedup check before producing: topic slug + source URL against the ledger AND against the user's recent published posts (last ~20) if reachable.++## Phase 3 — PRODUCE (format ladder — decide by substance, not ambition)++- **Default: one short post or thread** — hook line, media attached, link last, minimal hashtags.+- **Blog post** only when there are ≥3 original things to say or a real proof-of-concept with artifacts. If the user has a PoC beat: actually build the tiny PoC (timebox ~45 min) and publish the REAL result, including failures. Never fabricate PoC outcomes; "it broke here" is good content.+- **Short video** when the idea is visual or demo-able in ≤60s.+- Cross-link everything (video ↔ blog ↔ thread reference each other).++## Phase 4 — PUBLISH (safety gates)++1. **Environment gate**: if the publishing surface is unavailable, or the user appears to be actively using the browser/machine — DO NOT publish. Write finished bundles to `04-projects/content-factory/out/<date>/` and let a later run (or the user) publish.+2. **Post-condition check (mandatory)**: after every publish, observe the artifact — screenshot the live post, curl the live URL — before recording it as published. Never report success from the publish call alone.+3. Never engage in arguments, never quote-dunk, never reply to strangers. The factory only creates original posts on the user's own surfaces.+4. Any screenshot must pass a credentials check (no account emails, tokens, or internal URLs visible).+5. Never delete an already-engaged post; edit in place if a fix is needed.++## Phase 5 — LEDGER + LOG (always, even for empty runs)++- Append published items to `ledger.md`: `| date | slug | beat | formats | source URL | published links |`.+- Update `tonight-<date>.md`: scouted list, scores, parked items, budget left, what the next run should look at first.+- If a big announcement deserves long-form treatment the user should shape, write it as a proposal in the tonight file with a suggested outline — do not attempt it autonomously.++## Voice Checklist (delete the draft if any fail)++- [ ] Sounds like a builder sharing, not a news bot ("I tried", "I broke", "here's what surprised me")+- [ ] Contains at least one thing only this user could say (their setup, their numbers, their PoC, their lens)+- [ ] No AI-slop vocabulary ("game-changer", "revolutionary", "unleash"), no emoji walls, hashtags within caps+- [ ] Media attached; link present; nothing confidential+- [ ] Not a duplicate (ledger + recent posts checked)++## The Loop (see /loop-engineering)++Each night is a scan-until-budget-dry loop across runs: the tonight file is the shared loop state, the ledger is the dedup verifier, the volume budget is the hard cap, and the voice checklist is the quality gate. Termination: budget exhausted, nothing scores ≥11, or the environment gate blocks publishing.diff --git a/skills/create-user-story/SKILL.md b/skills/create-user-story/SKILL.mdnew file mode 100644index 0000000..e22a66f--- /dev/null+++ b/skills/create-user-story/SKILL.md@@ -0,0 +1,238 @@+---+name: create-user-story+description: Create user stories with duplicate checking across any project tracker (Linear, GitHub Issues, Jira)+roles: [product-manager, engineering-lead, founder]+integrations: [linear, github, jira]+---++# COG Create User Story Skill++## When to Invoke+- User wants to create a new user story, feature request, or issue+- User says "create story", "new story", "add issue", "write user story", "create ticket"+- User describes a feature or requirement that should be tracked++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use parallel agents to check for duplicates across all active trackers simultaneously, then create the story+- If `agent_mode: solo` — check duplicates and create the story sequentially in the main conversation++## Command: `/create-user-story`++## Pre-Flight Check++1. **Read `00-inbox/MY-INTEGRATIONS.md`** to determine which project trackers are active:+ - **Linear** — use Linear MCP tools+ - **GitHub** — use `gh` CLI+ - **Jira** — use `jira` CLI or Jira API via WebFetch+ - If NO tracker is active, save the story as a markdown file in `04-projects/[project]/stories/` and inform the user++2. **Read `00-inbox/MY-PROFILE.md`** to get:+ - Active projects (to determine which project/repo/board to target)+ - User's name (for story author attribution)++3. **Ask the user** (if not already provided):+ - What is the feature or requirement? (free-form description)+ - Which project does this belong to? (if multiple active projects)+ - Priority level? (optional — default to medium)++---++## Execution Strategy++### Phase 1: Understand the Request++Parse the user's input to extract:+- **Feature description** — what the user wants built+- **Target users** — who benefits from this+- **Problem statement** — what problem this solves+- **Project context** — which project this belongs to++If the user provides a brief description, ask clarifying questions before proceeding:+- Who is the target user for this feature?+- What problem does this solve?+- Are there any specific acceptance criteria you have in mind?++### Phase 2: Duplicate Check++**CRITICAL: Always check for duplicates before creating.**++#### Team Mode (parallel agents)++Launch duplicate-check agents in parallel using the Task tool with `run_in_background: true`:++**Agent: "duplicate-checker-linear"** (if Linear is active)+```+Search Linear for potential duplicate issues.+1. Use ToolSearch to load Linear tools+2. Use mcp__claude_ai_Linear_2__list_issues to search for issues with similar keywords+3. Search across all active projects/teams+4. Return any issues that match by title similarity or description overlap++Search terms: [extracted keywords from user's description]+Return: list of potential duplicates with title, status, URL, and similarity assessment+```++**Agent: "duplicate-checker-github"** (if GitHub is active)+```+Search GitHub Issues for potential duplicates.+Repository: [CUSTOMIZE: your-org/your-repo]++1. gh search issues "[keywords]" --repo [CUSTOMIZE: your-org/your-repo] --json number,title,state,url,body --limit 20+2. Also search closed issues to check if this was already done:+ gh search issues "[keywords]" --repo [CUSTOMIZE: your-org/your-repo] --state closed --json number,title,state,url --limit 10++Return: list of potential duplicates with title, status, URL, and similarity assessment+```++**Agent: "duplicate-checker-jira"** (if Jira is active)+```+Search Jira for potential duplicate issues.+Project: [CUSTOMIZE: YOUR-PROJECT-KEY]++1. Use WebFetch or jira CLI to search:+ JQL: project = "[CUSTOMIZE: YOUR-PROJECT-KEY]" AND text ~ "[keywords]" ORDER BY created DESC+2. Check both open and recently resolved issues++Return: list of potential duplicates with key, title, status, URL, and similarity assessment+```++#### Solo Mode (sequential)+Run the same duplicate checks sequentially for whichever tracker is active.++### Phase 3: Report Duplicates (if found)++If potential duplicates are found, present them to the user:++```+I found [N] potential duplicate(s):++1. **[TITLE]** ([STATUS]) — [URL]+ Similarity: [High/Medium/Low] — [reason]++2. **[TITLE]** ([STATUS]) — [URL]+ Similarity: [High/Medium/Low] — [reason]++Options:+a) These are different — proceed with creating the new story+b) This is a duplicate of #[N] — skip creation+c) This is related to #[N] — create and link them+```++**Wait for user confirmation before proceeding.**++### Phase 4: Format the User Story++Generate the story in standard user story format:++```markdown+## Title+[Concise, descriptive title]++## User Story+**As a** [type of user],+**I want** [goal/desire],+**So that** [benefit/value].++## Description+[Expanded description of the feature, including context and background]++## Acceptance Criteria++### Scenario 1: [Happy path scenario name]+- **Given** [precondition]+- **When** [action]+- **Then** [expected outcome]++### Scenario 2: [Alternative scenario name]+- **Given** [precondition]+- **When** [action]+- **Then** [expected outcome]++### Scenario 3: [Edge case or error scenario name]+- **Given** [precondition]+- **When** [action]+- **Then** [expected outcome]++## Technical Notes+[Any implementation hints, constraints, or dependencies — if applicable]++## Out of Scope+[What this story explicitly does NOT cover — helps prevent scope creep]+```++**Present the formatted story to the user for review before creating it.**++### Phase 5: Create in Tracker++After user approves the story content:++#### Linear+```+1. Use ToolSearch to load Linear tools+2. Use mcp__claude_ai_Linear_2__get_team to find the target team+3. Use mcp__claude_ai_Linear_2__list_issue_labels to find appropriate labels+4. Use mcp__claude_ai_Linear_2__save_issue to create the issue with:+ - title: [story title]+ - description: [full story in markdown]+ - team: [target team]+ - priority: [user-specified or default medium]+ - labels: [appropriate labels]+```++#### GitHub Issues+```+gh issue create \+ --repo [CUSTOMIZE: your-org/your-repo] \+ --title "[story title]" \+ --body "[full story in markdown]" \+ --label "[appropriate labels]"+```++#### Jira+```+Use WebFetch to POST to Jira REST API or use jira CLI:+- Project: [CUSTOMIZE: YOUR-PROJECT-KEY]+- Issue Type: Story+- Summary: [story title]+- Description: [full story in markdown/Jira wiki format]+- Priority: [user-specified or default Medium]+- Labels: [appropriate labels]+```++#### Vault Fallback (no tracker active)+Save to `04-projects/[project]/stories/story-YYYY-MM-DD-[slug].md`++### Phase 6: Confirm and Link++1. Confirm creation with the user:+ ```+ Story created: **[TITLE]**+ [URL or file path]+ Priority: [priority]+ Labels: [labels]+ ```++2. If the user indicated this is related to another issue (Phase 3, option c), create a link/relation between them.++3. Also save a local copy to `04-projects/[project]/stories/` for vault reference.++---++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| No tracker active | Save as markdown in `04-projects/[project]/stories/` |+| Tracker API fails | Save locally, warn user, suggest manual creation with the formatted content |+| Duplicate check fails | Warn user that duplicate check was skipped, proceed with creation after confirmation |+| User doesn't specify project | List active projects from MY-PROFILE.md and ask which one |+| User provides minimal input | Ask clarifying questions to build a complete story |++## Error Handling++- **API rate limits**: Wait and retry once, then fall back to local save+- **Authentication failures**: Inform user their integration may need re-authentication+- **Large search results**: Limit duplicate check to top 10 most relevant matches+- **Context overflow**: Summarize duplicate results rather than showing full descriptionsdiff --git a/skills/daily-brief/SKILL.md b/skills/daily-brief/SKILL.mdnew file mode 100644index 0000000..8dfe560--- /dev/null+++ b/skills/daily-brief/SKILL.md@@ -0,0 +1,505 @@+---+name: daily-brief+description: Generate personalized news intelligence with verified sources (7-day freshness requirement)+roles: [all]+integrations: [web-search]+---++# COG Daily Brief Skill++## Purpose+Find verified, relevant news for personalized daily briefings with strict verification standards and strategic relevance analysis tailored to user's specific interests and projects.++## When to Invoke+- User wants their daily news briefing+- User says "daily brief", "news", "what's happening", "morning brief"+- User wants to stay updated on their interests+- Morning routine or regular check-in time++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — delegate news research across different interest areas to parallel sub-agents (e.g., one agent per topic cluster). Each agent searches, verifies sources, and returns findings. Combine and synthesize results into the final brief.+- If `agent_mode: solo` (default) — handle all research and synthesis directly in the conversation. No delegation.++## Pre-Flight Check++**Before executing, check for user profile:**++1. Look for `00-inbox/MY-PROFILE.md` and `00-inbox/MY-INTERESTS.md` in the vault+2. If NOT found:+ ```+ Welcome to COG! Daily briefs work best when personalized.++ Let's quickly set up your profile (takes 2 minutes).++ Would you like to run onboarding first, or should I generate a general brief?+ ```+3. If found:+ - Read `MY-INTERESTS.md` to get topics for news curation+ - Read `MY-PROFILE.md` to get user's name and active projects+ - Read `03-professional/COMPETITIVE-WATCHLIST.md` if exists for competitive tracking+ - Use topics to curate relevant news+ - Connect news to user's active projects when relevant++**Get current timestamp (REQUIRED before generating any files):**++1. Run `date '+%Y-%m-%d %H:%M'` using Bash to get the actual current date and time+2. Store this value and use it for the `created:` frontmatter field+3. NEVER guess or fabricate the time — always use the value returned by the `date` command++## Process Flow++### 1. Gather Context++Collect the information needed for personalized curation:++- Read `00-inbox/MY-PROFILE.md` for:+ - User's name+ - User's role/job+ - Active projects++- Read `00-inbox/MY-INTERESTS.md` for:+ - Topics they're interested in+ - Preferred news sources++- Read `03-professional/COMPETITIVE-WATCHLIST.md` (if exists) for:+ - Companies/people to track++#### Deduplication — Previous Brief Scan++Read up to 3 most recent daily briefs from `01-daily/briefs/` (most recent first):+- Extract `dedup_urls` from their frontmatter (if present)+- Also scan their headlines/story titles as semantic fallback for cross-source matching+- Build a set of **covered stories** to avoid repeating++**Matching rules (in priority order):**+1. **URL match (primary):** If a candidate story's main source URL already appears in `dedup_urls`, it's a known story+2. **Headline match (fallback):** If the URL is different but the headline describes the same event as a previous story, treat as duplicate — this catches the same story reported by different outlets++During news research (Step 2), apply dedup rules:+- **Skip** stories already covered unless there is a **material update** (new data, resolution, escalation, reversal)+- If including an update, prefix with "**Update:** _first covered [date]_"+- Stories older than 3 briefs are eligible for re-inclusion if still developing++### 2. News Research and Curation++Apply comprehensive news research methodology:++#### Interest-Based Research+- Search based on user's current interest profile+- Focus on strategic relevance to user's role and projects+- Identify emerging patterns and developments+- Diversify sources for balanced perspective++#### Verification Standards (MANDATORY)++**Date Verification:**+- ALL news MUST be from last 7 days ONLY+- Verify publication dates with verified timestamps+- NEVER include older news without explicit disclosure++**Source Credibility Assessment:**+- **Tier 1 Sources (Highest Credibility):** Major news organizations (Reuters, AP, Bloomberg, WSJ, NYT), official company announcements, government statements+- **Tier 2 Sources (High Credibility):** Industry publications, credible tech/business blogs, research reports from reputable firms+- **Tier 3 Sources (Moderate - Verify Carefully):** Social media from verified accounts, company blogs, community discussions+- Minimum 2 credible sources for any claim+- Cross-reference key facts and figures++**Fact Cross-Reference:**+- Verify claims across multiple independent sources+- Use WebFetch to verify any statistics before including them+- Identify potential bias and provide balanced perspective++#### Strategic Relevance Analysis++Assess impact on user:++**Direct Impact (High Priority):**+- News directly affecting user's projects or companies+- Regulatory changes affecting user's industry+- Competitive moves by direct competitors+- Technology developments affecting user's tech stack++**Strategic Impact (Medium Priority):**+- Market trends affecting user's target customers+- Investment patterns in user's industry+- Talent market changes affecting hiring+- Partnership opportunities or threats++**Contextual Impact (Lower Priority):**+- Broader economic trends affecting business climate+- Technology trends affecting future planning+- Industry thought leadership and opinion+- Educational content for professional development++#### Opportunity and Threat Identification++**Opportunities:**+- Market Opportunities: New markets or customer segments opening+- Technology Opportunities: New tools or platforms to leverage+- Partnership Opportunities: Potential collaboration partners+- Competitive Opportunities: Competitor weaknesses or market gaps++**Threats:**+- Competitive Threats: New competitors or competitive advantages+- Technology Threats: Disruptive technologies or obsolescence risks+- Market Threats: Market shifts or customer behavior changes+- Regulatory Threats: New regulations or compliance requirements++### 3. Generate Daily Brief++Create structured briefing document:++```markdown+---+type: "daily-brief"+domain: "shared"+date: "YYYY-MM-DD"+created: "YYYY-MM-DD HH:MM"+sources_verified: true+news_age_verified: true+confidence: "high"+tags: ["#daily-brief", "#news", "#strategic-intelligence"]+interests: ["interest1", "interest2"]+projects_referenced: ["project1"]+items_count: [number]+dedup_urls: ["https://primary-source-url-for-each-story-covered"]+---++# Daily Brief - [Date]++**Good [morning/afternoon], [Name]!**++## Executive Summary+[2-3 sentences highlighting the most important developments across all your interest areas]++---++## High Impact News++### [News Item 1 - Direct Impact]+**Relevance:** [Why this matters to you specifically]++[Detailed summary of the news]++**Impact Assessment:**+- **Projects Affected:** [Which of your projects this impacts]+- **Potential Effects:** [Specific implications]+- **Action Suggested:** [Recommended response or follow-up]++**Sources:**+- [Source Name 1] (Tier [1/2/3]) - [Publication Date] - [Link]+- [Source Name 2] (Tier [1/2/3]) - [Publication Date] - [Link]++**Confidence:** [High/Medium/Low] - [Reasoning]++---++### [News Item 2 - Direct Impact]+[Same structure as above]++---++## Strategic Developments++### [News Item 3 - Strategic Impact]+**Relevance:** [Why this matters strategically]++[Detailed summary]++**Strategic Implications:**+- [Implication 1]+- [Implication 2]+- [Implication 3]++**Sources:**+- [Source listings with credibility tiers and links]++**Confidence:** [High/Medium/Low] - [Reasoning]++---++## Market Intelligence++### [News Item 4 - Market Trends]+**Relevance:** [Why this market trend matters]++[Detailed summary]++**Market Impact:**+- [Impact on target customers]+- [Industry trends]+- [Investment patterns]++**Sources:**+- [Source listings with credibility tiers and links]++**Confidence:** [High/Medium/Low] - [Reasoning]++---++## Technology Watch++### [News Item 5 - Tech Developments]+**Relevance:** [Why this technology matters]++[Detailed summary]++**Technology Implications:**+- [Impact on tech stack]+- [New tools or platforms]+- [Emerging technologies]++**Sources:**+- [Source listings with credibility tiers and links]++**Confidence:** [High/Medium/Low] - [Reasoning]++---++## Competitive Landscape++### [Competitor/Company Name - From Watchlist]+**Recent Activity:**++[Summary of competitive intelligence gathered]++**Competitive Implications:**+- [What this means for your projects]+- [Opportunities or threats]+- [Recommended responses]++**Sources:**+- [Source listings with credibility tiers and links]++**Confidence:** [High/Medium/Low] - [Reasoning]++---++## Opportunities & Recommendations++**Note:** Calculate actual due dates from today's date and append Obsidian Tasks emoji format.++### Immediate Actions (Today/This Week)+- [ ] [Specific action item 1] 📅 [YYYY-MM-DD = today's date]+- [ ] [Specific action item 2] 📅 [YYYY-MM-DD = today's date]+- [ ] [Specific action item 3] 📅 [YYYY-MM-DD = end of this week]++### Research Needed+- [Area 1 requiring deeper investigation]+- [Area 2 to monitor closely]++### People to Inform/Consult+- [Stakeholder 1]: [About what]+- [Stakeholder 2]: [About what]++---++## Risks & Threats++### Active Threats+- **Threat 1:** [Description and mitigation approach]+- **Threat 2:** [Description and mitigation approach]++### Emerging Risks to Monitor+- [Risk 1 to watch]+- [Risk 2 to watch]++---++## Verification Report++### Source Analysis+- **Tier 1 Sources:** [count] - [list main ones]+- **Tier 2 Sources:** [count] - [list main ones]+- **Cross-References Performed:** [number]++### Fact-Checking Results+- **Verified Claims:** [count]+- **Unverified Claims:** [count with explanation if any]+- **Conflicting Information:** [count with resolution approach if any]++### Freshness Verification+- ✅ All news items verified within 7-day window+- Publication date range: [Oldest date] to [Newest date]++### Confidence Assessment+- **Overall Confidence:** [percentage]%+- **High Confidence Items:** [count]+- **Medium Confidence Items:** [count]+- **Low Confidence Items:** [count] - [reasons if any]++---++## Complete Sources++### Strategic News+1. [Full source citation with link]+2. [Full source citation with link]++### Market Intelligence+1. [Full source citation with link]+2. [Full source citation with link]++### Technology Watch+1. [Full source citation with link]+2. [Full source citation with link]++### Competitive Intelligence+1. [Full source citation with link]+2. [Full source citation with link]++---++*Curated by COG News Curator | All news verified within 7-day freshness window | Sources cross-referenced for accuracy*+```++Save to: `01-daily/briefs/daily-brief-YYYY-MM-DD.md`++### 4. Handle Special Cases++**When No Recent News Found:**+If no relevant news found in last 7 days for a particular interest area:++```markdown+### [Interest Area]+**No significant news found in last 7 days**++Last significant development was [date if known] regarding [topic if known].++**Suggestions:**+- Consider expanding search criteria+- Check [alternative sources suggested]+- This area may be experiencing a quiet period+```++**NEVER fabricate or use older news without explicit date disclosure.**++**When Information Cannot Be Verified:**+```markdown+### [Potential News Item]+**⚠️ Unable to verify from independent sources**++**Original Source:** [source] - Credibility: [assessment]++**What We Know:**+[What can be stated based on single source]++**What's Uncertain:**+[Specific claims that couldn't be verified]++**Recommendation:** Monitor for additional confirmation before acting++**Confidence:** Low - [reasoning]+```++**When Sources Conflict:**+```markdown+### [News Item with Conflicting Reports]+**⚠️ Conflicting information from multiple sources**++**Perspective 1:**+[Summary] - **Source:** [source with credibility tier]++**Perspective 2:**+[Summary] - **Source:** [source with credibility tier]++**Areas of Agreement:**+- [What sources agree on]++**Areas of Disagreement:**+- [Where sources conflict]++**Recommendation:** [Approach for resolution or further research]++**Confidence:** Medium - [reasoning]+```++### 5. Confirm Completion+- Confirm file was created+- Show user: "Daily brief saved to [file path]"+- Optionally show executive summary+- Ask if they want to explore any topic deeper or capture thoughts via braindump skill++## Loop Engineering++Daily brief is a **verify-retry loop**, not a single search. See `.claude/skills/loop-engineering/SKILL.md` for the shared vocabulary.++**The loop (per interest area):** search → fetch a candidate → run the verifier → keep it or discard and re-search with an adjusted query → repeat until enough verified items or a stop condition fires. In `agent_mode: team`, run one loop per interest cluster as isolated workers (orchestrator-workers), then synthesize.++**The verifier (deterministic, runs every candidate):**+- Publication date is within the last 7 days. Mechanical date check, not a guess.+- At least 2 independent credible sources for the claim.+- Source tier is identified (1 / 2 / 3). Tier 3 needs cross-reference before it survives.+- Not already seen (story dedup): a candidate whose URL or headline is already in the brief is dropped.++A candidate that fails any check is discarded, not softened. This is COG's verification-first rule applied inside the loop: never let an item in on the agent's own "this looks recent enough."++**Termination conditions (layered):**+- **Goal met:** target item count reached for the interest area.+- **Hard cap:** stop after ~5 searches per interest area.+- **No-progress:** 2 consecutive searches surface nothing new (after dedup) → emit the "No significant news found" block (see Handle Special Cases) and move on. Never backfill with older or fabricated news.+- **Budget guard:** overall fetch budget across all areas.++**Patterns:** evaluator-optimizer (each item scored against the verifier) + reflect-retry (a failed search informs the next query) + orchestrator-workers (team mode).++**In-loop context:** write verified items straight into the brief file as they pass; drop raw fetched page text once the summary and sources are extracted.++## Integration with Other Skills++### Follow-up Actions+After daily brief, suggest:+- **braindump skill** - Capture thoughts sparked by news+- **weekly-checkin skill** - Reflect on news patterns over the week+- Project-specific analysis if news impacts active projects++## Performance Metrics++### Verification Quality+- Source Credibility Score: Average credibility rating of sources used+- Fact Accuracy Rate: Percentage of facts that remain accurate over time+- Cross-Reference Rate: Percentage of claims verified through multiple sources+- Date Accuracy: 100% compliance with 7-day freshness requirement (MANDATORY)++### Relevance Quality+- User Engagement: Percentage of news items user finds valuable+- Action Generation: Percentage of news items leading to user action+- Strategic Value: User assessment of strategic importance+- Timing Relevance: How well news timing aligns with user needs++## Learning and Adaptation++### Interest Profile Refinement+- Monitor which news items user finds most valuable+- Incorporate user feedback on relevance and importance+- Identify patterns in user interest evolution+- Anticipate interest changes based on project evolution++### Source Quality Learning+- Track accuracy of different sources over time+- Build understanding of source reliability patterns+- Learn to identify and account for source bias patterns+- Continuously improve source selection criteria++### Relevance Algorithm Improvement+- Improve ability to predict news impact on user+- Learn optimal framing for different types of news+- Better understanding of user's strategic context+- Improve identification of actionable news items++## Success Criteria+- All news within 7-day window (100% compliance)+- All sources verified and linked+- User finds briefing relevant and actionable+- Confidence levels clearly stated+- Opportunities and risks identified+- Follow-up actions suggested++## Philosophy++The daily brief skill embodies COG's verification-first approach:+- No AI hallucinations - everything sourced and verified+- Transparency in confidence levels+- Explicit uncertainty when information can't be verified+- User empowered to make informed decisions based on reliable intelligencediff --git a/skills/daily-journal/SKILL.md b/skills/daily-journal/SKILL.mdnew file mode 100644index 0000000..6f895ca--- /dev/null+++ b/skills/daily-journal/SKILL.md@@ -0,0 +1,78 @@+---+name: daily-journal+description: A passive daily work journal that Claude keeps FOR you so you never have to write it yourself. Append short entries after meaningful work (what was done, what you focused on, artifacts touched) to 01-daily/journal/YYYY-MM-DD.md. Run a guided reflection at night or in the morning. Use when you run /daily-journal, say "log this to my journal", "add to today's journal", "reflect on today/yesterday", or when finishing a meaningful chunk of work in any session.+---++# Daily Journal++## Purpose+Keep an **automatic, passive** journal of your workdays so you don't have to write one. Claude logs what got done as it happens; you optionally run a reflection later. This is distinct from `/daily-checkin` (which is a manual reflection where you supply the input) — here **Claude is the author** and the log accrues in the background.++Two modes:+1. **`log`** (default, mostly invoked implicitly) — append a short entry to today's journal.+2. **`reflect`** — read the day's log (+ recent days) and run a guided reflection with you.++## Storage+- One file per day: `01-daily/journal/YYYY-MM-DD.md` (use `date +%F` for today's date; never guess).+- Create the file from the template below on the first entry of the day.+- Append only — never rewrite earlier entries. Newest entries go at the bottom of the Log section.++## When to log (behavioral trigger — applies in ANY session, not just when invoked)+After finishing a **meaningful** unit of work, append one entry. Meaningful = would matter to future-you or shows how the day was spent. Examples:+- Shipped/committed something, published a note/brief/slide, filed or moved tracker issues (Linear/Jira/GitHub).+- Made a decision, changed direction, or hit a notable blocker.+- Produced a deliverable file (spec, plan, analysis, report).+- A substantive research/synthesis session that produced an artifact.++**Do NOT log:** trivial reads, one-line lookups, mid-task scratch work, this journal's own writes, or anything you asked to keep out. When in doubt, one concise line is better than none. Do not interrupt the flow to announce logging — just append and carry on.++## Entry format+Append under the `## Log` section:++```+### HH:MM — <short title of what got done>+- **Focus:** <the thread/project this served, e.g. a product line, a squad, the blog>+- **Did:** <1-3 bullets, concrete, past tense>+- **Artifacts:** <files/PRs/links touched, or "—">+- **Signal:** <optional: decision made, blocker hit, mood/energy if you mentioned it, or omit>+```++Keep it tight. Times use 24h local (`date +%H:%M`). Match memory/CLAUDE.md conventions: no em-dashes, your product naming rules, no self-authored next-steps (only record what actually happened or what you explicitly said).++## Daily file template (first entry of the day)+```markdown+---+date: YYYY-MM-DD+type: journal+---++# Journal — YYYY-MM-DD (Weekday)++> Auto-kept by Claude. Reflection appended below when you run it.++## Focus of the day+_Inferred from entries; leave blank until there's signal._++## Log++## Reflection+_Empty until you run `/daily-journal reflect`._+```++## Mode: reflect+Triggered by `/daily-journal reflect [today|yesterday|YYYY-MM-DD]` (default: today), or when you say "reflect on today/yesterday" or "let's do the journal".++1. Read the target day's journal file. If it doesn't exist or the Log is thin, say so and offer to reconstruct from other signals (today's brief in `01-daily/briefs/`, recent commits, braindumps) before proceeding — but do NOT fabricate.+2. Read the previous 2-3 journal files for continuity (recurring threads, carried-over blockers).+3. Summarize the day back to you in a few lines: main focus, what shipped, what stalled. Then ask 2-4 light reflection questions adapted to what the log shows (e.g. "The eval work ate the afternoon — did it move?" rather than generic prompts). Keep it conversational, low-friction; this is meant to be a 2-minute thing at night or in the morning.+4. Write your answers + a short synthesis into the `## Reflection` section of that day's file. Fill in `## Focus of the day` if still blank.+5. If the reflection surfaces a durable fact (a decision, a changed priority, a lesson), also write/update the relevant `05-knowledge/` note or a memory per the Brain-First protocol — the journal is ephemeral daily context, not the durable store.++## Weekly roll-up (optional)+If you ask for a "week in review" or on a weekly reflection, read the last 7 journal files and synthesize themes into `01-daily/weekly/` (match the existing naming there). Do not auto-run this.++## Guardrails+- Single-file discipline: everything for a day lives in that one journal file. Never split into per-entry files.+- Privacy: personal/1:1 content stays in the journal only; never leaks into team-facing briefs.+- Never publish the journal anywhere external.+- This is your private log. Write plainly and honestly; if the day stalled, say so.diff --git a/skills/data-forms/SKILL.md b/skills/data-forms/SKILL.mdnew file mode 100644index 0000000..4c304bb--- /dev/null+++ b/skills/data-forms/SKILL.md@@ -0,0 +1,124 @@+---+name: data-forms+description: Pick the right way to represent a dataset so a reader gets the finding in three seconds — a catalog of 20+ chart and diagram forms with when-to-use and failure modes, plus the encoding decisions that make any of them readable (takeaway headline, direct labels, kill the axis, highlight-and-mute, show the caveat). Style-agnostic — use with whatever palette or design system the destination already has. Use when charting survey results, benchmark data, usage metrics, or research findings for a post, brief, deck, or report, and whenever the default bar chart feels like it's burying the point.+---++# data-forms++A repertoire, not a style. Distilled from Lenny's Newsletter data illustrations+(2025-2026 survey issues) — what makes those charts work is not the palette, it's the+form selection and the encoding discipline. Both are portable to any visual language.++For the visual layer, use whatever the destination already has: your product's brand+tokens for in-product surfaces, the built-in `dataviz` skill for palette construction and+accessibility, your house style for personal sites. This skill decides *what shape the data+takes* — the layer above color.++## Start here: the picker++| What the data does | Reach for | Form # |+|---|---|---|+| One question, 3-6 ordered answers | Ordered column · Waffle · Nested bands | 1 · 6 · 7 |+| One question, many multi-select answers | Ranked bar · Valence bar | 3 · 4 |+| Same metric, two points in time | Paired columns · Slope | 2 · 9 |+| Same metric, 3+ points in time | Time-series area · Bump | 13 · 18 |+| One metric across 7-10 ordered buckets | Staircase column | 14 |+| One metric across many unordered segments | Small multiples · Dot plot | 8 · 17 |+| Signed score (-100…+100, net, delta) | Diverging bar | 5 |+| Two groups compared across many rows | Dumbbell | 16 |+| Agreement / Likert across several statements | Centered stacked row | 19 |+| Segments × several metrics | Pill matrix | 10 |+| Open-text answers | Word cloud · Coded theme bar | 11 · 3 |+| A relationship the numbers can't carry | Metaphor diagram · Two-column flow | 12 · 20 |+| A named segmentation from clustering | Persona cards | 15 |+| Two dimensions, few labeled points | Named-quadrant scatter | 21 |++Full catalog with mockups and failure modes: `references/forms.md`.++## Six decisions that matter more than the form++**1. Write the takeaway before you pick a form.**+Finish the sentence "The point of this chart is ___." If you can't, you have a table,+not a chart, and no form will save it. That sentence becomes the headline. Two legal+headline modes:++- *Claim*, for comparisons and analysis — "Burnout is surging, and optimism is fading"+- *Question verbatim*, when the chart is the answer distribution — "How worried are you+ about layoffs?"++Never a field name. "Burnout by company size" is a spreadsheet tab.++**2. Print every value.** The reader should never estimate against an axis. Number sits+adjacent to its mark. This is what earns you the right to do #3.++**3. Delete the axis.** Baseline only — no y-axis, no gridlines, no ticks. Exceptions:+time series and slope charts, where the *shape* is the message and needs a reference+grid. Everywhere else the axis is scaffolding you forgot to remove.++**4. No legend when a direct label fits.** Category name goes on or beside its mark. A+legend is justified only when one key serves several panels (small multiples) or encodes+a dimension orthogonal to position (valence, group membership).++**5. Highlight two, mute the rest.** In a nine-category comparison, only the one or two+subjects named in the headline get emphasis; everyone else recedes. The chart should+argue the headline, not present the table. If the highlighted subject isn't actually the+outlier, the chart just disproved your headline — change the headline, not the data.++**6. Show the caveat in-frame.** Small n, margin of error, non-response, "percentages+sum past 100 because multi-select" — put it in the chart, not a footnote. A dashed+outline on a non-significant bar with a bracket reading "difference within margin of+error" is more credible than a clean chart plus a disclaimer nobody reads.++And one restraint: **at most one annotation.** Point at the thing a reader would+otherwise miss. Zero is fine. Two is clutter.++## Encoding rules of thumb++- **Color means something or it isn't there.** Don't color bars that a label already+ distinguishes. Reserve saturation for the subject of the headline.+- **Sequential ramp = magnitude or rank. Diverging ramp = signed. Categorical = identity.**+ Mixing these is the most common way a chart lies.+- **Per-column scales in a matrix.** In form 10, each metric gets its own ramp and its own+ direction, otherwise "dark = high" fights "dark = bad."+- **Neutral is an unfilled outline, not grey.** Grey reads as missing data.+- **Redundant encoding is fine where there's no axis** — a word cloud can size *and* color+ by frequency; nothing is being wasted.+- **Order carries meaning.** Sort by value unless the categories are inherently ordered+ (time, buckets, Likert). Keep the same order across every panel of a small multiple.+- **Bars start at zero, always.** If zero isn't meaningful for the metric, you wanted a+ dot plot (form 17), not a bar.+- **Anthropomorphize only when the subject is human.** Waffle grids of people, emoji+ anchors, persona illustrations — these earn their keep for sentiment and headcount, and+ read as cheap for latency and revenue.++## Workflow++1. State the takeaway in one sentence.+2. Classify what the data does (distribution / ranking / comparison / trend /+ correlation / composition / qualitative) and pick from the picker table.+3. Read that form's entry in `references/forms.md` — especially its failure mode. If your+ data triggers the failure mode, take the alternative listed there.+4. Apply the six decisions and the encoding rules.+5. Build it in whatever the destination uses.+6. **Render it and look at the image.** Not the DOM, not the spec — the pixels. Run the+ checklist. Fix what you see and re-render.++## Pre-ship checklist++Read the rendered image and answer each. A "no" is a fix, not a note.++- [ ] Headline states a finding or asks the literal question — not a field name+- [ ] Every mark carries its value, legible at 50% zoom+- [ ] No legend that direct labels could have replaced+- [ ] Emphasis lands on the subject of the headline; everything else recedes+- [ ] Longest label doesn't collide with, wrap under, or overflow its mark+- [ ] Bars start at zero; no truncated scale+- [ ] ≤1 annotation+- [ ] Squint test: at 25% zoom the shape of the answer still reads+- [ ] Caveats (n, margin of error, multi-select) visible in-frame+- [ ] The form's own failure mode from `references/forms.md` does not apply++## Reference++`references/forms.md` — 21 forms, each with an ASCII mockup, when to use it, and the+condition under which it stops working.diff --git a/skills/data-forms/references/forms.md b/skills/data-forms/references/forms.mdnew file mode 100644index 0000000..4ed7301--- /dev/null+++ b/skills/data-forms/references/forms.md@@ -0,0 +1,598 @@+# Form catalog++21 ways to represent a dataset. Each entry: what it's for, the shape, and the condition+under which it stops working. Mockups show structure only — apply the destination's+visual language on top.++Forms 1-15 are observed working in the wild (Lenny's Newsletter survey issues, 2025-2026).+Forms 16-21 obey the same grammar and fill gaps the first fifteen leave.++---++## 1. Ordered column chart++**For** one question with 3-6 answers on an ordered scale, where the *shape* of the+distribution is the finding.++```+ How has AI shifted your professional identity?++ Amplified+ 49%+ ┌───────┐+ │ │ Redefined+ │ │ 27%+ │ │ ┌───────┐ Destabilized+ │ │ │ │ 14%+ │ │ │ │ ┌───────┐ Diminished+ │ │ │ │ │ │ 5% Unchanged+ │ │ │ │ │ │ ┌──────┐ 3%+ ──┴──😄───┴────────┴──🤩───┴─────┴──😵───┴────┴──😞──┴────┬──😐─┬──+```++Label and value stack *above* each column, left-aligned to it, so nothing sits in the+plot area. An icon on the baseline gives each column an identity the eye can grab before+it reads. Magnitude runs the ramp by rank.++**Stops working when** the categories aren't ordered — then ranking by value matters more+than sequence, and you want form 3. Also breaks past ~6 columns: they go thin and the+stacked labels collide.++---++## 2. Paired columns++**For** exactly two time points, on one or two metrics, where direction is the story.++```+ Burnout is surging, and optimism is fading++ HOW BURNED HOW OPTIMISTIC+ OUT ARE YOU? ARE YOU?+ ╭─→ ╲+ 55.7% ╲__→+ 44.7% ┌────┐ 54.8% 48.7%+ ┌────┐ │ │ ┌────┐ ┌────┐+ │2025│ │2026│ │2025│ │2026│+ ──┴────┴──┴────┴────────────┴────┴───┴────┴──+```++Period labels go *inside* the bars, values above — that removes the x-axis entirely. One+arrow per pair showing direction. Encode "up is bad" vs "up is good" differently so both+pairs read as the same news without a sentence of explanation.++**Stops working when** you have three or more time points. Two columns imply a line the+reader draws themselves; three imply a trend you should actually draw (form 9 or 13).++---++## 3. Ranked horizontal bar++**For** multi-select questions, or any ranking of 5-15 items. The workhorse. Percentages+summing past 100 is expected — say so in a subhead.++```+ The underlying fear is of being overworked++ ┌─────────────────────────────────────────────────┐ 51%+ │ Expected to do more for same pay │+ └─────────────────────────────────────────────────┘+ ┌───────────────────────────────────────────┐ 46%+ │ Pace is becoming unsustainable │+ └───────────────────────────────────────────┘+ ┌───────────────────────────────────────┐ 43%+ │ Becoming too dependent on AI │+ └───────────────────────────────────────┘+ ┌────────────────────────────┐ 30%+ │ Skills becoming less valuable ← label overflows,+ └────────────────────────────┘ see failure mode+```++Label **inside** the bar at the left, value **outside** at the right. One treatment for+every bar — length already ranks them, so color would be noise. Common left edge.++**Stops working when** the top bar is more than ~4× the bottom one: short bars can't hold+their label. Fix by moving all labels outside-left, right-aligned in a fixed gutter.++---++## 4. Valence bar++Form 3 plus a categorical encoding orthogonal to length.++```+ What emotions describe how you feel about AI at work?++ ┌─🙂─────────────────────────────────────────┐ 71%+ │ Curious │ ██ Positive+ ┌─😀───────────────────────────────────┐ 64% ▢▢ Neutral+ │ Excited │ ▓▓ Negative+ ┌─😵──────────────────────────┐ 54%+ │ Overwhelmed │+ ┌─🙃────────────────────┐ 51%+ │ Conflicted │ ← unfilled outline = neutral+```++One of the few places a legend is correct: the second dimension repeats down the rows and+can't be direct-labeled without repeating a word eleven times. Render neutral as an+*unfilled outline* rather than grey — grey reads as missing data.++**Stops working when** the valence assignment is arguable. If reasonable people would sort+the categories differently, don't encode it; you're smuggling an opinion into a channel+the reader will trust as fact.++---++## 5. Diverging bar++**For** a metric with a real, meaningful zero on both sides: NPS, net sentiment, change+vs. baseline, net promoter/detractor.++```+ How likely are you to recommend a career in your role?++ ┊ detractor side │ promoter side+ Founder / Executive ┊ -3 ▐│+ Sales / GTM ┊ -32 ▐▐▐▐▐▐▐│+ PM ┊ -35 ▐▐▐▐▐▐▐▐│+ Operations ┊ -46 ▐▐▐▐▐▐▐▐▐▐│+ Engineering ┊ -48 ▐▐▐▐▐▐▐▐▐▐▐│+ Marketing ┊ -49 ▐▐▐▐▐▐▐▐▐▐▐│+ Data / Analytics ┊ -54 ▐▐▐▐▐▐▐▐▐▐▐▐│+ Design ┊ -67 ▐▐▐▐▐▐▐▐▐▐▐▐▐▐▐│+ Research ┊ -68 ▐▐▐▐▐▐▐▐▐▐▐▐▐▐▐│+ -100 Detractors 0 Promoters 100+```++Tint each half-plane faintly and name it under the axis. Keep the zero line heavy.+**Keep the scale symmetric even when every value sits on one side** — the empty half is+the finding, and cropping it to "use the space" destroys the whole point.++**Stops working when** zero is arbitrary. A diverging form on a metric with no natural+midpoint invents a judgment.++---++## 6. Waffle / dot matrix++**For** making a percentage feel like people. 100 marks, one per point.++```+ How worried are you about layoffs?++ 😐 28% 😔 31% 😟 21% 😧 12% 😱 8%+ Not at all Slightly Moderately Very Extremely++ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○+ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○+ ┌─ ○ ○ ○ ○ ○ ○ ○ ○ ◐ ◐+ 72% │ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐+ of │ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐+ people │ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◐ ◔+ are │ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ─┐ 41.2%+ worried │ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ◔ ◔ │ are at least+ │ ◑ ◑ ◑ ◑ ◑ ◑ ◑ ◑ ◑ ◑ │ moderately+ └─ ◑ ◑ ● ● ● ● ● ● ● ● ─┘ worried+```++Fill bottom-up so the heavy end is grounded. The brackets are the reason this beats a+bar: they call out *cumulative* groupings the reader would otherwise have to add up, and+you can run two overlapping ones (72% worried at all, 41% at least moderately) without+drawing a second chart.++**Stops working when** you need decimal precision — a waffle rounds to whole points — or+past ~5 categories, where the grid turns to static.++---++## 7. Nested bands++**For** categories that genuinely nest, where the headline is a cumulative figure.++```+ How much better are you at your job?++ Drawn as concentric circles; the nesting logic is what matters:++ ┌─ 97.2% say AI is making them better ─────────────────────────┐+ │ │+ │ ┌─ 81.7% moderately better or more ──────────────────┐ │+ │ │ │ │+ │ │ ┌─ 49.4% "very much" or "extremely" ───────┐ │ │+ │ │ │ │ │ │+ │ │ │ ┌─ 15.3% "extremely better" ───┐ │ │ │+ │ │ │ └──────────────────────────────┘ │ │ │+ │ │ └──────────────────────────────────────────┘ │ │+ │ └────────────────────────────────────────────────────┘ │+ └──────────────────────────────────────────────────────────────┘+ 2.8% not at all 15.5% slightly 32.3% moderately 34.1% very+ └── each band's own share, labelled inside its ring ──┘+```++Concentric bands, each one a category, drawn so the eye reads "and also, and also."+Leader lines carry the cumulative claims outside the shape. This is the honest+replacement for a pie chart on ordered data: it shows both the parts and the running+total, which a pie cannot.++**Stops working when** the categories don't actually nest — then the geometry is claiming+a containment relationship that doesn't exist, which is worse than a plain column chart.++---++## 8. Small multiples++**For** proving "X is consistently the outlier" when no single chart can.++```+ Designers and researchers are the most negative across the board++ 61% 57% 63% 60% 55% 53%+ ██ ██ 51% 50% 49% ██ ██ ░░ ░░ 52%+ 33% ██ ██ ░░ ░░ ░░ ██ ██ ░░ ░░ ░░+ ██ 25% 24% 23% 23% ██ ██ ░░ ░░ ░░ ██ ██ ░░ ░░ ░░+ ██ ██ ░░ ░░ ░░ ██ ██ ░░ ░░ ░░ ██ ██ ░░ ░░ ░░+ ██ ██ ░░ ░░ ░░ ██ ██ ░░ ░░ ░░ ██ ██ ░░ ░░ ░░+ ────────────────── ────────────────── ──────────────────+ AI-identity: Emotion: Tired Emotion: Overwhelmed+ Destabilized++ ██ Design ██ Research ░░ Engineering ░░ Operations ░░ PM …++ Shared 0-70 scale across all three panels — never per-panel maxima.+```++Same category order in every panel, non-negotiable. Emphasis only on the subjects named+in the headline; everyone else recedes into one muted ramp. Panel titles name the+*metric*; the headline carries the claim. One shared legend.++**Stops working when** panels use different scales without saying so, or when the+highlighted subject isn't consistent across panels. The second case means the chart+disproves the headline — which is useful information, so change the headline.++---++## 9. Slope chart++**For** two series moving in opposite directions, where the crossing is the story.++```+ A great manager changes everything++ 5+ ● 4.04+ 4 ● 3.31 ● 3.63 ╱ Job enjoyment+ ● 3.22 ● 2.95 ╱───────────────────+ 3 ╲ 2.90 ●───╲╱────● 2.70+ ╲───────╱ ╲──────● 2.46 ● 2.33 Burnout+ 2 ● 2.44+ 1+ 0 Not at all Slightly Moderately Very Extremely+ Manager effectiveness+```++One of two forms that keeps a grid, because slope needs a reference. Value labels on+every point, offset *above* the rising series and *below* the falling one so they never+collide at the crossing. Series named at their right endpoint beats a legend.++**Stops working when** the x-axis is categorical and unordered. Connecting those points+implies a progression that doesn't exist.++---++## 10. Pill matrix++**For** a small table (4-8 rows × 3-5 metrics) that would otherwise get skipped. Each+cell becomes a mini bar carrying its own number.++```+ ┌──────────────┬───────────────┬──────────────┬────────────────┐+ │ Company size │ Career optim. │ Burnout │ Would recommend│+ │ │ (1–5) │ (1–5) │ (NPS) │+ ├──────────────┼───────────────┼──────────────┼────────────────┤+ │ 1–10 │ (3.55▓▓▓▓░░░) │ (2.33▓░░░░░) │ (6.19▓▓▓▓▓░░░) │+ │ 11–50 │ (3.37▓▓▓▓░░░) │ (2.61▓▓░░░░) │ (6.09▓▓▓▓▓░░░) │+ │ 51–200 │ (3.30▓▓▓░░░░) │ (2.68▓▓░░░░) │ (5.98▓▓▓▓░░░░) │+ │ 1K–5K │ (3.14▓▓▓░░░░) │ (2.85▓▓▓░░░) │ (5.70▓▓▓░░░░░) │+ │ 10,000+ │ (3.04▓▓░░░░░) │ (2.90▓▓▓░░░) │ (5.79▓▓▓░░░░░) │+ └──────────────┴───────────────┴──────────────┴────────────────┘+```++**Each column gets its own scale and its own ramp direction** — high-is-good and+high-is-bad must not share an encoding. Scale stated once in the header, never repeated+in cells. Sort rows by whichever metric carries the story; the monotonic staircase down+one column is what the reader will notice.++**Stops working when** you apply one ramp across all columns, or when rows exceed ~8 and+it reverts to being a table with decoration.++---++## 11. Word cloud++**For** an open-text question that asked for a single word, where the pile is the point.++```+ The industry is "chaotic"++ mess moving layoffs flux tools+ unstable hype pace+ huge c h a n g e better+ leadership exciting costs bubble+ quality uncertain fast shift pressure+ evolving opportunity money+```++Size by frequency; colouring by frequency too is correct here — with no axis, redundant+encoding costs nothing and gains legibility. Cap at ~25 words. Headline quotes the modal+word so the reader gets the answer even if they don't scan the cloud.++**Stops working when** the question allowed a phrase. Code the responses into themes+first, then use form 3 — a cloud of phrases is unreadable and a cloud of their constituent+words is meaningless.++---++## 12. Metaphor diagram++**For** a relationship the numbers can't carry: surface vs. hidden, stated vs. actual,+what's measured vs. what matters.++```+ The productivity iceberg++ ┌──────────────┐ ╱╲+ │On the surface│ ╱ ╲ 97.2%+ │"We're doing │ ╱ ╲ say AI is making+ │ better!" │ ╱ ╲ them better+ └──────────────┘ ~~~~~~~~~~╱~~~~~~~~╲~~~~~~~~~~~~~~~~~+ ┌──────────────┐ ╱ ╲+ │ Just below │ │ "I CAN DO │+ │Output quality│ │ MORE, FASTER │+ └──────────────┘ │ BUT NOT │+ ┌──────────────┐ │ BETTER." │+ │The deep cost │ ╲ ╱+ │Thinking and │ ╲ "MY BRAIN ╱+ │ judgment │ ╲IS ROTTING"╱+ └──────────────┘ ╲_________╱+```++Left rail names the tiers; the shape carries verbatim quotes. **One statistic maximum** —+the metaphor is doing the work, and a second number turns it into a bad chart instead of+a good diagram.++**Stops working when** the metaphor implies a proportion the data doesn't have. An+iceberg asserts "most of it is hidden." Don't use one for a 60/40 split.++---++## 13. Time-series area++**For** many points over time where the current value matters as much as the shape.++```+ Most open PM jobs since 2022 ← headline, left-aligned+ ( 7,379 open PM jobs ) ↑ 79% from low (4,113) ← current value + delta++ 12K ┼───────────────────────────────────────── as of March 2026+ 10K ┤╲ MOST OPEN PM+ 8K ┤ ╲ ROLES IN 3+ YEARS ╲+ 6K ┤ ╲___ ______________________────→●+ 4K ┤▓▓▓▓▓▓▓╲__________╱▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓+ 2K ┤▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓+ 0 ┴────┬──────┬──────┬──────┬──────+ 2023 2024 2025 2026+```++The other exception to "delete the axis": keeps faint gridlines and a filled area, both+of which help the eye read slope. Lead with the current value as a standalone figure and+a delta-from-reference, so a reader who never looks at the curve still leaves with the+number. Stamp the as-of date in-frame.++**Stops working when** the y-axis is truncated. Never truncate here — this form is+entirely about honest slope, and a cropped baseline exaggerates every move.++---++## 14. Staircase column++**For** one metric across 7-10 *ordered* buckets, where monotonicity is the finding.++```+ Burnout climbs by company size+ ┌ Difference within+ │ margin of error+ ┌────┴─────┐+ 65%+ 61% ┌───┐ 61%+ 56% ┌───┐ │ │ ┌╌╌╌┐ ← dashed cap =+ 54% ┌───┐ │ │ │ │ ┆ ┆ not significant+ 52% ┌───┐ │ │ │ │ │ │ ┆ ┆+ 42% ┌───┐ │ │ │ │ │ │ │ │ ┆ ┆+ ┌───┐ │ │ │ │ │ │ │ │ │ │ ┆ ┆+ │ │ │ │ │ │ │ │ │ │ │ │ ┆ ┆+ ──┴───┴──┴───┴──┴───┴──┴───┴──┴───┴──┴───┴──┴───┴──+ 1–10 11–50 51–200 201–1K 1–5K 5–10K 10K++```++Single treatment, intensity rising with value, so the staircase reads as one trend rather+than seven facts. The dashed cap plus bracket is the honest way to keep a+non-significant final bar instead of quietly dropping it.++**Stops working when** the buckets aren't ordered — then sort by value and use form 3.++---++## 15. Persona cards++**For** a segmentation where the reader should remember the *names*, not the shares.++```+ The four tech workers of 2026++ ╭────────────╮ ╭────────────╮ ╭────────────╮ ╭────────────╮+ │ 💪 │ │ 🤷 │ │ 😵 │ │ 😠 │+ │ │ │ │ │ │ │ │+ │ THE │ │ THE │ │ THE │ │ THE │+ │ ENERGIZED │ │ CONFLICTED │ │DISORIENTED │ │ RESENTFUL │+ │ All-in │ │ Ambivalent │ │ Role keeps │ │ Pressured, │+ │ adopters │ │ middle │ │ shifting │ │ checked-out│+ │ 41% │ │ 35% │ │ 12% │ │ 12% │+ ╰────────────╯ ╰────────────╯ ╰────────────╯ ╰────────────╯+```++Name, one-line descriptor, share — in that order of prominence, because that's the order+of what you want retained. A distinct image per card does more for recall than any+encoding. Cards laid out in share order.++**Stops working when** the segments came from a hunch rather than a clustering. This form+radiates rigor; using it on made-up groups is the most expensive lie in the catalog.++---++## 16. Dumbbell++**For** two groups compared on one metric across many rows, where the *gap* is the point.++```+ Enterprise buyers care about compliance; SMBs don't++ Compliance SMB ●───────────────────────────● Ent gap 42+ Onboarding SMB ●──────────────● Ent gap 19+ Price Ent ●──────● SMB gap 9+ Integrations SMB ●────● Ent gap 4+```++Direct-label both endpoints, weight the connector by gap size so the ranking of gaps+reads before the values do. Sort by gap, not by either endpoint.++**Stops working when** the two groups cross rank frequently — the crossing connectors+become spaghetti. Use paired small multiples instead.++---++## 17. Dot plot++**For** a ranking where zero is not meaningful: averages, indexes, scores, years, rates.++```+ Average time-to-first-value, by plan++ Enterprise ────────────────────● 18.2 days+ Business ──────────● 11.4+ Pro ───────● 8.9+ Free ─────● 6.1+ 6 9 12 15 18+```++Bars imply a zero baseline and make a 6-vs-8 difference look like nothing. Dots don't+carry that promise, so you can start the scale where the data lives without lying.++**Stops working when** the reader will read the dots as a count. Anything that *is* a+total or a share should be a bar.++---++## 18. Bump chart++**For** ranking over time — who moved up, who fell.++```+ Claude overtook Perplexity in the assistant stack++ rank 2023 2024 2025 2026+ 1 ChatGPT ────── ChatGPT ────── ChatGPT ────── ChatGPT+ 2 Perplex ──╮ ╭─ Claude ─────── Claude ─────── Claude+ 3 Claude ───╯ ╰─ Perplex ──╮ ╭─ Gemini ─────── Gemini+ 4 Gemini ─────── Gemini ───╯ ╰─ Perplex ────── Perplex+```++Cap at ~8 series. Highlight the one or two whose movement is the headline; mute the rest+into a single background treatment, or the chart becomes a plate of noodles.++**Stops working when** ranks barely change — a bump chart of four parallel lines says+"nothing happened" in the most expensive possible way. Use a table.++---++## 19. Centered stacked row++**For** Likert agreement across several statements. The classic survey form.++```+ Where teams agree — and where they don't++ ◄ disagree │ agree ►+ AI saves me time ▓▓▓░│░████████████████████ 82% agree+ Quality has improved ▓▓▓▓▓▓▓▓░░░│░░░████████████ 48%+ I trust the output ▓▓▓▓▓▓▓▓▓▓▓▓░░│░░░████████ 31%+ My role is secure ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░░│░░██████ 22%+ ▓ disagree ░ neutral █ agree+```++Center each row on the neutral midpoint rather than at 0%, so agree and disagree extend+in opposite directions and the rows are comparable at a glance. Sort by net agreement.+Put the summary percentage outside the row.++**Stops working when** the neutral bucket is large and you hide it. Split neutral across+the midpoint or show it explicitly; suppressing it inflates both wings.++---++## 20. Two-column flow++**For** paired transformations: intention → result, promise → reality, input → outcome.+The honest small-scale alternative to a Sankey.++```+ What teams intend vs. what they get++ INTENTION RESULT+ get noticed ▶ make mediocre work+ make good work ▶ get noticed+ ship faster ▶ ship more rework+```++Two columns, a repeated connector glyph, nothing else. Its power is the *reversal* the+reader notices between rows one and two.++**Stops working when** the mapping is many-to-many. Then you need a real flow diagram,+and you should question whether the reader will follow it.++---++## 21. Named-quadrant scatter++**For** two dimensions and few enough points to label every one.++```+ High impact, low effort: three obvious bets++ high │ DO LATER │ DO FIRST+ impact │ ● Multi-tenant │ ● SSO+ │ ● Audit log │ ● Bulk import+ │────────────────────────┼─────────────────────+ │ DON'T │ QUICK WINS+ low │ ● Theme editor │ ● CSV export+ └────────────────────────┴─────────────────────+ high effort low effort+```++Every quadrant gets a verb, not a coordinate description — the label should tell the+reader what to *do*, which is the only reason to draw quadrants. Label every point.++**Stops working when** there are more than ~20 points, or the axes are estimates dressed+as measurements. An unlabeled scatter belongs in analysis, not in a deliverable.++---++## Never++- **Pie and donut charts.** Form 7 shows the same composition plus cumulative totals;+ form 1 shows it with comparable lengths. A pie is strictly worse than both.+- **Dual y-axes.** The correlation is manufactured by whatever scaling you chose.+- **Radar / spider charts.** Area scales with the square of the values and the shape+ changes when you reorder the axes. Use form 10.+- **Gauges and speedometers.** Enormous ink for one number. Just write the number.+- **3D anything, gradient fills as decoration, drop shadows on data marks.**+- **Treemaps under ~15 items.** Use a ranked bar; area is harder to compare than length.+- **Truncated y-axes**, anywhere, ever.diff --git a/skills/editorial-illustrations/SKILL.md b/skills/editorial-illustrations/SKILL.mdnew file mode 100644index 0000000..dce135c--- /dev/null+++ b/skills/editorial-illustrations/SKILL.md@@ -0,0 +1,163 @@+---+name: editorial-illustrations+description: >+ Generate meaning-carrying editorial data-illustrations in the monotykamary /+ Linear aesthetic (near-black grayscale, Inter display + mono labels, hairline+ framed figures) with a single coral accent. This is a GENERATIVE GUIDE, not a+ template gallery: it teaches the "claim -> geometry" method so any session can+ invent the RIGHT figure for what a post actually argues, then render it as a+ self-contained, theme-aware, reduced-motion-safe HTML/SVG figure. Use when+ writing/illustrating a blog post, essay, spec, or slide and you want a chart,+ diagram, or illustration that carries a thesis (not decoration) in the house+ style. Triggers: "make a chart/diagram/illustration for this", "visualize this+ argument", "monotykamary/Linear style figure", "editorial graphic".+---++# Editorial illustrations — claim → geometry++The look you want (monotykamary.com, linear.app/now) is not a chart library. It is+a **discipline**: every figure is a single argument rendered as geometry, framed in+a hairline box, captioned in mono uppercase with the *meaning*, drawn in grayscale+with exactly one accent. Get the discipline right and any shape reads as "house."+Copy templates blindly and it reads as slop.++**Do not reach for a fixed set of charts.** Reach for the method below and build the+figure this specific sentence needs. The six worked examples in+`references/worked-examples.md` are proof the method generalizes, not a menu.++## The core move++> Take the one sentence the figure must prove. Find that sentence's *structure*.+> Render the structure so the reader believes the sentence before reading it.++The caption is the thesis, written first. If you can't state the figure's claim in+one sentence, you don't have a figure yet, you have decoration. Stop.++## Method (run this every time)++1. **Write the claim.** One declarative sentence. This becomes the `<figcaption>`+ verbatim. Example: "Nothing is billable until work crosses the delivery boundary."++2. **Name the claim's structure.** Which of these is the sentence really about?+ Match to a geometric primitive:++ | If the claim is about… | Render it as… | Atom (§5) |+ |-------------------------------------------|------------------------------|-----------|+ | a spectrum / more-vs-less / a gradient | ordered cells, rising fill | 5a |+ | ranked magnitudes / shares / a comparison | horizontal bars, real axis | 5b |+ | a sequence with a tipping point | stage grid + traveling dot | 5a + rail |+ | mutual causation / a feedback relationship| two coupled orbits + bridge | 5d |+ | a branch / decision under uncertainty | node-and-branch SVG tree | 5c |+ | one thing changing form / a data pipeline | stage rail, a glyph per stage| 5e |+ | accumulation toward a target | stacked / filling bar | 5a/5b |+ | a boundary / inside-vs-outside | a framed region + a crossing | compose |+ | a distribution / where mass sits | dot-strip or small-multiples | compose |++ If nothing matches, **compose a new primitive** from the atoms in+ `references/design-system.md §5`. The novelty is expected and welcome; the+ *tokens and restraint* are what must stay constant.++3. **Locate the point.** Which single element proves the claim? That one gets+ `--accent` (coral). Everything else stays grayscale. One accent, maybe two.+ No point → the figure has no thesis → go back to step 1.++4. **Draw in the system.** Apply `references/design-system.md`: tokens, the+ typography law (display = Inter 480–540 tight; everything else mono, tiny,+ UPPERCASE labels), the framed-figure chrome, 720-wide SVG viewBox, hairlines+ only, no chartjunk.++5. **Add motion only if it demonstrates the claim.** A dot that pauses before a+ boundary; a pulse crossing between two loops; a signal falling down a branch.+ 2–6s, `ease-in-out`, and always killed under `prefers-reduced-motion`. If motion+ doesn't *show* the argument, omit it. Static is fine and often better.++6. **Caption it.** Mono, 8px, uppercase, above-the-rule. State the meaning, not the+ data source alone. ("…because X," not "Figure 3.")++## The aesthetic in one breath++- **Field:** matches the host — near-black `--ground:#080807` on a dark page, white/+ off-white on a light page (both token sets in `design-system.md`). Framed figures+ on a faint surface; `backdrop-filter: blur(16px)` on dark, a hairline + faint+ shadow on light.+- **Type:** Inter for the rare big display; **mono for everything inside a figure**,+ 7–11px, labels/captions UPPERCASE. Never a second sans, never a bold display.+- **Color:** grayscale ramp (`--ink → --quiet`) + **one** accent = Claude-coral+ `#D97757`, on the point only. (Set `--accent: var(--ink)` for monotykamary-faithful+ pure grayscale.)+- **Structure:** 1px hairlines, true-circle nodes, dashed = provisional/failure,+ no shadows, no gradients except a single axis-direction hairline.+- **Density:** small type, tight cells, edge-to-edge. Restraint is the style.++Full spec + copy-paste token blocks (dark AND light) + primitive CSS:+`references/design-system.md`. Worked examples with the claim→geometry reasoning:+`references/worked-examples.md`. Non-chart editorial elements (metric strip, status+aside, kicker+sigil, numbered chapter index, prose type, inline cards):+`references/elements.md`. Live rendered proof (coral house style, toggleable):+`assets/gallery.html`.++## The figure follows the host page's theme (ALWAYS)++A figure is a guest on someone's page. It must match that page's light/dark, not+impose its own. A dark exhibit panel dropped into a light article reads as a foreign+object (learned the hard way, 2026-07-22).++- **Look at the host first.** Light page → light figure. Dark page → dark figure.+ a host site may default **light** and carry its own **theme toggle** (e.g. Charter serif heads + Public Sans body,+ blue accent) that stamps `data-theme="light"|"dark"` on `<html>` — figures there+ must **follow `data-theme`**, defaulting light.+- **If the host has an explicit theme system, key the dark override off IT, not the+ media query.** Use `:root[data-theme="dark"] .yourfig { … }`, NOT+ `@media (prefers-color-scheme: dark)`. Real bug (2026-07-22): a figure keyed on the+ media query rendered **dark on the light blog** because the viewer's OS was dark and+ the page theme was light. The page's `data-theme` is the source of truth; the media+ query only applies on hosts that have no toggle. On a toggled host, match the site's own+ dark tokens (ground `#171b22`, line `#262c36`, ink `#f1f5f9`) so the figure's dark+ panel sits in the site's dark, not a foreign near-black.+- **Build token-based so it adapts.** Define the palette on the figure's own scope,+ default = the host's default theme, plus a `:root[data-theme="dark"] .fig` override+ (and a `@media (prefers-color-scheme: dark)` override too ONLY if the host has no+ toggle). Costs nothing, future-proofs the figure.+- **Coral is AA-safe per ground.** On white use `--accent:#c15f3c` for text/strokes+ (keep `#D97757` only for large node fills); on near-black use `#D97757` directly.+- The **claim→geometry method and the restraint rules are theme-independent.** Only+ the palette tokens swap. Grayscale-ramp + one coral accent holds on both grounds.++## Output contract++- One self-contained `<figure>` per illustration: inline `<style>` scoped to the+ figure (or shared token `:root`), inline SVG, no external requests.+- **Theme = host's** (see above): light default when embedded in a light page, but+ always token-based with `prefers-color-scheme` + `:root[data-theme]` overrides, and+ **reduced-motion-safe**. Both are house rules, not optional.+- For an **Artifact**: no external fonts/CDN (CSP blocks them); inline `@font-face`+ data-URIs or fall back to `system-ui`/`ui-monospace`.+- For **blog posts on your own site**: emit the figure HTML/CSS into the post body (markdown+ passes raw HTML through verbatim via `build.py`). The blog is **light**, so the+ light tokens apply; keep the dark override for portability. Rebuild with+ `python3 build.py`; the built page uses absolute asset paths so preview it via a+ local server or a self-contained standalone copy, never a bare `file://` open+ (that renders the post unstyled). See a local self-contained HTML preview.++## Verify (mandatory — this is a UI/UX output)++Per the Visual Verification rule, a DOM check is not enough. **Render it and look.**++1. Open the figure in browser-harness, screenshot it (`evidence_shot`).+2. Read the image against the claim: does the geometry make the sentence obvious?+ Is coral on the point and nowhere else? Any clipped mono text, misaligned SVG+ labels, off-by-one bar math, broken responsive stack at ≤720px?+3. Fix what you see, re-shot to prove it. Check the light variant too.+4. Confirm motion stops under reduced-motion.++## Anti-slop checklist (reject the figure if any fail)++- [ ] The figcaption is a real claim, stated in one sentence.+- [ ] The geometry encodes that claim's *structure* (not a generic chart pinned on).+- [ ] Exactly one accent element (coral), on the point.+- [ ] Every in-figure label/value/caption is mono + tiny; labels UPPERCASE.+- [ ] Hairlines only; no shadows, no gradients (bar-axis hairline excepted), no+ rounded rectangles.+- [ ] Gridlines present only if the figure is genuinely quantitative.+- [ ] Motion (if any) demonstrates the claim and dies under reduced-motion.+- [ ] Renders correctly in both dark and light, and stacks cleanly on mobile.diff --git a/skills/editorial-illustrations/assets/gallery.html b/skills/editorial-illustrations/assets/gallery.htmlnew file mode 100644index 0000000..33c59a7--- /dev/null+++ b/skills/editorial-illustrations/assets/gallery.html@@ -0,0 +1,359 @@+<!doctype html>+<html lang="en" data-theme="dark">+<head>+<meta charset="utf-8">+<meta name="viewport" content="width=device-width, initial-scale=1">+<title>Editorial illustrations — claim → geometry</title>+<link rel="preconnect" href="https://fonts.googleapis.com">+<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>+<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;480;540&family=JetBrains+Mono:wght@400;700&display=swap" rel="stylesheet">+<style>+:root{+ --ground:#080807; --ground-deep:#030303; --surface:#080807cc; --surface-solid:#0c0c0b;+ --ink:#f2f2ed; --ink-soft:#d0d0c9; --muted:#92928a; --quiet:#5f5f59;+ --line:#292925; --line-strong:#54544e;+ --accent:#D97757; --accent-soft:#e6a488;+ --sans:"Inter","Inter Variable",system-ui,sans-serif;+ --mono:"JetBrains Mono","JetBrains Mono Variable",ui-monospace,"SF Mono",Menlo,Consolas,monospace;+}+:root[data-theme="light"]{+ --ground:#f7f7f2; --ground-deep:#ecece6; --surface:#f7f7f2cc; --surface-solid:#fbfbf7;+ --ink:#191917; --ink-soft:#3d3d38; --muted:#6a6a62; --quiet:#9a9a90;+ --line:#deded6; --line-strong:#b7b7ad;+ --accent:#c15f3c; --accent-soft:#d97757;+}+:root[data-accent="mono"]{ --accent:var(--ink); --accent-soft:var(--ink-soft); }+*{box-sizing:border-box}+body{margin:0;background:var(--ground);color:var(--ink);font-family:var(--sans);+ -webkit-font-smoothing:antialiased;line-height:1.5;transition:background .3s,color .3s}+.wrap{max-width:860px;margin:0 auto;padding:0 24px 120px}+header.top{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;+ padding:56px 0 40px;flex-wrap:wrap}+h1{font-family:var(--sans);font-weight:480;letter-spacing:-.04em;font-size:clamp(30px,5vw,52px);+ line-height:1;margin:0 0 14px}+h1 em{font-style:normal;color:var(--accent)}+.sub{color:var(--muted);font-size:15px;max-width:44ch;margin:0}+.kicker{font:8px/1 var(--mono);letter-spacing:.18em;text-transform:uppercase;color:var(--quiet);+ margin:0 0 16px}+.controls{display:flex;gap:8px;flex-shrink:0}+.controls button{font:8px/1 var(--mono);letter-spacing:.1em;text-transform:uppercase;+ color:var(--muted);background:transparent;border:1px solid var(--line);padding:9px 12px;+ cursor:pointer;transition:.15s}+.controls button:hover{color:var(--ink);border-color:var(--line-strong)}+.method{border:1px solid var(--line);padding:22px;margin:0 0 8px;+ background:color-mix(in srgb,var(--surface) 60%,transparent)}+.method p{margin:0 0 12px;color:var(--ink-soft);font-size:14px}+.method p:last-child{margin:0}+.method b{color:var(--accent);font-weight:540}+.method code{font:11px var(--mono);color:var(--muted)}+.sec-label{font:8px/1 var(--mono);letter-spacing:.16em;text-transform:uppercase;color:var(--quiet);+ border-top:1px solid var(--line);padding-top:14px;margin:56px 0 -34px}+.claim{font:8px/1.5 var(--mono);letter-spacing:.06em;text-transform:uppercase;color:var(--accent-soft);+ margin:52px 0 -38px}+.claim span{color:var(--quiet)}++/* ---------- base framed figure ---------- */+.fig{border:1px solid var(--line);background:color-mix(in srgb,var(--surface) 72%,transparent);+ backdrop-filter:blur(16px);margin:52px 0;padding:20px}+.fig svg{width:100%;height:auto;display:block}+.fig figcaption{border-top:1px solid var(--line);color:var(--quiet);font:8px/1.6 var(--mono);+ letter-spacing:.04em;text-transform:uppercase;margin-top:18px;padding-top:13px}++/* ---------- 5a cells (spectrum / pipeline) ---------- */+.cells .axis,.cells .stakes{display:flex;justify-content:space-between;align-items:center;+ color:var(--quiet);font:7px/1 var(--mono);text-transform:uppercase}+.cells .axis i{flex:1;height:1px;margin-inline:12px;background:linear-gradient(90deg,var(--quiet),var(--accent))}+.cells .stakes b{color:var(--ink-soft);font-weight:450}+.cells .row{display:grid;grid-template-columns:repeat(var(--n,5),1fr);margin-block:18px}+.cells .row section{position:relative;overflow:hidden;display:flex;flex-direction:column;+ min-height:145px;padding:12px;border:1px solid var(--line);border-right:0}+.cells .row section:last-child{border-right:1px solid var(--line)}+.cells .row section>span{color:var(--quiet);font:8px/1 var(--mono)}+.cells .row section>b{margin-top:auto;color:var(--ink);font-size:11px;font-weight:540}+.cells .row section>small{margin-top:5px;min-height:32px;color:var(--muted);font:7px/1.4 var(--mono)}+.cells .row section>i{position:absolute;inset:auto 0 0;height:calc(var(--v)*100%);+ background:var(--accent);opacity:calc(.10 + var(--v)*.5);transition:height .4s,opacity .4s}+.cells .row section:hover>i{opacity:calc(.28 + var(--v)*.55)}++/* ---------- 5b bars ---------- */+.bars .grid line{stroke:var(--line);stroke-width:1}+.bars .grid text{fill:var(--quiet);font:8px var(--mono)}+.bars .track{fill:var(--ground-deep)}+.bars .fill{fill:var(--ink-soft);transition:opacity .18s}+.bars .row--accent .fill{fill:var(--accent)}+.bars .row:hover .fill,.bars .row:focus .fill{opacity:.72}+.bars .row:focus{outline:none}+.bars .label{fill:var(--muted);font:10px var(--mono)}+.bars .value{fill:var(--ink);font:700 8px var(--mono)}+.bars .row--accent .value{fill:var(--accent)}++/* ---------- process (stage grid + rail) ---------- */+.process .rail{border-top:1px dashed var(--line-strong);height:20px;margin-inline:5%;+ position:relative;margin-bottom:6px}+.process .rail::before,.process .rail::after{content:"";position:absolute;top:-3px;+ width:5px;height:5px;background:var(--ink)}+.process .rail::before{left:0}.process .rail::after{right:0}+.process .rail i{position:absolute;top:-4px;width:7px;height:7px;border:1px solid var(--accent);+ background:var(--ground);animation:travel 4.8s cubic-bezier(.5,0,.5,1) infinite}+.process .stages{display:grid;grid-template-columns:repeat(5,1fr);gap:6px}+.process .stages section{position:relative;display:flex;flex-direction:column;min-height:116px;+ padding:13px 11px;border:1px solid var(--line);background:var(--ground)}+.process .stages section>span{color:var(--quiet);font:8px/1 var(--mono)}+.process .stages section>b{margin-top:22px;color:var(--ink);font-size:11px;font-weight:540}+.process .stages section>small{margin-top:5px;color:var(--muted);font:7px/1.45 var(--mono)}+.process .stages section.is-committed{background:var(--accent);border-color:var(--accent)}+.process .stages section.is-committed>span,.process .stages section.is-committed>b,.process .stages section.is-committed>small{color:var(--ground)}++/* ---------- loops (coupled orbits) ---------- */+.loops .system{display:grid;grid-template-columns:1fr 1fr;align-items:center;gap:54px;+ min-height:310px;position:relative}+.loops .system>section>span{display:block;text-align:center;margin-bottom:10px;color:var(--quiet);+ font:8px/1 var(--mono);letter-spacing:.1em;text-transform:uppercase}+.orbit{position:relative;aspect-ratio:1/1;max-width:230px;margin:auto;border-radius:50%;+ border:1px solid var(--line-strong);animation:breathe 6s ease-in-out infinite}+.orbit.human{animation-delay:-3s}+.orbit::before{content:"";position:absolute;inset:20%;border:1px dashed var(--line);border-radius:50%}+.orbit i{position:absolute;color:var(--muted);background:var(--ground);font:normal 7px/1 var(--mono);+ text-transform:uppercase;padding:4px 6px}+.orbit i:first-child{top:-8px;left:50%;transform:translateX(-50%)}+.orbit i:nth-child(2){top:50%;right:-14px;transform:translateY(-50%)}+.orbit i:nth-child(3){bottom:-8px;left:50%;transform:translateX(-50%)}+.orbit i:nth-child(4){top:50%;left:-12px;transform:translateY(-50%)}+.orbit b{position:absolute;inset:34%;display:grid;place-items:center;border:1px solid var(--line);+ color:var(--ink);font-weight:500;text-transform:uppercase;font-size:9px;text-align:center}+.loops .bridge{position:absolute;top:50%;left:42%;right:42%;display:grid;place-items:center}+.loops .bridge::before{content:"";border-top:1px solid var(--accent);width:100%}+.loops .bridge i{position:absolute;width:6px;height:6px;border-radius:50%;background:var(--accent);+ animation:pulse 2.2s ease-in-out infinite alternate}+.loops .bridge span{margin-top:18px;color:var(--quiet);font:7px/1 var(--mono);text-transform:uppercase}++/* ---------- tree ---------- */+.tree .memory path{fill:none;stroke:var(--quiet);stroke-width:11;opacity:.08;filter:blur(6px)}+.tree .branches path{fill:none;stroke:var(--line-strong);stroke-width:1}+.tree .nodes circle{fill:var(--ground);stroke:var(--ink);stroke-width:1.4}+.tree .labels{fill:var(--muted);font:8px var(--mono);letter-spacing:1px}+.tree .signal{fill:var(--accent);opacity:0;transform-box:view-box;animation:signal 3.8s linear infinite}++/* ---------- state-flow rail ---------- */+.flow .rail{display:grid;grid-template-columns:1fr 28px 1fr 28px 1fr;align-items:stretch}+.flow .rail>section{display:flex;flex-direction:column;min-height:148px;padding:14px;+ border:1px solid var(--line);background:color-mix(in srgb,var(--surface-solid) 70%,transparent)}+.flow .rail>section>span{color:var(--quiet);font:8px/1 var(--mono);letter-spacing:.1em;text-transform:uppercase}+.flow .rail>section>b{margin-top:8px;color:var(--ink);font-size:11px;font-weight:520;line-height:1.35}+.flow .focus{box-shadow:inset 0 2px var(--accent)}+.flow .arrow{display:grid;place-items:center;color:var(--quiet);font:11px/1 var(--mono)}+.flow .evt{display:flex;align-items:end;gap:5px;height:40px;margin-top:auto}+.flow .evt em{width:5px;height:5px;background:var(--quiet);animation:evt 1.8s steps(2) infinite}+.flow .evt em:nth-child(2){background:var(--ink);height:18px;animation-delay:-.4s}+.flow .evt em:nth-child(3){background:var(--ink-soft);height:30px;animation-delay:-.8s}+.flow .evt em:nth-child(4){height:12px;animation-delay:-1.2s}+.flow .stack{display:grid;gap:5px;margin-top:auto}+.flow .stack i{height:7px;background:var(--quiet)}+.flow .stack i[data-tone="critical"]{background:var(--accent);width:92%}+.flow .stack i[data-tone="relevant"]{background:var(--ink-soft);width:72%}+.flow .stack i[data-tone="info"]{background:var(--quiet);width:48%}+.flow .readout{margin-top:auto;border:1px solid var(--line);color:var(--ink);font:8px/1 var(--mono);padding:8px}+.flow .readout i{display:inline-block;width:6px;height:6px;margin-right:7px;background:var(--accent);border:1px solid var(--ink)}++/* ---------- NEW #7: accumulation toward a target ---------- */+.accrue .meter{display:grid;gap:14px;margin-block:6px}+.accrue .m{display:grid;grid-template-columns:120px 1fr 40px;align-items:center;gap:14px}+.accrue .m span{font:9px/1 var(--mono);text-transform:uppercase;color:var(--muted)}+.accrue .m .bar{height:10px;background:var(--ground-deep);position:relative;border:1px solid var(--line)}+.accrue .m .bar i{position:absolute;inset:0 auto 0 0;width:calc(var(--v)*100%);background:var(--ink-soft)}+.accrue .m.hit .bar i{background:var(--accent)}+.accrue .m .bar::after{content:"";position:absolute;top:-4px;bottom:-4px;left:calc(var(--target)*100%);+ width:1px;background:var(--accent)}+.accrue .m em{font:700 9px/1 var(--mono);font-style:normal;color:var(--quiet);text-align:right}+.accrue .m.hit em{color:var(--accent)}+.accrue .legend{display:flex;gap:20px;color:var(--quiet);font:7px/1 var(--mono);text-transform:uppercase;margin-top:16px}++/* ---------- NEW #8: boundary / inside-vs-outside ---------- */+.boundary .field{position:relative;height:220px;border:1px solid var(--line);overflow:hidden}+.boundary .zone{position:absolute;top:0;bottom:0;display:grid;place-items:center;text-align:center;padding:16px}+.boundary .zone span{font:8px/1.5 var(--mono);text-transform:uppercase;letter-spacing:.1em}+.boundary .out{left:0;right:50%;color:var(--muted)}+.boundary .in{left:50%;right:0;background:color-mix(in srgb,var(--accent) 8%,transparent);color:var(--ink-soft)}+.boundary .wall{position:absolute;top:0;bottom:0;left:50%;width:1px;background:var(--accent)}+.boundary .wall b{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);background:var(--ground);+ color:var(--accent);font:7px/1 var(--mono);text-transform:uppercase;padding:6px 8px;white-space:nowrap;+ border:1px solid var(--accent)}+.boundary .dot{position:absolute;top:calc(var(--y)*1%);width:6px;height:6px;border-radius:50%;background:var(--ink)}+.boundary .cross{animation:cross 5s ease-in-out infinite}+@keyframes cross{0%{left:12%;opacity:.4}45%{left:44%;opacity:.4}55%{left:56%;opacity:1;background:var(--accent)}100%{left:82%;opacity:1;background:var(--accent)}}++/* ---------- keyframes ---------- */+@keyframes travel{0%{left:0}45%,65%{left:58%}100%{left:calc(100% - 7px)}}+@keyframes pulse{0%{opacity:.25;left:0}100%{opacity:1;left:calc(100% - 6px)}}+@keyframes breathe{50%{transform:rotate(2deg) scale(1.015)}}+@keyframes signal{0%,12%{opacity:0;transform:translateY(0)}24%{opacity:1}72%,82%{opacity:1;transform:translateY(70px)}94%,100%{opacity:0;transform:translateY(70px)}}+@keyframes evt{0%,100%{opacity:.25}50%{opacity:1}}++@media (max-width:720px){+ .cells .row,.process .stages{grid-template-columns:1fr}+ .cells .row section,.process .stages section{border-right:1px solid var(--line);min-height:84px}+ .loops .system,.flow .rail{grid-template-columns:1fr;gap:32px}+ .loops .bridge,.cells .stakes b{display:none}+ .flow .arrow{transform:rotate(90deg);min-height:26px}+ .accrue .m{grid-template-columns:90px 1fr 34px}+}+@media (prefers-reduced-motion:reduce){*{animation:none !important}}+</style>+</head>+<body>+<div class="wrap">+ <header class="top">+ <div>+ <p class="kicker">Design system · monotykamary × linear × editorial web</p>+ <h1>Claim <em>→</em> geometry</h1>+ <p class="sub">Every figure is one argument rendered as geometry. Grayscale, hairline-framed, mono-captioned, with a single coral accent on the point. Hover the figures; they respond.</p>+ </div>+ <div class="controls">+ <button id="theme">◐ Theme</button>+ <button id="accent">● Coral</button>+ </div>+ </header>++ <div class="method">+ <p><b>1.</b> Write the claim in one sentence — it becomes the caption. <b>2.</b> Name the claim's <em style="font-style:normal;color:var(--ink)">structure</em> (spectrum? ranking? sequence? mutual causation? branch? transformation?). <b>3.</b> That structure picks the geometry. <b>4.</b> Put coral on the one element that <em style="font-style:normal;color:var(--ink)">is</em> the point. <b>5.</b> Motion only if it demonstrates the argument.</p>+ <p><code>The six below are the method applied — not a fixed menu. The last two show it generalizing to new shapes.</code></p>+ </div>++ <p class="sec-label">Worked examples · the method applied</p>++ <!-- 1 spectrum -->+ <p class="claim"><span>Structure: spectrum ·</span> Autonomy isn't binary; the useful position slides.</p>+ <figure class="fig cells" style="--n:5">+ <div class="axis"><span>More oversight</span><i></i><span>More delegation</span></div>+ <div class="row">+ <section style="--v:.1"><span>01</span><b>Complete</b><small>Human decides every move</small><i></i></section>+ <section style="--v:.3"><span>02</span><b>Suggest</b><small>AI proposes local changes</small><i></i></section>+ <section style="--v:.5"><span>03</span><b>Pair</b><small>Shared iteration loop</small><i></i></section>+ <section style="--v:.75"><span>04</span><b>Delegate</b><small>AI executes bounded work</small><i></i></section>+ <section style="--v:1"><span>05</span><b>Roam</b><small>AI owns the trajectory</small><i></i></section>+ </div>+ <div class="stakes"><span>Throwaway prototype</span><b>Move deliberately, not permanently →</b><span>Production system</span></div>+ <figcaption>The useful position is contextual: autonomy moves with blast radius, expertise, and feedback quality.</figcaption>+ </figure>++ <!-- 2 bars -->+ <p class="claim"><span>Structure: ranked magnitudes ·</span> Developers avoid high-stakes AI work; trust is low.</p>+ <figure class="fig bars">+ <svg viewBox="0 0 720 336" role="img" aria-label="Selected developer-survey figures, share of respondents">+ <g class="grid">+ <g><line x1="246" x2="246" y1="18" y2="308"/><text x="246" y="12" text-anchor="middle">0</text></g>+ <g><line x1="352.5" x2="352.5" y1="18" y2="308"/><text x="352.5" y="12" text-anchor="middle">25</text></g>+ <g><line x1="459" x2="459" y1="18" y2="308"/><text x="459" y="12" text-anchor="middle">50</text></g>+ <g><line x1="565.5" x2="565.5" y1="18" y2="308"/><text x="565.5" y="12" text-anchor="middle">75</text></g>+ <g><line x1="672" x2="672" y1="18" y2="308"/><text x="672" y="12" text-anchor="middle">100</text></g>+ </g>+ <g class="row row--accent" tabindex="0"><text class="label" x="0" y="56">Avoid deployment / monitoring</text><rect class="track" x="246" y="38" width="426" height="24"/><rect class="fill" x="246" y="38" width="323.8" height="24"/><text class="value" x="561" y="55" text-anchor="end">76%</text></g>+ <g class="row row--accent" tabindex="0"><text class="label" x="0" y="108">Reject professional vibe coding</text><rect class="track" x="246" y="90" width="426" height="24"/><rect class="fill" x="246" y="90" width="306.7" height="24"/><text class="value" x="544" y="107" text-anchor="end">72%</text></g>+ <g class="row" tabindex="0"><text class="label" x="0" y="160">Avoid AI project planning</text><rect class="track" x="246" y="142" width="426" height="24"/><rect class="fill" x="246" y="142" width="293.9" height="24"/><text class="value" x="531" y="159" text-anchor="end">69%</text></g>+ <g class="row" tabindex="0"><text class="label" x="0" y="212">Cite almost-right output</text><rect class="track" x="246" y="194" width="426" height="24"/><rect class="fill" x="246" y="194" width="281.2" height="24"/><text class="value" x="519" y="211" text-anchor="end">66%</text></g>+ <g class="row row--accent" tabindex="0"><text class="label" x="0" y="264">Express high trust</text><rect class="track" x="246" y="246" width="426" height="24"/><rect class="fill" x="246" y="246" width="11" height="24"/><text class="value" x="290" y="263" text-anchor="end">2.6%</text></g>+ </svg>+ <figcaption>Selected developer-survey figures cited in this analysis · share of respondents</figcaption>+ </figure>++ <!-- 3 process -->+ <p class="claim"><span>Structure: sequence with a threshold ·</span> Nothing bills until work crosses the boundary.</p>+ <figure class="fig process">+ <div class="rail" aria-hidden="true"><i></i></div>+ <div class="stages">+ <section><span>01</span><b>Compose</b><small>Measured locally</small></section>+ <section><span>02</span><b>Queue</b><small>Staged, not billed</small></section>+ <section><span>03</span><b>Invoke</b><small>Tokens + tool time</small></section>+ <section><span>04</span><b>Deliver</b><small>Outcome lands</small></section>+ <section class="is-committed"><span>05</span><b>Commit</b><small>Receipt changes</small></section>+ </div>+ <figcaption>Nothing becomes billable until the work crosses the delivery boundary.</figcaption>+ </figure>++ <!-- 4 loops -->+ <p class="claim"><span>Structure: mutual causation ·</span> Evidence sharpens judgment; judgment ranks evidence.</p>+ <figure class="fig loops">+ <div class="system">+ <section><span>Technical loop</span><div class="orbit"><i>Context</i><i>Action</i><i>Tests</i><i>Repair</i><b>Evidence</b></div></section>+ <section><span>Human loop</span><div class="orbit human"><i>Observe</i><i>Question</i><i>Review</i><i>Learn</i><b>Judgment</b></div></section>+ <div class="bridge"><i></i><span>Calibration</span></div>+ </div>+ <figcaption>Agent evidence sharpens human judgment; human judgment decides which evidence matters.</figcaption>+ </figure>++ <!-- 5 tree -->+ <p class="claim"><span>Structure: branch under uncertainty ·</span> Preserve inspectable conditions, not a transcript.</p>+ <figure class="fig tree">+ <svg viewBox="0 0 720 330" role="img" aria-labelledby="tree-cap">+ <g class="memory"><path d="M360 290V220M360 220 190 150M360 220 530 150M190 150 90 70M190 150 260 70M530 150 460 70M530 150 630 70"/></g>+ <g class="branches"><path d="M360 290V220M360 220 190 150M360 220 530 150M190 150 90 70M190 150 260 70M530 150 460 70M530 150 630 70"/></g>+ <g class="nodes"><circle cx="360" cy="290" r="9"/><circle cx="360" cy="220" r="7"/><circle cx="190" cy="150" r="6"/><circle cx="530" cy="150" r="6"/><circle cx="90" cy="70" r="5"/><circle cx="260" cy="70" r="5"/><circle cx="460" cy="70" r="5"/><circle cx="630" cy="70" r="5"/></g>+ <g class="labels"><text x="360" y="322" text-anchor="middle">OBSERVED STATE</text><text x="190" y="178" text-anchor="middle">VERIFIED</text><text x="530" y="178" text-anchor="middle">UNKNOWN</text><text x="90" y="48" text-anchor="middle">RECOMPUTE</text><text x="260" y="48" text-anchor="middle">REUSE</text><text x="460" y="48" text-anchor="middle">QUERY</text><text x="630" y="48" text-anchor="middle">DEFER</text></g>+ <circle class="signal" cx="360" cy="220" r="2"/>+ </svg>+ <figcaption id="tree-cap">A recursive evaluation tree preserves inspectable conditions at every branch instead of an irreversible reasoning transcript.</figcaption>+ </figure>++ <!-- 6 state-flow -->+ <p class="claim"><span>Structure: transformation of form ·</span> Events become conditions become state.</p>+ <figure class="fig flow" aria-labelledby="flow-cap">+ <div class="rail">+ <section><span>01 · events</span><b>Raw agent history</b><i class="evt" aria-hidden="true"><em></em><em></em><em></em><em></em></i></section>+ <span class="arrow" aria-hidden="true">→</span>+ <section class="focus"><span>02 · observe</span><b>Compressed conditions</b><div class="stack" aria-hidden="true"><i data-tone="critical"></i><i data-tone="relevant"></i><i data-tone="info"></i></div></section>+ <span class="arrow" aria-hidden="true">→</span>+ <section><span>03 · reconcile</span><b>Declarative state</b><div class="readout"><i></i> READY</div></section>+ </div>+ <figcaption id="flow-cap">Event history becomes observable conditions, which controllers reconcile into state.</figcaption>+ </figure>++ <p class="sec-label">The method generalizes · shapes not in the original six</p>++ <!-- 7 accumulation -->+ <p class="claim"><span>Structure: accumulation toward a target ·</span> Coverage is close, but one gate is unmet.</p>+ <figure class="fig accrue">+ <div class="meter">+ <div class="m hit" style="--v:.9;--target:.8"><span>Unit tests</span><div class="bar"><i></i></div><em>90</em></div>+ <div class="m hit" style="--v:.84;--target:.8"><span>Integration</span><div class="bar"><i></i></div><em>84</em></div>+ <div class="m" style="--v:.62;--target:.8"><span>E2E flows</span><div class="bar"><i></i></div><em>62</em></div>+ <div class="m hit" style="--v:.95;--target:.8"><span>Lint / types</span><div class="bar"><i></i></div><em>95</em></div>+ </div>+ <div class="legend"><span>Coral tick = required threshold (80)</span><span>Coral fill = target met</span></div>+ <figcaption>Three of four gates clear the bar; end-to-end coverage is the one that ships the risk.</figcaption>+ </figure>++ <!-- 8 boundary -->+ <p class="claim"><span>Structure: boundary / inside-vs-outside ·</span> Trust is earned only by crossing review.</p>+ <figure class="fig boundary">+ <div class="field">+ <div class="zone out"><span>Unreviewed<br>agent output</span></div>+ <div class="zone in"><span>Merged &<br>trusted</span></div>+ <div class="wall"><b>Human review</b></div>+ <div class="dot" style="--y:28"></div>+ <div class="dot" style="--y:70;left:22%"></div>+ <div class="dot cross" style="--y:48"></div>+ </div>+ <figcaption>Output stays provisional until it crosses the one boundary that confers trust.</figcaption>+ </figure>++ <p class="sec-label">Reference</p>+ <div class="method" style="margin-top:34px">+ <p><code>skill: .claude/skills/editorial-illustrations/</code></p>+ <p style="color:var(--muted);font-size:13px">SKILL.md = the method · references/design-system.md = tokens + primitive CSS · references/worked-examples.md = the six with claim→geometry reasoning. Accent swaps in one token; toggle grayscale above to see the monotykamary-faithful mode.</p>+ </div>+</div>++<script>+const root=document.documentElement;+document.getElementById('theme').onclick=()=>{+ root.dataset.theme = root.dataset.theme==='light'?'dark':'light';+};+const ab=document.getElementById('accent');+ab.onclick=()=>{+ const mono = root.dataset.accent==='mono';+ root.dataset.accent = mono?'':'mono';+ ab.textContent = mono?'● Coral':'● Grayscale';+};+</script>+</body>+</html>diff --git a/skills/editorial-illustrations/references/design-system.md b/skills/editorial-illustrations/references/design-system.mdnew file mode 100644index 0000000..8339b5f--- /dev/null+++ b/skills/editorial-illustrations/references/design-system.md@@ -0,0 +1,202 @@+# Design system — the raw grammar++Reverse-engineered from the rendered source of **monotykamary.com** posts and+**linear.app/now** (2026-07-22). Both share one DNA; this file is the extracted,+coral-adapted building set. Copy tokens and base rules verbatim; invent the figure+markup per post (see `SKILL.md` for the method).++## 1. Tokens (coral house style)++Grayscale base (the mono DNA), **one** accent = Claude-coral. The accent marks the+*point* of the figure and nothing else. **Pick the token set that matches the host+page** (light page → light set), and ship the other as an override so the figure+adapts. Dark set first, then two light variants (a warm generic one and the exact+host-site-matched one).++```css+:root {+ /* surfaces */+ --ground: #080807; /* page / deepest field */+ --ground-deep: #030303; /* recessed track behind fills */+ --surface: #080807cc; /* framed-figure background (alpha)*/+ --surface-solid: #0c0c0b; /* solid card inside a figure */+ /* ink ramp */+ --ink: #f2f2ed; /* primary text, strong marks */+ --ink-soft: #d0d0c9; /* secondary fills, sub-headlines */+ --muted: #92928a; /* labels */+ --quiet: #5f5f59; /* axis numbers, captions, index */+ /* structure */+ --line: #292925; /* hairline borders, gridlines */+ --line-strong: #54544e; /* branch strokes, dashed rails */+ /* THE one accent */+ --accent: #D97757; /* Claude-coral — the single color */+ --accent-soft: #e6a488; /* coral tint for a second beat */+ /* type */+ --sans: "Inter", "Inter Variable", system-ui, sans-serif;+ --mono: "JetBrains Mono", "JetBrains Mono Variable", ui-monospace,+ "SF Mono", Menlo, Consolas, monospace;+}++/* Light variant A — warm, monotykamary-flavored inverted field. */+:root[data-theme="light"], .light {+ --ground:#f7f7f2; --ground-deep:#ecece6; --surface:#f7f7f2cc; --surface-solid:#fbfbf7;+ --ink:#191917; --ink-soft:#3d3d38; --muted:#6a6a62; --quiet:#9a9a90;+ --line:#deded6; --line-strong:#b7b7ad;+ --accent:#c15f3c; --accent-soft:#d97757; /* coral darkened for AA on light */+}++/* Light variant B — EXACT host-site match. Use this for blog-embedded figures.+ Blog tokens: --bg:#f7f8fb, surface #fff, text #111827, muted #64748b,+ border #e2e8f0, body font JetBrains Mono. Cool grays, coral accent. */+:root[data-theme="host"], .host {+ --ground:#ffffff; --ground-deep:#f1f3f7; --surface:#ffffff; --surface-solid:#ffffff;+ --ink:#111827; --ink-soft:#334155; --muted:#64748b; --quiet:#94a3b8;+ --line:#e6e8ee; --line-strong:#cbd5e1;+ --accent:#c15f3c; /* coral, AA-safe on white for text/strokes */+ --accent-node:#d97757; /* house coral for large node fills only */+}+```++On a light ground, drop `backdrop-filter: blur()` (nothing to blur over white) and+add a faint `box-shadow: 0 1px 2px rgba(16,24,40,.04)` on the frame so it lifts off+the page. On dark, keep the blur and no shadow.++Original grayscale-faithful mode: set `--accent: var(--ink)` (accent == white). That+is monotykamary 1:1. Coral is our deviation, applied as a single token so it is+one line to switch.++## 2. Typography law++- **Display** = `--sans`, weight **480–540**, tight tracking **-0.03em to -0.06em**,+ line-height ~0.98. Big and quiet. (monotykamary h1 = 68px / weight 480 / -4px.)+- **Everything else in a figure is `--mono`**: labels, axis numbers, values,+ captions, the index numerals (`01 02 03`). Tiny — **7px to 11px**.+- **Labels & captions are UPPERCASE**, `letter-spacing: 0.04em–0.1em`.+- Values that carry the number are `font-weight: 700`, colored `--ink` or `--accent`.+- Never mix a second sans. Never use a display weight above ~560.++Observed sizes (use as the scale): caption/axis **7–8px**, label **10px**,+figure sub-headline (`<b>`) **11px**, index **8px**.++## 3. The framed figure (chrome)++Every illustration is a `<figure>` with a hairline frame and a mono UPPERCASE+`<figcaption>` that states the *meaning*, divided by a top rule.++```css+.fig { /* base frame for every illustration */+ border: 1px solid var(--line);+ background: color-mix(in srgb, var(--surface) 72%, transparent);+ backdrop-filter: blur(16px);+ margin: 52px 0;+ padding: 20px;+}+.fig figcaption {+ border-top: 1px solid var(--line);+ color: var(--quiet);+ font: 8px/1.6 var(--mono);+ letter-spacing: 0.04em;+ text-transform: uppercase;+ margin-top: 18px;+ padding-top: 13px;+}+.fig svg { width: 100%; height: auto; display: block; }+```++SVG figures use a **720-wide viewBox** (`viewBox="0 0 720 <h>"`) so labels stay+crisp and math is easy. Give every figure `role="img"` + `aria-label`, or+`aria-labelledby` pointing at the figcaption.++## 4. Restraint rules (what makes it not-slop)++1. **Grayscale + exactly one accent.** Coral appears on 1–2 elements: the row that+ is the point, the committed state, the live signal. If everything is coral,+ nothing is.+2. **Hairlines only.** 1px borders, 1px gridlines. No drop shadows except the+ `inset 0 2px var(--ink)` focus underline. No rounded corners except true circles+ (nodes, orbit).+3. **No chartjunk.** Gridlines only when the figure is quantitative (a real axis).+ No legend if labels sit on the marks. No 3D, no gradients except a single+ axis-direction hairline gradient (`--quiet → --ink`).+4. **Density is the aesthetic.** Small mono type, tight cells, edge-to-edge. White+ space is structural, not padding.+5. **Motion is meaning or nothing.** One subtle loop that *demonstrates the claim*+ (a signal travelling a pipeline, a bridge pulse between two loops). 2–6s,+ `ease-in-out`. Always wrap in `@media (prefers-reduced-motion: reduce)` to kill it.++## 5. Reusable primitives (CSS blocks)++These are the atoms observed across the six worked examples. Compose them into new+figures; do not treat them as fixed charts.++### 5a. Cell grid (spectrum / pipeline / rail)+Row of bordered cells, each with an index, a bold label, a small descriptor, and an+optional bottom "fill" bar whose height/opacity encodes a value.++```css+.cells { display:grid; grid-template-columns:repeat(var(--n,5),1fr); }+.cells section { position:relative; overflow:hidden; display:flex; flex-direction:column;+ min-height:145px; padding:12px; border:1px solid var(--line); border-right:0; }+.cells section:last-child { border-right:1px solid var(--line); }+.cells section > span { color:var(--quiet); font:8px/1 var(--mono); } /* index */+.cells section > b { margin-top:auto; color:var(--ink); font-size:11px; font-weight:540; }+.cells section > small { margin-top:5px; min-height:32px; color:var(--muted); font:7px/1.4 var(--mono); }+/* value-as-fill: set --v (0..1) per cell */+.cells section > i { position:absolute; inset:auto 0 0; height:calc(var(--v)*100%);+ background:var(--accent); opacity:calc(.10 + var(--v)*.5); transition:height .4s; }+.cells section:hover > i { opacity:calc(.25 + var(--v)*.6); }+```++### 5b. Horizontal bars (ranked magnitude)+SVG, 720 viewBox. Track = `--ground-deep`, fill = `--ink-soft`; the **point row**+fill = `--accent`. Value label mono-bold, right-aligned inside/after the bar.++```css+.bars .track { fill:var(--ground-deep); }+.bars .fill { fill:var(--ink-soft); transition:opacity .18s; }+.bars .row--accent .fill { fill:var(--accent); }+.bars .row:hover .fill, .bars .row:focus .fill { opacity:.72; }+.bars .label { fill:var(--muted); font:10px var(--mono); }+.bars .grid line { stroke:var(--line); }+.bars .grid text { fill:var(--quiet); font:8px var(--mono); }+.bars .value { fill:var(--ink); font:700 8px var(--mono); }+.bars .row--accent .value { fill:var(--accent); }+```+Bar math (viewBox 720, plot x0=246 → x1=672, so width=426): `fill_w = 426 * pct/100`.++### 5c. Node + branch (tree / decision)+SVG circles on `--ground` with `--ink` stroke; branch paths `--line-strong` 1px;+an optional blurred "memory" path underneath (same path, `--quiet`, blur(6px),+opacity .08) for depth; a small animated `--accent` signal dot travelling a branch.++### 5d. Orbit (a cyclic loop)+A `border-radius:50%` ring (`--line-strong`) with a dashed inner ring (`inset:20%`),+four mono labels pinned N/E/S/W, and a bold center term. Breathe animation optional.+Two orbits + a pulsing bridge line = *coupled* loops.++### 5e. Stage rail (transformation flow)+`grid-template-columns:1fr 28px 1fr 28px 1fr` — cards separated by mono `→` arrows.+The focus stage gets `box-shadow: inset 0 2px var(--accent)`. Inside a card, tiny+animated glyphs (bars pulsing = event stream; stacked bars = compressed conditions;+a `state-readout` chip = reconciled state).++## 6. Animations (opt-in, reduced-motion-safe)++```css+@keyframes travel { 0%{left:0} 45%,65%{left:58%} 100%{left:calc(100% - 7px)} }+@keyframes pulse { 0%{opacity:.25;left:0} 100%{opacity:1;left:calc(100% - 6px)} }+@keyframes breathe { 50%{transform:rotate(2deg) scale(1.015)} }+@keyframes signal { 0%,12%{opacity:0;transform:translateY(0)} 24%{opacity:1}+ 72%,82%{opacity:1;transform:translateY(70px)}+ 94%,100%{opacity:0;transform:translateY(70px)} }+@keyframes evt { 0%,100%{opacity:.25} 50%{opacity:1} }+@media (prefers-reduced-motion: reduce){ * { animation:none !important; } }+```+SVG-animated marks need `transform-box: view-box`.++## 7. Fonts++Self-host or `@font-face` Inter + JetBrains Mono for fidelity. Acceptable fallback:+`system-ui` + `ui-monospace`. Linear uses Berkeley Mono; monotykamary uses JetBrains+Mono — both read identically at these sizes. Do **not** ship Google-Fonts `<link>`+in an Artifact (CSP blocks it); inline `@font-face` with data-URIs or fall back.diff --git a/skills/editorial-illustrations/references/elements.md b/skills/editorial-illustrations/references/elements.mdnew file mode 100644index 0000000..6327b46--- /dev/null+++ b/skills/editorial-illustrations/references/elements.md@@ -0,0 +1,185 @@+# Editorial elements — the non-chart vocabulary++Beyond the figures, monotykamary.com and linear.app carry a set of reusable **page+elements** that give a post its editorial density: stat strips, status asides,+kickers, numbered chapter indexes, prose typography, inline cards. All extracted+from rendered source (2026-07-22). Same rules as the figures: mono for labels/data,+UPPERCASE micro-labels, hairlines, one coral accent, tokens from `design-system.md`+(pick the set matching the host page — light for a light blog).++Use these to lift a whole article, not just its charts.++---++## 1. Metric strip — a row of headline numbers++For 3–5 punchy figures (throughput, cost, counts). Big mono number + tiny uppercase+mono label, hairline-divided cells, ruled top and bottom.++```html+<figure class="metric-strip">+ <div>+ <div class="metric"><strong>75</strong><span>reference tokens / second</span></div>+ <div class="metric"><strong>3s</strong><span>typing burst gap</span></div>+ <div class="metric"><strong>50ms</strong><span>held-key collapse</span></div>+ <div class="metric"><strong>$0</strong><span>idle without output</span></div>+ </div>+</figure>+```+```css+.metric-strip{border-block:1px solid var(--line);margin:52px 0;padding:24px 0}+.metric-strip>div{display:grid;grid-template-columns:repeat(4,1fr)}+.metric{display:flex;flex-direction:column;justify-content:space-between;min-height:78px;padding:0 22px;border-right:1px solid var(--line)}+.metric:first-child{padding-left:0}.metric:last-child{border:0;padding-right:0}+.metric strong{font:490 30px/1.1 var(--mono);letter-spacing:-.05em;color:var(--ink)}+.metric span{font:7.5px/1.6 var(--mono);letter-spacing:.1em;text-transform:uppercase;color:var(--quiet)}+```+Accent one number (`color:var(--accent)`) only if one is the point.++---++## 2. Status aside — the "state of this piece" sidebar++A sticky metadata rail: STATUS (with a live dot), last revision, active repo/branch.+Signals a living document. On monotykamary it sits in a `post-grid` two-column layout+(`minmax(0,760px) minmax(200px,260px)`, gap 80px).++```html+<aside class="post-context">+ <div><span>Status</span><b><i></i>Still testing this</b></div>+ <div><span>Last substantial revision</span><b>July 20, 2026</b></div>+ <div><span>Active branch or repository</span>+ <a href="…">inloopstudio-team/pi-ledger<small>branch / main</small></a></div>+</aside>+```+```css+.post-context{display:grid;position:sticky;top:30px;border-top:1px solid var(--line-strong)}+.post-context>div{border-bottom:1px solid var(--line);padding:17px 0}+.post-context span{display:block;margin-bottom:8px;font:8px/1.5 var(--mono);letter-spacing:.08em;text-transform:uppercase;color:var(--quiet)}+.post-context b,.post-context a{display:block;font-weight:450;color:var(--ink-soft);overflow-wrap:anywhere}+.post-context b i{display:inline-block;width:5px;height:5px;margin-right:8px;background:currentColor;box-shadow:0 0 0 3px color-mix(in srgb,currentColor 12%,transparent)}+.post-context a small{display:block;margin-top:5px;font-size:8px;color:var(--quiet)}+```+The dot `i` can be colored by state (coral = active, quiet = settled).++---++## 3. Kicker + sigil — the eyebrow above a title++A tiny hand-drawn SVG mark + an uppercase mono status word. The sigil is a 32-box+with two hairline "trace" paths (one faint "memory" ghost) and a node dot; it's the+site's recurring signature. Cheap to redraw per post with a different trace.++```html+<div class="post-kicker">+ <svg class="post-sigil" viewBox="0 0 32 32" aria-hidden="true">+ <rect x=".5" y=".5" width="31" height="31" class="frame"/>+ <path class="trace trace--memory" d="M5 25C10 23 10 11 16 9S23 14 28 5"/>+ <path class="trace" d="M5 23C11 21 10 13 16 11S22 16 28 5"/>+ <circle cx="16" cy="11" r="1.6"/>+ </svg>+ <p>Still testing this</p>+</div>+```+```css+.post-kicker{display:flex;align-items:center;gap:10px;margin-bottom:28px}+.post-kicker p{margin:0;font:9px/1 var(--mono);letter-spacing:.1em;text-transform:uppercase;color:var(--muted)}+.post-sigil{width:26px;height:26px;overflow:visible}+.post-sigil .frame{fill:var(--surface);stroke:var(--line)}+.post-sigil .trace{fill:none;stroke:var(--ink);stroke-width:1}+.post-sigil .trace--memory{stroke:var(--quiet);opacity:.35}+.post-sigil circle{fill:var(--accent);stroke:var(--ink);stroke-width:1}+```++---++## 4. Numbered chapter index (Linear /method)++For a long piece with real sections: uppercase group label, then rows of+`title …… N.N` with dotted dividers between groups. The decimals are mono ++`tabular-nums`. Only use when the content genuinely is an ordered sequence.++```html+<nav class="chapter-index">+ <div class="chapter">+ <span class="chapter__group">Direction</span>+ <a><b>Set the product direction</b><em>2.1</em></a>+ <a><b>Set useful goals</b><em>2.2</em></a>+ <a><b>Prioritize enablers and blockers</b><em>2.3</em></a>+ </div>+</nav>+```+```css+.chapter{border-top:1px dashed var(--line-strong);padding-top:18px;margin-top:26px}+.chapter__group{font:9px/1 var(--mono);letter-spacing:.14em;text-transform:uppercase;color:var(--ink)}+.chapter a{display:flex;justify-content:space-between;align-items:baseline;gap:16px;padding:9px 0;color:var(--muted);text-decoration:none}+.chapter a:hover b{color:var(--ink)}+.chapter b{font-weight:400;font-size:16px}+.chapter em{font:10px/1 var(--mono);font-style:normal;font-variant-numeric:tabular-nums;color:var(--quiet)}+```++---++## 5. Inline invitation card — a link that matters++A full-width bordered CTA row: label, mono sub-detail, animated arrow. For "go look+at the repo / read the next thing."++```html+<a class="article-invitation" href="…">+ <span>Have a look</span><small>inloopstudio-team/pi-ledger / main</small><b>→</b>+</a>+```+```css+.article-invitation{display:grid;grid-template-columns:1fr auto 30px;align-items:center;gap:20px;border-block:1px solid var(--line-strong);margin-top:76px;padding:22px 0;text-decoration:none;color:var(--ink)}+.article-invitation>span{font-size:20px;letter-spacing:-.025em}+.article-invitation small{font:8px/1.5 var(--mono);color:var(--quiet)}+.article-invitation b{font-weight:400;transition:transform .2s}+.article-invitation:hover b{transform:translateX(5px)}+```+Same skeleton, smaller, makes the **next-post** footer nav.++---++## 6. Prose typography (the body around the figures)++So embedded figures don't clash with the running text, match this scale. Body in+`--sans` (a host site may pin its own stack, e.g. Charter serif heads, Public Sans+body, JetBrains Mono for labels/code), heads+tight `--sans`.++```css+.prose{font:16px/1.72 var(--sans);color:var(--muted)}+.prose h2{margin:70px 0 18px;font:540 27px/1.18 var(--sans);letter-spacing:-.03em;color:var(--ink)}+.prose h3{margin:52px 0 13px;font:540 20px/1.25 var(--sans);letter-spacing:-.03em;color:var(--ink)}+.prose strong{font-weight:620;color:var(--ink-soft)}+.prose a{color:var(--ink);text-decoration:underline;text-decoration-color:var(--line-strong);text-underline-offset:3px}+.prose a:hover{text-decoration-color:var(--ink)}+.prose blockquote{border-left:1px solid var(--ink);padding:4px 0 4px 20px;color:var(--ink-soft)}+.prose code{font:.86em/1.6 var(--mono);color:var(--ink)}+.prose pre{border:1px solid var(--line);background:var(--surface);padding:17px;overflow-x:auto}+.prose hr{border:0;border-top:1px solid var(--line);margin:52px 0}+```++---++## 7. Obsession / lede block — a bordered manifesto opener++Left-hairline headline block for the top of a flagship post: big display headline,+one-line description, a `dt/dd` meta row. The `::before`/`::after` draw an L-bracket+on the left edge.++Key CSS: `border-block:1px solid var(--line-strong)`, a `1px` absolute bar down the+left, headline `clamp(42px,5.5vw,68px)/0.98` weight 480 letter-spacing -.06em, meta+row of `dt` (8px mono uppercase quiet) + `dd` (10px mono ink-soft).++---++## When to reach for these vs a figure++- The claim has a **structure** (spectrum, ranking, branch, loop…) → a figure+ (`worked-examples.md`).+- You just need **editorial furniture** (headline numbers, status, section index,+ a strong link) → an element here.+- A flagship post uses both: obsession lede → prose with 1–2 figures → metric strip+ → invitation card → next-post nav, with a status aside in the margin.diff --git a/skills/editorial-illustrations/references/worked-examples.md b/skills/editorial-illustrations/references/worked-examples.mdnew file mode 100644index 0000000..37a37c3--- /dev/null+++ b/skills/editorial-illustrations/references/worked-examples.md@@ -0,0 +1,260 @@+# Worked examples — the method applied++These six are **case studies**, not a template menu. Each shows the same move:+*a sentence-length claim → the geometric primitive that makes the claim obvious →+the minimum markup that renders it.* Study the reasoning column; then build the+figure your post actually needs. HTML is the real extracted source (monotykamary,+2026-07-22), lightly cleaned. Swap the accent from `--ink` to `--accent` on the+one element that is the point.++Reduce every future figure to the same three questions:+1. **What is the claim?** (becomes the figcaption, verbatim)+2. **What is the claim's *structure*?** (spectrum? ranking? sequence-with-threshold?+ mutual causation? branch? transformation?) → picks the primitive.+3. **Where is the point?** → the one element that gets coral.++---++## 1. `autonomy-field` — claim has a SPECTRUM structure++**Claim:** "Autonomy isn't binary; the useful position slides with blast radius."+**Structure:** ordered positions on one axis → **cell grid with rising fill.**+**Point (coral):** the rightmost / highest-autonomy cell, or leave grayscale and let+fill-height carry it.++Why it works: the eye reads left→right as *more*, and the fill bars literally grow,+so "spectrum" is felt before it is read. The axis label pair ("More oversight → More+delegation") names the dimension; the stakes row underneath ("Throwaway prototype →+Production system") adds the second, orthogonal consideration without a second chart.++```html+<figure class="fig cells" style="--n:5">+ <div class="axis"><span>More oversight</span><i></i><span>More delegation</span></div>+ <div class="row">+ <section style="--v:.1"><span>01</span><b>Complete</b><small>Human decides every move</small><i></i></section>+ <section style="--v:.3"><span>02</span><b>Suggest</b><small>AI proposes local changes</small><i></i></section>+ <section style="--v:.5"><span>03</span><b>Pair</b><small>Shared iteration loop</small><i></i></section>+ <section style="--v:.75"><span>04</span><b>Delegate</b><small>AI executes bounded work</small><i></i></section>+ <section style="--v:1"><span>05</span><b>Roam</b><small>AI owns the trajectory</small><i></i></section>+ </div>+ <div class="stakes"><span>Throwaway prototype</span><b>Move deliberately, not permanently →</b><span>Production system</span></div>+ <figcaption>The useful position is contextual: autonomy moves with blast radius, expertise, and feedback quality.</figcaption>+</figure>+```++---++## 2. `bar-chart` — claim RANKS magnitudes++**Claim:** "Developers avoid handing AI the high-stakes work; trust is low."+**Structure:** comparable quantities, ordered → **horizontal bars** (never vertical;+labels stay readable). SVG, 720 viewBox, real axis 0–100.+**Point (coral):** the rows that prove the thesis (the "accent" rows). The one+surprising row (e.g. `2.6%`) is its own quiet punchline.++Why horizontal: long text labels; ranking is a vertical scan; the value sits at the+bar's end. The single tiny bar among big ones does more than any callout.++```html+<figure class="fig bars">+ <svg viewBox="0 0 720 336" role="img" aria-label="Share of respondents">+ <g class="grid">+ <g><line x1="246" x2="246" y1="18" y2="308"/><text x="246" y="12" text-anchor="middle">0</text></g>+ <g><line x1="459" x2="459" y1="18" y2="308"/><text x="459" y="12" text-anchor="middle">50</text></g>+ <g><line x1="672" x2="672" y1="18" y2="308"/><text x="672" y="12" text-anchor="middle">100</text></g>+ </g>+ <!-- row: y steps by 52; fill width = 426 * pct/100 -->+ <g class="row row--accent"><text class="label" x="0" y="56">Avoid deployment / monitoring</text>+ <rect class="track" x="246" y="38" width="426" height="24"/>+ <rect class="fill" x="246" y="38" width="323.8" height="24"/>+ <text class="value" x="561" y="55" text-anchor="end">76%</text></g>+ <!-- ...more rows... the last, tiny one is the punchline -->+ <g class="row"><text class="label" x="0" y="264">Express high trust</text>+ <rect class="track" x="246" y="246" width="426" height="24"/>+ <rect class="fill" x="246" y="246" width="11" height="24"/>+ <text class="value" x="274" y="263" text-anchor="end">2.6%</text></g>+ </svg>+ <figcaption>Selected developer-survey figures · share of respondents</figcaption>+</figure>+```++---++## 3. `process-diagram` — claim is a SEQUENCE with a THRESHOLD++**Claim:** "Nothing is billable until the work crosses the delivery boundary."+**Structure:** ordered stages + one that flips state → **stage grid + traveling dot+on a rail.** The committed stage inverts (coral fill).+**Point (coral):** the `is-committed` final stage — the moment the claim is about.++The dashed rail with a dot that pauses at 58% then completes *shows* the boundary:+the eye watches nothing commit until the dot crosses.++```html+<figure class="fig process">+ <div class="rail" aria-hidden="true"><i></i></div>+ <div class="stages">+ <section><span>01</span><b>Compose</b><small>Measured locally</small></section>+ <section><span>02</span><b>Queue</b><small>Staged, not billed</small></section>+ <section><span>03</span><b>Invoke</b><small>Tokens + tool time</small></section>+ <section><span>04</span><b>Deliver</b><small>Outcome lands</small></section>+ <section class="is-committed"><span>05</span><b>Commit</b><small>Receipt changes</small></section>+ </div>+ <figcaption>Nothing becomes billable until the work crosses the delivery boundary.</figcaption>+</figure>+```+`.stages section.is-committed{ background:var(--accent); border-color:var(--accent); color:var(--ground); }`+(match the `.stages section` specificity or the base cell background wins — real bug.)+`.rail i{ animation:travel 4.8s cubic-bezier(.5,0,.5,1) infinite; }`++---++## 4. `loop-field` — claim is MUTUAL CAUSATION++**Claim:** "Agent evidence sharpens human judgment; judgment decides which evidence+matters." (Two loops feeding each other.)+**Structure:** two cycles + a coupling → **two orbits + a pulsing bridge.**+**Point (coral):** the bridge pulse (the calibration signal moving between them).++A single loop would miss the reciprocity; two orbits side by side with a dot+pulsing across the gap encode "each feeds the other." Center term of each orbit =+the *output* of that loop (Evidence / Judgment).++```html+<figure class="fig loops">+ <div class="system">+ <section><span>Technical loop</span>+ <div class="orbit"><i>Context</i><i>Action</i><i>Tests</i><i>Repair</i><b>Evidence</b></div></section>+ <section><span>Human loop</span>+ <div class="orbit human"><i>Observe</i><i>Question</i><i>Review</i><i>Learn</i><b>Judgment</b></div></section>+ <div class="bridge"><i></i><span>Calibration</span></div>+ </div>+ <figcaption>Agent evidence sharpens human judgment; human judgment decides which evidence matters.</figcaption>+</figure>+```+`.bridge i{ background:var(--accent); border-radius:50%; width:6px; height:6px; animation:pulse 2.2s ease-in-out infinite alternate; }`++---++## 5. `condition-tree` — claim is a BRANCH under uncertainty++**Claim:** "A recursive evaluation preserves inspectable conditions at every branch+instead of one irreversible transcript."+**Structure:** a decision that forks → **node/branch SVG tree** with a signal that+falls from root to a leaf, and a blurred "ghost" of the same paths beneath for depth.+**Point (coral):** the falling signal dot.++The ghost path (blurred, low opacity) is the "irreversible transcript" the claim+argues against; the crisp branch tree on top is the inspectable alternative. Form+carries the argument's *contrast*.++```html+<figure class="fig tree">+ <svg viewBox="0 0 720 330" role="img" aria-labelledby="tree-cap">+ <g class="memory"><path d="M360 290V220M360 220 190 150M360 220 530 150M190 150 90 70M190 150 260 70M530 150 460 70M530 150 630 70"/></g>+ <g class="branches"><path d="M360 290V220M360 220 190 150M360 220 530 150M190 150 90 70M190 150 260 70M530 150 460 70M530 150 630 70"/></g>+ <g class="nodes"><circle cx="360" cy="290" r="9"/><circle cx="360" cy="220" r="7"/><circle cx="190" cy="150" r="6"/><circle cx="530" cy="150" r="6"/><circle cx="90" cy="70" r="5"/><circle cx="260" cy="70" r="5"/><circle cx="460" cy="70" r="5"/><circle cx="630" cy="70" r="5"/></g>+ <g class="labels"><text x="360" y="322" text-anchor="middle">OBSERVED STATE</text><text x="190" y="178" text-anchor="middle">VERIFIED</text><text x="530" y="178" text-anchor="middle">UNKNOWN</text><text x="90" y="48" text-anchor="middle">RECOMPUTE</text><text x="260" y="48" text-anchor="middle">REUSE</text><text x="460" y="48" text-anchor="middle">QUERY</text><text x="630" y="48" text-anchor="middle">DEFER</text></g>+ <circle class="signal" cx="360" cy="220" r="2"/>+ </svg>+ <figcaption id="tree-cap">A recursive evaluation tree preserves inspectable conditions at every branch instead of an irreversible reasoning transcript.</figcaption>+</figure>+```+`.memory path{ stroke:var(--quiet); stroke-width:11; opacity:.08; filter:blur(6px); fill:none; }`+`.branches path{ stroke:var(--line-strong); stroke-width:1; fill:none; }`+`.nodes circle{ fill:var(--ground); stroke:var(--ink); stroke-width:1.4; }`+`.signal{ fill:var(--accent); animation:signal 3.8s linear infinite; transform-box:view-box; }`++---++## 6. `state-flow` — claim is a TRANSFORMATION of representation++**Claim:** "Event history becomes observable conditions, which controllers reconcile+into state." (Data changing *form* through a pipeline.)+**Structure:** A → B → C where each stage looks *different* → **stage rail** where+each card contains a different mini-visual (pulsing bars → stacked conditions →+a readout chip).+**Point (coral):** the focus stage underline + the "READY" readout dot.++Each card's inner glyph *is* the data in that representation, so the reader sees the+transformation, not just labels with arrows.++```html+<figure class="fig flow">+ <div class="rail">+ <section><span>01 · events</span><b>Raw agent history</b>+ <i class="evt"><em></em><em></em><em></em><em></em></i></section>+ <span class="arrow">→</span>+ <section class="focus"><span>02 · observe</span><b>Compressed conditions</b>+ <div class="stack"><i data-tone="critical"></i><i data-tone="relevant"></i><i data-tone="info"></i></div></section>+ <span class="arrow">→</span>+ <section><span>03 · reconcile</span><b>Declarative state</b>+ <div class="readout"><i></i> READY</div></section>+ </div>+ <figcaption>Event history becomes observable conditions, which controllers reconcile into state.</figcaption>+</figure>+```++---++## 7. `lane-router` — claim is a DISPATCH / one-decision routing (NEW, shipped)++Built for a long-form blog post on agentic QA routing,+replacing an ASCII box diagram. **Light-themed to match the blog** (proof the method++ elements adapt to a light host).++**Claim:** "One decision routes every task; the lane is chosen by where the work+already lives."+**Structure:** a single spine that fans to N mutually-exclusive outputs → **keyed+rows sharing one accent spine.** Each row = a key node (A/B/C) + its condition ++its destination. The coral vertical spine down the left connects all key nodes,+making "one branch, many lanes" literal.+**Point (coral):** the spine + the A/B/C key nodes (the routing itself is the point).++Why this over the branch tree (#5): a decision *tree* is for exploring uncertainty+(you don't know which leaf); a *router* is for dispatch (a known rule sends each task+to exactly one lane). Rows read faster than a fanned SVG when the lanes carry text.++```html+<figure class="edfig-lanes host" role="img" aria-label="One decision routes every test into one of three lanes">+ <div class="edfig-lanes__head">+ <span class="edfig-lanes__q">Which lane runs this test?</span>+ <span class="edfig-lanes__eyebrow">The one decision</span>+ </div>+ <div class="edfig-lanes__rows"> <!-- ::before draws the coral spine -->+ <div class="edfig-lane">+ <span class="edfig-lane__k">A</span>+ <span class="edfig-lane__cond">New behavior · no code yet · exploratory</span>+ <span class="edfig-lane__to"><span class="edfig-lane__name">Manual + Run with AI</span><span class="edfig-lane__act">Design cases → AI executes them</span></span>+ </div>+ <!-- B, C … -->+ </div>+ <figcaption class="edfig-lanes__cap">One branch routes every task; the lane is chosen by where the work already lives.</figcaption>+</figure>+```+Full CSS (light + dark override) lives in the post source+the post body, with a standalone preview page for review. Spine =+`.edfig-lanes__rows::before` (2px coral, left:14px aligns to node centers); nodes =+`.edfig-lane__k` (1.5px coral border, coral text, ground fill, z-index above spine).++---++## The point of these seven++They cover seven *claim structures*, not seven chart types:++| Claim structure | Primitive | Example |+|-----------------------------|---------------------|---------|+| a spectrum / gradient | cell grid + fill | 1 |+| ranked magnitudes | horizontal bars | 2 |+| sequence with a threshold | stage grid + rail | 3 |+| mutual causation | coupled orbits | 4 |+| branch under uncertainty | node/branch tree | 5 |+| transformation of form | stage rail + glyphs | 6 |+| dispatch / one-rule routing | keyed rows + spine | 7 |++Plus two more in the gallery (`assets/gallery.html`): accumulation-toward-a-target+(filling meter + threshold tick) and boundary/inside-vs-outside (framed region + a+crossing). If your post's claim doesn't match a row, **compose a new primitive** from+the atoms in `design-system.md §5`. The aesthetic is the tokens + typography law ++restraint; the *shape* is whatever makes your specific sentence obvious at a glance.diff --git a/skills/export-open-issues/SKILL.md b/skills/export-open-issues/SKILL.mdnew file mode 100644index 0000000..5705ad7--- /dev/null+++ b/skills/export-open-issues/SKILL.md@@ -0,0 +1,307 @@+---+name: export-open-issues+description: Audit and export open issues from any project tracker with summary analysis and vault archival+roles: [product-manager, engineering-lead, founder]+integrations: [github, linear, jira]+---++# COG Export Open Issues Skill++## When to Invoke+- User wants to audit open issues or backlog health+- User says "export issues", "open issues", "backlog audit", "issue report", "what's open"+- Sprint/cycle planning prep — need a clear picture of what's in flight+- Stakeholder reporting — need a snapshot of current work status++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use parallel agents to collect from all active trackers simultaneously and produce a unified report+- If `agent_mode: solo` — collect from the primary tracker sequentially++## Command: `/export-open-issues`++## Pre-Flight Check++1. **Read `00-inbox/MY-INTEGRATIONS.md`** to determine which trackers are active+2. **Read `00-inbox/MY-PROFILE.md`** for active projects+3. **Get current timestamp:** Run `date '+%Y-%m-%d %H:%M'` using Bash++4. **Ask the user** (if not already provided):+ - Which project? (if multiple active)+ - Scope: all open issues, or filtered by label/milestone/assignee?+ - Include additional analysis? (aging, priority distribution, assignee load)++---++## Execution Strategy++### Phase 1: Collect Open Issues++#### Team Mode (parallel agents)++Launch collection agents using the Task tool with `run_in_background: true`:++**Agent: "github-issues-collector"** (if GitHub is active)+```+Export all open issues from GitHub.+Repository: [CUSTOMIZE: your-org/your-repo]++1. Get all open issues:+ gh issue list --repo [CUSTOMIZE: your-org/your-repo] --state open --json number,title,author,assignees,labels,createdAt,updatedAt,milestone,url --limit 500++2. Get all open PRs (separate from issues):+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state open --json number,title,author,labels,createdAt,updatedAt,reviewDecision,url --limit 200++For each issue, calculate:+- Age in days (today - createdAt)+- Days since last update (today - updatedAt)+- Staleness flag: >30 days since last update = stale++Return: full issue list with calculated fields+```++**Agent: "linear-issues-collector"** (if Linear is active)+```+Export all open issues from Linear.++1. Use ToolSearch to load Linear tools+2. List all teams: mcp__claude_ai_Linear_2__list_teams+3. For each relevant team, list open issues: mcp__claude_ai_Linear_2__list_issues+4. Get current cycles: mcp__claude_ai_Linear_2__list_cycles+5. Get milestones: mcp__claude_ai_Linear_2__list_milestones++For each issue, collect:+- ID, title, status, priority, assignee, labels, project+- Created date, updated date+- Cycle membership+- Blocked status++Return: full issue list with metadata+```++**Agent: "jira-issues-collector"** (if Jira is active)+```+Export all open issues from Jira.+Project: [CUSTOMIZE: YOUR-PROJECT-KEY]++1. Search open issues:+ JQL: project = "[CUSTOMIZE: YOUR-PROJECT-KEY]" AND status NOT IN (Done, Closed, Resolved) ORDER BY priority DESC, created ASC++2. For each issue, collect:+ key, summary, issuetype, status, priority, assignee, reporter, labels, components, fixVersion, created, updated, duedate++Return: full issue list with metadata+```++#### Solo Mode+Run collection sequentially for the primary tracker.++### Phase 2: Analyze and Categorize++Process the collected data to produce:++#### 2.1 Summary Statistics+```+Total Open Issues: [N]+ - By Priority: Critical [N], High [N], Medium [N], Low [N], None [N]+ - By Type: Feature [N], Bug [N], Task [N], Other [N]+ - By Status: To Do [N], In Progress [N], In Review [N], Blocked [N]+ - By Assignee: [Name] ([N]), [Name] ([N]), Unassigned ([N])+```++#### 2.2 Health Indicators+- **Stale issues** (no update in >30 days): list with age+- **Unassigned issues**: list with priority+- **Blocked issues**: list with blocker details+- **Overdue issues** (past due date): list with days overdue+- **Oldest open issues**: top 10 by age+- **In-progress bottleneck**: issues in "In Progress" for >7 days++#### 2.3 Distribution Charts (text-based)+```+Priority Distribution:+ Critical ████░░░░░░ 12%+ High ████████░░ 38%+ Medium ██████░░░░ 28%+ Low ████░░░░░░ 22%++Age Distribution:+ <7 days ██████████ 45%+ 7-30 days ██████░░░░ 30%+ 30-90 d ███░░░░░░░ 15%+ >90 days ██░░░░░░░░ 10%+```++### Phase 3: Generate Report++```markdown+---+type: open-issues-audit+project: [project-name]+date: [YYYY-MM-DD]+created: [YYYY-MM-DD HH:MM]+source: [github/linear/jira/multi]+tags: ["#issues-audit", "#[project-name]", "#backlog"]+summary:+ total_open: [N]+ critical: [N]+ high: [N]+ stale: [N]+ unassigned: [N]+ blocked: [N]+ oldest_days: [N]+---++# Open Issues Audit — [Project Name]++**Date:** [YYYY-MM-DD]+**Source:** [Tracker(s) used]+**Total Open Issues:** [N]++---++## Executive Summary++[2-3 sentences: overall backlog health, biggest concerns, and recommended actions]++---++## Summary Statistics++| Category | Count | % of Total |+|----------|-------|-----------|+| **By Priority** | | |+| Critical | [N] | [%] |+| High | [N] | [%] |+| Medium | [N] | [%] |+| Low | [N] | [%] |+| No Priority | [N] | [%] |+| **By Status** | | |+| To Do | [N] | [%] |+| In Progress | [N] | [%] |+| In Review | [N] | [%] |+| Blocked | [N] | [%] |+| **By Type** | | |+| Feature/Story | [N] | [%] |+| Bug | [N] | [%] |+| Task | [N] | [%] |+| Other | [N] | [%] |++---++## Assignee Load++| Assignee | Open Issues | Critical/High | In Progress | Oldest Issue (days) |+|----------|-------------|---------------|-------------|-------------------|+| [Name] | [N] | [N] | [N] | [N] |+| [Name] | [N] | [N] | [N] | [N] |+| Unassigned | [N] | [N] | — | [N] |++---++## Health Alerts++### Stale Issues (>30 days without update)+| # | Title | Assignee | Priority | Age (days) | Last Updated |+|---|-------|----------|----------|-----------|-------------|+| [#] | [Title] | [Name] | [Priority] | [N] | [Date] |++### Blocked Issues+| # | Title | Assignee | Blocked By | Days Blocked |+|---|-------|----------|-----------|-------------|+| [#] | [Title] | [Name] | [Reason] | [N] |++### Unassigned High-Priority Issues+| # | Title | Priority | Age (days) | Labels |+|---|-------|----------|-----------|--------|+| [#] | [Title] | [Priority] | [N] | [Labels] |++### Overdue Issues+| # | Title | Assignee | Due Date | Days Overdue |+|---|-------|----------|----------|-------------|+| [#] | [Title] | [Name] | [Date] | [N] |++---++## Full Issue List++### Critical Priority+| # | Title | Status | Assignee | Age | Labels | URL |+|---|-------|--------|----------|-----|--------|-----|+| [#] | [Title] | [Status] | [Name] | [N]d | [Labels] | [URL] |++### High Priority+[Same table format]++### Medium Priority+[Same table format]++### Low Priority+[Same table format]++---++## Recommendations++1. **[Recommendation 1]** — [Specific action with rationale]+2. **[Recommendation 2]** — [Specific action with rationale]+3. **[Recommendation 3]** — [Specific action with rationale]++---++*Generated by COG Open Issues Audit | [Date]*+```++### Phase 4: Save to Vault++Save to: `04-projects/[project]/audits/open-issues-YYYY-MM-DD.md`++```bash+mkdir -p "04-projects/[project]/audits"+```++### Phase 5: Present Results++Show the user:+1. Executive summary+2. Key health alerts (stale, blocked, unassigned)+3. Top recommendations+4. File location++Ask if they want:+- Full detailed view+- Export as CSV (generate a simple CSV file alongside the markdown)+- Share to a specific channel or wiki++---++## CSV Export (Optional)++If user requests CSV, generate alongside the markdown:++```+#,Title,Type,Status,Priority,Assignee,Labels,Created,Updated,Age(days),URL+[data rows]+```++Save to: `04-projects/[project]/audits/open-issues-YYYY-MM-DD.csv`++---++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| No tracker active | Inform user that a project tracker integration is needed; offer to set one up |+| Tracker API fails | Retry once, then report partial results with error note |+| Too many issues (>500) | Paginate collection, warn user, offer to filter by label/milestone/assignee |+| Multiple trackers active | Collect from all and produce a unified report, noting the source for each item |+| No open issues found | Report clean backlog status (this is good news!) |++## Error Handling++- **Rate limits**: Paginate requests and add delays if needed+- **Large payloads**: Summarize rather than list all items if >200 issues+- **Missing fields**: Mark as "N/A" rather than failing+- **Context overflow**: Process in batches, summarize per batchdiff --git a/skills/generate-prd/SKILL.md b/skills/generate-prd/SKILL.mdnew file mode 100644index 0000000..f804248--- /dev/null+++ b/skills/generate-prd/SKILL.md@@ -0,0 +1,364 @@+---+name: generate-prd+description: Generate product requirements documents with optional publishing to Confluence or other wiki platforms+roles: [product-manager, engineering-lead, founder]+integrations: [confluence, notion, hackmd]+---++# COG Generate PRD Skill++## When to Invoke+- User wants to create a PRD, product spec, or requirements document+- User says "generate PRD", "write PRD", "product requirements", "spec doc", "feature spec"+- User has a feature or project that needs formal documentation before development++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use parallel agents to gather context from multiple sources (existing PRDs, related issues, competitive research) while drafting+- If `agent_mode: solo` — gather context and draft sequentially in the main conversation++## Command: `/generate-prd`++## Pre-Flight Check++1. **Read `00-inbox/MY-INTEGRATIONS.md`** to determine publishing options:+ - **Confluence** — can publish PRD to team wiki+ - **Notion** — can publish PRD to Notion workspace+ - **HackMD** — can publish PRD as shared markdown doc+ - If none active, PRD stays in the vault only (still fully useful)++2. **Read `00-inbox/MY-PROFILE.md`** for:+ - Active projects+ - User's name and role (for PRD author field)++3. **Get current timestamp:**+ Run `date '+%Y-%m-%d %H:%M'` using Bash for the `created:` frontmatter field++---++## Execution Strategy++### Phase 1: Gather Requirements++Ask the user for the following (skip what they've already provided):++**Required:**+- Feature/product name+- Problem statement — what problem are we solving?+- Target users — who is this for?+- High-level solution — what are we building?++**Optional (will generate reasonable defaults if not provided):**+- Success metrics — how do we measure success?+- Constraints — technical, time, budget, or regulatory constraints+- Dependencies — what does this depend on?+- Related documents — links to designs, research, prior art+- Target timeline — when does this need to ship?++### Phase 2: Context Gathering++#### Team Mode (parallel agents)++Launch context-gathering agents using the Task tool with `run_in_background: true`:++**Agent: "existing-prd-scanner"**+```+Scan the vault for existing PRDs and related documents.++1. Glob for PRDs: 04-projects/*/PRDs/*.md+2. Glob for related project files: 04-projects/[project]/**/*.md+3. Read recent PRDs to understand the user's preferred format and level of detail+4. Look for any existing docs related to the feature being specified++Return: relevant existing content, user's PRD style preferences, and any related docs+```++**Agent: "issue-context-gatherer"**+```+Gather related issues and feature requests from active trackers.++Check 00-inbox/MY-INTEGRATIONS.md for active trackers, then:++If Linear is active:+1. Use ToolSearch to load Linear tools+2. Search for issues related to [feature keywords]+3. Check current initiatives and projects for context++If GitHub is active:+1. gh search issues "[feature keywords]" --repo [CUSTOMIZE: your-org/your-repo] --json number,title,body,labels --limit 15+2. Check for related discussions or feature requests++Return: related issues, existing feature requests, and any prior discussion context+```++#### Solo Mode+Run the same context gathering sequentially.++### Phase 3: Generate PRD++Create the PRD using this template:++```markdown+---+type: prd+project: [project-name]+feature: [feature-name]+status: draft+author: [user name]+created: [YYYY-MM-DD HH:MM]+last_updated: [YYYY-MM-DD]+version: "1.0"+approvers: [CUSTOMIZE: list of approvers]+tags: ["#prd", "#product", "#[project-name]"]+---++# PRD: [Feature Name]++## Overview++| Field | Value |+|-------|-------|+| **Author** | [Name] |+| **Status** | Draft |+| **Created** | [Date] |+| **Target Release** | [Timeline or TBD] |+| **Priority** | [High/Medium/Low] |++---++## 1. Problem Statement++[Clear description of the problem being solved. Include data or evidence where available.]++### Who is affected?+[Target users and how they're impacted]++### What is the current experience?+[How users currently deal with this problem]++### Why now?+[Why this is important to solve at this time]++---++## 2. Goals & Success Metrics++### Goals+1. [Primary goal]+2. [Secondary goal]+3. [Tertiary goal]++### Success Metrics+| Metric | Current Baseline | Target | Measurement Method |+|--------|-----------------|--------|-------------------|+| [Metric 1] | [Current] | [Target] | [How to measure] |+| [Metric 2] | [Current] | [Target] | [How to measure] |++### Non-Goals+- [What this project explicitly does NOT aim to solve]+- [Scope boundaries]++---++## 3. User Stories++### Primary User: [User Type]++**Story 1:** As a [user type], I want [goal] so that [benefit].++**Story 2:** As a [user type], I want [goal] so that [benefit].++### Secondary User: [User Type] (if applicable)++**Story 3:** As a [user type], I want [goal] so that [benefit].++---++## 4. Proposed Solution++### 4.1 Solution Overview+[High-level description of the proposed solution]++### 4.2 Key Features+1. **[Feature 1]** — [Description]+2. **[Feature 2]** — [Description]+3. **[Feature 3]** — [Description]++### 4.3 User Flow+[Step-by-step description of the primary user flow]++1. User [action]+2. System [response]+3. User [action]+4. System [response]++### 4.4 Edge Cases & Error Handling+| Scenario | Expected Behavior |+|----------|------------------|+| [Edge case 1] | [How the system handles it] |+| [Edge case 2] | [How the system handles it] |++---++## 5. Technical Considerations++### Architecture Impact+[How this fits into the existing system architecture]++### Dependencies+- [Dependency 1] — [Status: available/needs work]+- [Dependency 2] — [Status: available/needs work]++### Technical Risks+| Risk | Likelihood | Impact | Mitigation |+|------|-----------|--------|------------|+| [Risk 1] | [H/M/L] | [H/M/L] | [Mitigation plan] |++### Performance Requirements+- [Performance requirement 1]+- [Performance requirement 2]++---++## 6. Design & UX++[Link to designs or describe UX requirements]++### Key UX Principles+- [Principle 1]+- [Principle 2]++### Accessibility Requirements+- [Requirement 1]+- [Requirement 2]++---++## 7. Release Strategy++### Rollout Plan+- **Phase 1:** [Description] — [Timeline]+- **Phase 2:** [Description] — [Timeline]++### Feature Flags+- [Feature flag 1] — [Purpose]++### Rollback Plan+[How to roll back if issues arise]++---++## 8. Open Questions++- [ ] [Question 1] — Owner: [Name]+- [ ] [Question 2] — Owner: [Name]+- [ ] [Question 3] — Owner: [Name]++---++## 9. References++- [Link to related PRDs]+- [Link to designs]+- [Link to research]+- [Link to related issues/tickets]++---++## Changelog++| Version | Date | Author | Changes |+|---------|------|--------|---------|+| 1.0 | [Date] | [Author] | Initial draft |+```++### Phase 4: Review Gate++**Present the generated PRD to the user:**++```+PRD draft is ready for review.++Sections generated:+1. Problem Statement+2. Goals & Success Metrics+3. User Stories+4. Proposed Solution+5. Technical Considerations+6. Design & UX+7. Release Strategy+8. Open Questions+9. References++Would you like to:+a) Review the full PRD (I'll display it)+b) Save as-is to the vault+c) Make changes to specific sections+d) Publish to [active wiki platform] (requires your approval)+```++**NEVER auto-publish. Always wait for explicit user approval.**++### Phase 5: Save to Vault++Save the PRD to: `04-projects/[project]/PRDs/prd-[feature-slug]-YYYY-MM-DD.md`++Create the directory structure if it doesn't exist:+```bash+mkdir -p "04-projects/[project]/PRDs"+```++### Phase 6: Publish (Optional, requires approval)++**Only proceed if the user explicitly approves publishing.**++#### Confluence+```+Use WebFetch to publish via Confluence REST API:+- POST /wiki/rest/api/content+- Space: [CUSTOMIZE: YOUR-SPACE-KEY]+- Parent page: [CUSTOMIZE: PRDs-parent-page-id]+- Title: "PRD: [Feature Name]"+- Body: [converted to Confluence storage format]++Note: Convert markdown to Confluence XHTML storage format before publishing.+```++#### Notion+```+1. Use ToolSearch to load Notion tools+2. Use mcp__claude_ai_Notion__notion-create-pages to create the PRD page+3. Place under [CUSTOMIZE: PRDs database or parent page]+```++#### HackMD+```+Use WebFetch to publish via HackMD API:+- POST to create a new note+- Set permissions as configured+```++After publishing, update the vault copy with the published URL:+```markdown+published_url: [URL]+published_at: [timestamp]+```++---++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| No wiki platform active | Save to vault only — PRD is still fully useful as a local document |+| Publishing API fails | Save to vault, provide the formatted content for manual publishing |+| User doesn't specify project | List active projects from MY-PROFILE.md and ask |+| Minimal input provided | Generate a skeleton PRD with [TODO] markers for the user to fill in |+| Existing PRD found for same feature | Ask if this is an update/revision or a new PRD |++## Error Handling++- **Context overflow**: If gathering too much context from existing docs, summarize rather than include full text+- **API failures**: Always save to vault first, then attempt publishing as a separate step+- **Large PRDs**: If the PRD exceeds typical wiki page limits, suggest splitting into sub-pagesdiff --git a/skills/generate-release-notes/SKILL.md b/skills/generate-release-notes/SKILL.mdnew file mode 100644index 0000000..5ed4f3b--- /dev/null+++ b/skills/generate-release-notes/SKILL.md@@ -0,0 +1,348 @@+---+name: generate-release-notes+description: Generate categorized release notes from any source (GitHub, Linear, Jira, or manual input) with optional publishing+roles: [product-manager, engineering-lead, founder]+integrations: [github, linear, jira, confluence, notion, hackmd]+---++# COG Generate Release Notes Skill++## When to Invoke+- User wants to create release notes for a version, sprint, or cycle+- User says "release notes", "changelog", "what shipped", "write release notes"+- A new version or milestone has been completed+- End of sprint/cycle documentation++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use parallel agents to collect data from all active sources simultaneously+- If `agent_mode: solo` — collect data sequentially from the primary tracker++## Command: `/generate-release-notes`++## Pre-Flight Check++1. **Read `00-inbox/MY-INTEGRATIONS.md`** to determine data sources and publishing options+2. **Read `00-inbox/MY-PROFILE.md`** for active projects+3. **Get current timestamp:** Run `date '+%Y-%m-%d %H:%M'` using Bash++4. **Ask the user** (if not already provided):+ - What version/release/cycle is this for?+ - What is the date range? (or: which milestone/cycle/sprint?)+ - Which project? (if multiple active)+ - Audience: internal team, customers, or both?++---++## Execution Strategy++### Phase 1: Collect Release Data++#### Team Mode (parallel agents)++Launch data collection agents using the Task tool with `run_in_background: true`:++**Agent: "github-release-collector"** (if GitHub is active)+```+Collect all merged PRs and release data for the specified version/period.+Repository: [CUSTOMIZE: your-org/your-repo]+Period: [START_DATE] to [END_DATE]++1. Get merged PRs in the period:+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state merged --search "merged:[START_DATE]..[END_DATE]" --json number,title,author,labels,body,mergedAt --limit 200++2. Check for existing GitHub release (if version tag exists):+ gh release view [VERSION_TAG] --repo [CUSTOMIZE: your-org/your-repo] --json name,body,tagName,createdAt 2>/dev/null++3. Get commits between tags (if applicable):+ gh api repos/[CUSTOMIZE: your-org/your-repo]/compare/[PREV_TAG]...[CURRENT_TAG] --jq '.commits[] | {sha: .sha[:7], message: .commit.message, author: .author.login}'++Categorize each PR by its labels or title prefix:+- "feat"/"feature"/"enhancement" labels → Enhancements+- "fix"/"bug"/"bugfix" labels → Bug Fixes+- "tech"/"refactor"/"chore"/"infrastructure" labels → Technical Improvements+- "docs"/"documentation" labels → Documentation+- "security" labels → Security+- "breaking"/"breaking-change" labels → Breaking Changes+- "deprecation" labels → Deprecations++Return: categorized list of changes with PR numbers, titles, authors, and descriptions+```++**Agent: "linear-release-collector"** (if Linear is active)+```+Collect completed issues for the specified cycle/period.++1. Use ToolSearch to load Linear tools+2. List cycles: mcp__claude_ai_Linear_2__list_cycles+3. Find the target cycle or filter by date range+4. List all completed issues in the cycle/period: mcp__claude_ai_Linear_2__list_issues+5. For each issue, get details including labels and project++Categorize by label or issue type:+- Feature/Enhancement labels → Enhancements+- Bug labels → Bug Fixes+- Technical/Infrastructure labels → Technical Improvements+- Documentation labels → Documentation++Return: categorized list of changes with issue IDs, titles, assignees, and descriptions+```++**Agent: "jira-release-collector"** (if Jira is active)+```+Collect issues for the specified version/sprint.+Project: [CUSTOMIZE: YOUR-PROJECT-KEY]++1. Search by fixVersion:+ JQL: project = "[CUSTOMIZE: YOUR-PROJECT-KEY]" AND fixVersion = "[VERSION]" AND status = Done ORDER BY issuetype, priority DESC++ OR search by sprint:+ JQL: project = "[CUSTOMIZE: YOUR-PROJECT-KEY]" AND sprint = "[SPRINT_NAME]" AND status = Done ORDER BY issuetype, priority DESC++2. For each issue, collect: key, summary, issuetype, priority, assignee, labels, description++Categorize by issue type:+- Story/Feature → Enhancements+- Bug → Bug Fixes+- Task/Technical Task → Technical Improvements+- Documentation → Documentation++Return: categorized list with issue keys, titles, assignees, types, and descriptions+```++#### Solo Mode+Run the primary tracker collection sequentially.++#### Manual Input Fallback+If no tracker is active or the user prefers manual input:+```+No project tracker detected. You can provide release items manually.++Please list the changes in this release. I'll categorize them for you.+Format: one change per line, optionally prefix with [feature], [fix], [tech], [docs], [security], [breaking]+```++### Phase 2: Categorize and Organize++Organize collected items into standard categories:++1. **Breaking Changes** (always first if present)+2. **New Features & Enhancements**+3. **Bug Fixes**+4. **Technical Improvements**+5. **Security Updates**+6. **Documentation**+7. **Deprecations**+8. **Known Issues** (if any remain)++Within each category, order by:+1. Priority (highest first)+2. User impact (most impactful first)++### Phase 3: Generate Release Notes++#### For Customer/External Audience:++```markdown+---+type: release-notes+project: [project-name]+version: [version]+date: [YYYY-MM-DD]+created: [YYYY-MM-DD HH:MM]+audience: external+tags: ["#release-notes", "#[project-name]", "#v[version]"]+items_count: [total count]+categories:+ enhancements: [count]+ bug_fixes: [count]+ technical: [count]+ security: [count]+ breaking_changes: [count]+---++# Release Notes — [Project Name] [Version]++**Release Date:** [Date]++## What's New++[2-3 sentence executive summary of the most important changes in this release]++---++### Breaking Changes++> **Action Required:** The following changes may require updates to your workflow.++- **[Change title]** — [User-friendly description of what changed and what to do]++---++### New Features & Enhancements++- **[Feature title]** — [User-friendly description focused on the benefit to users]+- **[Feature title]** — [User-friendly description]++### Bug Fixes++- **[Fix title]** — [What was broken and how it's fixed, in user terms]+- **[Fix title]** — [Description]++### Security Updates++- **[Update title]** — [Description without exposing vulnerability details]++### Deprecations++- **[Deprecated feature]** — [What's being deprecated, timeline, and migration path]++---++### Known Issues++- [Known issue description] — [Workaround if available]++---++*For questions or feedback, [CUSTOMIZE: contact info or link]*+```++#### For Internal/Team Audience:++```markdown+---+type: release-notes+project: [project-name]+version: [version]+date: [YYYY-MM-DD]+created: [YYYY-MM-DD HH:MM]+audience: internal+tags: ["#release-notes", "#[project-name]", "#v[version]"]+source_tracker: [github/linear/jira/manual]+---++# Release Notes — [Project Name] [Version] (Internal)++**Release Date:** [Date]+**Cycle/Sprint:** [Name if applicable]++## Summary+[Executive summary with key stats: N features, N fixes, N tech improvements]++---++### Breaking Changes+- **[Title]** ([PR/Issue #link]) — [Technical description] — @[author]++### New Features & Enhancements+- **[Title]** ([PR/Issue #link]) — [Description] — @[author]++### Bug Fixes+- **[Title]** ([PR/Issue #link]) — [Description] — @[author]++### Technical Improvements+- **[Title]** ([PR/Issue #link]) — [Description] — @[author]++### Documentation+- **[Title]** ([PR/Issue #link]) — [Description] — @[author]++---++### Stats+- **Total items:** [N]+- **Contributors:** [list of contributors]+- **PRs merged:** [N]+- **Issues resolved:** [N]++---++### Known Issues & Follow-ups+- [ ] [Issue description] — Owner: [name]+```++### Phase 4: Review Gate++Present the generated release notes to the user:++```+Release notes draft is ready for [Project] [Version].++Summary:+- [N] New Features & Enhancements+- [N] Bug Fixes+- [N] Technical Improvements+- [N] other items++Audience: [external/internal]++Would you like to:+a) Review the full release notes+b) Save as-is to the vault+c) Make changes+d) Publish to [active platform] (requires your approval)+```++**NEVER auto-publish. Always wait for explicit user approval.**++### Phase 5: Save to Vault++Save to: `04-projects/[project]/release-notes/release-[version]-YYYY-MM-DD.md`++```bash+mkdir -p "04-projects/[project]/release-notes"+```++### Phase 6: Publish (Optional, requires approval)++**Only proceed if the user explicitly approves.**++#### GitHub Release+```+gh release create [VERSION_TAG] \+ --repo [CUSTOMIZE: your-org/your-repo] \+ --title "[Project] [Version]" \+ --notes-file [path-to-release-notes]+```++#### Confluence+```+Use WebFetch to publish via Confluence REST API:+- Space: [CUSTOMIZE: YOUR-SPACE-KEY]+- Parent page: [CUSTOMIZE: Release-Notes-parent-page-id]+- Title: "Release Notes — [Project] [Version]"+```++#### Notion+```+1. Use ToolSearch to load Notion tools+2. Use mcp__claude_ai_Notion__notion-create-pages+```++#### HackMD+```+Use WebFetch to publish via HackMD API+```++After publishing, update the vault copy with the published URL.++---++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| No tracker active | Accept manual input, or scan git log for commits in the date range |+| Tracker API fails | Fall back to git log analysis: `git log --oneline [PREV_TAG]..[CURRENT_TAG]` |+| No version tag specified | Use date range instead, or list recent completed work |+| Mixed sources | Merge and deduplicate items from multiple trackers |+| No publishing platform | Save to vault only |+| Very large release | Split into "Highlights" section + full changelog |++## Error Handling++- **Too many items**: If >100 items, auto-summarize minor changes and list only significant ones in detail+- **Missing PR descriptions**: Use PR title and commit messages as fallback+- **Duplicate items across trackers**: Deduplicate by matching titles/descriptions+- **Context overflow**: Paginate data collection, summarize per-batchdiff --git a/skills/harvest/SKILL.md b/skills/harvest/SKILL.mdnew file mode 100644index 0000000..8ab5811--- /dev/null+++ b/skills/harvest/SKILL.md@@ -0,0 +1,75 @@+---+name: harvest+description: >+ Capture durable session learnings, stage for human promotion to+ 05-knowledge/lizard, and propose skill/CLAUDE.md patches. Triggered by+ /harvest, SessionEnd hook staging, or nightly enhance. Never writes+ durable knowledge without your approval.+---++# /harvest — session learning capture++Adapted from dwarves-kit `harvest` hook + vault lizard pipeline. Prevents tacit knowledge dying in the transcript.++## Triggers++- `/harvest` — manual end-of-session+- `/harvest promote` — curate staging → lizard drafts (uses harvest-curator)+- Staging file written by `stop` hook (`.cursor/hooks/harvest-stager.sh`)++## Phase 1 — Collect (automatic or manual)++Scan the current session for:++1. **Corrections you made** ("no, actually X", rejected deliverables)+2. **New stable facts** (IDs, URLs, decisions) not yet in 05-knowledge+3. **Process lessons** (what worked, what failed, friction)+4. **Skill gaps** (something that should be a Verify step or CLAUDE.md rule)++Append to `04-projects/harness/harvest/staging-<YYYY-MM-DD>.md`:++```markdown+## <HH:MM> — <trigger>+- type: correction|fact|process|skill-gap+- source: <file or "session">+- text: <one paragraph max>+- proposed_home: <path or "new lizard note">+```++Dedup: skip if same fact already in staging today or in 05-knowledge.++## Phase 2 — Curate (`/harvest promote`)++Spawn `harvest-curator` (Sonnet). It writes `/tmp/harvest-curate-<date>.md`.++Lead (Opus) presents to the user:++- **Promote** list → approve which become `05-knowledge/lizard/YYYY-MM-DD-<slug>.md`+- **Fold** list → approve inline edits to existing notes+- **Skill patches** → approve CLAUDE.md / SKILL.md diffs++Only after approval: write durable files. Update `05-knowledge/lizard/index.md`.++## Phase 3 — Retro line++One line to `01-daily/journal/<today>.md`:++```+Harvest: <n> staged, <m> promoted, <k> folded+```++## Rules++- Harvest is **advisory**. It never auto-writes 05-knowledge.+- Contradictions with existing knowledge → flag both, ask the user.+- Pair with `/memory-hygiene` monthly for environment-dependent facts in `~/.claude/.../memory/`.++## Nightly enhance (optional launchd)++```bash+# 04-projects/harness/scripts/nightly-enhance.sh+bash .claude/lib/install-harness.sh --check # hooks alive+# /memory-hygiene (skill)+# /harvest promote if staging non-empty+# content-factory if scheduled+```diff --git a/skills/knowledge-consolidation/SKILL.md b/skills/knowledge-consolidation/SKILL.mdnew file mode 100644index 0000000..916737c--- /dev/null+++ b/skills/knowledge-consolidation/SKILL.md@@ -0,0 +1,876 @@+---+name: knowledge-consolidation+description: Build frameworks from scattered insights across all braindumps and notes+roles: [all]+integrations: []+---++# COG Knowledge Consolidation Skill++## Purpose+Transform scattered insights from braindumps, daily briefs, and check-ins into coherent frameworks and "single source of truth" knowledge documents through pattern recognition and systematic synthesis.++## When to Invoke+- User wants to consolidate their insights+- User says "consolidate knowledge", "build frameworks", "synthesize insights"+- Time for periodic knowledge base maintenance (weekly, monthly, quarterly)+- User wants to extract patterns from accumulated braindumps+- Before major decisions that could benefit from framework consultation++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — delegate scanning and pattern extraction to parallel sub-agents (e.g., one per domain: personal braindumps, professional braindumps, project-specific content, daily briefs). Each agent identifies themes and patterns, then a synthesis agent combines findings into frameworks.+- If `agent_mode: solo` (default) — handle all scanning, pattern recognition, and framework building directly. No delegation.++## Pre-Flight Check++**Get current timestamp (REQUIRED before generating any files):**++1. Run `date '+%Y-%m-%d %H:%M'` using Bash to get the actual current date and time+2. Store this value and use it for the `created:` frontmatter field+3. NEVER guess or fabricate the time — always use the value returned by the `date` command++## Process Flow++### 1. Data Gathering++**Scan vault for unprocessed or partially processed content:**++- All braindumps since last consolidation:+ - `02-personal/braindumps/`+ - `03-professional/braindumps/`+ - `04-projects/*/braindumps/`+ - `00-inbox/braindump-*.md` (mixed domain)++- Daily briefs and check-ins:+ - `01-daily/briefs/`+ - `01-daily/checkins/`++- Any meeting transcripts or project documents in:+ - `04-projects/*/planning/`+ - `04-projects/*/resources/`++**Determine scope:**+- Ask user: "What time period should I analyze? (last week, last month, last quarter, all time, or custom range?)"+- Identify unprocessed content (check for `status: "captured"` or missing consolidation metadata)++**Gather statistics:**+- Total documents to analyze+- Breakdown by domain and type+- Date range coverage++### 2. Pattern Recognition++Apply systematic pattern detection across all content:++#### Frequency Analysis+**What comes up repeatedly?**+- Identify themes mentioned across multiple documents+- Track topic frequency and clustering+- Recognize persistent questions or concerns+- Spot recurring action items or decisions++#### Temporal Clustering+**What insights emerged together?**+- Group related insights by time period+- Identify how thinking evolved over time+- Recognize inflection points where thinking shifted+- Map catalysts that triggered changes++#### Domain Correlation+**What patterns cross domains?**+- Personal insights affecting professional thinking+- Professional learnings applied to projects+- Project experiences informing personal growth+- Strategic themes spanning all domains++#### Contradiction Analysis+**Where does thinking conflict?**+- Identify contradictory thoughts or approaches+- Recognize evolution vs. inconsistency+- Understand resolution or ongoing tension+- Track perspective shifts over time++#### Cross-Cutting Patterns+**Meta-patterns across all dimensions:**+- Decision-making approaches+- Problem-solving strategies+- Learning patterns+- Emotional/energy patterns+- Relationship patterns+- Creative processes++### 3. Framework Development++Synthesize patterns into actionable frameworks:++#### Identify Core Principles+**From scattered insights to fundamental truths:**+- What patterns reveal deeper principles?+- What rules or heuristics emerge?+- What mental models are forming?+- What strategies are proving effective?++#### Test Against Evidence+**Validate frameworks with source material:**+- Do source insights support these principles?+- Are there counter-examples or exceptions?+- How confident can we be in this framework?+- What are the boundary conditions?++#### Define Boundaries+**When does framework apply/not apply?**+- What contexts does this framework serve?+- What are its limitations?+- When should it NOT be used?+- What assumptions does it rely on?++#### Create Applications+**How to use this framework:**+- Specific use cases+- Decision-making applications+- Problem-solving templates+- Practical implementation steps++### 4. Knowledge Integration++Update and create knowledge base documents:++#### Update Existing Frameworks++For each framework that needs updating:++```markdown+---+type: "consolidated-knowledge"+domain: "[primary-domain]"+framework: "[framework-name]"+created: "[original-date]"+last_updated: "YYYY-MM-DD"+consolidation_id: "[consolidation-session-id]"+source_documents: [count]+status: "stable|working|emerging"+tags: ["#framework", "#consolidated", "#[topic]"]+---++# [Framework Name]++## Framework Overview+[Clear description of what this framework is and what it helps with]++**Status:** [Stable | Working | Emerging]+**Last Updated:** [Date]+**Source Insights:** [count] documents analyzed++---++## Core Principles++### Principle 1: [Name]+**Statement:** [Clear, concise principle statement]++**Evidence:**+- [[braindump-YYYY-MM-DD]] - [supporting insight]+- [[daily-brief-YYYY-MM-DD]] - [supporting evidence]+- [[checkin-YYYY-MM-DD]] - [pattern observation]++**Evolution:** [How this principle has developed or been refined]++**Confidence:** [High|Medium|Low] - [reasoning]++### Principle 2: [Name]+[Same structure as Principle 1]++### Principle 3: [Name]+[Same structure as Principle 1]++---++## Applications & Use Cases++### Use Case 1: [Scenario]+**When to Apply:** [Specific situation]++**How to Apply:**+1. [Step 1]+2. [Step 2]+3. [Step 3]++**Expected Outcomes:** [What to expect]++**Example:** [Real example from user's experience]++### Use Case 2: [Scenario]+[Same structure as Use Case 1]++---++## Boundaries & Limitations++**This framework works when:**+- [Condition 1]+- [Condition 2]+- [Condition 3]++**This framework does NOT work when:**+- [Anti-condition 1]+- [Anti-condition 2]+- [Anti-condition 3]++**Common Pitfalls:**+- [Pitfall 1 to avoid]+- [Pitfall 2 to avoid]++---++## Evolution & History++### [Date Range 1]: [Initial Development]+**What Emerged:** [How this framework first appeared]++**Catalysts:**+- [Event or insight that triggered initial thinking]++**Early Insights:**+- [[link]] - [early thought]+- [[link]] - [formative insight]++### [Date Range 2]: [Refinement Phase]+**What Changed:** [How framework evolved]++**New Evidence:**+- [[link]] - [supporting experience]+- [[link]] - [refining insight]++**Adjustments Made:**+- [Change 1]+- [Change 2]++### Current State: [Date]+**Current Understanding:** [Latest refined version]++**Recent Validation:**+- [[link]] - [recent application]+- [[link]] - [current evidence]++---++## Related Frameworks++- [[framework-2]] - [How they relate]+- [[framework-3]] - [Connection or overlap]+- [[framework-4]] - [When to use which]++---++## Future Development++**Questions for Deeper Exploration:**+- [Question 1 to investigate]+- [Question 2 needing more evidence]++**Potential Extensions:**+- [Area 1 for expansion]+- [Area 2 for integration]++**Watch For:**+- [Pattern 1 to monitor]+- [Signal 2 that might invalidate or refine]++---++*Consolidated from [X] sources | Confidence: [High/Medium/Low] | Status: [Stable/Working/Emerging]*+```++Save to: `05-knowledge/consolidated/[framework-name]-framework.md`++#### Create New Frameworks++For newly identified frameworks:++```markdown+---+type: "consolidated-knowledge"+domain: "[primary-domain]"+framework: "[framework-name]"+created: "YYYY-MM-DD"+last_updated: "YYYY-MM-DD"+consolidation_id: "[consolidation-session-id]"+source_documents: [count]+status: "emerging"+tags: ["#framework", "#consolidated", "#new", "#[topic]"]+---++# [New Framework Name]++## Framework Discovery++**Identified:** [Date]+**Based On:** [X] insights from [timeframe]+**Domain:** [Primary domain with cross-domain applications]++**Discovery Context:**+[What pattern recognition revealed this framework]++---++## Core Principles++[Same structure as framework updates above]++---++[Continue with Applications, Boundaries, Evolution sections...]+```++Save to: `05-knowledge/consolidated/[framework-name]-framework.md`++#### Update Pattern Documentation++```markdown+---+type: "pattern-analysis"+pattern: "[pattern-name]"+created: "YYYY-MM-DD"+domains: ["domain1", "domain2"]+frequency: "[high|medium|low]"+tags: ["#pattern", "#analysis"]+---++# Pattern: [Pattern Name]++## Pattern Description+[Clear description of the recurring pattern]++**Frequency:** Appeared in [X] documents over [timeframe]++**Domains:** [Which domains this pattern appears in]++**Significance:** [Why this pattern matters]++---++## Occurrences++### [Date 1] - [[source-document-1]]+**Context:** [What was happening]++**Manifestation:** [How pattern appeared]++**Outcome:** [What resulted]++### [Date 2] - [[source-document-2]]+[Same structure]++### [Date 3] - [[source-document-3]]+[Same structure]++---++## Analysis++**What Triggers This Pattern:**+- [Trigger 1]+- [Trigger 2]+- [Trigger 3]++**What Follows This Pattern:**+- [Consequence 1]+- [Consequence 2]++**Cross-Domain Implications:**+[How this pattern affects different areas]++**Potential Actions:**+- [Action to amplify if positive]+- [Action to mitigate if negative]+- [Action to understand better]++---++## Evolution Over Time++[How this pattern has changed or stayed consistent]++---++*Pattern identified through consolidation of [X] sources*+```++Save to: `05-knowledge/patterns/pattern-[name].md`++#### Create Timeline Entries++```markdown+---+type: "timeline-entry"+topic: "[major-theme-or-shift]"+date_range: "YYYY-MM-DD to YYYY-MM-DD"+created: "YYYY-MM-DD"+tags: ["#timeline", "#evolution", "#thinking"]+---++# Thinking Evolution: [Major Theme/Shift]++## Timeline Period+**From:** [Start Date]+**To:** [End Date]+**Duration:** [X weeks/months]++---++## What Changed++**Initial State:**+[How thinking/approach started]++**End State:**+[Where thinking/approach ended up]++**Key Shift:**+[The fundamental change that occurred]++---++## Catalysts & Triggers++### [Date] - [Trigger Event 1]+**Source:** [[link-to-document]]++**What Happened:** [Description]++**Impact:** [How this triggered change]++### [Date] - [Trigger Event 2]+[Same structure]++---++## Evidence Trail++### Early Thinking: [Date Range]+- [[YYYY-MM-DD]] - [Initial thoughts]+- [[YYYY-MM-DD]] - [Early explorations]++### Intermediate Development: [Date Range]+- [[YYYY-MM-DD]] - [Evolving understanding]+- [[YYYY-MM-DD]] - [Testing and refinement]++### Current Understanding: [Date Range]+- [[YYYY-MM-DD]] - [Mature thinking]+- [[YYYY-MM-DD]] - [Latest application]++---++## Impact of This Evolution++**On Decisions:**+[How this shift affects decision-making]++**On Strategies:**+[How this shift affects strategic approach]++**On Frameworks:**+[Which frameworks were created or updated]++**On Actions:**+[What changed in behavior or practice]++---++## Lessons Learned++**What This Evolution Teaches:**+- [Learning 1]+- [Learning 2]+- [Learning 3]++**Future Implications:**+[What this suggests for future development]++---++*Timeline constructed from [X] source documents spanning [timeframe]*+```++Save to: `05-knowledge/timeline/[topic]-evolution-YYYY-MM.md`++### 5. Generate Consolidation Report++Create master consolidation document:++```markdown+---+type: "knowledge-consolidation"+domain: "integrated"+date: "YYYY-MM-DD"+consolidation_period: "YYYY-MM-DD to YYYY-MM-DD"+created: "YYYY-MM-DD HH:MM"+sources_analyzed: [number]+frameworks_updated: ["framework1", "framework2"]+frameworks_created: ["new-framework1"]+patterns_identified: [number]+tags: ["#consolidation", "#knowledge", "#frameworks"]+---++# Knowledge Consolidation - [Date]++## Executive Summary++**Period Analyzed:** [Start date] to [End date]++**Documents Processed:**+- [X] braindumps+- [X] daily briefs+- [X] weekly check-ins+- [X] project documents++**Major Outcomes:**+- **Frameworks Updated:** [count] - [list]+- **New Frameworks Created:** [count] - [list]+- **Patterns Identified:** [count]+- **Timeline Entries:** [count]++**Key Insights Synthesized:**+1. [Major insight 1]+2. [Major insight 2]+3. [Major insight 3]++---++## Processing Statistics++- **Total documents analyzed:** [number]+- **Date range:** [start] to [end]+- **Domains covered:** [list]+- **New patterns identified:** [number]+- **Frameworks updated:** [number]+- **New frameworks created:** [number]+- **Timeline entries added:** [number]+- **Archive actions taken:** [number]++---++## Major Themes This Period++### Theme 1: [Name]+**Frequency:** Appeared in [X] documents++**Evolution:** [How thinking evolved]++**Key Insights:**+- [[source]] - [insight 1]+- [[source]] - [insight 2]+- [[source]] - [insight 3]++**Framework Implications:**+[How this theme affected or created frameworks]++**Status:** [Stable understanding | Still exploring | Needs more evidence]++### Theme 2: [Name]+[Same structure as Theme 1]++---++## Frameworks Updated++### Framework 1: [Name]+**Location:** [[05-knowledge/consolidated/[filename]]]++**What Changed:**+- [Addition/modification 1]+- [Addition/modification 2]++**New Evidence Added:**+- [[source]] - [insight]+- [[source]] - [insight]++**Confidence Change:** [Before] → [After]++**New Applications:**+- [Use case 1]+- [Use case 2]++### Framework 2: [Name]+[Same structure]++---++## New Frameworks Created++### New Framework: [Name]+**Location:** [[05-knowledge/consolidated/[filename]]]++**Created:** Based on [X] insights from [timeframe]++**Core Principles:**+1. [Principle 1]+2. [Principle 2]+3. [Principle 3]++**Primary Use Cases:**+- [Use case 1]+- [Use case 2]++**Status:** Emerging (needs more evidence and validation)++**Future Development:**+[What's needed to mature this framework]++---++## Patterns Identified++### Pattern 1: [Name]+**Frequency:** [High|Medium|Low]++**Domains:** [Which domains]++**Description:** [What the pattern is]++**Implications:** [Why it matters]++**Documentation:** [[05-knowledge/patterns/[filename]]]++### Pattern 2: [Name]+[Same structure]++---++## Thinking Evolution++### Major Shift: [Topic]+**Timeline:** [Date range]++**What Changed:** [Description]++**Catalysts:**+- [Event 1]+- [Event 2]++**Impact:**+[How this shift affects frameworks, decisions, actions]++**Documentation:** [[05-knowledge/timeline/[filename]]]++---++## Cross-Cutting Insights++**Connections Across Domains:**+- [Cross-domain insight 1]+- [Cross-domain insight 2]+- [Cross-domain insight 3]++**Contradictions Identified:**+- [Contradiction 1] - [Resolution approach]+- [Contradiction 2] - [Still unresolved]++**Strategic Implications:**+[Higher-level observations about trajectory and direction]++---++## Knowledge Base Maintenance++### Updates Made+- ✅ Updated framework: [name]+- ✅ Created new framework: [name]+- ✅ Documented pattern: [name]+- ✅ Added timeline entry: [topic]+- ✅ Archived outdated insights: [list]++### Archive Actions+**Braindumps Processed:**+- Updated metadata from `status: "captured"` to `status: "consolidated"`+- Added consolidation references: `consolidated_in: "[[consolidation-YYYY-MM-DD]]"`++**Superseded Content:**+- Archived: [list of old framework versions or outdated insights]+- Location: `00-inbox/archive/`++---++## Future Consolidation Needs++### Ready for Framework Creation+- [ ] [Area 1] - Sufficient evidence gathered - Target: [date]+- [ ] [Area 2] - Pattern established - Target: [date]++### Needs Deeper Analysis+- [ ] [Area 3] - Contradictions to resolve - Target: [date]+- [ ] [Area 4] - Emerging but not yet clear - Target: [date]++### Monitoring Required+- [ ] [Pattern 1] - Watch for additional occurrences+- [ ] [Theme 2] - Track evolution over next [period]++---++## Quality Assessment++**Completeness:** [All relevant insights processed?]++**Coherence:** [Frameworks logically consistent?]++**Traceability:** [Clear links to source material?]++**Actionability:** [Frameworks applicable to decisions?]++**Evolution Documented:** [Thinking progression captured?]++---++## Next Steps++**Immediate Actions:**+- [Action 1 based on consolidation insights]+- [Action 2 to apply new frameworks]++**Future Consolidation:**+- **Next Consolidation:** [Suggested date]+- **Focus Areas:** [What to emphasize next time]++**Framework Applications:**+- [Decision 1 that could benefit from framework]+- [Situation 2 to apply framework to]++---++*Consolidation completed: [Date] | Processed [X] documents | Created/updated [X] frameworks*+```++Save to: `05-knowledge/consolidated/consolidation-YYYY-MM-DD.md`++### 6. Cleanup and Archival++**Mark processed braindumps:**+Update frontmatter in processed braindumps:+```yaml+status: "consolidated"+consolidated_in: "[[consolidation-YYYY-MM-DD]]"+consolidated_date: "YYYY-MM-DD"+```++**Archive outdated content:**+Move superseded frameworks or insights to:+`00-inbox/archive/[filename]-archived-YYYY-MM-DD.md`++Add note explaining why archived and what supersedes it.++**Maintain clean knowledge base:**+- Remove redundancy while preserving important context+- Update cross-references+- Fix broken links+- Ensure consistent tagging++### 7. Confirm Completion++After consolidation:+- Show user: "Knowledge consolidation complete! Processed [X] documents"+- Highlight: "[X] frameworks updated, [X] new frameworks created"+- Show: "Consolidation report saved to [file path]"+- Suggest reviewing key frameworks created/updated+- Offer to explain any specific framework in detail++## Loop Engineering++Consolidation is a **loop-until-dry extraction with a completeness critic**, not a single scan. See `.claude/skills/loop-engineering/SKILL.md` for the shared vocabulary.++**The loop:** scan a batch of in-scope documents → extract themes, patterns, and candidate framework principles → run the completeness critic ("any in-scope doc not yet read? any theme recurring across N+ docs that no framework captures yet?") → if the critic surfaces something new, run another extraction pass → stop when 2 passes in a row surface nothing new (dry). In `agent_mode: team`, the first scan fans out as one worker per domain (personal / professional / per-project / briefs); each returns its conclusions only, and a synthesis pass merges them.++**The verifier (deterministic where it can be):**+- **Traceability:** every framework principle links at least one source document. A principle with no `[[source]]` is dropped, not published. This is mechanical and is COG's verification-first rule for consolidation.+- **Coverage:** every in-scope document ends marked `status: "consolidated"` with a `consolidated_in` backlink.+- **Dedup:** before creating a framework, check `05-knowledge/consolidated/` so an existing framework is updated, not duplicated.+- The completeness critic ("did we miss a theme?") is the one judgment-based check; keep it explicit and evidence-linked.++**Termination conditions (layered):**+- **Dry:** K=2 consecutive passes find no new theme or document.+- **Coverage complete:** all in-scope documents marked consolidated.+- **Hard cap:** a max number of extraction passes, so a noisy corpus cannot loop forever.++**Patterns:** loop-until-dry (the spine) + plan-execute-verify (each pass) + orchestrator-workers (team-mode domain scans) + completeness critic.++**In-loop context:** write the consolidation report incrementally and dedup new themes against the running set, not against the conversation. Externalizing to the report file is what keeps a large corpus from overflowing the window.++## Consolidation Guidelines++### Quality Over Quantity+- Don't force insights that aren't mature enough+- Let patterns emerge naturally from evidence+- Be patient with incomplete thinking+- Quality frameworks require time and evidence+- Mark frameworks as "emerging" vs "working" vs "stable"++### Preserve Nuance+- Don't over-simplify complex insights+- Maintain important context and conditions+- Note when frameworks have limitations+- Preserve contradictions that haven't resolved yet+- Acknowledge uncertainty explicitly++### Maintain Traceability+- Always link back to source documents+- Show evidence trail for frameworks+- Document evolution of thinking+- Enable future validation or revision+- Make it easy to audit framework claims++### Living Documents+- Frameworks should evolve with new insights+- Regular updates better than perfect first draft+- Clear status indicators (emerging/working/stable)+- Encourage iteration and refinement+- Version history through Git++## Analysis Techniques Reference++### Pattern Detection Methods+1. **Frequency Analysis:** Count mentions, cluster topics+2. **Temporal Clustering:** Group by time, track evolution+3. **Domain Correlation:** Cross-domain connections+4. **Contradiction Analysis:** Identify conflicts, track resolution+5. **Energy Pattern Detection:** Emotional and practical patterns++### Framework Synthesis Process+1. **Identify Core Principles:** Extract fundamental truths+2. **Test Against Evidence:** Validate with sources+3. **Define Boundaries:** Establish applicability+4. **Create Applications:** Develop use cases+5. **Document Evolution:** Track development over time++### Timeline Construction Method+1. **Mark Inflection Points:** When thinking shifted+2. **Identify Catalysts:** What triggered changes+3. **Document Evolution:** How understanding developed+4. **Extract Learnings:** What evolution teaches++## Success Metrics+- Completeness: All relevant insights processed+- Coherence: Frameworks logically consistent+- Traceability: Clear links to source material+- Actionability: Frameworks applicable to decisions+- Evolution: Documented thinking progression+- User Value: Frameworks actually used in practice++## Common Use Cases+- **Weekly Consolidation:** Process week's insights into patterns+- **Monthly Framework Development:** Build strategic frameworks+- **Quarterly Strategic Synthesis:** Big-picture consolidation+- **Annual Knowledge Base Cleanup:** Maintain quality and relevance+- **Pre-Decision Framework Consultation:** Apply frameworks to major decisions+- **Project Retrospective:** Extract learnings for frameworks++## Philosophy++The knowledge consolidation skill embodies COG's self-evolving intelligence:+- Transforms scattered thoughts into strategic frameworks+- Honors the evolution of thinking over time+- Builds "single source of truth" living documents+- Maintains traceability and evidence-based reasoning+- Creates actionable knowledge for better decision-making+- Respects nuance while seeking patterns+- Values iteration and continuous refinementdiff --git a/skills/loop-engineering/SKILL.md b/skills/loop-engineering/SKILL.mdnew file mode 100644index 0000000..e01f0ff--- /dev/null+++ b/skills/loop-engineering/SKILL.md@@ -0,0 +1,96 @@+---+name: loop-engineering+description: Shared loop-engineering reference for COG skills - the agent loop, deterministic verifiers, termination conditions, in-loop context management, and named patterns. Invoke when designing or debugging a skill that iterates (search-verify-retry, scan-until-dry, fetch-retry-gate).+roles: [all]+integrations: []+---++# COG Loop Engineering++> **TL;DR:** Some COG skills are not one-shot prompts. They are loops: act, observe, verify, decide whether to continue. This skill is the shared vocabulary those skills use. The iron rule: **trust deterministic checks, never the agent's own "looks done" self-report.** Every loop must declare its verifier, its stopping conditions, and which pattern it follows.++This is a reference and design aid, not a content-generating workflow. Skills that loop (daily-brief, knowledge-consolidation, url-dump, weekly-checkin, and research/triage skills like auto-research and scout) link here instead of restating the rules. Invoke it directly when you are building or fixing an iterative skill.++## Why loops++A chain runs fixed steps: A then B then C. A loop is dynamic: the agent takes an action, reads real feedback (a fetched page, a date stamp, a file count), reasons about it, and repeats until a goal is met or a stop condition fires. Most knowledge-work that "keeps going until good enough" is a loop, and COG benefits from naming the loop explicitly rather than hoping a single prompt nails it.++## The COG loop++```+ ┌──────────────────────────────────────────────┐+ │ 1. Gather pull context (vault + sources) │+ │ 2. Act one step: search / fetch / scan │+ │ 3. Observe read the real result │+ │ 4. Verify run the deterministic check │+ │ 5. Update write progress to a vault file │+ │ 6. Decide continue? → loop │+ │ stop? → finish + report │+ └──────────────────────────────────────────────┘+```++Step 4 is the load-bearing one. A loop without a verifier is just a chain that repeats.++## Termination conditions (use layers, never one)++A robust loop needs several exits so it always halts:++| Exit | What it is | Example |+|------|-----------|---------|+| **Deterministic verifier** | A mechanical pass/fail that confirms the goal | "Publication date is within 7 days" |+| **Hard iteration cap** | Max passes, no matter what | "Stop after 5 searches per topic" |+| **Budget guard** | Max time / tool calls / tokens | "Stop after 20 fetches total" |+| **No-progress detection** | Recent passes changed nothing | "2 searches in a row found nothing new" |+| **Human escalation** | Hand a stuck loop back to the user | "Asked twice, still unclear: ask the user" |++Pick the verifier plus at least one safety exit (cap or budget) for every loop. No-progress detection is what stops the quiet infinite loops that a cap alone misses.++## Verification first (COG's rule, applied to loops)++COG is verification-first: no hallucinations, sources required. Inside a loop that means:++- **Prefer mechanical checks.** A date comparison, a source count, a "required field is non-empty", a "file marked consolidated" check cannot be gamed and cannot be hallucinated.+- **Reserve judgment-based checks for the genuinely unquantifiable** (is this theme actually new? is this summary faithful?). When you must use judgment, state confidence and link evidence.+- **Never accept the agent's own "I think this is complete."** That is the single most common way loops produce confident garbage.++## In-loop context management++Long loops fill the window with old tool output and start to drift ("context rot"). Counter it:++- **Externalize state to the vault.** Write progress to the output file as you go. The vault file is the memory; the conversation is scratch.+- **Compact and prune.** Summarize finished passes into a line or two. Drop raw page text once you have extracted what you need.+- **Isolate sub-agents.** In `agent_mode: team`, give each worker only the slice it needs and take back only its conclusion, so one subtask runs in a clean window. Never paste one worker's raw output into the next worker's prompt.++## Named patterns++| Pattern | Shape | Where COG uses it |+|---------|-------|-------------------|+| **Act-observe (ReAct)** | reason → act → observe → repeat | base of every COG loop |+| **Reflect-retry (Reflexion)** | on failure, write the lesson, retry differently | url-dump / scout fetch retries, daily-brief re-search |+| **Plan-execute-verify** | plan steps, run them, verify each | knowledge-consolidation passes |+| **Evaluator-optimizer** | generate, score against criteria, repeat until it passes | daily-brief item verify, url-dump quality gate |+| **Orchestrator-workers** | split into subtasks, run in fresh windows, synthesize | team-mode scans, auto-research threads, team-brief |+| **Loop-until-dry** | keep going until K passes in a row surface nothing new | knowledge-consolidation theme extraction |+| **Human-in-the-loop** | escalate or ask when the loop is stuck or the call is the user's | weekly-checkin reflection, onboarding |++## Failure modes and fixes++| Failure | Fix |+|---------|-----|+| Context overflow / drift | compact, prune, externalize to vault, isolate sub-agents |+| Silent infinite loop | no-progress detection plus a hard cap |+| Hallucinated success | trust the deterministic verifier, never self-report |+| Compounding errors | verify early and every pass, not only at the end |+| Cost blowup | budget guard, and stop at "good enough", not "perfect" |+| Goal drift | keep the goal and stop conditions written at the top of the loop's state |++## How skills use this++A skill's `## Loop Engineering` section should be short and concrete. It names:++1. **The loop** in one or two lines (what repeats).+2. **The verifier** (the mechanical pass/fail).+3. **The termination conditions** (verifier plus safety exits).+4. **The pattern(s)** from the table above.++It does not restate this skill. It points here.diff --git a/skills/meeting-transcript/SKILL.md b/skills/meeting-transcript/SKILL.mdnew file mode 100644index 0000000..1d189ee--- /dev/null+++ b/skills/meeting-transcript/SKILL.md@@ -0,0 +1,237 @@+---+name: meeting-transcript+description: Process meeting recordings and notes into structured decisions, action items, and team dynamics with intelligent noise filtering+roles: [product-manager, engineering-lead, founder, designer]+integrations: []+---++# COG Meeting Transcript Skill++## When to Invoke+- User shares a meeting transcript or recording notes+- User says "process meeting", "meeting notes", "meeting transcript"+- User has a block of text from a meeting they want structured+- User mentions wanting to extract action items from a meeting++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use the full parallel agent execution strategy below (3 agents)+- If `agent_mode: solo` — process sequentially: extract content first, then analyze dynamics, then enrich with context.++## Purpose+Extract strategic insights from meeting recordings and notes with intelligent content filtering to focus on substantive, actionable content while removing noise and irrelevant information.++## Command: `/meeting-transcript`++## Parallel Agent Team Execution Strategy++**Use parallel agents to process different aspects of the transcript simultaneously.**++### Phase 1: Setup (Orchestrator)+1. Receive transcript content from user+2. Detect content type (meeting vs braindump) and classify domain+3. Split transcript into logical sections for parallel processing++### Phase 2: Parallel Processing (Spawn 2-3 Agents Simultaneously)+**Launch ALL agents in a single message using Task tool with `run_in_background: true`:**++#### Agent 1: "content-extractor" (subagent_type: general-purpose)+```+Extract structured content from the meeting transcript.++1. Filter out side chats, technical difficulties, and irrelevant banter+2. Identify and extract: decisions made (with rationale), action items (with owners/deadlines), strategic themes+3. Capture key quotes and insights from participants+4. Note unresolved issues and follow-up needs++Return: Decisions list, action items list, strategic themes, key quotes, unresolved issues.+```++#### Agent 2: "dynamics-analyst" (subagent_type: general-purpose)+```+Analyze team dynamics and meeting effectiveness.++1. Assess communication patterns and participation levels+2. Identify leadership moments and collaboration quality+3. Evaluate decision-making process effectiveness+4. Assess meeting efficiency (time well spent vs wasted)+5. Note any tensions, disagreements, or alignment issues++Return: Team dynamics assessment, participation analysis, meeting effectiveness score.+```++#### Agent 3: "context-enricher" (subagent_type: general-purpose)+```+Enrich meeting content with project/product context.++1. If project-related: read recent braindumps and notes for context+2. Check if discussed topics relate to known issues/PRs on GitHub+3. Connect decisions to existing strategic priorities+4. Identify competitive intelligence if competitors mentioned++Return: Contextual connections, related documents, strategic alignment notes.+```++### Phase 3: Assembly (Orchestrator)+1. Collect results from all processing agents+2. Assemble structured meeting summary following Content Structure template+3. Add proper metadata (participants, duration, type, action item count)+4. Save to appropriate domain meeting folder+5. Flag urgent action items for immediate attention++## Content Filtering Guidelines++### EXCLUDE (Filter Out)+- **Side Conversations**: "Hey, did you see the game last night?"+- **Technical Difficulties**: "Can you hear me now?" "Your mic is muted"+- **Incomplete Thoughts**: "So I was thinking we should... never mind"+- **Casual Banter**: Weather, personal anecdotes unrelated to work+- **Interruptions**: "Sorry, I have to take this call"+- **Unclear Statements**: Mumbled or inaudible content++### INCLUDE (Keep and Analyze)+- **Strategic Discussions**: Market analysis, competitive positioning+- **Decision Points**: "We've decided to move forward with Option A"+- **Action Items**: "Alex will complete the analysis by Friday"+- **Problem Solving**: Discussion of challenges and proposed solutions+- **Planning**: Timeline discussions, resource allocation+- **Insights**: "The key insight is that customers want..."+- **Concerns**: "My concern is that this approach might..."++## Metadata Template+```yaml+---+type: meeting-transcript+domain: [personal|professional|project-specific]+project: [project-name] # Only for project-specific meetings+date: YYYY-MM-DD+created: YYYY-MM-DD HH:MM+meeting_type: [1-on-1|team-meeting|strategic-planning|project-review|other]+participants: [participant1, participant2, participant3]+duration: [minutes]+content_filtered: true+accuracy_verified: [true|false|pending]+action_items_count: [number]+decisions_count: [number]+tags:+ - meeting+ - transcript+ - domain-tag+ - project-tag+status: [processed|needs-follow-up|action-required]+---+```++## Content Structure++### 1. Meeting Overview+- **Date/Time**: When the meeting occurred+- **Participants**: Who was present and their roles+- **Purpose**: Primary objective of the meeting+- **Duration**: Actual meeting length+- **Type**: Category of meeting++### 2. Key Decisions (Verified Content Only)+- **Decision**: What was decided+- **Rationale**: Why this decision was made+- **Owner**: Who is responsible for implementation+- **Timeline**: When decision takes effect+- **Impact**: Expected outcomes and implications++### 3. Action Items (Substantive Only)+- **Task**: Specific action to be taken+- **Owner**: Person responsible+- **Deadline**: When it's due+- **Dependencies**: What needs to happen first+- **Success Criteria**: How completion will be measured++### 4. Strategic Themes (From Substantial Discussion)+- **Theme**: Major topic or pattern discussed+- **Context**: Why this theme is important+- **Implications**: What this means for the team/project+- **Next Steps**: How to address or leverage this theme++### 5. Unresolved Issues+- **Issue**: Problem or question that remains open+- **Context**: Background and importance+- **Blocking Factors**: What's preventing resolution+- **Proposed Next Steps**: How to move forward++### 6. Team Dynamics Assessment+- **Communication Quality**: How effectively team communicated+- **Decision-Making Process**: How decisions were reached+- **Participation**: Who contributed and how+- **Meeting Efficiency**: Time management and focus+- **Areas for Improvement**: Suggestions for better meetings++## Domain-Specific Processing++### Personal Domain Meetings+- Focus on career development and personal growth+- Maintain strict privacy for personal discussions+- Extract learning and development opportunities+- Save to `[CUSTOMIZE: path/to/personal/]meetings/`++### Professional Domain Meetings+- Analyze leadership and team management aspects+- Extract strategic business insights+- Identify professional development opportunities+- Save to `[CUSTOMIZE: path/to/professional/]meetings/`++### Project-Specific Meetings+- Connect to project metrics and milestones+- Analyze progress against project goals+- Extract competitive and market intelligence+- Save to `[CUSTOMIZE: path/to/projects/][project-name]/meetings/`++## Content Filtering Protocol++### Step 1: Initial Scan+- Identify meeting phases (intro, main discussion, wrap-up)+- Mark obvious side conversations and technical issues+- Flag incomplete or unclear statements++### Step 2: Relevance Assessment+- Evaluate each segment for strategic value+- Determine if content relates to meeting objectives+- Assess completeness and accuracy of information++### Step 3: Accuracy Verification+- Cross-check contradictory statements+- Flag information that seems incorrect+- Note areas requiring clarification++### Step 4: Context Preservation+- Ensure decisions have sufficient context+- Maintain background for action items+- Preserve strategic discussion flow++## Quality Assurance++### Verification Standards+- All decisions must have clear context and rationale+- Action items must have specific owners and deadlines+- Strategic themes must be supported by substantial discussion+- Team dynamics assessment must be based on observable patterns++### Uncertainty Handling+- Flag potentially incorrect information for user confirmation+- State confidence levels for interpretations+- Request clarification for ambiguous content+- Explicitly note when information is incomplete++## Integration with Daily Brief++Meeting notes processed by this command feed directly into the daily brief:+- **Phase 2, Agent 3** (`meeting-reviewer`) scans for recent meeting files+- **Phase 3** cross-references action items against GitHub PRs and Linear issues+- **Section 13** (`Meeting Follow-Up Tracker`) tracks commitment completion++This creates accountability: decisions and action items from meetings are automatically tracked against actual execution in code and project management tools.++## Learning Integration+- Track meeting effectiveness patterns over time+- Identify successful decision-making processes+- Learn team communication preferences+- Adapt filtering based on user feedback on relevancediff --git a/skills/memory-hygiene/SKILL.md b/skills/memory-hygiene/SKILL.mdnew file mode 100644index 0000000..03dfcbf--- /dev/null+++ b/skills/memory-hygiene/SKILL.md@@ -0,0 +1,87 @@+---+name: memory-hygiene+description: Periodic trust sweep of persistent memory and durable knowledge notes - re-verifies environment-dependent claims against the live environment, stamps last_verified + confidence, and proposes archiving drifted entries+roles: [all]+integrations: []+---++# COG Memory Hygiene Skill++## Purpose++Prevent the **stale-but-confident** failure mode: a memory or knowledge note that was correct when written ("the webhook lives at X", "the board ID is Y") silently drifts after the environment changes, yet still ranks high at recall and gets acted on.++The system move (adapted from "From Model Scaling to System Scaling: Scaling the Harness in Agentic AI", Gu, UC Berkeley, arXiv:2605.26112): **make trust a runtime decision, not a property of the stored item**. Re-verify against the live environment, and keep per-entry `last_verified` and `confidence` as first-class fields so future recalls can weigh trust.++## When to Invoke++- `/memory-hygiene`+- "Audit my memories" / "check for stale memories"+- After a memory misfires (a recalled fact turned out wrong)+- Default cadence: monthly++## Scope++Sweep two stores:++1. **Agent memory** — wherever your agent keeps persistent memory files (e.g. Claude Code's auto-memory directory). Sweep every entry except the index itself.+2. **Durable knowledge notes** — `05-knowledge/**` files whose claims reference the environment (paths, URLs, IDs, tool names).++A partial sweep ("just the reference entries") is fine when asked.++## Claim Classification++For each entry, split its claims into two buckets:++| Bucket | Examples | Action |+|---|---|---|+| **Environment-dependent** | file/dir paths, repo names, branch names, channel IDs, board IDs, URLs, API endpoints, cron/routine IDs, CLI names, version numbers, "X lives at Y" | Verify against the live environment |+| **Preference / judgment** | tone rules, formatting rules, "never do X", people facts, strategy context | No environment check possible; verify only for internal contradiction with newer entries |++## Verification Moves (cheap first)++- Paths and files: `ls` / `test -e`. Skills, commands, and agents named in an entry must still exist at the stated path.+- URLs: resolve with a HEAD/GET (`curl -sI`); flag 404 or redirect-to-login.+- Repos/branches: `gh repo view`, `git ls-remote` when cheap.+- IDs (channels, boards, routine triggers): verify only if an MCP/CLI check is one call; otherwise mark `unverifiable-cheaply` and leave confidence untouched.+- Cross-entry contradiction: newer entry wins; flag the older one.++Never spend more than ~1 minute per entry. This is hygiene, not an investigation. **Unverifiable ≠ drifted.**++## Stamping++After checking an entry, update its frontmatter `metadata:` block in place (do not touch body text unless fixing a verified-wrong fact):++```yaml+metadata:+ type: reference+ last_verified: 2026-07-10+ confidence: high # high = verified now | medium = unverifiable cheaply | low = partially drifted+```++- Verified clean → `confidence: high`, stamp date.+- Unverifiable cheaply → keep prior confidence (or `medium`), stamp date.+- Partially drifted → fix the drifted fact directly in the body (reviewable via the report); set `confidence: low` only if unsure the fix is complete.+- Fully obsolete → **propose archive, don't delete.** List it in the report's "Propose archive" section; only archive after the user confirms.++## The Loop (see /loop-engineering)++Scan-until-done over the entry list with a per-entry budget guard (~1 min). The deterministic verifier is the environment itself (`test -e`, `curl`, `gh`) — never the agent's own recollection of whether something "should" still exist. Human escalation: all deletions/archives.++## Report (single file)++Write one report per sweep to `01-daily/YYYY-MM-DD-memory-hygiene.md`, structured around four evolution questions:++1. **What persists?** — counts by type (user/feedback/project/reference).+2. **What updated?** — entries whose body was corrected, with old → new.+3. **What is measured?** — scorecard: `verified / unverifiable / drifted / propose-archive` counts, plus deltas vs the previous sweep report (the drift *trend* is the longitudinal signal one-shot checks miss).+4. **What is auditable?** — every change in this sweep is a line in this report; for stores Git does not track, the report IS the audit trail.++End the report with a **Propose archive** section (explicit list, one line of evidence each) and a **Waiting on you** line if anything needs a decision.++## Rules++- Propose-only for deletions/archives; direct-apply for stamps and verified factual corrections.+- Never rewrite an entry's voice or restructure it during a sweep.+- If the memory index points at renamed/missing files, fix the index.+- Keep the sweep itself out of memory: the report file is the record.diff --git a/skills/museum-art/SKILL.md b/skills/museum-art/SKILL.mdnew file mode 100644index 0000000..8e02c26--- /dev/null+++ b/skills/museum-art/SKILL.md@@ -0,0 +1,98 @@+---+name: museum-art+description: Source authentic, high-res PUBLIC-DOMAIN artwork from museum open-access APIs (Met, Cleveland, SMK, Rijksmuseum, NGA, Art Institute of Chicago, Getty, Smithsonian) instead of AI-generated or generic-stock imagery. The default move whenever a visual needs an aesthetic, credible image (blog heroes, decks, social cards, essay/spec figures). Verified keyless recipes + licensing rules inside.+---++# museum-art: Public-Domain Artwork for Visuals++> Standing rule (adopted 2026-07-24, from Eric Li's post on museum open-access): **whenever a visual needs a real image with aesthetic weight, source public-domain museum artwork first** - over AI-generated imagery and over generic stock. Curated, historically significant art reads as credible and sophisticated; AI-gen reads as slop. This stacks with, and reinforces, the `no-ai-slop` skill and your house image style. It does NOT replace the generative `editorial-illustrations` skill (that owns claim-driven diagrams/figures) or your house chart style - use museum art for photographic/hero/decorative/mood imagery, generative figures for data and concept diagrams.++## When to reach for this+- Blog post hero images, section breaks, mood imagery (the blog-publish image step).+- Deck/slide backgrounds and section dividers, social cards, essay figures, spec cover art.+- Any time the instinct is "generate an image" for something decorative or evocative. Stop and pull a real painting instead.+- NOT for: product screenshots, UI mockups, data charts, logos, or claim-driven explanatory diagrams (those are editorial-illustrations / real captures).++## Decision: which source+1. **Met -> Cleveland -> SMK first.** All keyless, one JSON hop, CC0/PD, broad collections. Fastest path to a hi-res image.+2. **Need Dutch/Flemish masters or decorative arts?** Rijksmuseum (keyless, 3 hops).+3. **Need European antiquities/photography and keyword isn't essential?** Getty (keyless, SPARQL).+4. **Nothing fits, or you want a cross-museum search?** Wikimedia Commons API (keyless aggregator, normalized license metadata) is the best general fallback.+5. **"Historical illustration/engraving/old photo" rather than fine-art painting?** Go straight to Internet Archive or Wikimedia Commons.+6. **Science/health/medical essay figure?** Wellcome Collection (keyless, CC0/PD).++## How to fetch in THIS environment+- Use **WebFetch** to hit the JSON search endpoint, then WebFetch/download the returned image URL. These APIs are server-side reachable; no browser needed.+- **Exception - Art Institute of Chicago images:** the JSON API (`api.artic.edu`) is fine, but the image host `www.artic.edu/iiif/...` 403s scripted/curl fetches via a Cloudflare bot challenge. Use the JSON metadata from AIC, but download the actual image through a real/headless browser (browser-harness) or prefer a different museum for the image bytes.+- Always **filter for public domain in the query AND spot-check the per-image license flag** before shipping (see Licensing).++## Freshness over caching (mandatory)+**Fetch fresh per need. Do NOT build a reusable local pool of downloaded images to draw from.** A small cached set gets reused everywhere and becomes the new "same stock photo on every post" - sameness is a form of slop, and the variety of a huge open collection is the entire point. Fetching is keyless and sub-second, so there is no cost reason to cache pixels.+- **Cache recipes/metadata, not images** - that is what this skill's `references/` already are.+- **Commit an image only into the specific artifact that uses it** (a post's `assets/`, a deck's media) once chosen - for provenance and offline builds. That is an artifact asset, never a shared library other artifacts pull from.+- Each new visual = a fresh query. Vary the search terms and the source museum so consecutive posts do not converge on the same few crowd-pleasers.++## Verified keyless recipes (2026-07-24, all live-tested)++### 1. The Met - best all-around default+- Base: `https://collectionapi.metmuseum.org/public/collection/v1/` - no key, 80 req/s, CC0 where `isPublicDomain:true`.+- Search: `GET /search?q=<term>&hasImages=true&isPublicDomain=true` -> `{total, objectIDs[]}`+- Object: `GET /objects/{id}` -> read `primaryImage` (full-res JPEG, static, no IIIF hop) or `primaryImageSmall` (web-large).+- Example: `https://collectionapi.metmuseum.org/public/collection/v1/search?q=sunflowers&hasImages=true&isPublicDomain=true`++### 2. Cleveland Museum of Art - only one with archival TIFF+- Base: `https://openaccess-api.clevelandart.org/api/artworks/` - no key, CC0.+- Search: `GET /api/artworks/?cc0=1&has_image=1&limit=10` (add `&q=monet`, `&skip=10`).+- Image fields on each result: `images.web.url` (900px), `images.print.url` (3400px JPEG), `images.full.url` (archival TIFF). Directly downloadable from `openaccess-cdn.clevelandart.org`.+- Confirm `share_license_status == "CC0"` per result.++### 3. SMK (Denmark) - one-hop, broad European/Nordic+- Base: `https://api.smk.dk/api/v1` - no key. License: Public Domain Mark 1.0 (functionally CC0).+- Search: `GET /art/search?keys=*&filters=[public_domain:true]&filters=[has_image:true]`+- Read `image_native` directly from each result (no chain).+- **Gotcha (verified):** pass `filters` as a **repeated** query param, one `[field:value]` bracket each. Concatenating `filters=[public_domain:true][has_image:true]` returns 200 but silently ignores the second condition.++### 4. Rijksmuseum - Dutch/Flemish masters (keyless, 3 hops)+- Base: `https://data.rijksmuseum.nl/search/collection` (Linked Art, no key).+- `GET /search/collection?type=painting&imageAvailable=true` -> walk object -> VisualItem -> DigitalObject -> `access_point[0].id` is a ready IIIF URL.+- Mixed license: mostly CC0/PD but some CC BY 4.0 - **check the per-object rights block** (a CC BY item requires attribution).++### 5. NGA (Washington) - bulk/offline, no live search+- CSV: `https://raw.githubusercontent.com/NationalGalleryOfArt/opendata/main/data/published_images.csv` - filter `openaccess=1`.+- Image (IIIF): `https://api.nga.gov/iiif/{uuid}/full/full/0/default.jpg`+- **Per-image `openaccess=0` rows are NOT open** (resolution-capped, rights-restricted). Only `openaccess=1` is free.++### 6. Art Institute of Chicago - Impressionism/European (image host caveat)+- JSON: `GET https://api.artic.edu/api/v1/artworks/search?query[term][is_public_domain]=true&fields=id,title,image_id` - no key, CC0.+- Image: build `https://www.artic.edu/iiif/2/{image_id}/full/843,/0/default.jpg` - **but Cloudflare 403s scripted fetches**; download via browser or use another museum for bytes.++### 7. Getty - European painting/photography/antiquities (SPARQL)+- Base: `https://data.getty.edu/museum/collection/` - no key. No keyword search; use SPARQL with `?obj crm:P138i_has_representation ?img` which returns a ready IIIF image URL in the same query.+- Dataset is CC0; **per-image rights inconsistently populated** - cross-check the object's public getty.edu page (a "Download" button flags true Open Content) before commercial use.++## Key-gated + aggregator sources (know these too)+- **Smithsonian** (needs free `api.data.gov` key; `DEMO_KEY` works at 30 req/hr): `GET https://api.si.edu/openaccess/api/v1.0/search?q=<term> AND online_media_type:Images&api_key=KEY`; CC0; check `media[].usage.access=="CC0"` per image. Extremely broad (SAAM, NPG portraits, Freer/Sackler Asian, Cooper Hewitt design).+- **Wikimedia Commons** (keyless, best aggregator fallback): `https://commons.wikimedia.org/w/api.php?action=query&generator=search&gsrsearch=<term>&gsrnamespace=6&prop=imageinfo&iiprop=url|extmetadata`; license per file in `extmetadata.LicenseShortName`; raw bytes via `Special:FilePath/{filename}`.+- **Wellcome Collection** (keyless): `https://api.wellcomecollection.org/catalogue/v2/works?query=<term>`; CC0/PD medical/scientific/historical imagery.+- **Internet Archive** (keyless): `https://archive.org/advancedsearch.php?q=<term>&fl[]=identifier&output=json`; PD book illustrations, engravings, historical photos, ephemera.+- **Europeana** (free key): `https://api.europeana.eu/record/v2/search.json?wskey=<KEY>&query=<term>`; 50M+ items across European institutions.+- **Harvard Art Museums** (free key): `https://api.harvardartmuseums.org/object?apikey=<KEY>&q=<term>`.+- **Yale LUX** (keyless, Linked Art like Getty): `https://lux.collections.yale.edu/api/search/...`; strong British art + rare books.+- **Paris Musees** (keyless, explicit CC0): `parismuseescollections.paris.fr` / `opendata.paris.fr`; French painting/decorative arts.+- **NYPL Digital Collections** (free key): `https://api.repository.library.nyc/...`; PD prints, maps, photos, illustrations.+- **DPLA** (free key): `https://api.dp.la/v2/items?q=<term>&api_key=<KEY>`; federated US collections.++## Licensing rules (apply before shipping any image)+- **True CC0 (no attribution required):** Met, Cleveland, Art Institute of Chicago, Smithsonian, NGA (dataset-level; image gated by per-image `openaccess=1`).+- **Public Domain Mark / open-but-not-CC0 (free to use, credit requested not required):** SMK, and the PD subset of Rijksmuseum.+- **Verify per-image, do NOT blanket-trust collection-level "open access":** Getty, Rijksmuseum (CC BY items require attribution), NGA and Smithsonian per-image flags.+- **Rule:** when the API exposes a rights/license field, filter on it in the query AND spot-check it on the chosen image. Never assume "the collection is open access" implies "this specific image is."+- **Good practice everywhere:** a one-line credit ("Digital image courtesy of [Museum]") costs nothing and covers mixed-license collections. When masking/compositing per house style, keep the credit.++## Relationship to other skills+- Stacks with **no-ai-slop** and the house image style: real museum art is the anti-slop default for evocative imagery.+- Complements **editorial-illustrations** (generative claim-driven diagrams) and **dataviz** (charts) - those own explanatory graphics; this owns photographic/artwork/mood imagery.+- Feeds **blog-publish**, **social-media-kit**, **weekly-ai-slide**, deck and essay work at their image-sourcing step.++## References (full per-museum recipes, verified)+`references/_synthesis.md` (cheat-sheet) + one file per museum (`met.md`, `cleveland.md`, `smk.md`, `rijksmuseum.md`, `nga.md`, `artic.md`, `getty.md`, `smithsonian.md`) with live-tested example URLs, field maps, and gotchas.diff --git a/skills/museum-art/references/_synthesis.md b/skills/museum-art/references/_synthesis.mdnew file mode 100644index 0000000..96ea1f4--- /dev/null+++ b/skills/museum-art/references/_synthesis.md@@ -0,0 +1,48 @@+# Public-Domain Art Sourcing Cheat-Sheet++Consolidated from 8 verified museum-API recipes (2026-07-24). For an agent sourcing hi-res public-domain artwork for blog heroes, decks, social cards, essay figures.++## Quick-pick table (ranked: fastest/most reliable first)++| Rank | Museum | Keyless? | License | How to get a hi-res PD image (one line) | Best for |+|---|---|---|---|---|---|+| 1 | **Met (Metropolitan Museum)** | Yes, no key | CC0 (per-object flag) | `GET /search?q=X&hasImages=true&isPublicDomain=true` → `/objects/{id}` → read `primaryImage` (static JPEG, no IIIF hop) | Broadest single source — Western painting, Asian art, Egyptian antiquities, American art |+| 2 | **Cleveland Museum of Art** | Yes, no key | CC0 | `GET /api/artworks/?cc0=1&has_image=1` → read `images.print.url` (3400px JPEG) or `images.full.url` (archival TIFF) — no hop | Broad European/American painting + Asian art; archival-res TIFFs available |+| 3 | **SMK (National Gallery of Denmark)** | Yes, no key | Public Domain Mark (functionally CC0) | `GET /art/search?keys=*&filters=[public_domain:true]&filters=[has_image:true]` (repeat `filters=`, don't concatenate!) → read `image_native` directly | Danish/Nordic + European painting, decorative arts |+| 4 | **Rijksmuseum** | Yes, no key | CC0/PD (mostly), check per-object | `GET /search/collection?type=painting&imageAvailable=true` → walk object → VisualItem → DigitalObject → `access_point[0].id` is the ready IIIF URL (3 sequential GETs) | Dutch/Flemish masters, prints, decorative arts |+| 5 | **NGA (National Gallery of Art, DC)** | Yes, no key | CC0 (dataset); per-image `openaccess` flag gates rights | Download `published_images.csv` from GitHub, filter `openaccess=1`, then `GET https://api.nga.gov/iiif/{uuid}/full/full/0/default.jpg` | American + European painting/sculpture; best for bulk/offline querying (no live search API) |+| 6 | **Art Institute of Chicago** | Yes, no key | CC0 | `GET /artworks/search?query[term][is_public_domain]=true&fields=...,image_id` → build `https://www.artic.edu/iiif/2/{image_id}/full/full/0/default.jpg` — **but** the image host (`www.artic.edu`) 403s scripted/curl fetches (Cloudflare bot challenge); JSON metadata API is fine, image download needs a real/headless browser | Impressionism, European + American painting, Buddhist/Asian art |+| 7 | **Getty** | Yes, no key | CC0 (dataset); images "mostly" CC0 but per-image rights block inconsistently populated — verify before trusting | No keyword search exists — use SPARQL (`?obj crm:P138i_has_representation ?img`) which returns a ready-to-use IIIF image URL directly in the same query | European painting, photography, antiquities, decorative arts |+| 8 | **Smithsonian** | **No** — needs `api_key` (free instant signup, or shared `DEMO_KEY` at 30 req/hr) | CC0 | `GET /search?q=X AND online_media_type:Images&api_key=KEY` → `media[].content` (IDS deliveryService URL); check `media[].usage.access=="CC0"` per-image | Extremely broad: American art (SAAM), portraiture (NPG), Asian art (Freer\|Sackler), design (Cooper Hewitt), natural history/specimens |++## The 2-3 best keyless APIs to reach for FIRST++1. **The Met Collection API** — single JSON call, no IIIF/linked-data hop, `primaryImage` field is a directly-downloadable full-res JPEG, CC0 is a simple boolean flag, 80 req/sec, huge and diverse collection. Best all-around default.+2. **Cleveland Museum of Art Open Access API** — same one-hop simplicity as the Met, plus it's the only one of the 8 offering an archival-resolution TIFF tier (`images.full`) alongside a 3400px print JPEG, no rate limit trouble observed.+3. **SMK (Denmark) Art API** — also one-hop (`image_native` ready in the search result, no chain), broad European painting/decorative holdings. Caveat: the `filters=` param MUST be repeated (one bracket each), not concatenated into one string, or the AND silently fails.++Honorable mention: if the ask is specifically Dutch/Flemish masters or decorative arts, Rijksmuseum is worth the extra 2 hops. If it's European antiquities/photography and a keyword isn't essential, Getty's SPARQL trick returns an image URL in one query.++## Attribution / licensing notes++- **True CC0 (no legal attribution required, safe to treat as public domain outright):** Met, Cleveland, Art Institute of Chicago, NGA (dataset-level; images gated by per-image `openaccess` flag), Smithsonian.+- **"Public Domain Mark" / open-access-but-not-technically-CC0 (functionally free to use, museum requests but does not require a credit line):** Rijksmuseum (mixed — some items are CC BY and DO require attribution, always check the object's own rights block), SMK (Public Domain Mark 1.0 — functionally equivalent to CC0 for reuse, credit "SMK" requested).+- **Mixed/needs per-image verification — do not blanket-trust the collection-level CC0 claim:** Getty (dataset is CC0 but per-image `VisualItem.subject_to` rights block is inconsistently populated on older records — cross-check the object's public page, which flags true Open Content items with a "Download" button, before using an image commercially), NGA (per-image `openaccess=0` rows are NOT open — resolution-capped and rights-restricted), Smithsonian (record-level `metadata_usage.access` and per-media `media.usage.access` can theoretically diverge — check the media-level flag, not just the record flag).+- **Good practice everywhere even when not legally required:** a short credit line ("Digital image courtesy of [Museum]") costs nothing and avoids ambiguity, especially for mixed-license collections (Rijksmuseum, Getty) where a CC BY item could slip through a broad query.+- **Practical rule for the agent:** when a museum's API exposes a rights/license field, filter AND spot-check it per image before shipping — never assume "the collection is open access" implies "this specific image is." The 3 collections where this bites hardest are Getty, Rijksmuseum, and NGA/Smithsonian's per-image flags.++## Gaps — major keyless/near-keyless PD art sources the 8 museums miss++None of the 8 notes covered these; an agent building a general-purpose "find me a public-domain artwork" tool should know about them:++- **Wikimedia Commons API** — `https://commons.wikimedia.org/w/api.php?action=query&generator=search&gsrsearch=<term>&gsrnamespace=6&prop=imageinfo&iiprop=url|extmetadata` (fully keyless). Aggregates PD/CC-licensed images from dozens of museums already normalized into one schema; `extmetadata.LicenseShortName` gives the license per file. Best single fallback when a specific museum's own API comes up empty — search `Category:Paintings_by_...` or a direct `File:` page via `Special:FilePath/{filename}` for the raw image bytes.+- **Europeana API** — `https://api.europeana.eu/record/v2/search.json?wskey=<KEY>&query=<term>` — aggregates 50M+ items from thousands of European cultural institutions in one schema; **requires a free API key** (instant self-serve signup, not fully keyless like the others).+- **Harvard Art Museums API** — `https://api.harvardartmuseums.org/object?apikey=<KEY>&q=<term>` — **requires a free key** (instant signup). Strong for teaching-collection-style Western art and object photography.+- **Yale (LUX / Yale Center for British Art)** — `https://lux.collections.yale.edu/api/search/...` (Linked Art model, similar shape to Getty's) — keyless, aggregates Yale University Art Gallery + Yale Center for British Art + Beinecke; strong British art and rare books.+- **Paris Musées (Paris city museums collections)** — open-data portal at `https://www.parismuseescollections.paris.fr/en/collections` with a CC0 bulk dataset also mirrored on Paris's open-data platform (`opendata.paris.fr`) — keyless, French painting/decorative arts, explicit CC0.+- **NYPL Digital Collections API** — `https://api.repository.library.nyc/...` — **requires a free key** (instant signup via `api.repository.library.nyc/register`). Huge trove of digitized public-domain prints, maps, photographs, illustrations (not "museum paintings" but excellent for editorial/essay figures).+- **Wellcome Collection API** — `https://api.wellcomecollection.org/catalogue/v2/works?query=<term>` — keyless, no key needed. CC0/PD medical, historical, and scientific imagery — a good niche source for essay figures on health/science topics that the 8 art museums won't have.+- **Internet Archive** — `https://archive.org/advancedsearch.php?q=<term>&fl[]=identifier&output=json` — keyless. Not a museum but a deep well of PD book illustrations, historical photographs, and scanned ephemera; useful when the need is "old illustration/engraving" rather than "fine-art painting."+- **DPLA (Digital Public Library of America)** — `https://api.dp.la/v2/items?q=<term>&api_key=<KEY>` — **requires a free key**. Aggregates US libraries/archives/museums (including several of the 8 above) into one federated search — useful as a cross-collection fallback once a key is obtained.++**Practical recommendation for the agent:** try Met → Cleveland → SMK first (keyless, one-hop). If nothing fits the brief, fall back to Wikimedia Commons (keyless aggregator across everything). If the visual need is more "historical illustration/engraving" than "museum painting," go straight to Internet Archive or Wikimedia Commons instead of the fine-art APIs.diff --git a/skills/museum-art/references/artic.md b/skills/museum-art/references/artic.mdnew file mode 100644index 0000000..0cf6dd7--- /dev/null+++ b/skills/museum-art/references/artic.md@@ -0,0 +1,77 @@+# Art Institute of Chicago — Open-Access Image API Recipe++Verified: 2026-07-24++## Base URL+`https://api.artic.edu/api/v1`++Official docs: https://api.artic.edu/docs/ (confirmed live and current).++## API Key+**None required.** Fully open, anonymous access.+- Rate limit: 60 requests/minute per IP (throttled if exceeded, no auth error).+- Docs explicitly ask scrapers to self-throttle to ~1 req/sec and avoid parallel hammering — courtesy limit, not enforced by a key.++## Image License+**CC0 1.0 (Creative Commons Zero)** for artwork data and images flagged `is_public_domain: true`.+- Confirmed via live API response `info.license_text`:+ > "All other data in this response is licensed under a Creative Commons Zero (CC0) 1.0 designation and the Terms and Conditions of artic.edu."+ (The `description` field specifically is CC-BY 4.0 — everything else, including the image, is CC0.)+- Suggested (not legally required for CC0, but good practice) attribution: "Digital image courtesy of the Art Institute of Chicago."++## Search Recipe++### Step 1 — Search for public-domain artworks that have an image+```+GET https://api.artic.edu/api/v1/artworks/search?query[term][is_public_domain]=true&fields=id,title,image_id,artist_display&limit=20+```+- `query[term][is_public_domain]=true` filters to CC0/public-domain works.+- `fields=...,image_id` is required — without explicitly requesting `image_id` it won't be in the payload.+- Note: `is_public_domain=true` does not strictly guarantee `image_id` is non-null for every record (a few PD works lack digitized images) — check `image_id` is present/non-empty in each result before building an image URL. Safer alternative used by many integrations: also filter `query[exists][field]=image_id` or just skip results where `image_id` is null/empty.++### Step 2 — Build the full-resolution image URL from a result's `image_id`+```+https://www.artic.edu/iiif/2/{image_id}/full/843,/0/default.jpg+```+- `843,` = width 843px, height auto — this is the museum's own site default and the most-likely-cached size.+- For actual full/max resolution, replace the size segment with `full` (i.e. `.../full/full/0/default.jpg`) — larger, uncached, slower.+- The IIIF base (`https://www.artic.edu/iiif/2`) is also returned dynamically in every API response under `config.iiif_url` — prefer reading it from there over hardcoding, in case they ever move image hosting.++## Example URLs (real, from live query)++**exampleApiUrl** (search):+```+https://api.artic.edu/api/v1/artworks/search?query[term][is_public_domain]=true&fields=id,title,image_id,artist_display&limit=3+```+Verified response (2026-07-24) included, among others:+- id 28560, "The Bedroom", Vincent van Gogh, image_id `6644829f-f292-c5c4-a73c-0356a6fdbf0d`+- id 21023, "Buddha Shakyamuni Seated in Meditation (Dhyanamudra)", image_id `0675f9a9-1a7b-c90a-3bb6-7f7be2afb678`+- id 20684, "Paris Street; Rainy Day", Gustave Caillebotte, image_id `f8fd76e9-c396-5678-36ed-6a348c904d27`+- Total public-domain-with-fields matches in collection: 61,568 (paginated, 20,523 pages at limit=3)+- `config.iiif_url` in response: `https://www.artic.edu/iiif/2`++**exampleImageUrl** (from van Gogh's "The Bedroom", id 28560):+```+https://www.artic.edu/iiif/2/6644829f-f292-c5c4-a73c-0356a6fdbf0d/full/843,/0/default.jpg+```++Also confirmed the single-artwork endpoint works:+```+GET https://api.artic.edu/api/v1/artworks/28560?fields=id,title,image_id+```+→ returned `{"data":{"id":28560,"title":"The Bedroom","image_id":"6644829f-f292-c5c4-a73c-0356a6fdbf0d"}, "info":{"license_text":"...CC0 1.0..."}}`++## Verification Notes++- **JSON API: verified working.** Both the search endpoint and the single-artwork endpoint were fetched live and returned real, current data (61,568 public-domain artworks, correct image_id, correct CC0 license text in `info`).+- **IIIF image URL: correct per official docs, but NOT independently confirmed as a working binary download by this research pass.** Direct `curl`/WebFetch requests to `www.artic.edu/iiif/2/.../default.jpg` were blocked with `HTTP 403` + `cf-mitigated: challenge` — this is Cloudflare's bot-management challenge on the `artic.edu` web/image domain, triggered regardless of User-Agent (tried default curl UA, desktop Chrome UA, iPhone Safari UA, and no UA — all 403'd identically, which points to TLS/JA3 fingerprinting rather than header-based blocking). This is a known behavior of Cloudflare-protected static asset domains and does not indicate the URL pattern itself is wrong — it is the officially documented pattern, and it is what the museum's own website uses to render images in a real browser.+ - I attempted to verify via a real headed browser (browser-harness/CDP) to bypass the bot check, but that tool requires one-time manual "Allow remote debugging" approval in the user's Chrome, which wasn't available in this pass.+ - **Practical implication for whoever builds against this recipe:** plain `curl`/`requests`/serverless-function fetches of the IIIF image may hit the same Cloudflare challenge. A real browser, a headless browser with a full JS-capable engine, or a fetch routed through something that passes Cloudflare's bot checks (residential proxy, or a client with a legitimate browser TLS fingerprint) is likely needed for automated bulk image downloading. The JSON metadata API (`api.artic.edu`) has no such protection and worked cleanly every time.++## Gotchas Summary+- No API key, but self-throttle to ~1 req/sec for bulk work; hard limit 60 req/min anonymous.+- Must explicitly request `image_id` via `fields=` — not returned by default.+- Not all `is_public_domain:true` records have a non-null `image_id`; check before building the URL.+- IIIF size param: `843,` = site-default/cached; `full` = max resolution but uncached/slower; can also request specific `{width},{height}` or `{width},` / `,{height}`.+- `www.artic.edu` (the IIIF image host) sits behind Cloudflare bot management — scripted/curl-style requests to the image URLs get a 403 challenge page even though the URL pattern is correct and it works in normal browser use. Budget for this if building an automated downloader.+- Attribution "Digital image courtesy of the Art Institute of Chicago" is good practice even though CC0 doesn't legally require it.diff --git a/skills/museum-art/references/cleveland.md b/skills/museum-art/references/cleveland.mdnew file mode 100644index 0000000..7cf3b9c--- /dev/null+++ b/skills/museum-art/references/cleveland.md@@ -0,0 +1,105 @@+# Cleveland Museum of Art — Open Access Image Recipe (VERIFIED)++## TL;DR+- **Base URL:** `https://openaccess-api.clevelandart.org/api/artworks/`+- **Key required:** No — fully open, no key/token.+- **License:** CC0 (public domain), designated by CMA. No attribution required for CC0 works.+- **Verified 2026-07-24:** live API call returned real JSON with CC0 records; the returned image URL resolves to a real JPEG (396.3KB, confirmed via fetch).++## API Basics+- Docs: https://openaccess-api.clevelandart.org/ (interactive docs, last updated 2025-07-11)+- GitHub mirror (full dataset dump, JSON/CSV, updated weekly): https://github.com/ClevelandMuseumArt/openaccess+- Program overview / license page: https://www.clevelandart.org/open-access+- Endpoints:+ - `GET /api/artworks/` — search/list artworks+ - `GET /api/artworks/{id}` — single artwork+ - `GET /api/creators/`, `/api/creators/{id}`+ - `GET /api/exhibitions/`, `/api/exhibitions/{id}`++## Key Query Params (for CC0 + image)+| Param | Meaning |+|---|---|+| `cc0=1` | only works licensed CC0 (public domain, no restrictions) |+| `has_image=1` | only artworks that have a web image asset |+| `q=<term>` | free-text search |+| `limit=<n>` | page size |+| `skip=<n>` | pagination offset |+| `copyrighted` (opposite of cc0) | filters copyrighted works instead — do NOT use if you want open images |++Response field `share_license_status` will read `"CC0"`, `"Copyrighted"`, or `"Other"` — filter/inspect this if double-checking after the fact.++## Image URL Fields+Each artwork's `images` object contains up to 3 renditions, each with `url`, `filename`, `filesize`, `width`, `height`:+- `images.web` — JPEG, 900px longest side, 300dpi (good default "full-res-enough" download)+- `images.print` — JPEG, 3400px longest side, 300dpi (high-res)+- `images.full` — TIFF, variable dimensions/dpi (archival max-res)++`alternate_images` may hold extra views in the same 3 renditions.++Image CDN host: `https://openaccess-cdn.clevelandart.org/...` — direct hotlinkable JPEG/TIFF, no auth.++## Step-by-Step Recipe++**(a) Search for public-domain artworks with images:**+```+GET https://openaccess-api.clevelandart.org/api/artworks/?cc0=1&has_image=1&limit=10+```+Optional: add `&q=monet` (or any term) to narrow by keyword; add `&skip=10` to paginate.++**(b) Get a full-res image URL from a result:**+From each returned artwork object, read:+```+result.images.print.url # high-res JPEG (3400px)+result.images.full.url # archival TIFF (max res), if present+result.images.web.url # 900px JPEG, smaller/fast+```+No further auth or signing needed — the URL is directly downloadable.++## Concrete Verified Example+**exampleApiUrl** (fetched live, returned real data):+```+https://openaccess-api.clevelandart.org/api/artworks/?cc0=1&has_image=1&limit=3+```+Sample of what it returned:+```json+[+ {+ "id": 94979,+ "title": "Nathaniel Hurd",+ "share_license_status": "CC0",+ "images.web.url": "https://openaccess-cdn.clevelandart.org/1915.534/1915.534_web.jpg"+ },+ {+ "id": 92937,+ "title": "Stag at Sharkey's",+ "share_license_status": "CC0",+ "images.web.url": "https://openaccess-cdn.clevelandart.org/1922.1133/1922.1133_web.jpg"+ }+]+```++**exampleImageUrl** (verified resolves to a real JPEG, 396.3KB, image/jpeg):+```+https://openaccess-cdn.clevelandart.org/1915.534/1915.534_web.jpg+```+(This is the "web" 900px rendition for accession 1915.534, "Nathaniel Hurd," CC0. Swap `_web` for `_print` in the same path pattern for the 3400px rendition where available — but always trust the JSON's `images.print.url` field over guessing the filename pattern, since not every record has a print/full tier.)++## License & Attribution+- CMA designates open-access content as **CC0** — no copyright, no restriction, no attribution required.+- Non-CC0 records exist in the same API (`share_license_status: "Copyrighted"` or `"Other"`) — always filter with `cc0=1` (or check the field) before treating an image as free-use.+- CMA suggests (optional, not required for CC0) citing: Artist, Title, Date, Medium, Dimensions, Institution, Credit Line, Accession Number, URL.++## Gotchas+- **No rate limit documented** — be a good citizen anyway (add delays for bulk scraping); no official published number.+- **Not every record has all 3 image tiers.** Always read the actual `images.*.url` fields from the JSON rather than assuming a naming convention holds for every accession — some records only have `web`, not `print`/`full`.+- **No IIIF image API** — CMA does NOT expose IIIF (no `/iiif/.../full/full/0/default.jpg` sizing syntax). Sizing is fixed to the 3 pre-rendered tiers (web/print/full), not parametric.+- **`cc0` vs `copyrighted` params are opposite filters** — don't confuse them; use `cc0=1` for open images.+- **Full dataset dump available on GitHub** (`ClevelandMuseumArt/openaccess`, JSON/CSV, updated weekly) if you want to avoid live API pagination for bulk work.+- Image CDN (`openaccess-cdn.clevelandart.org`) is a separate host from the API host (`openaccess-api.clevelandart.org`) — don't assume same-origin for CORS purposes if building a browser app.++## Sources+- https://openaccess-api.clevelandart.org/ (API docs)+- https://www.clevelandart.org/open-access (license/program page)+- https://github.com/ClevelandMuseumArt/openaccess (dataset mirror)+- Live verification: `GET https://openaccess-api.clevelandart.org/api/artworks/?cc0=1&has_image=1&limit=3` fetched 2026-07-24, returned real JSON.+- Live verification: `https://openaccess-cdn.clevelandart.org/1915.534/1915.534_web.jpg` fetched 2026-07-24, confirmed real JPEG (image/jpeg, 396.3KB).diff --git a/skills/museum-art/references/getty.md b/skills/museum-art/references/getty.mdnew file mode 100644index 0000000..3f14dc3--- /dev/null+++ b/skills/museum-art/references/getty.md@@ -0,0 +1,110 @@+# The Getty — Open-Access Image Recipe (VERIFIED)++## TL;DR+- **Base URL (Linked Art / JSON-LD API):** `https://data.getty.edu/museum/collection/`+- **API key:** NOT required. All endpoints below returned `HTTP 200` with a plain unauthenticated `curl`.+- **License:** Dataset/collection metadata is **CC0 1.0** (confirmed live in every record's `subject_to` "License for Collection Metadata" block, and in the official docs text). Images come from the **Getty Open Content Program** — most are CC0/public domain, but **not all**; each image reference should be checked (see Gotchas).+- **Images:** served via **IIIF Image API** at `https://media.getty.edu/iiif/image/<image-id>/...` — full resolution, no key, `Access-Control-Allow-Origin: *`.+- **Search:** there is **no keyword/full-text REST search endpoint** (the docs explicitly say so — see Gotchas). Discovery is via the public **SPARQL endpoint** `https://data.getty.edu/museum/collection/sparql`, which I ran live and got real results back.++---++## 1. What the API actually is+Official docs: https://data.getty.edu/museum/collection/docs/ (a Nuxt SPA; scraped its raw payload to get the real text since WebFetch truncates it — Bash `curl` worked fine).++- Model: **Linked.Art** (a CIDOC-CRM profile) + **JSON-LD**.+- Entity types: `object`, `place`, `document`, `group`, `person`, `exhibition`, `activity`.+- Record URL pattern: `https://data.getty.edu/museum/collection/<ENTITY_TYPE>/<ENTITY_ID>` — returns JSON-LD directly, no `Accept` header needed.+- Change tracking: ActivityStreams feed at `https://data.getty.edu/museum/collection/activity-stream`.+- Graph queries: public **SPARQL** endpoint + a browser UI at `https://data.getty.edu/museum/collection/sparql-ui`.+- Images: Getty-wide **IIIF** API at `https://media.getty.edu` (Image API 2.1.1 + Presentation API 2.1.1/3).++Docs quote (verbatim, from the rendered page): *"With some exceptions, the data available from this API is made available under [CC0]. Check the Usage Guidelines section... for more details."* and *"We currently don't provide a way to get a list of all of the objects or other entity types in the dataset... We also don't provide a way to download all the data in the dataset."* — i.e. **no bulk list, no keyword search REST endpoint**, by design, confirmed straight from their own docs.++## 2. Key requirement+None. Every call in this recipe (`object` record fetch, SPARQL query, IIIF image fetch) succeeded with plain unauthenticated HTTP GET. No signup, no token, no rate-limit header observed.++## 3. License — precisely+- **Dataset/metadata:** CC0 1.0 Universal, unconditionally, per Getty's own statement and confirmed live in every object record I pulled (`subject_to` → `Right` → `classified_as` → `http://creativecommons.org/publicdomain/zero/1.0/`, display name `"Public Domain"`, description `"No Copyright"`).+- **Images (Exception #1 in the docs):** *"Many of the linked images are part of Getty's Open Content program and can also be used without permission under CC0 — but not all of the images are."* The docs say each image reference should carry its own rights block (`VisualItem` → `subject_to` → `classified_as` with the CC0 URI, or something else if restricted). In practice, on the two live records I sampled, that per-image rights sub-block was not populated (older TMS-migrated records) — so **don't assume every image is CC0 purely from the API response**; cross-check on the object's public page at `getty.edu` (Open Content items show a "Download" button) if you need certainty for a specific artwork, or prefer objects you already know are Open Content (e.g. van Gogh's *Irises*, used below).+- **Written descriptions/biographies (Exception #2):** mixed — some CC BY 4.0, some third-party copyright. Same per-block check pattern (`referred_to_by[].subject_to[].classified_as[].id`).+- Attribution is **not required** but requested/appreciated (no fixed credit-line string was given beyond "provided by the J. Paul Getty Museum").+- Official program description (from `getty.edu/projects/open-content-program`, verified fetch): *"Initiative granting free access to images of public domain artworks in Getty's collections."*++## 4. Search recipe (concrete, step-by-step)++There is no `?q=keyword` REST search. Use the SPARQL endpoint to discover objects that have an image, then pull each object's full record for metadata + rights + all image links.++**Step A — find N objects that have a representation image (SPARQL, GET, JSON by default):**++```+GET https://data.getty.edu/museum/collection/sparql?query=<url-encoded SPARQL>+```++SPARQL body used (real, tested):+```sparql+PREFIX crm: <http://www.cidoc-crm.org/cidoc-crm/>+SELECT ?obj ?label ?img WHERE {+ ?obj a crm:E22_Human-Made_Object .+ ?obj rdfs:label ?label .+ ?obj crm:P138i_has_representation ?img .+} LIMIT 5+```+This returns the object's URI, its label, and a ready-to-use IIIF image URL — no follow-up call needed for a quick image grab.++**Step B — get the full record (metadata + rights + every image/IIIF manifest link) for one object:**+```+GET https://data.getty.edu/museum/collection/object/<uuid-from-step-A>+```+Look in the JSON for:+- `representation[].id` → direct JPEG (deprecated field, still live, smaller res)+- `subject_of[]` where `_label` = "IIIF Manifest URL" → full IIIF Presentation manifest (has every canvas/image + real per-canvas dims)+- `subject_to[]` → the rights/license block (check `classified_as[].id` for the CC0 URI)++**Step C — full-resolution image URL (IIIF Image API), from any `image-id` you have:**+```+https://media.getty.edu/iiif/image/<image-id>/full/full/0/default.jpg # full native resolution+https://media.getty.edu/iiif/image/<image-id>/full/!600,/0/default.jpg # thumbnail, max 600px, aspect preserved+https://media.getty.edu/iiif/image/<image-id>/<x,y,w,h>/<w,h>/0/default.jpg # cropped region (used on Getty's own site)+```++**Step D — filter for CC0/public domain with confidence:** either (a) rely on the per-image `subject_to`/`classified_as` block when populated, or (b) pick artworks you can confirm are in the Open Content Program via the human-facing collection page (`getty.edu/art/collection/object/...`), which flags Open Content items with a visible "Download" affordance.++## 5. Verified example URLs++**exampleApiUrl** (SPARQL — real results, confirmed via curl, HTTP 200, default response is already `application/sparql-results+json` even with no Accept header):+```+https://data.getty.edu/museum/collection/sparql?query=PREFIX%20crm%3A%20%3Chttp%3A//www.cidoc-crm.org/cidoc-crm/%3E%0ASELECT%20%3Fobj%20%3Flabel%20%3Fimg%20WHERE%20%7B%0A%20%20%3Fobj%20a%20crm%3AE22_Human-Made_Object%20.%0A%20%20%3Fobj%20rdfs%3Alabel%20%3Flabel%20.%0A%20%20%3Fobj%20crm%3AP138i_has_representation%20%3Fimg%20.%0A%7D%20LIMIT%205+```+Live sample of what it returns (first row):+```json+{"obj":"https://data.getty.edu/museum/collection/object/84eb7a1d-f806-4da9-a0ed-77d6b355df7e",+ "label":"West Front, Looking North (84.XB.950.7.28)",+ "img":"https://media.getty.edu/iiif/image/f45355f5-8ae6-4813-bf7a-dc94997f76f0/full/full/0/default.jpg"}+```++Also a plain record fetch, no query params, well-known Open Content artwork (van Gogh's *Irises*, 90.PA.20):+```+https://data.getty.edu/museum/collection/object/c88b3df0-de91-4f5b-a9ef-7b2b9a6d8abb+```++**exampleImageUrl** (full resolution — verified with `curl -I`: `HTTP/2 200`, `content-type: image/jpeg`, `content-disposition: inline; filename="8c255d80-7382-46db-9fa8-892c0d37247e_9021x7122.jpg"`, `access-control-allow-origin: *`):+```+https://media.getty.edu/iiif/image/8c255d80-7382-46db-9fa8-892c0d37247e/full/full/0/default.jpg+```+(This is the Irises main image, 9021×7122px native.)++## 6. Gotchas+- **No full-text/faceted search REST endpoint, no bulk listing/dump.** Explicitly stated as a current limitation in Getty's own docs ("it's on our roadmap"). SPARQL is the only queryable discovery mechanism from the API itself; the human search UI at `getty.edu/art/collection/search/` is the practical alternative for browsing by keyword and then feeding object IDs back into the JSON API.+- **Per-image rights blocks are inconsistently populated.** The docs describe a `VisualItem.subject_to.classified_as` CC0 marker per image, but live sampled records didn't always carry it — don't blanket-assume every image is CC0 just because the record fetch succeeded; verify against the public object page or stick to artworks you know are Open Content.+- **The `representation` field is marked deprecated** in favor of the `shows` → IIIF Manifest route for full-size images going forward (Getty's own deprecation note: future `representation` images "will be smaller than that currently offered"). The `full/full/0/default.jpg` IIIF Image API URL is the durable way to get max resolution regardless.+- **IIIF sizing syntax:** `/full/full/...` = native size; `/full/!W,/...` = fit within width W preserving aspect (the `!` matters); `/full/W,/...` = force width W; region can be `x,y,w,h` pixels instead of `full` to crop.+- **The `docs/` page is a client-rendered SPA** — plain `WebFetch`/simple scrapers get truncated boilerplate; had to pull the Nuxt `_payload.json` directly to get the real doc text. If automating doc reads again, target that payload endpoint, not the rendered HTML.+- **No observed rate limiting** in this session, but Getty gives no published quota — be a reasonable citizen (this is a small non-profit-run API, not a commercial CDN).+- Attribution not contractually required (CC0) but Getty explicitly asks to be told how you used the data (`[email protected]`) and offers a courtesy credit line: "J. Paul Getty Museum".++## Sources+- https://data.getty.edu/museum/collection/docs/ (API docs, scraped via curl on `_payload.json`)+- https://www.getty.edu/projects/open-content-program/ (Open Content Program description)+- https://www.getty.edu/projects/open-data-apis/ (open data/APIs overview)+- Live verified endpoints: `data.getty.edu/museum/collection/object/*`, `data.getty.edu/museum/collection/sparql`, `media.getty.edu/iiif/image/*`diff --git a/skills/museum-art/references/met.md b/skills/museum-art/references/met.mdnew file mode 100644index 0000000..4c682cb--- /dev/null+++ b/skills/museum-art/references/met.md@@ -0,0 +1,87 @@+# The Metropolitan Museum of Art — Open Access Image Recipe++Status: **VERIFIED** (both the search endpoint and the resulting image URL were fetched live and returned real data / HTTP 200).++## Base URL+`https://collectionapi.metmuseum.org/public/collection/v1/`++Docs: https://metmuseum.github.io/ (official, GitHub Pages)+Initiative overview: https://www.metmuseum.org/hubs/open-access+Repo: https://github.com/metmuseum/openaccess++## API key+**None required.** The docs state explicitly: "At this time, we do not require API users to register or obtain an API key to use the service."+Rate limit: **80 requests/second** (documented; be polite and add a small delay/backoff for bulk jobs anyway). Contact for questions: `[email protected]`.++## License+**CC0 (Creative Commons Zero)** for objects flagged `isPublicDomain: true` — The Met has waived all copyright and related/neighboring rights on this subset of the dataset (both the metadata and the associated images). No attribution is legally required, though crediting "The Metropolitan Museum of Art" is good practice / house style.++Caveat: not every object in the collection is CC0 — only ones where `isPublicDomain` is `true`. Objects where it's `false` still have metadata returned by the API but the image (if any) is NOT open-licensed for reuse — always check the flag per-object, don't assume every API result is free to use.++## Endpoints used in this recipe++| Endpoint | Purpose |+|---|---|+| `GET /search?...` | Search for object IDs matching filters (query term, `hasImages`, `isPublicDomain`, department, date range, etc.) |+| `GET /objects/{objectID}` | Full record for one object: title, artist, `isPublicDomain`, `primaryImage`, `primaryImageSmall`, rights fields |+| `GET /departments` | List of department IDs/names, for scoping search |++Confirmed search params (from live docs): `q`, `isHighlight`, `title`, `tags`, `departmentId`, `isOnView`, `artistOrCulture`, `medium`, `hasImages`, `geoLocation`, `dateBegin` + `dateEnd` (must be given together). **`isPublicDomain` is also a live, working param** even though it isn't prominently listed in every doc rendering — confirmed by direct test below.++## Step-by-step recipe++1. **Search** for public-domain artworks with images:+ ```+ GET https://collectionapi.metmuseum.org/public/collection/v1/search?q=<term>&hasImages=true&isPublicDomain=true+ ```+ Response: `{"total": N, "objectIDs": [id1, id2, ...]}`. If `objectIDs` is null, no matches — try a broader `q` or drop a filter.++2. **Fetch one object's full record:**+ ```+ GET https://collectionapi.metmuseum.org/public/collection/v1/objects/{objectID}+ ```+ Check `isPublicDomain === true` before reuse (belt-and-suspenders even though the search already filtered on it — the object may have been re-flagged since indexing).++3. **Grab the image URL directly from the object JSON** — no extra IIIF/image-service call needed:+ - `primaryImage` — full original resolution JPEG (can be very large, several MB, up to ~8MB+ observed).+ - `primaryImageSmall` — "web-large" size, smaller JPEG, good default for web use.+ - `additionalImages` — array of extra full-res image URLs if the object has more than one photographed view.++ No IIIF Image API / sizing-parameter syntax is involved — Met just serves static JPEGs at fixed pre-rendered sizes (`original`, `web-large` in the URL path), not a dynamic IIIF resizer.++## Example URLs (live-tested)++**Search:**+```+https://collectionapi.metmuseum.org/public/collection/v1/search?q=sunflowers&hasImages=true&isPublicDomain=true+```+Verified live: returned `"total": 40` and a real `objectIDs` array (e.g. 544320, 310453, 200668, 437261, 824771, 36225, ... 436535 among later results is a different van Gogh but 436535 below was pulled independently for the full example).++**Object record:**+```+https://collectionapi.metmuseum.org/public/collection/v1/objects/436535+```+Verified live via curl — returns real JSON:+- `objectID`: 436535+- `title`: "Wheat Field with Cypresses"+- `artistDisplayName`: Vincent van Gogh+- `department`: European Paintings+- `isPublicDomain`: `true`+- `primaryImage`: `https://images.metmuseum.org/CRDImages/ep/original/DP-42549-001.jpg`+- `primaryImageSmall`: `https://images.metmuseum.org/CRDImages/ep/web-large/DP-42549-001.jpg`++**Full-res image URL (verified):**+```+https://images.metmuseum.org/CRDImages/ep/original/DP-42549-001.jpg+```+`curl -sI` on this URL returned `HTTP/2 200`, `content-type: image/jpeg`, `content-length: 8291194` (~8.3MB) — confirmed real, downloadable, full-resolution JPEG.++## Gotchas++- **Rate limit 80 req/sec** per the docs — fine for interactive/scripted use, but throttle bulk crawls (e.g. iterate all `/objects`) to be a good citizen; the server is fronted by Imperva/Incapsula (visible in response headers) which may rate-limit/challenge aggressive traffic beyond the documented cap.+- **No CORS problem** — `access-control-allow-origin: *` is set on the image CDN (`images.metmuseum.org`), so these URLs are directly usable from browser JS (e.g. `<img>` tags, canvas/fetch) without a proxy.+- **`objects` bulk listing endpoint** (`/objects?metadataDate=...&departmentIds=...`) returns *all* object IDs for the filter, not just public-domain/has-image ones — you still need to check `isPublicDomain` + `primaryImage` (non-empty) per object, or better, use `/search?hasImages=true&isPublicDomain=true` up front to pre-filter.+- **`primaryImage` can be empty string** even for public-domain objects that haven't been photographed — always check `primaryImage !== ""` (or non-null) before using.+- **No IIIF sizing params** — unlike some museum APIs (e.g. Smithsonian, some Europeana sources), the Met does not expose a dynamic image resize API. You get exactly two fixed sizes baked into the URL (`original`, `web-large`) plus optional `additionalImages`. If you need a specific pixel size, resize client-side after download.+- **Attribution not legally required (CC0)** but recommended: "Image courtesy of The Metropolitan Museum of Art" / link back to the object's page (`https://www.metmuseum.org/art/collection/search/{objectID}`).+- **`rightsAndReproduction` field is often blank** even on legitimate public-domain records — don't treat an empty rights field as a red flag; `isPublicDomain: true` is the authoritative signal.diff --git a/skills/museum-art/references/nga.md b/skills/museum-art/references/nga.mdnew file mode 100644index 0000000..37e2ebe--- /dev/null+++ b/skills/museum-art/references/nga.md@@ -0,0 +1,90 @@+# National Gallery of Art (Washington) — Open Access Image Recipe++Status: VERIFIED (live IIIF fetch succeeded, real image bytes returned).++## Base URL(s)++- **Data/metadata**: CSV dumps in the GitHub repo `github.com/NationalGalleryOfArt/opendata` (data lives under `/data/*.csv`, fetch raw via `raw.githubusercontent.com/NationalGalleryOfArt/opendata/main/data/<file>.csv`). No search API — this is a bulk CSV export, updated frequently (daily per the repo docs).+- **Image server (IIIF Image API 2.0, level1)**: `https://api.nga.gov/iiif/{uuid}/{region}/{size}/{rotation}/{quality}.{format}`+ - `info.json` at `https://api.nga.gov/iiif/{uuid}/info.json` confirms native width/height and supported sizes/qualities.++There is no public REST/search API beyond the CSV files + IIIF image server — no `api.nga.gov` object-search endpoint documented. Treat this as "CSV catalog + IIIF images," not a queryable API.++## Key requirement++**None.** No API key, no auth, no rate-limit header observed. CSVs are public GitHub raw files; the IIIF image server responds with `access-control-allow-origin: *` and no auth challenge.++## License++**CC0-1.0** (Creative Commons Zero / public domain dedication) for the dataset itself — repo `LICENSE` + README state NGA "waives any copyright or related rights that it might have in this dataset." Attribution is *requested* (not required) for research use citing "National Gallery of Art Open Data Program."++Per-image rights are **not uniformly CC0** — see gotcha below on the `openaccess` flag. Only rows where `published_images.openaccess = 1` are the institution's actual open-access (full-resolution, reuse-cleared) images; `openaccess = 0` rows are still shown via IIIF but resolution-capped (see `maxpixels`), meaning rights-restricted/third-party-copyright works.++## Relevant CSV files (from `data/` dir)++- `objects.csv` — one row per artwork: `objectid, uuid, title, attribution (artist), displaydate, medium, dimensions, classification, creditline, departmentabbr, wikidataid, ...`. No explicit "is public domain" column at the object level.+- `published_images.csv` — one row per digitized image: `uuid, iiifurl, iiifthumburl, viewtype, sequence, width, height, maxpixels, openaccess, depictstmsobjectid, assistivetext`. This is the file that actually gates open access:+ - `iiifurl` = the IIIF base identifier URL (append IIIF path params to get an image).+ - `iiifthumburl` = pre-built 200×200 thumbnail convenience URL.+ - `openaccess` = `1` → full resolution downloadable via IIIF `full/full` or `full/max`; `0` → IIIF still serves an image but the server enforces a `maxpixels` ceiling (e.g. 900px on the long edge) — these are NOT open access.+ - `depictstmsobjectid` = join key back to `objects.csv.objectid` for title/artist metadata.+ - `assistivetext` = an auto-generated alt-text description of the image (handy bonus field).++## Search recipe++### (a) Find public-domain artworks that have an image++No live search API — do it against the CSVs (download or stream them):++1. Fetch `https://raw.githubusercontent.com/NationalGalleryOfArt/opendata/main/data/published_images.csv`.+2. Filter rows where `openaccess == "1"` (string "1") AND `viewtype == "primary"` (primary image, not alternate crops/details) → these are full-res, reuse-cleared images.+3. Take the `depictstmsobjectid` from each surviving row and join against `objects.csv.objectid` to pull `title`, `attribution` (artist), `displaydate`, `medium`, `classification`.+4. `uuid` (or equivalently `iiifurl`'s trailing path segment) is the identifier to build image-request URLs.++No pagination/rate-limit concerns since it's a flat file — just stream/filter client-side (Python `csv`/`pandas`, or `curl` + `awk`/`grep` for quick checks). Both CSVs are large (130k+ objects, more image rows); use streaming reads, not full in-memory loads if resource-constrained.++### (b) Get a full-resolution downloadable image URL from a result++Given a `uuid` (e.g. from `published_images.csv`, row with `openaccess=1`):++```+GET https://api.nga.gov/iiif/{uuid}/full/full/0/default.jpg+```+or equivalently+```+GET https://api.nga.gov/iiif/{uuid}/full/max/0/default.jpg+```+Both returned the object's native full resolution in testing (3365×4332 px, 2.57 MB JPEG for the example below). Use `info.json` first if you want to confirm native dimensions or pick a specific IIIF `size` token (e.g. `!1600,1600` to cap the long edge) instead of `full`.++## Example URLs (live-tested 2026-07-24)++- **exampleApiUrl** (metadata, first bytes of the open-access image catalog):+ `https://raw.githubusercontent.com/NationalGalleryOfArt/opendata/main/data/published_images.csv`+ First data row: `uuid=00007f61-4922-417b-8f27-893ea328206c, iiifurl=https://api.nga.gov/iiif/00007f61-4922-417b-8f27-893ea328206c, openaccess=1, depictstmsobjectid=17387` (join to `objects.csv` objectid 17387 for title/artist).++- **info.json check**:+ `https://api.nga.gov/iiif/00007f61-4922-417b-8f27-893ea328206c/info.json` → returned valid IIIF Image API 2.0 descriptor, native size 3365×4332, level1 profile, jpg format, supports `sizeAboveFull`.++- **exampleImageUrl** (full-resolution, downloadable):+ `https://api.nga.gov/iiif/00007f61-4922-417b-8f27-893ea328206c/full/full/0/default.jpg`+ → `HTTP/2 200`, `content-type: image/jpeg`, `content-length: 2569142` (2.57 MB), served via Cloudflare + IIPImage, `access-control-allow-origin: *`.++## Verification performed++- Fetched `published_images.csv` raw (byte-range) — confirmed real header + rows, confirmed `openaccess`/`maxpixels` semantics by comparing an `openaccess=1` row (no maxpixels cap) against an `openaccess=0` row (maxpixels=900).+- Fetched `objects.csv` raw (byte-range) — confirmed schema and that title/artist metadata lives here, joined via `objectid`.+- `curl` GET `info.json` for a real uuid — valid IIIF descriptor returned.+- `curl -I` (HEAD) on `full/full/0/default.jpg` and `full/max/0/default.jpg` — both HTTP 200, image/jpeg, multi-MB content-length, i.e. genuinely full resolution, not a redirect or error page.+- `curl -I` on the `iiifthumburl` pattern (`full/!200,200/0/default.jpg`) — HTTP 200, small JPEG (9.7 KB), confirming the thumbnail convenience URL also works.++**verified = true.**++## Gotchas++- **`openaccess` flag is per-image, not per-object.** Always filter on it — do not assume every row in `published_images.csv` is reuse-cleared. Rows with `openaccess=0` are capped by IIIF server-side (`maxpixels`, e.g. 900px long edge) — these are rights-restricted (e.g. copyrighted contemporary works, loans) and should be excluded from a "CC0 image" pipeline.+- **IIIF profile is level1** — supports `sizeAboveFull` per the `info.json` profile, which is why `full/full` and `full/max` both return native resolution rather than erroring; not all IIIF servers allow this (level0 servers only serve pre-baked sizes).+- **No live object/artwork search API.** Anyone wanting "search by artist/title/date" must filter the CSV client-side (or load into SQLite/DuckDB — the repo ships `sql_tables/` schema helpers for exactly this). Don't assume a `?q=` REST endpoint exists.+- **CSV files are large** (130k+ objects across multiple linked tables — `objects.csv`, `published_images.csv`, `constituents.csv`, `objects_constituents.csv`, etc. per the repo's `data/` dir) — use streaming parses or DuckDB/SQLite rather than loading everything into memory naively.+- **Rate limits**: none encountered on either GitHub raw or `api.nga.gov` in this test; Cloudflare fronts `api.nga.gov` and sets `__cf_bm` cookies but did not block repeated HEAD requests. Be a reasonably polite bulk client anyway (the data updates frequently — no need to re-download the whole CSV more than daily).+- **Attribution**: not legally required (CC0) but NGA requests citing "National Gallery of Art Open Data Program" for datasets built on this data; for images, credit lines are in `objects.csv.creditline` per object (nice to surface even though not mandatory).+- **`assistivetext`** in `published_images.csv` is a free, pre-generated alt-text/description per image — useful if you need accessible captions without running your own vision model.diff --git a/skills/museum-art/references/rijksmuseum.md b/skills/museum-art/references/rijksmuseum.mdnew file mode 100644index 0000000..b333bd4--- /dev/null+++ b/skills/museum-art/references/rijksmuseum.md@@ -0,0 +1,88 @@+# Rijksmuseum — Open-Access Image Recipe (VERIFIED 2026-07-24)++## TL;DR+- **Starting hint was stale.** `rijksmuseum.nl/api/en/collection` (the old apikey-based "Collection API") is **deprecated**. The current, live, documented API is the **Linked Art Search API** at `data.rijksmuseum.nl/search/collection`.+- **No API key needed** for the current API. It's fully open.+- Images come via a separate **IIIF** image service (`iiif.micr.io`), reached by walking the linked-art graph from a search result.+- License: **CC0 / Public Domain** for the vast majority of digitized objects (confirmed on the test object). Attribution is requested but not legally required for CC0/PD items.++## Base URL+- Search: `https://data.rijksmuseum.nl/search/collection`+- Object resolver (linked data / JSON-LD): `https://id.rijksmuseum.nl/{objectId}`+- Image (IIIF, via Micrio): `https://iiif.micr.io/{imageId}/{region}/{size}/{rotation}/{quality}.{format}`++## API Key+**Not required.** The new Search API (`data.rijksmuseum.nl`) is public, no registration, no key, no auth header. (The legacy `rijksmuseum.nl/api/en/collection` API *did* require a free key via account registration + profile settings — but that endpoint is marked DEPRECATED in the current docs and should not be used for new integrations.)++## License+- **CC0 / Public Domain** for most digitized collection objects — confirmed directly on the test object's `VisualItem` record: `subject_to` → `classified_as` → `https://creativecommons.org/publicdomain/mark/1.0/` ("Public Domain") and a nested `subject_of` rights block citing `https://creativecommons.org/publicdomain/zero/1.0/` (CC0).+- Some items are CC BY 4.0 (attribution required) or fully copyrighted/restricted — always read the object's own rights block rather than assuming.+- Museum's policy page (`data.rijksmuseum.nl/policy/`): attribution is *requested* ("kindly ask you to credit the Rijksmuseum") but not legally mandatory for CC0/PD works.++## Search Recipe (step by step)++### (a) Search for public-domain artworks that have images+1. Call `GET https://data.rijksmuseum.nl/search/collection?type=painting&imageAvailable=true`+ - `imageAvailable=true` filters to objects with a digital reproduction.+ - Other useful params: `creator`, `creationDate` (wildcards `*`/`?`), `description`, `material`, `technique`, `title`, `type`, `objectNumber`, `memberOfSetId`, `aboutActor`. Repeat a param to OR multiple values (e.g. two `material=`).+ - There is **no direct license/CC0 filter param** — the API doesn't expose rights as a search facet. In practice, filter/verify license per-object (see step 4 below) since almost everything with `imageAvailable=true` in the general collection is Public Domain/CC0.+ - Response is a Linked-Art `OrderedCollectionPage`: `orderedItems: [{id: "https://id.rijksmuseum.nl/{objectId}", type: "HumanMadeObject"}, ...]`, plus `partOf.totalItems` and a `next.id` URL (contains an opaque `pageToken`) for pagination — just follow `next.id` verbatim for the next page. Page size is capped at 100.++2. Pick an object id from `orderedItems`, e.g. `https://id.rijksmuseum.nl/200105887`.++### (b) Get a full-resolution downloadable image URL from a result+3. `GET https://id.rijksmuseum.nl/{objectId}` (Accept: application/json) → JSON-LD `HumanMadeObject` record. Find the `shows` array → `{id: "https://id.rijksmuseum.nl/{visualItemId}", type: "VisualItem"}`.+4. `GET https://id.rijksmuseum.nl/{visualItemId}` → `VisualItem` record. Check:+ - `subject_to[].classified_as[].id` for the rights statement (look for `creativecommons.org/publicdomain/...`).+ - `digitally_shown_by` → `{id: "https://id.rijksmuseum.nl/{digitalObjectId}", type: "DigitalObject"}`.+5. `GET https://id.rijksmuseum.nl/{digitalObjectId}` → `DigitalObject` record. Its `access_point[0].id` is the **ready-to-use full-resolution IIIF image URL**, already in the form `https://iiif.micr.io/{imageId}/full/max/0/default.jpg` — no further construction needed, just use it as-is.++### IIIF sizing (if you want other resolutions/crops)+Template: `https://iiif.micr.io/{imageId}/{region}/{size}/{rotation}/{quality}.{format}`+- `region`: `full` (whole image) or `x,y,w,h` pixel box+- `size`: `max` (native full res), `!2000,2000` (fit within box), `800,` (width 800, auto height)+- `rotation`: `0` normally+- `quality`: `default` (or `gray`, `bitonal`)+- `format`: `jpg`, `png`, `webp`, etc.+Docs: `data.rijksmuseum.nl/docs/iiif/image` (IIIF Image API), `data.rijksmuseum.nl/docs/iiif/presentation` (manifests), `data.rijksmuseum.nl/docs/iiif/` (overview).++## Concrete Example (fully verified live, 2026-07-24)++**exampleApiUrl** (search):+```+https://data.rijksmuseum.nl/search/collection?type=painting&imageAvailable=true+```+Verified via `curl` → HTTP 200, valid JSON, `totalItems: 4916`, first result `https://id.rijksmuseum.nl/200100988`.++**Object chain used for the image example:**+- Object: `https://id.rijksmuseum.nl/200105887` → "Cat at Play" (Katjesspel), Henriëtte Ronner-Knip, c.1860-1878, object number SK-A-3089+- VisualItem: `https://id.rijksmuseum.nl/202105887` → rights = Public Domain / CC0+- DigitalObject: `https://id.rijksmuseum.nl/5001087555671055286110` → `access_point[0].id`++**exampleImageUrl**:+```+https://iiif.micr.io/YAxov/full/max/0/default.jpg+```+Verified via `curl -I` and full download:+- HTTP/2 200, `content-type: image/jpeg`, `content-length: 1,463,989 bytes`+- Actual pixel dimensions: **3720×2696**, baseline JPEG+- `access-control-allow-origin: *` (CORS-open, safe to hotlink/fetch client-side)+- Served via Cloudflare, `cache-control: public, max-age=31536000` (1yr cache — fine to cache aggressively)++## Gotchas+- **Two generations of API coexist in search results/docs.** Don't follow the old `rijksmuseum.nl/api/en/collection` (`key=...&imgonly=True` style) — it's the deprecated Collection API. Use `data.rijksmuseum.nl/search/collection` instead.+- **No single-call shortcut for the image.** Unlike some museum APIs (e.g. a flat `webImage.url` field), Rijksmuseum's linked-art model requires **3 sequential GETs** (object → VisualItem → DigitalObject) to reach the actual image URL. Budget for that in any pipeline (or cache the chain).+- **No license filter in search params.** `imageAvailable=true` gets you images, not necessarily license — verify CC0/PD per object via the VisualItem's `subject_to` block if you need to be strict (though in practice public-collection paintings/prints are overwhelmingly Public Domain/CC0).+- **Library/archive records excluded** from the Search API (museum objects only).+- **Pagination**: don't hand-build `pageToken` — always follow the exact `next.id` URL returned in the response.+- **Rate limits**: not documented/published for the new API; no auth means no per-key throttling was observed in this test, but be a good citizen (no aggressive parallel hammering).+- **Attribution**: not legally required for CC0/PD, but the museum requests a credit line ("Rijksmuseum") — cheap to add and avoids any ambiguity for CC BY items mixed into broader queries.+- **IIIF host is `iiif.micr.io`** (third-party Micrio infrastructure), not `data.rijksmuseum.nl` itself — don't assume same-origin/rate-limit policy as the main API.++## Sources+- https://data.rijksmuseum.nl/docs/ (API overview)+- https://data.rijksmuseum.nl/docs/search (Search API reference)+- https://data.rijksmuseum.nl/docs/api/collection (old Collection API — marked DEPRECATED)+- https://data.rijksmuseum.nl/docs/iiif/ , /docs/iiif/image , /docs/iiif/presentation (IIIF docs)+- https://data.rijksmuseum.nl/policy/ (licensing/rights policy)+- Live verified via `curl`: `data.rijksmuseum.nl/search/collection`, `id.rijksmuseum.nl/200105887`, `id.rijksmuseum.nl/202105887`, `id.rijksmuseum.nl/5001087555671055286110`, `iiif.micr.io/YAxov/full/max/0/default.jpg`diff --git a/skills/museum-art/references/smithsonian.md b/skills/museum-art/references/smithsonian.mdnew file mode 100644index 0000000..a0a308c--- /dev/null+++ b/skills/museum-art/references/smithsonian.md@@ -0,0 +1,100 @@+# Smithsonian Open Access API — Verified Recipe++Status: **VERIFIED** (live queries executed 2026-07-24, all succeeded with real data and a resolvable full-res image).++## Base URL++```+https://api.si.edu/openaccess/api/v1.0/+```++Key endpoints:+- `search` — full-text/field search across ~7.5M+ records (Solr-backed)+- `content/{id}` — fetch one record by its `id` (from a search result)+- `stats` — collection unit counts+- `metadata/v2.0/terms/{category}` — controlled-vocabulary term lists++All requests go through **api.data.gov** as the API gateway (hostname is `api.si.edu` but auth/quota is api.data.gov's).++## API Key++**Required: yes**, via the query param `api_key`.++- Free signup: https://api.data.gov/signup/ (name + email, key emailed immediately — standard api.data.gov self-serve flow, no approval wait, no cost).+- For quick testing without signing up, the shared `DEMO_KEY` works (used below) but is rate-limited much harder.+- Rate limits: `DEMO_KEY` = 30 requests/hour/IP; a registered personal key = 1,000 requests/hour. (Per api.data.gov standard tiers; Smithsonian doesn't publish a separate limit.)++## License++**CC0 1.0 Universal (public domain dedication)** for everything tagged Open Access. No attribution legally required, though crediting "Smithsonian Institution" is good practice.++Two places the CC0 flag shows up in the JSON, both worth checking:+- `content.descriptiveNonRepeating.metadata_usage.access` = `"CC0"` (record-level)+- `content.descriptiveNonRepeating.online_media.media[].usage.access` = `"CC0"` (per-image-level — check this one, since a record can be CC0 but an individual attached media item can carry different rights)++Not every one of the Smithsonian's ~157M total records is Open Access — only records with `metadata_usage.access: "CC0"` are released for unrestricted reuse. Filtering on this field (or the `online_media_type` field, see below) is what separates "any record" from "downloadable public-domain asset."++## Search Recipe++### (a) Search for public-domain artworks that have images++```+GET https://api.si.edu/openaccess/api/v1.0/search+ ?q=<TERMS> AND online_media_type:Images AND unit_code:<UNIT>+ &rows=10+ &start=0+ &api_key=<YOUR_KEY>+```++- `online_media_type:Images` — restricts to records that have at least one attached image-type media object. (This is the field that matters; do **not** rely on adding `cc0:CC0` alone — that clause was accepted by the query parser without error but did not reliably filter, see Gotchas.)+- `unit_code:<UNIT>` — scope to one museum, e.g. `SAAM` (Smithsonian American Art Museum), `NPG` (National Portrait Gallery), `FSG` (Freer|Sackler), `CHNDM` (Cooper Hewitt), `NMNHBIRDS`, etc. Omit for cross-collection search.+- Free-text `q=` terms combine with `AND`/`OR` Solr syntax, e.g. `q=sunflower AND online_media_type:Images`.+- **After getting results, always check `content.descriptiveNonRepeating.online_media.media[].usage.access == "CC0"`** on each hit before treating its image as free-to-use — some non-Open-Access records still surface in a broad search.++### (b) Get a full-resolution downloadable image URL from a result++For each hit, walk: `content.descriptiveNonRepeating.online_media.media[]` — an array (a record can have multiple images). Each media object has:++- `media.usage.access` — CC0 check (per above)+- `media.content` — an IDS delivery-service URL, e.g. `https://ids.si.edu/ids/deliveryService?id=<idsId>` — **calling this with no size param returns the full-resolution original** (verified: 1.8MB JPEG).+- `media.resources[]` — explicit named download links when the record has them pre-generated: `"High-resolution TIFF"`, `"High-resolution JPEG"` (with `width`/`height` in pixels), `"Screen Image"`, `"Thumbnail Image"`. Not every record has the high-res TIFF/JPEG resources array populated — some only expose `Screen Image`/`Thumbnail Image`, in which case use the `deliveryService` content URL directly for full res.++**IIIF-style resizing**: append `&max=<pixels>` to the `deliveryService` URL to cap the longest edge, e.g. `&max=2000` (verified: dropped a 1.8MB image to 828KB at max=2000). Omit `max` entirely for the original full-size file.++## Example URLs (both verified live, 2026-07-24)++**exampleApiUrl** (search — Smithsonian American Art Museum CC0 images):+```+https://api.si.edu/openaccess/api/v1.0/search?q=cc0:CC0%20AND%20online_media_type:Images%20AND%20unit_code:SAAM&api_key=DEMO_KEY&rows=5+```+Verified response: HTTP 200, `rowCount: 12999`, returned real SAAM artwork records (e.g. "A Chiefe Herowan," object id `saam_1985.66.403_410`, record link https://americanart.si.edu/collections/search/artwork/?id=18695) each carrying `metadata_usage.access: "CC0"` and an `online_media.media[]` array.++**exampleImageUrl** (full-resolution, from a National Museum of Natural History Birds specimen record returned by the broader query `q=cc0:CC0 AND online_media_type:Images`):+```+https://ids.si.edu/ids/download?id=NMNH-vol.090_449776-449800.jpg+```+Verified: `curl -sL` → HTTP 200, `image/jpeg`, 23,659,074 bytes, resolves (307 redirect) to `https://smithsonian-open-access.s3-us-west-2.amazonaws.com/media/nmnh/NMNH-vol.090_449776-449800.jpg`. `usage.access: "CC0"` on the media object.++Alternate example (SAAM artwork, screen-res since no TIFF resource present, still CC0):+```+https://ids.si.edu/ids/deliveryService?id=SAAM-1985.66.403410_1+```+Verified: HTTP 200, `image/jpeg`, 1,833,356 bytes.++## Gotchas++- **`cc0:CC0` as a query clause is not a reliable filter.** It doesn't error, but adding it to a query did not change result counts predictably in testing — always independently verify `metadata_usage.access` / `media.usage.access` == `"CC0"` in the returned JSON rather than trusting the query string to have filtered correctly.+- **`online_media_type:Images` also isn't a guaranteed hard filter on every unit.** Several paintings-category test queries returned zero records with a populated `online_media` object despite the filter term, while bird/NMNH and SAAM units reliably returned populated media. Best practice: request extra rows and skip any result whose `descriptiveNonRepeating` lacks an `online_media` key.+- **Rate limits are api.data.gov's, not Smithsonian's**: DEMO_KEY = 30 req/hr/IP (easy to exhaust in a scripting loop — get a real key for anything beyond a handful of test calls).+- **IDS delivery URLs sometimes 307-redirect to S3** (`smithsonian-open-access.s3-us-west-2.amazonaws.com`) — follow redirects (`curl -L`) or your HTTP client's default redirect-follow.+- **Attribution not legally required** under CC0, but Smithsonian's own guidance asks for a credit line where practical (e.g. "Smithsonian American Art Museum").+- **Two rights fields to reconcile**: record-level `metadata_usage.access` and per-media `media.usage.access` can theoretically diverge (a CC0 record could contain a rights-restricted third-party image) — always check the media-level flag before using a specific image.+- Full docs referenced (not independently fetchable due to JS-rendered pages, but corroborated via GitHub/Postman/search): https://www.si.edu/openaccess/devfaq, https://edan.si.edu/openaccess/docs/, https://github.com/Smithsonian/OpenAccess++## Sources+- https://www.si.edu/openaccess/faq+- https://edan.si.edu/openaccess/docs/+- https://github.com/Smithsonian/OpenAccess+- https://github.com/Smithsonian/smithsonian-openaccess (Python client)+- https://api.data.gov/signup/+- Live API responses captured via curl, 2026-07-24 (this session)diff --git a/skills/museum-art/references/smk.md b/skills/museum-art/references/smk.mdnew file mode 100644index 0000000..00e3620--- /dev/null+++ b/skills/museum-art/references/smk.md@@ -0,0 +1,161 @@+# SMK (National Gallery of Denmark) — Open Access Image Recipe++Status: **VERIFIED working** (2026-07-24, live curl + WebFetch checks against the real API).++## Base URL++```+https://api.smk.dk/api/v1+```++Official docs (Swagger UI, embedded OpenAPI 3.0.3 spec — page itself is JS-rendered but the+spec JSON is inlined in `swagger-ui-init.js`):+- Human docs: https://api.smk.dk/api/v1/docs/+- Article: https://www.smk.dk/en/article/smk-api/+- Contact: [email protected]++## API key++**None needed.** Confirmed empirically — 8+ unauthenticated GET requests in a row all returned+HTTP 200 with no `Authorization` header, no key, no `X-Api-Key`. The API is explicitly described+as "free to use." No signup, no throttling encountered in this test burst.++## License++Individual objects carry a `rights` field. For public-domain works it is:++```+"rights": "https://creativecommons.org/publicdomain/mark/1.0/"+```++i.e. **Public Domain Mark 1.0** (SMK calls it "Public Domain" on their license page,+https://www.smk.dk/en/license/public-domain/ — not literally the CC0 waiver, but functionally+equivalent: no copyright restrictions, reuse/modify/redistribute freely, attribution not+mandatory but good practice — credit "SMK / Statens Museum for Kunst"). Filter for it with the+`public_domain:true` facet filter (below) rather than parsing `rights` per item.++## The gotcha the starting hint got wrong++The hinted query shape `filters=[public_domain:true][has_image:true]` (both brackets+concatenated into ONE `filters=` value) is **accepted by the server (200 OK) but silently wrong**+— it does not AND the two conditions. Verified by comparing `found` counts:++| Query | `found` |+|---|---|+| `filters=[public_domain:true]` only | 150,301 |+| `filters=[has_image:true]` only | 54,393 |+| `filters=[public_domain:true][has_image:true]` (single concatenated value) | 150,301 (wrong — ignored the second bracket) |+| `filters=[public_domain:true]&filters=[has_image:true]` (**repeated param, one bracket each**) | **39,479** (correct intersection) |++**Rule: pass `filters` as a repeated query parameter, one `[field:value]` bracket per+occurrence, not concatenated.**++## Recipe++### (a) Search for public-domain artworks that have an image++```+GET https://api.smk.dk/api/v1/art/search+ ?keys=*+ &filters=[public_domain:true]+ &filters=[has_image:true]+ &offset=0+ &rows=10+```++URL-encoded (paste-able):+```+https://api.smk.dk/api/v1/art/search?keys=*&filters=%5Bpublic_domain:true%5D&filters=%5Bhas_image:true%5D&offset=0&rows=10+```++Other useful params (from the OpenAPI spec, `/art/search` GET):+- `keys` (required) — search keywords; `*` = match all.+- `rows` — page size, max 2000, default 10.+- `offset` — pagination start.+- `fields` — restrict returned fields (array param).+- `sort` — sort field, default relevance.+- Other facet filters follow the same `[field:value]` bracket syntax, e.g. `[has_3d_file:true]`,+ `[on_display:true]`, `[collection:...]`.++### (b) Get a full-resolution downloadable image from a result item++Each item in `items[]` already carries everything needed — no second API call required:++- `image_native` — direct downloadable full-res JPEG URL (this is the one to use for+ "download the image").+- `image_thumbnail` — pre-sized ~1024px-wide JPEG via the IIIF thumb server.+- `image_iiif_id` / `image_iiif_info` — the raw IIIF Image API base + `info.json`, for+ requesting any custom size/region/rotation via standard IIIF syntax+ `{iiif_id}/{region}/{size}/{rotation}/{quality}.{format}`.+- `image_width` / `image_height` / `image_size` — native pixel dimensions and byte size.++Example from a verified live item (object KKS5261, "Augustus og den tiburtinske sibylle"):+```json+{+ "id": "1170000001_object",+ "object_number": "KKS5261",+ "public_domain": true,+ "rights": "https://creativecommons.org/publicdomain/mark/1.0/",+ "image_width": 4992,+ "image_height": 6287,+ "image_size": 32476791,+ "image_thumbnail": "https://iip-thumb.smk.dk/iiif/jp2/qz20sx771_kks5261.tif.jp2/full/!1024,/0/default.jpg",+ "image_native": "https://api.smk.dk/api/v1/download/W3siaW1nX3VybCI6Imh0dHBzOi8vaWlwLnNtay5kay9paWlmL2pwMi9xejIwc3g3NzFfa2tzNTI2MS50aWYuanAyL2Z1bGwvZnVsbC8wL25hdGl2ZS5qcGciLCJwdWJsaWNfZG9tYWluIjp0cnVlLCJvYmplY3RfbnVtYmVyIjoiS0tTNTI2MSIsIm51bSI6IiJ9XQ==/KKS5261.jpg",+ "image_iiif_id": "https://iip.smk.dk/iiif/jp2/qz20sx771_kks5261.tif.jp2",+ "image_iiif_info": "https://iip.smk.dk/iiif/jp2/qz20sx771_kks5261.tif.jp2/info.json"+}+```++To fetch a specific single object later by its `object_number`, use:+```+GET https://api.smk.dk/api/v1/art?object_number=KKS5261+```+(the `object_url` field on every item is pre-built this way).++## Example URLs (both verified live, 2026-07-24)++**exampleApiUrl** (search query — returns JSON, confirmed 200 with 39,479 total matches):+```+https://api.smk.dk/api/v1/art/search?keys=*&filters=%5Bpublic_domain:true%5D&filters=%5Bhas_image:true%5D&offset=0&rows=2+```++**exampleImageUrl** (full-resolution downloadable JPEG, confirmed HTTP 200, `Content-Type:+image/jpeg`, `Content-Length: 24043853` bytes, 4992x6287 px):+```+https://api.smk.dk/api/v1/download/W3siaW1nX3VybCI6Imh0dHBzOi8vaWlwLnNtay5kay9paWlmL2pwMi9xejIwc3g3NzFfa2tzNTI2MS50aWYuanAyL2Z1bGwvZnVsbC8wL25hdGl2ZS5qcGciLCJwdWJsaWNfZG9tYWluIjp0cnVlLCJvYmplY3RfbnVtYmVyIjoiS0tTNTI2MSIsIm51bSI6IiJ9XQ==/KKS5261.jpg+```++Alternative (IIIF-native, resize on the fly, also confirmed 200):+```+https://iip.smk.dk/iiif/jp2/qz20sx771_kks5261.tif.jp2/full/1024,/0/default.jpg+```++## Verification log++- `curl -sI` on `image_native` URL → `HTTP/1.1 200 OK`, `Content-Type: image/jpeg`,+ `Content-Length: 24043853`, `Access-Control-Allow-Origin: *`.+- `curl -s` on `art/search` example URL → HTTP 200, valid JSON, `found: 39479`,+ `items[0].public_domain == true`, `items[0].has_image` implied by presence of `image_native`.+- `curl -sI` on IIIF `info.json` → HTTP 200, valid IIIF Image API 2.0 manifest with `sizes` array.+- Burst of 5 sequential unauthenticated requests → all 200, no throttling/key errors observed.++## Gotchas++1. **`filters` must be repeated, not concatenated** — see table above. This is the single+ biggest trap; the naive single-string form silently returns the wrong (larger, un-intersected)+ result set instead of erroring.+2. **`keys` is a required param** even for "give me everything" — use `keys=*`.+3. `image_hires` field exists in the schema but was `None` on the sampled item; `image_native`+ is the reliable full-res download link, not `image_hires`.+4. `image_native` URLs are single-use-looking base64-ish opaque tokens embedding the source IIIF+ path + object metadata — they are stable (not time-limited signed URLs) but don't try to+ hand-construct them; always take them verbatim from the API response.+5. IIIF server (`iip.smk.dk`) supports standard region/size/rotation/quality params if you want+ sizes other than native — `sizes` in `info.json` lists SMK's precomputed steps (156px up to+ 2496px wide) but arbitrary `w,` / `w,h` sizes also work via `full/1024,/0/default.jpg` syntax.+6. No published rate limit was hit in testing; be a good citizen (the API is free, maintained by+ a small team — contact [email protected] for anything at bulk-harvest scale).+7. `rights` is per-item — not every item with `public_domain:true` necessarily has an identical+ `rights` URL, but in the sample it was the CC Public Domain Mark 1.0 link.+8. `object_number` (e.g. `KKS5261`) is the human-facing ID; `id` (e.g. `1170000001_object`) is+ internal. Use `object_number` for the `/art?object_number=` single-item lookup.diff --git a/skills/no-ai-slop/LICENSE b/skills/no-ai-slop/LICENSEnew file mode 100644index 0000000..644ebee--- /dev/null+++ b/skills/no-ai-slop/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Peter Yang++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/skills/no-ai-slop/SKILL.md b/skills/no-ai-slop/SKILL.mdnew file mode 100644index 0000000..e44511a--- /dev/null+++ b/skills/no-ai-slop/SKILL.md@@ -0,0 +1,93 @@+---+name: no-ai-slop+description: Edit drafts into sharper, more human writing while preserving the writer's personal voice, or detect AI-slop patterns without rewriting. Use when the user wants a draft clearer, more direct, more opinionated, or less AI-sounding, or asks whether writing reads as AI.+---++# No AI slop++You are a sharp human editor. Preserve the user's point and personal voice while making the writing clearer and more alive. Remove AI patterns without turning distinctive writing into generic polished prose.++## Two jobs++**Edit (default).** The user shares a draft to fix. Make the minimum effective edit with the rules below and return the edited draft plus a What changed section.++**Detect.** The user asks whether a piece is AI slop, or asks to audit, scan, or flag a draft without rewriting. Name each pattern from this skill that appears, quote the line, and give the fix in a few words. Do not rewrite, score the draft, or guess whether AI wrote it. AI detectors guess. Named patterns are evidence the user can check. Offer to edit the draft after.++## What to ask for++If the user has not provided a draft, ask them to paste it.++If the audience or format is unclear, ask one question: Who is this for and where will it be published?++If the goal is unclear, ask what the reader should think, feel, or do after reading it.++## Editing principles++- **Preserve the writer's real voice.** First notice the draft's vocabulary, cadence, bluntness, humor, uncertainty, digressions, and level of polish. Keep the traits that feel personal to the writer. Do not make every paragraph equally tidy or rewrite distinctive lines merely for consistency.+- **Make the minimum effective edit.** Fix AI patterns, errors, repetition, and unclear passages. Leave strong human sentences alone. A rough draft with a real voice should still sound like the same person after editing.+- **Lead with the point when the setup adds nothing.** Cut generic throat-clearing. Keep a personal aside, story, or admission when it creates context, tension, or character.+- **Front-load only when it improves clarity.** Put conclusions early when that helps the reader. Do not force every section and paragraph into the same point-detail-background shape.+- **Keep the user's meaning.** Don't invent claims, examples, stats, or opinions. If something is unclear, ask.+- **Open it up, don't dumb it down.** Keep the substance, nuance, and precision. Strip out only what makes it hard to read: jargon, long sentences, abstract nouns, and tangled structure.+- **Use active voice.** "The team shipped it Tuesday" beats "the decision emerged." Never let inanimate things do human verbs.+- **Make every sentence earn its place.** Cut empty qualifiers and throat-clearing. Keep phrases such as "I think," "maybe," or "to be honest" when they express real uncertainty, self-awareness, or the writer's spoken rhythm.+- **Untangle sentences without flattening the cadence.** Split sentences and paragraphs when they are genuinely hard to follow. Keep longer spoken sentences, fragments, and changes in pace when they are clear and characteristic of the writer.+- **Be concrete and specific.** Abstraction is where writing goes to die. "The integration improved efficiency" becomes "The integration cut deploy time from 40 minutes to 4." Names, numbers, dates, mechanisms, and examples beat abstractions.+- **Protect the specific fact.** Don't smooth a useful detail into generic importance. "The tool significantly improves engineering productivity" becomes "The tool cut review time from 30 minutes to 8."+- **Make verbs do the work.** Replace weak verb phrases with direct verbs. "Made a decision" becomes "decided." "Has the ability to" becomes "can."+- **Know the job.** Before structure or word choice, know what the piece is trying to do and who it is for.+- **Preserve useful edge and character.** Keep strong opinions, blunt language, humor, profanity, self-interruptions, and honest admissions when they belong to the writer. Don't replace them with safer or more professional wording.+- **Keep structure unless it's hurting the piece.** Preserve the writer's progression and detours when they carry personality. If you reorganize, say why in the What changed section.++## Words to cut++Banned outright: delve, foster, leverage, utilize, facilitate, empower, streamline, robust, cutting-edge, paradigm shift, game changer, this is huge, this changes everything, tapestry, realm, beacon, multifaceted, meticulous, intricate, paramount, transformative, elevate, embark, supercharge, harness, ever-evolving.++Often-empty adverbs: just, literally, honestly, simply, actually, truly, fundamentally, importantly, crucially, inherently, inevitably. Cut them when they add nothing. Keep them when they carry emphasis, uncertainty, contrast, or the writer's natural spoken rhythm.++Often-empty phrases: it's worth noting, it's important to note, at the end of the day, when it comes to, at its core, in today's world, in the age of, in the world of, the reality is, the truth is, in terms of, with regard to, in order to, going forward, in this article, let's dive in. Cut them when they delay the point. Keep an occasional phrase when it is part of the writer's recognizable voice and the sentence still earns its place.++## Patterns to cut++**Binary contrasts.** "This is not X. It's Y." / "The question isn't X, it's Y." / "It's not just X but Y." State Y directly. "The question isn't the model. It's the eval." becomes "The eval matters more than the model."++**Throat-clearing openers.** "Here's the thing," "Here's what I mean," "Let me be clear," "I'll be honest," "The uncomfortable truth is." Cut them and state the point.++**Faux-insight setups.** "This is the part most people skip," "What most people get wrong," "Here's what nobody tells you," "The part everyone misses." These flatter the writer as the lone expert. Cut the setup and make the claim stand on its own. "The part everyone misses: distribution is the real moat" becomes "Distribution is the moat."++**Colon reveals.** A noun phrase, a colon, then a lowercase dramatic reveal: "The detail that makes it work: a separate agent grades it." "The best part: it learns." Rewrite as a plain sentence ("A separate agent does the grading, which is what makes it work"). Use colons for lists, labels, and quotes, not fake drama. Prefer sentence case after a colon unless grammar, a proper noun, a title, or code requires otherwise.++**Superficial analysis.** Cut trailing `-ing` clauses that pretend to explain meaning: "highlighting," "underscoring," "reflecting," "showcasing." "The launch adds file search, highlighting the team's commitment to better workflows" becomes "The launch adds file search, so users can find old drafts without leaving the editor."++**Importance puffery.** "Stands as a testament," "marks a pivotal moment," "plays a vital role," "solidifies its position," "underscores its significance." State the fact and let the reader judge whether it matters. "The launch marks a pivotal moment for the company" becomes "The launch is the company's first paid product."++**Weasel attribution.** "Experts agree," "industry reports suggest," "many argue," "widely regarded as," "studies show." Name the source or cut the claim. If the user has no source, ask instead of inventing one.++**Fake-strong verbs.** Prefer "is" and "has" when they are clearer. "The app serves as a centralized hub for sponsor management" becomes "The app tracks sponsors, drafts, due dates, and approvals in one place."++**Synonym cycling.** If the clear word is right, repeat it. Don't rotate terms for style. "The agent reviews the draft. The assistant scores the piece. The tool suggests fixes" becomes "The agent reviews the draft, scores it, and suggests fixes."++**Negative listing.** "Not a X. Not a Y. A Z." Just say Z.++**Dramatic fragmentation.** "X. And Y. And Z." or "That's it. That's the whole thing." Use complete sentences.++**Robotic rhythm.** Avoid repeated sentence shapes, identical paragraph structures, and stacked punchy fragments. Vary the shape only when it helps the point.++**Rhetorical setups.** "What if I told you...", "Think about it:", "Plot twist:", and self-answered "Question? Answer." pairs. Drop them and make the point.++**Fake-profound kickers.** Cut the final "deep" line when it turns the point into a cute metaphor, aphorism, or mic-drop sentence. Do not rewrite it into a better metaphor. Do not preserve the rhythm. Delete it, then end on the clearest concrete sentence already in the draft. If the ending needs more closure, add a plain takeaway or next action.++**Summary-recap endings.** "In conclusion," "Ultimately," "Overall," or a final paragraph that restates the piece. The reader was just there. End on the last concrete point, takeaway, or next action instead.++**Formatting slop.** Emoji in headings, bold sprinkled mid-sentence for emphasis, bullet lists where two sentences of prose would read better, and headers over two-sentence sections. Format should follow the content, not decorate it.++**Em dashes.** Do not use them as a default rhythm crutch. In short copy, use none. In longer drafts, 1-2 are fine if they clearly beat commas, periods, or parentheses. Remove clusters and decorative dashes.++## Workflow++1. Read the full draft before editing.+2. Identify the core point and 3-5 voice signals to preserve, such as vocabulary, cadence, bluntness, humor, uncertainty, or digressions. Keep this note internal. If you cannot identify the core point, ask the user.+3. For a detect request, return the findings report described in Two jobs and stop.+4. For an edit, make the minimum effective changes, then check the edited draft against `eval.md` yourself.+5. If any check fails, fix the draft and run the checks again.+6. Output the full edited draft and a short **What changed** section.diff --git a/skills/no-ai-slop/SOURCE.md b/skills/no-ai-slop/SOURCE.mdnew file mode 100644index 0000000..141ca85--- /dev/null+++ b/skills/no-ai-slop/SOURCE.md@@ -0,0 +1,12 @@+# Vendored skill++Source: https://github.com/petergyang/no-ai-slop (Peter Yang), MIT License.+Vendored into this vault 2026-07-23, unmodified except this note.++Validated against monotykamary/Tom's published writing before adoption: its+instructions match Tom's proven practice on concreteness, named sources, active+voice, killing fake-profound kickers and summary-recap endings, and formatting+restraint. It is stricter than Tom on binary contrasts / colon reveals (Tom uses+them sparingly for genuine reframes — the skill itself allows this as voice) and+on em dashes (Tom uses them freely; this vault's house rule bans them entirely, which+wins). Use as the final editing pass for blog posts and social copy.diff --git a/skills/no-ai-slop/eval.md b/skills/no-ai-slop/eval.mdnew file mode 100644index 0000000..a72a95e--- /dev/null+++ b/skills/no-ai-slop/eval.md@@ -0,0 +1,42 @@+# No AI slop eval++Use this after the rewrite. Answer each check with pass or fail. If any check fails, fix the draft before returning it.++For detect requests, make sure the response names each pattern found with a quoted line and a short fix, without rewriting the draft.++## Editing principles++1. Does the edit preserve the user's point without adding claims, examples, stats, quotes, or opinions?+2. Does it preserve the writer's distinctive vocabulary, cadence, bluntness, humor, uncertainty, digressions, and level of polish?+3. Does it leave strong human sentences alone instead of rewriting them for consistency or making every paragraph equally tidy?+4. Is the amount of cutting proportional to the actual slop, with no aggressive compression that strips out character?+5. Does the draft lead with what the reader needs while keeping personal setup that adds context, tension, or character?+6. Are points front-loaded where that improves clarity without forcing every unit into the same structure?+7. Do sentences earn their place, with concrete facts, protected details, and direct verbs where the draft supports them?+8. Does the draft use active voice with human subjects where possible?+9. Does the edit keep useful edge and preserve structure unless the structure was hurting the piece?+10. Are genuinely tangled sentences fixed while clear spoken cadence, fragments, and changes in pace remain intact?++## Words to cut++1. Are banned words, filler phrases, often-empty adverbs, and inflated claims removed unless quoted as examples?++## Patterns to cut++1. Are binary contrasts, negative listings, rhetorical setups, and throat-clearing openers removed?+2. Are faux-insight setups, colon reveals, superficial analysis, fake-strong verbs, synonym cycling, dramatic fragments, and robotic rhythm fixed?+3. Are importance puffery and weasel attribution replaced with plain facts and named sources, or flagged for the user when no source exists?+4. Are fake-profound kicker lines deleted instead of rewritten into better metaphors?+5. Are summary-recap endings cut so the piece ends on a concrete point, takeaway, or next action?+6. Is formatting slop removed: Emoji headings, decorative bold, bullets that should be prose, headers over tiny sections?+7. Are colons sentence case unless grammar, a proper noun, a title, or code requires otherwise?+8. Are em dashes used sparingly: Usually none in short copy, and only 1-2 in longer drafts when they clearly help?++## Final read++1. Was the edit checked directly against this file without requiring separate editor and evaluator agents?+2. Does the draft avoid robotic symmetry, repeated sentence shapes, and stacked punchy fragments?+3. Would the writer recognize the edited draft as their own voice?+4. Would the edited draft sound natural if read to a sharp colleague?+5. Does the final output include the full edited draft and a short **What changed** section?+6. For detect requests, does the response name each pattern with a quoted line and a short fix, without rewriting, scoring, or claiming AI authorship?diff --git a/skills/onboarding/SKILL.md b/skills/onboarding/SKILL.mdnew file mode 100644index 0000000..5803157--- /dev/null+++ b/skills/onboarding/SKILL.md@@ -0,0 +1,559 @@+---+name: onboarding+description: Personalize COG for your workflow - creates profile, interests, and watchlist files with guided setup (run this first!)+roles: [all]+integrations: []+---++# COG Onboarding Skill++## Purpose+Welcome new users and collect essential information to personalize their COG experience. All configuration is stored as natural markdown files within the vault structure, following COG's philosophy of transparent, editable knowledge.++## When to Invoke+- User explicitly requests `/onboarding` or mentions "onboarding" or "setup COG"+- User is new and hasn't completed onboarding yet+- User wants to update their profile or add new projects+- Any time profile customization is needed++## Core Design Principle: Smart, Low-Friction Onboarding++**The onboarding MUST feel like a natural conversation, NOT a form to fill out.**++Key rules:+- **Ask open-ended questions, not option-pickers.** Never present numbered lists of choices for the user to pick from.+- **Ask as few questions as possible.** Infer what you can from context and the user's natural responses.+- **Never ask redundant questions.** If you can extract the answer from something the user already said, don't ask again.+- **Parse intelligently.** If someone says "I'm Alex, a PM at a fintech startup tracking Stripe and Plaid", extract: name=Alex, role=PM at fintech startup, watchlist=[Stripe, Plaid]. Don't ask follow-up questions for info already given.+- **Confirm, don't re-ask.** If you're unsure about something the user said, confirm your interpretation rather than asking the question fresh.++## Process Flow++### 1. Welcome Message+Greet the user warmly and explain what COG is:+```+Welcome to COG - your self-evolving second brain powered by Claude + Obsidian + Git!++COG helps you capture thoughts, get daily intelligence briefings, and build knowledge over time - all stored as simple markdown files you own.++Let's get you set up. Tell me a bit about yourself - your name, what you do, and what topics or areas you're most interested in staying sharp on. Feel free to share as much or as little as you'd like.+```++**This single open-ended prompt replaces the old sequential questions.** The user can naturally mention their name, role, interests, sources, projects, and competitors all at once - or just share a few things.++### 2. Check for Existing Profile++Look for `00-inbox/MY-PROFILE.md`. If it exists:+```+I found an existing COG profile! What would you like to update? Just tell me what you'd like to change - your interests, projects, profile info, or anything else.+```++**Don't present a numbered menu.** Let them describe what they want in natural language.++### 3. Intelligent Information Extraction++After the user responds, extract as much as possible from their natural language:++| Field | How to Extract |+|-------|---------------|+| **Name** | Look for self-introduction patterns ("I'm Alex", "My name is...", "Call me..."). Use first name by default. |+| **Role** | Look for job/activity mentions ("I'm a PM", "I work in...", "software engineer at..."). |+| **Interests** | Look for topic mentions ("interested in AI", "following crypto", "love design"). Also infer from role context. |+| **News Sources** | Look for source mentions ("I read HN", "follow on Twitter"). If not mentioned, skip - it's optional. |+| **Projects** | Look for project mentions ("working on a SaaS app", "building..."). If not mentioned, skip. |+| **Competitive Watch** | Look for company/person mentions ("tracking Stripe", "watching what OpenAI does"). If not mentioned, skip. |++### 4. Smart Follow-Up (Only If Needed)++After extracting what you can, check what's missing from the **required** fields only:+- **Name** (required)+- **Role** (required)+- **Interests** (required - need at least 2-3 topics)++If any required field is missing, ask ONE follow-up that covers all gaps. For example:+```+Thanks! I got your name and role. What topics are you most interested in staying updated on? (e.g., AI, startups, design, health - whatever matters to you)+```++**Optional fields** (news sources, projects, competitive watch) should NEVER generate follow-up questions. If the user didn't mention them, skip them. They can always add them later by editing the files or running onboarding again.++### 5. Confirm and Create++Before creating files, briefly confirm what you captured and ask about agent team mode:+```+Here's what I've got:++- **Name**: Alex+- **Role**: Product Manager at a fintech startup+- **Interests**: AI/ML, fintech trends, product strategy, UX design+- **Projects**: Payments dashboard revamp+- **Tracking**: Stripe, Plaid++One more thing - COG can run in two modes:+- **Solo mode** (default): I handle everything directly in our conversation.+- **Agent team mode**: I delegate research, analysis, and writing to specialist sub-agents for deeper, more thorough results. Works best with Claude Code.++Which do you prefer? (Solo is great for most people - team mode is for power users who want maximum depth.)+```++**Wait for confirmation**, then generate everything. If they say "looks good" or similar, proceed. If they correct something, update and proceed without re-confirming. Default to `solo` if they don't express a preference.++### 5.5. Role Pack Matching++After extracting the user's role text in Step 3, scan `.claude/roles/*.md` for a matching role pack:++1. Read each role pack file's YAML frontmatter (`role_id` and `aliases`)+2. Compare the user's extracted role text (case-insensitive) against:+ - Exact `role_id` match (e.g., "product-manager")+ - Any string in `aliases` (e.g., "pm", "product lead", "head of product")+ - Fuzzy substring match (e.g., "product manager at a fintech startup" contains "product manager")+3. If a match is found:+ - Store the matched `role_id` as `role_pack` in the MY-PROFILE.md frontmatter+ - Present role-specific recommendations:+ ```+ As a [Role Display Name], here are the skills and integrations that'll be most useful for you:++ **Recommended skills** (ordered by relevance for your role):+ [List top 5-6 skills from the role pack with the "Why it matters for you" context]++ **Recommended integrations**:+ [List integrations from the role pack with role-specific explanations]+ ```+ - Use the role pack's suggested `agent_mode` as the default (instead of `solo`)+4. If no match is found:+ - Set `role_pack: custom` in MY-PROFILE.md+ - Recommend core skills only (those with `roles: [all]`)+ - Ask about common integrations: "Do you use GitHub, Slack, or any other tools you'd like COG to connect with?"++### 5.6. Integration Discovery++After role pack matching, set up the user's integration preferences:++1. If a role pack was matched, present its recommended integrations with role-specific context:+ ```+ Based on your role, these integrations would give COG the most context:++ [For each integration in role pack:]+ - **[Integration]** — [Why it matters for you, from role pack]++ Which of these do you already use? And are there any other tools you'd like to connect?+ ```++2. Parse the user's response:+ - Services they confirm using → add to **Active** section of MY-INTEGRATIONS.md+ - Services they don't mention or say no to → add to **Disabled** section+ - Additional services they mention → add to **Active** section+ - Always add `ElevenLabs` to **Disabled** unless explicitly requested++3. Generate `00-inbox/MY-INTEGRATIONS.md`:+ ```markdown+ ---+ type: integrations+ created: YYYY-MM-DD+ tags: ["#integrations", "#config", "#cog"]+ ---++ # My Integrations++ *COG checks this file before using any external service. Edit anytime.*++ ## Active+ [For each confirmed integration:]+ - **[Service]**: [Brief description of how COG uses it]++ ## Disabled+ [For each declined/unmentioned integration:]+ - **[Service]**: Skipped during onboarding. Enable anytime by moving to Active section.++ ---++ *Move services between Active and Disabled sections to control what COG connects to.*+ ```++4. If no role pack was matched, ask about common integrations conversationally:+ ```+ COG can connect with tools like GitHub, Slack, Linear, Notion, and PostHog for richer analysis. Do you use any of these? (Totally optional - COG works great without them too.)+ ```++### 6. Generate Profile Documents++Create the following markdown files:++#### `00-inbox/MY-PROFILE.md`+```markdown+---+type: profile+created: YYYY-MM-DD+onboarding_completed: true+role_pack: [matched role_id or "custom"]+agent_mode: [solo or team, based on role pack suggestion]+tags: ["#profile", "#config", "#cog"]+---++# My COG Profile++## About Me+- **Name**: [Name]+- **Role**: [Job/role/main activity]+- **Role Pack**: [Display name from matched role pack, or "Custom" if no match]+- **Profile Created**: [Date]++## Settings+- **Agent Mode**: [solo/team] *(solo = handle everything directly; team = delegate to specialist sub-agents for deeper results)*++## Active Projects+[If they mentioned projects:]+- [[04-projects/[slug]/PROJECT-OVERVIEW|Project Name 1]]+- [[04-projects/[slug]/PROJECT-OVERVIEW|Project Name 2]]++[If no projects:]+*No active projects yet. Add them anytime by editing this file or running onboarding again.*++## Related+- [[MY-INTERESTS|My Interests & News Sources]]+- [[03-professional/COMPETITIVE-WATCHLIST|Competitive Watchlist]] *(if applicable)*++## Notes+*Feel free to add notes here about your COG usage, preferences, or anything else.*++---++*Edit this file anytime to update your profile. COG reads it when you use skills.*+```++#### `00-inbox/MY-INTERESTS.md`+```markdown+---+type: interests+created: YYYY-MM-DD+tags: ["#interests", "#daily-brief", "#config"]+---++# My Interests & News Sources++*These topics guide my daily intelligence briefings.*++## Topics I'm Interested In+- [Topic 1]+- [Topic 2]+- [Topic 3]+- [Topic 4]+- [Topic 5]++## Preferred News Sources+[If sources were mentioned:]+*Where I like to get information:*+- [Source 1]+- [Source 2]+- [Source 3]++[If no sources mentioned:]+*No specific sources set. COG will search broadly for your topics. Add preferred sources here anytime.*++## Notes+*Add any additional context about your interests here.*++---++*Update this file anytime as your interests evolve. Just edit and save—COG will pick up the changes.*+```++#### `03-professional/COMPETITIVE-WATCHLIST.md` (only if they mentioned companies/people to track)+```markdown+---+type: competitive-intelligence+created: YYYY-MM-DD+tags: ["#competitive", "#intelligence", "#tracking"]+---++# Competitive Watchlist++*Companies, people, or organizations I'm keeping an eye on.*++## Watching+- [Company/Person 1]+- [Company/Person 2]+- [Company/Person 3]++## Why I'm Tracking Them+*Add context here about why these matter to you or your projects.*++---++*When you mention these in braindumps, COG will automatically extract the intel to your project competitive folders.*+```++#### For Each Project: `04-projects/[project-slug]/PROJECT-OVERVIEW.md`+```markdown+---+type: project-overview+project: [project-name]+slug: [project-slug]+created: YYYY-MM-DD+status: active+tags: ["#project", "#overview"]+---++# [Project Name]++## What is this project?+[Brief description - leave for user to fill in]++## Current Status+*What phase are you in? What's happening now?*++## Project Resources+- [[braindumps/|Project Braindumps]]+- [[competitive/|Competitive Intelligence]]+- [[content/|Content & Assets]]+- [[planning/|Planning Documents]]++## Next Steps+- [ ] [Action item 1]+- [ ] [Action item 2]++---++*This overview helps COG organize your project-related thoughts and updates.*+```++### 7. Create Directory Structure+Based on configuration, create personalized structure:++**Base Structure (Always):**+```+00-inbox/+01-daily/+ briefs/+ checkins/+02-personal/+ braindumps/+ development/+ wellness/+03-professional/+ braindumps/+ leadership/+ strategy/+ skills/+04-projects/+05-knowledge/+ consolidated/+ patterns/+ timeline/+ booklets/+06-templates/+```++**Project-Specific (For each listed project):**+```+04-projects/[project-slug]/+ PROJECT-OVERVIEW.md+ braindumps/+ competitive/+ content/+ planning/+ resources/+```++### 8. Create Welcome Guide++Generate: `00-inbox/WELCOME-TO-COG.md`++```markdown+---+type: guide+created: YYYY-MM-DD+tags: ["#welcome", "#getting-started", "#cog"]+---++# Welcome to Your COG Second Brain, [Name]!++Your COG is now personalized and ready to use. Here's how to get started:++## Your Profile Documents++I've created these documents to store your preferences:++- **[[MY-PROFILE]]** - Your basic info, role pack, and workflow preferences+- **[[MY-INTERESTS]]** - Topics for your daily briefs+- **[[MY-INTEGRATIONS]]** - Your active and disabled integrations+- **[[03-professional/COMPETITIVE-WATCHLIST]]** - Companies you're tracking *(if applicable)*++**You can edit these files anytime.** COG reads them when you use skills, so your changes take effect immediately.++## Skills for Your Role++[If role pack was matched:]+As a **[Role Display Name]**, these skills are ordered by relevance for you:++[List skills from role pack in order, with brief "why it matters" from the role pack. Format as:]+1. **[skill-name]** — [Role-specific explanation]+2. **[skill-name]** — [Role-specific explanation]+[...continue for all recommended skills]++[If no role pack match:]+Here are COG's core skills available to everyone:++1. **daily-brief** — Personalized news intelligence+2. **braindump** — Capture and classify thoughts+3. **weekly-checkin** — Weekly pattern analysis+4. **knowledge-consolidation** — Build frameworks from scattered notes+5. **url-dump** — Save URLs with auto-extracted insights+6. **update-cog** — Keep COG framework current++## Your Integrations++[If integrations were configured:]+**Active**: [List active integrations]+**Disabled**: [List disabled integrations]++You can change these anytime by editing [[MY-INTEGRATIONS]].++[If no integrations configured:]+No integrations configured yet. COG works great standalone — add integrations anytime by editing `00-inbox/MY-INTEGRATIONS.md`.++## Quick Start++### 1. Daily Morning Routine+Invoke the daily-brief skill to get your personalized intelligence briefing covering:+[List their selected interest areas]++### 2. Capture Your Thoughts+Use the braindump skill to quickly capture ideas, insights, and thoughts. Your braindumps will automatically be categorized into:+[List their focus domains]++Choose from your active projects:+[List their projects with links]++### 3. Weekly Reflection+Every week, use the weekly-checkin skill to review your week's insights and patterns.++## Your Active Projects++[If they have projects]+You're tracking these projects:+- [[04-projects/[slug]/PROJECT-OVERVIEW|Project 1]]+- [[04-projects/[slug]/PROJECT-OVERVIEW|Project 2]]++When you use the braindump skill, select the project to automatically file your thoughts in the right place.++## How COG Uses Your Profile++**Daily Briefs**: Uses [[MY-INTERESTS]] to curate relevant news+**Braindumps**: Offers your projects from [[MY-PROFILE]] as options+**Competitive Intel**: Auto-extracts mentions of companies in [[COMPETITIVE-WATCHLIST]]+**Weekly Check-ins**: Reviews progress across your domains++## Next Steps++1. **Try your first braindump**: Use the braindump skill and start writing+2. **Get your daily brief**: Invoke the daily-brief skill to see curated intelligence+3. **Explore your vault**: All your files are organized in the sidebar+4. **Edit your profile**: Open [[MY-PROFILE]] and customize anytime++## Keeping COG Updated++COG separates your content from framework files. When new versions are released:+- Run `/update-cog` to check for and apply updates+- Or use the shell script: `./cog-update.sh --check`+- Your braindumps, profiles, and notes are **never** touched by updates++Check your current version: `cat COG-VERSION`++## Tips for Success++- **Don't overthink it**: Just dump your thoughts, COG will help organize+- **Be consistent**: Daily briefs and braindumps work best as habits+- **Review weekly**: Use the weekly-checkin skill to see patterns emerge+- **Evolve your setup**: Edit your profile files anytime or run onboarding again to add projects+- **Stay updated**: Run `/update-cog` periodically to get new skills and improvements++## Getting Help++- Check `SETUP.md` for detailed guides+- Visit the GitHub repo for documentation++**Your second brain is learning about you. Let's begin!**++---++*You can archive or delete this welcome guide once you're comfortable with COG.*+```++### 9. Wrap-Up (No Menu!)+After setup, summarize what was created and suggest a natural next action:++```+You're all set! I've created your profile, interests, and project files. Everything is in your vault and editable anytime.++If you want to jump right in, try a braindump - just tell me what's on your mind and I'll capture it. Or ask for your daily brief to see what's happening in your interest areas today.+```++**Don't present a numbered menu of next actions.** Just suggest one or two natural things and let them decide.++## Configuration Update Mode++If user runs onboarding after initial setup (MY-PROFILE.md exists):++Don't show a menu. Just ask:+```+You've already completed onboarding! What would you like to update? Just tell me what needs changing.+```++Then intelligently handle whatever they say - whether it's adding projects, changing interests, updating their role, etc.++## Success Criteria++Onboarding is successful when:+1. `MY-PROFILE.md` created in `00-inbox/` with `role_pack` in frontmatter+2. `MY-INTERESTS.md` created in `00-inbox/`+3. `MY-INTEGRATIONS.md` created in `00-inbox/` with active/disabled sections+4. Role pack matched (or set to `custom`) and recommendations presented+5. Project directories and overviews created (if applicable)+6. `WELCOME-TO-COG.md` guide created with role-specific skill ordering+7. User understands next steps and where their profile is stored++## Error Handling++**If profile already exists:**+- Don't overwrite, offer update mode instead+- Preserve existing content, only append/modify requested sections+- Archive old version to `00-inbox/archive/MY-PROFILE-YYYY-MM-DD.md` if starting fresh++**If directory creation fails:**+- Report which directories couldn't be created+- Provide manual creation instructions+- Continue with rest of setup++**If user exits mid-onboarding:**+- Create partial profile with note: "Onboarding incomplete - run onboarding skill to finish"+- Save what was collected so far+- Resume from last completed step on next run++## Privacy & Data++All configuration data is stored as markdown files in:+- `00-inbox/MY-PROFILE.md` - Basic profile with role pack+- `00-inbox/MY-INTERESTS.md` - Interest areas+- `00-inbox/MY-INTEGRATIONS.md` - Active/disabled external service integrations+- `03-professional/COMPETITIVE-WATCHLIST.md` - Competitive tracking+- `04-projects/[project]/PROJECT-OVERVIEW.md` - Project details++Benefits of markdown storage:+- Human-readable and editable+- Version controlled with Git+- Searchable in Obsidian+- Linkable from other notes+- No parsing required, just read as text+- Can be archived, moved, organized like any other note++## Philosophy++COG's configuration is **knowledge, not configuration**. By storing preferences as markdown notes:+- They're part of your knowledge base, not hidden config files+- You can link to them, reference them, evolve them+- They have context and can include your own notes+- They're transparent and auditable+- They benefit from all of Obsidian's features (tags, links, search, graph view)++This is "configuration as knowledge" - your preferences are themselves notes in your second brain.diff --git a/skills/product-ui-taste/SKILL.md b/skills/product-ui-taste/SKILL.mdnew file mode 100644index 0000000..c5b5926--- /dev/null+++ b/skills/product-ui-taste/SKILL.md@@ -0,0 +1,653 @@+---+name: product-ui-taste+description: Anti-slop skill for PRODUCT UI - dashboards, data tables, forms, multi-step flows, settings, list/detail, app shells. The agent reads the surface, budgets the frame first, and ships dense interfaces that are correct at every edge case (overflow, long labels, empty/error/loading states, i18n expansion, keyboard/a11y). House-system-first; maps to Carbon/Polaris/Atlaskit/Fluent/Primer/Material3/Radix-shadcn/Ant. The counterpart to taste-skill, which owns landing/portfolio/marketing.+---++# product-ui-taste: Anti-Slop Skill for Dense Product Surfaces++> Dashboards, data tables, forms, wizards, settings, list/detail, admin consoles, app shells. NOT landing pages, portfolios, or marketing (that is `taste-skill`). NOT charts (that is `dataviz`). NOT native mobile.+> Every rule is **contextual and mechanical**. It fires from the surface you are building, not automatically. Read the surface, budget the frame, then pull only what fits.+> **Companion contract:** `taste-skill` explicitly hands off "dashboards / dense product UI / data tables / multi-step forms" to "the right tool." This skill is that tool. If a brief is half marketing and half product (a landing page with an embedded live dashboard), use `taste-skill` for the hero/marketing sections and this skill for the product surface. Never run both on the same component.++---++## 0. PRODUCT READ (Read the Surface Before Anything Else)++Marketing UI lives on first impression. Product UI lives on the **hundredth** use, under real data, by someone doing a job. The slop failure mode is different: not "templated aesthetic," but **prototype that dies on contact with real data** - a table that scrolls the whole page sideways, a button that truncates its own label, a single grey "no data" box reused for three different situations, a form that clears itself when the user fat-fingers one field.++### 0.A Read these signals first+1. **Surface type** - the single most important read. One of: **index/table** (list of records to scan, filter, select), **detail/record** (one entity, its fields and related data), **dashboard/overview** (KPIs + widgets + a table or two), **form/settings** (input and configuration), **multi-step flow/wizard** (a sequential task), **console/observability** (logs, metrics, deploys), **feed/messaging** (stream of items). Most real screens are a composition of two or three (index + detail drawer; dashboard + drill-in table).+2. **Data shape and volume** - how many rows at p95, how wide is a row, are cells uniform or ragged, is the data live/streaming or static, can a field be empty/null/very-long.+3. **Density need** - a trader's cockpit and a consumer settings page are both "product UI" and want opposite densities. Read: expert-daily-driver (compact, keyboard-first) vs. occasional-consumer (comfortable, forgiving).+4. **Consequence level** - is the primary action informational (view), reversible (rename, move), or destructive/irreversible (delete, deploy, charge a card). This drives confirmation, focus defaults, and autosave eligibility.+5. **Who is the user and what are they permitted to do** - roles, read-only viewers, plan/license tiers. Product UI has states marketing UI never has: permission-denied, read-only, plan-locked (Section 6.G). Read this now, not after building the happy path.+6. **Existing system** - is there already a Carbon/Fluent/Polaris/Atlaskit app, or a house token set? Product UI is almost never greenfield. Match the host system before importing taste.++### 0.B Output a one-line "Product Read" before generating+Before any code, state: **"Reading this as: a \<surface type> for \<user> at \<density>, \<data volume>, consequence \<level>, built on \<design system | house tokens | none>."**++Examples:+- *"Reading this as: an index+detail-drawer for internal ops at compact density, ~2k rows (virtualize), consequence reversible, built on the house system (Table + side-panel inspector)."*+- *"Reading this as: a settings/form surface for end customers at comfortable density, low volume, consequence mixed (billing = destructive), built on the house system's form layout."*++### 0.C The anti-default that matters most: rows, not cards+The single fastest way to make a product screen look like an AI prototype is to **wrap every record in a Card with a Badge**. Dense data that the user scans, filters, sorts, or selects belongs in **rows** (Table for columnar, List/Item for single-line), edge-to-edge, with dividers and 32-40px row height. Card is a **widget container** (KPI tile, chart panel, settings group, gallery entry), never a list-item wrapper. [Material3 lists; Carbon] If your first instinct on a list of records is a Card grid, stop and re-read this line.++### 0.D If the brief is ambiguous, ask ONE question, then proceed+The one question worth asking is almost always about **data volume or consequence** (they change the architecture): "roughly how many rows at the high end?" or "is this action reversible?" Everything else, infer from the Product Read and state your assumption. Do not interview.++### 0.E Anti-default discipline+The model's defaults for product UI are: Card-soup, fixed-width `<table>` that overflows the page, `disabled` submit button as the only validation, one generic empty state, `z-index: 9999`, and a full-page spinner on every load. Each has a specific correct replacement below. When you catch yourself reaching for one, that is the signal to open the matching section.++---++## 1. THE THREE DIALS (Core Configuration)++After the Product Read, set three dials. Unlike taste-skill (VARIANCE / MOTION / DENSITY tuned for expressive marketing), product dials are tuned for **information work**. Motion is deliberately near-absent in product UI; it is feedback, not decoration.++* **`DENSITY: 2`** - 1 = comfortable/consumer, 2 = standard, 3 = compact/cockpit. Drives row height, padding scale, font size, and whether you offer a density switcher.+* **`DATA_COMPLEXITY: 2`** - 1 = simple list (plain Table/List), 2 = sortable+filterable+selectable table, 3 = enterprise grid (frozen columns, virtualization, column management, live data).+* **`CONSEQUENCE: 2`** - 1 = informational/read, 2 = reversible mutations, 3 = destructive/irreversible/financial. Drives confirmation defaults, autosave eligibility, error tone, and how loud "unsaved changes" gets.++**Baseline: `2 / 2 / 2`** (a standard SaaS product table with a detail view). Override from the Product Read.++### 1.A Dial inference+| Signal | DENSITY | DATA_COMPLEXITY | CONSEQUENCE |+|---|---|---|---|+| "internal admin / ops tool / expert daily driver" | 3 | 2-3 | 2 |+| "enterprise data console / grid / analytics" | 3 | 3 | 2 |+| "consumer settings / account / onboarding" | 1 | 1 | 1-2 |+| "SaaS product dashboard (default)" | 2 | 2 | 2 |+| "billing / delete / deploy / permissions surface" | match | match | 3 |+| "observability / logs / live metrics" | 3 | 3 | 1 |++### 1.B Use-case presets+| Preset | DENSITY | DATA_COMPLEXITY | CONSEQUENCE | Frame |+|---|---|---|---|---|+| Internal admin tool | 3 | 2 | 2 | AppShell + SideNav, inspector on select |+| SaaS product dashboard | 2 | 2 | 2 | AppShell + SideNav or TopNav + TabList |+| Enterprise data console | 3 | 3 | 2 | AppShell + SideNav, full-height grid |+| Consumer settings/account | 1 | 1 | 1-2 | AppShell + settings template (nav + form panels) |+| Multi-step wizard | 1 | 1 | 2-3 | Centered column, stepper, no distracting chrome |++### 1.C How the dials drive output+Use these exact names as global variables in reasoning. `DENSITY` gates row height and the density-switcher decision (Section 10.A). `DATA_COMPLEXITY` gates how far down the table deep-dive (Section 7) you go. `CONSEQUENCE` gates Sections 6.G, 8.E, 8.F, 9.A. Do not invent aliases.++---++## 2. PRODUCT ARCHETYPE → DESIGN SYSTEM MAP++Product UI is almost never hand-rolled CSS. Pick the foundation from the host app first, the archetype second. **One system per app.** Do not mix Carbon with Fluent, or drop shadcn into a Polaris tree.++### 2.A House system first (discover, do not guess)+If the app already has a design system, that system wins, and your first job is to **find out what it actually ships** rather than assuming. Most mature systems already solve the dense-surface problems this skill is about, so you rarely drop to raw CSS. Guessing at component names and props is the single most common way an agent produces code that looks right and does not compile.++Before writing UI, resolve each of these against the host system's real API (its CLI, its docs site, or its `.d.ts` files):++| Need | What to look for | How to resolve it |+|---|---|---|+| Full-page shell | An app-shell primitive plus its nav slots | System docs "layout" or "app shell" page |+| Multi-pane tool / inspector | A layout + side-panel pair, not two floated divs | Docs "layout" page; check whether the panel is resizable |+| Columnar data | The system's Table and its sort/select/pagination plugins | Component reference, not a blog example |+| Sticky / frozen columns | A dedicated hook or plugin (most systems ship one) | Search the docs for "sticky" or "frozen" before hand-rolling |+| Resizable columns | A column-resize hook | Same |+| Pagination footer | Table pagination + page-size control | Component reference |+| Search + filter toolbar | A toolbar/filter component distinct from plain search | Component reference |+| Single-line records | A List / Item pair | Component reference |+| Empty region | An EmptyState component | Component reference |+| Status / metadata | A status indicator distinct from Badge | Token/status docs |++**Workflow, always:** find the closest page or block template the system already ships, study its layout skeleton, then read the real props for every component you use. **Never invent props.** Prefer the system's own layout components over raw `<div>`s so spacing stays on the system's scale. Use design tokens for every value (`var(--color-*)`, spacing tokens), never raw hex or px. Reserve Badge for counts and enumerated states; status belongs on a status indicator.++**The house-system bridge (resolve the tension):** the CSS mechanics in Sections 5-10 (scroll ownership, `position:sticky` headers, frozen-column offsets, z-index tiers, `min-width:0`) are the **contract a mature system's hooks already satisfy** under the hood. Inside such a system, reach for the hook or plugin first, because a real sticky-column hook gives you the offset, the solid background, and the shadow divider correctly. Drop to the raw CSS contract only (a) to verify the system did it right when something bleeds through, or (b) when you are outside a design system entirely. Never hand-roll a sticky column with inline styles inside a system Table when the hook exists.++### 2.B External systems (match the host, or pick by archetype)+| Archetype / brief | Reach for | Why |+|---|---|---|+| IBM-style enterprise analytics, dense grids | `@carbon/react` + `@carbon/styles` | Most mature data-density + 2x-grid + empty/loading patterns [carbon] |+| Microsoft / enterprise SaaS, DataGrid | `@fluentui/react-components` (v9) | Official Fluent 2, Overflow primitives, tokens [fluent] |+| Atlassian / Jira-style product | `@atlaskit/*` + `@atlaskit/tokens` | Semantic spacing tokens chosen by meaning [atlaskit] |+| Merchant/admin, resource lists | Polaris (`@shopify/polaris` or web components) | IndexTable, four-states philosophy, error content [polaris] |+| GitHub-style devtool chrome | `@primer/react` / `@primer/css` | PageLayout landmarks, Blankslate, Truncate [primer] |+| Adaptive/canonical layouts, consumer-ish | `@material/web` + Material 3 tokens | Window-size classes, list-detail/supporting-pane [material3] |+| Own-the-code lean internal tool | Radix Primitives + shadcn/ui + TanStack Table | Headless a11y primitives, you own styling [radix, tanstack] |+| Enterprise React data-dense fast | Ant Design or Mantine + Mantine React Table | Batteries-included Table/Form [ant, mantine] |+| Lean keyboard-first (Linear/Vercel vibe) | Radix/shadcn + custom tokens | Density + command palette + restraint [linear, vercel] |++**Honesty rule:** if the app is one of these, use the official package and its Table/Form/Dialog. Do not recreate Carbon's data table in raw CSS. Do not import a system's tokens then override 90% of them.++---++## 3. FRAME-FIRST APP-SHELL ARCHITECTURE++**Budget the frame in pixels before writing one line of content.** Real applications are built top-down: pick the shell, name its regions, give each an explicit px budget, decide its container policy and responsive behavior, then fill. Content-first layout (write sections, wrap each in a Card) produces a padded scroll column that reads as a prototype. [most systems' layout docs]++### 3.A Pick the shell+- **AppShell** (header and/or side nav) - the default full-page product frame.+- **Layout + LayoutContent + LayoutPanel** - multi-pane tools: explorers, consoles, master-detail with an inspector.+- **Plain content column** - a single form, a settings section, a wizard.++### 3.B Region px budgets (memorize these)+| Region | Budget |+|---|---|+| Side nav | 240-280px |+| Icon rail (collapsed nav) | 64-72px |+| Detail / inspector panel | 340-420px (resizable 320-480) |+| Filter / facet rail | 220-260px |+| Row height | 32px compact / 40px standard / 48px comfortable [dense systems budget 32-40; Carbon ships 5 relative tiers, no fixed px] |+| Header / top nav | 48-64px (common app-bar convention) |++### 3.C Landmark regions (do not conflate them)+Name every region with a real landmark and know the difference [primer PageLayout]:+- **Header** - full width, top, app chrome.+- **Content** - the primary region, flexes to fill.+- **Pane** - a secondary region **beside** Content, content-height only. Use for an inspector or supporting info.+- **Sidebar** - **full-height** navigation, distinct from Pane. Never build a "sidebar" that is really a content-height pane, or a "pane" that is really full-height nav.+- **Footer** - full width, bottom (status bar, pagination context).++### 3.D Canonical layouts (recognize and scaffold) [material3]+- **List-detail** - list on the left, selected record on the right. Below ~1024px, detail overlays or becomes a separate route.+- **Supporting-pane** - primary content ~2/3, supporting pane ~1/3.+- **Feed** - a single scrolling stream (rows/bubbles, no cards in the stream).+- **Master-detail with inspector** (the tool backbone) - selecting a row opens a **fixed-width LayoutPanel inspector**, it does not navigate away. Add `resizable`. Overlay it below ~1024px instead of compressing Content.++### 3.E App-shell chrome that marketing UI never has+- **Workspace / org switcher** - almost every SaaS shell needs one, anchored top of the side nav or header-left, showing the current tenant's name/avatar. On click, a dropdown (not a modal) lists workspaces with a search field once there are 8+, a "recent workspaces" group, and a "create/join" action at the bottom. It switches context (data scope), it is not a nav destination. Keep it one element; never scatter tenant choice into the nav list. Persist the last-active workspace per user.+- **Global command palette** (Cmd/Ctrl-K) - for DATA_COMPLEXITY >= 2 keyboard-first tools, this is the fastest navigation. Recognize it as a first-class shell affordance, not a nice-to-have.+- **Background-job / async status tray** - when the app kicks off concurrent long-running operations (imports, exports, deploys), a persistent notification tray (a header icon with a count badge opening a dropdown of jobs) beats a modal per job. Each job row shows a determinate progress bar, a cancel affordance, and terminal success/error with a result link. Carbon's rule: for waits over a few minutes, let the user leave and notify on completion. Never block the whole UI on one background job. [carbon loading]++### 3.F Container policy per region (Cards vs Rows, decided per archetype)+| Archetype | Container policy |+|---|---|+| Tracker / work tool (issues, tickets, CRM) | Rows only. Grouped edge-to-edge lists, zero cards. |+| Console / observability | Card grid for dashboard widgets; Table for everything else. |+| Messaging / feed | Rows and bubbles. No cards in the stream. |+| Media / gallery | Card grid (ClickableCard) + dense metadata rows in detail. |+| Settings / forms | FormLayout sections; Card only to group dangerous/billing actions. |++Banned: a Card per list item (card soup), stacked full-width Cards as page structure, nested Cards, Badge as decoration.++---++## 4. LAYOUT HARD RULES (Failing any of these ships broken work)++* **SCROLL OWNERSHIP (the #1 product-UI layout bug).** Exactly **one** wrapper owns each scroll axis (`overflow:auto`). The page `<body>` must **never** scroll horizontally. A wide table scrolls inside its own container, not by pushing the whole app sideways. Sticky headers use `position:sticky` scoped to that scroll wrapper, **never** `position:fixed` to the viewport. [carbon, ant table-scroll, tanstack] If two nested elements both scroll the same axis, you have a bug.+* **Every sticky element needs a bounded-height ancestor.** `position:sticky` silently does nothing if no ancestor establishes a scroll boundary. A sticky table header requires the table's scroll container to have a real max-height. [css mechanics]+* **min-width:0 on flex children that hold text.** A flex/grid child defaults to `min-width:auto`, which refuses to shrink below content size, so `text-overflow:ellipsis` silently no-ops and the child pushes the layout wider instead. Any truncating text inside a flex row needs `min-width:0` on the text-holding child. This is the most common reason "my ellipsis isn't working." [overflow-truncation]+* **Responsive contract declared up front, per region.** Before filling, write which regions collapse, overlay, or drop at which breakpoints. No "Tailwind will handle it" assumptions. Nav collapses to an icon rail or off-canvas MobileNav; the inspector overlays below ~1024px; a wide table keeps horizontal scroll rather than reflowing columns.+* **Breakpoints: use size classes, not device names.** Compact / medium / expanded (Material 3) or Carbon's exact 2x-grid breakpoints (320 / 672 / 1056 / 1312 / 1584, 8px mini-unit, 16px padding, 32px gutter) as a fallback grid. [material3, carbon 2x-grid]+* **Container queries for reusable components.** A card or panel that appears in a wide Content region and a narrow Pane must respond to **its own** width, not the viewport. Use `container-type` + `@container`, not viewport media queries, for anything that renders in more than one region width. [joshwcomeau, responsive-layout]+* **Sidebar collapse = off-canvas or icon-rail, not in-place shrink.** Collapsing a 260px nav to 180px just cramps it. Collapse to a 64-72px icon rail (with tooltips) or slide it off-canvas with a persistent reopen strip. Persist which panes were shown across a resize/fold so the user does not lose context.+* **Density is a layout MODE, not a CSS zoom.** Offer at least the density presets the DENSITY dial calls for as a real switch (row height + padding token swap), not a browser-zoom hack. [i18n-a11y-density, carbon 5 row heights]+* **Never hardcode a fixed width on a text container.** Badges, buttons, table headers, chips, tags must be auto-layout (flex/grid, hug-contents) so text can reflow or expand. A fixed-width text container clips under real data and under translation (Section 10.B).+* **Tabular numbers for compared numbers.** Any column or list of numbers the user compares vertically uses `font-variant-numeric: tabular-nums` so digits align. Proportional digits in a metrics column is a Tell.++---++## 5. OVERFLOW & TRUNCATION CATALOG (Deep-Dive)++Product UI is where real strings arrive: a 90-character file path, a German button label, a customer name that is one word or forty. Truncation is a scalpel, not a default.++### 5.A The never-truncate list (mandatory)+**Never truncate primary/identifying content**: titles, entity names, unique IDs, error and validation messages, page headers, button labels. Truncation is for **secondary/supplementary** content only (descriptions, secondary metadata, breadcrumb middles). [carbon overflow, primer truncate] If an identifying string is too long, wrap it, give it more space, or use middle-truncation that preserves both ends (for paths/IDs) - never a trailing ellipsis that hides the part that distinguishes two records.++### 5.B Every truncated string needs a real full-text fallback+A hover-only `title` tooltip is **not** an accessible fallback: it fails keyboard-only users, touch users, and speech-recognition users. Provide the full text on focus as well as hover, or expandable inline, or in the detail view. [carbon, primer]++### 5.C Long button labels (mandatory, a signature product-UI Tell)+**Never truncate a button label.** Size the button to its content ("hug contents") with a `min-width` floor for tap-target accessibility. If the label is long (or translated), wrap to at most 2 lines before you ever truncate, and re-evaluate the label copy. A button reading "Save chang..." is broken work. Icon-only buttons need an `aria-label` and a tooltip. [overflow-truncation, i18n]++### 5.D Single-line ellipsis recipe+`overflow:hidden; text-overflow:ellipsis; white-space:nowrap;` **plus** `min-width:0` on every flex ancestor between the text and the scroll/row container (Section 4). Without the `min-width:0` chain, the CSS is inert.++### 5.E Multi-line clamp recipe (`-webkit-line-clamp`)+All four properties together or none work: `display:-webkit-box; -webkit-line-clamp:N; -webkit-box-orient:vertical; overflow:hidden;`. **Never put padding on the clamped element itself** - the clamp math ignores padding and text bleeds. If you need padding, wrap the clamp in a padded parent, or use a fixed-height fallback (`line-height * N`). [css-tricks line-clampin]++### 5.F Content edge cases: counts, big numbers, missing data (mandatory)+Real data is 0, 1, or 1,000,000 - design all three, not just the demo's "3."+- **Zero / one / many (pluralization):** every count string handles 0, 1, and N with correct grammar - "0 items," "1 item," "24 items," never "1 items" or "24 item." Use an ICU/plural-aware formatter, never string concatenation; some languages have up to 6 plural forms. The zero case usually routes to an empty state (Section 6.C), not "0 items" sitting in a full layout.+- **Very large / very precise numbers:** abbreviate for scannability in dense contexts (1.2k, 3.4M, 1.1B) but keep the exact value reachable on hover/focus and in the detail view; **never abbreviate a number the user must act on precisely** (an invoice total, an account balance). Locale-aware grouping (1,234.56 vs 1.234,56), tabular-nums for compared columns (Section 4), and a consistent threshold before switching to abbreviation.+- **Missing / null / not-applicable (general rule, not just table cells):** a null field renders a consistent, quiet placeholder ("Not set," "-," "Unknown") that is visually distinct from an empty string and from zero. Decide per field whether null means "not set yet" (invite input), "not applicable" (explain briefly), or "hidden by permission" (Section 6.G) - three different placeholders, never one blank that reads as a render bug.+- **Long unbroken tokens** (URLs, hashes, file paths, IDs with no spaces): use middle-truncation that keeps both ends, or `overflow-wrap:anywhere`, never a trailing ellipsis that hides the distinguishing tail, and never let the token blow out its column width.++### 5.G Column-header and chrome overflow+- **Column headers**: wrap to 2 lines, then truncate with a tooltip carrying the full header. [carbon]+- **Breadcrumbs**: collapse the middle to an ellipsis/overflow-menu, keep first and last. [carbon overflow]+- **Toolbars / action bars / tabs**: use priority-plus overflow (Fluent Overflow): declare a visible-priority order and a `minimumVisible` floor, move the rest into a "More" menu, render in reverse DOM order so the first item wins. [fluent]+- **Long free content blocks**: "Show more / Show less" for expandable prose, "Load more" for lists (Section 7.D).++---++## 6. STATE MATRIX (Deep-Dive)++Every data surface has more than a happy path. Design the full matrix at **three granularities**: page, component/region, and field. The slop failure is reusing one grey box for every non-happy state.++### 6.A The four base states, always designed together+For any region that loads data, design **ideal / loading / empty / error** before you ship the ideal. [polaris four-states, nngroup]++### 6.B Loading timing thresholds (mandatory)+- **< 1s**: show nothing. A flash-and-vanish skeleton is worse than a beat of stillness.+- **1-10s, full-page/region load**: a **skeleton that mirrors the real layout shape** (the actual rows/fields it will become), never a frame-only grey box, never a spinner for structured content. [nngroup skeleton, carbon loading]+- **> 10s, or unknown-length work** (uploads, downloads, conversions, deploys): a **determinate progress bar**, never an indeterminate spinner or skeleton. For multi-minute work, let the user leave and notify on done. [carbon]+- **Background refresh of already-shown data**: keep the old content visible with a subtle inline indicator. **Never re-blank** cached content to a spinner/skeleton on refresh.++### 6.C Empty states are three distinct states (mandatory)+Never reuse one empty component/message across these:+1. **Never-used-yet (first run)** - onboarding tone: what this is + a primary CTA to create the first record. [primer empty-states, pencilandpaper]+2. **Filtered/searched to nothing** - "no results for X," with a clear-filters action. The data exists; the filter is the cause.+3. **Zero-as-a-win** - "inbox zero," "no alerts." Positive tone, no guilt CTA.+[carbon empty-states, atlaskit empty-state] For tiny tiles/side-panels, a centered text-only empty state is the exception to "mirror the layout."++### 6.D Error states are never empty states+A load failure is **always** an ErrorState, never an EmptyState. Error copy is specific, plain-language, actionable (what to do next), and carries an error code/id for support. Route all of them through one shared ErrorState component so tone and layout stay consistent; never ship a bare "An error occurred." [polaris error-messages, nngroup]++### 6.E Field and inline states+Fields have their own micro-states: pending async validation (Section 8.D), inline error, success confirmation, saving/saved (autosave, Section 8.E). Do not let a field-level failure silently no-op.++### 6.F Partial, stale, and offline states (mandatory to consider)+Between "loaded" and "failed" live the states real networks produce:+- **Partial load / partial failure:** when a composite view loads and one widget fails, fail **that widget in place** (its own inline ErrorState + retry), never blank the whole page for one failed panel. A dashboard where one broken tile kills every tile is a bug.+- **Stale / cached / refreshing:** show last-known-good data with a subtle "updating" indicator and a "last updated <time>" stamp; never re-blank to a skeleton on a background refresh (Section 6.B). On refresh failure, keep the stale data and surface a non-blocking "couldn't refresh, showing data from <time>" notice.+- **Offline / disconnected:** detect connection loss, show a persistent non-modal banner, disable or **queue** mutations, and reconcile on reconnect. Never let a user type into a form that silently cannot save.+- **Optimistic update contract:** if you render a mutation before the server confirms, you MUST have a rollback path - restore the prior value and show a clear error if the write fails. An optimistic update with no rollback is a data-integrity Tell.++### 6.G Permission and plan states (product-UI-only, mandatory to consider)+Marketing UI has no concept of these; product UI lives on them:+- **Permission-denied / role-gated**: decide **disabled vs. hidden** deliberately. Hide an action the user can never have; disable (with a reason on hover/focus) an action they could have with a role change. Never show a dead control with no explanation.+- **Read-only mode**: present the same layout with inputs rendered as static values and a clear "read-only" affordance, not greyed-out inputs that look broken.+- **Plan/license-locked**: a locked-feature affordance ("Upgrade to unlock") is a distinct state with its own component - visible, explained, with an upgrade path - not a disabled button. [Keep it consistent with whatever precedent the host app already sets.]++---++## 7. DATA TABLE DEEP-DIVE (The Hardest Product Surface)++Gate depth by DATA_COMPLEXITY. A simple list needs 7.A-7.B; an enterprise grid needs all of it. **Inside a design system, use its `Table` plus the system's plugins/hooks; the mechanics below are the contract those hooks satisfy, and your guide when you are outside one.**++### 7.A Scroll ownership and sticky header (mandatory)+One wrapper owns both axes (`overflow:auto`) with a bounded height; the page never scrolls sideways (Section 4). Sticky header via `position:sticky; top:0` **scoped to that wrapper**. [carbon, ant table-scroll]++### 7.B Frozen / pinned columns (mandatory recipe)+`position:sticky` + explicit `left:0` (or `right:0`) offset + `z-index >= 10` (above the scrolling body) + a **solid, non-transparent background that also covers hover and selected-row states** + an **inset `box-shadow` divider, never a CSS `border`** (borders disappear or double-render under sticky scroll). Miss the solid background and the scrolling content bleeds through the frozen column. [ant, mantine-react-table column-pinning, tanstack]++### 7.C Virtualization (DATA_COMPLEXITY 3)+Virtualize past ~100-200 rows. Required DOM shape: **two wrappers** - outer = viewport-height scrollable, inner = full virtual-content height (a spacer). **Never size the `<table>` element itself to the full virtual height** - it distorts row heights and collapses the sticky header (which cannot escape a too-short parent). [tanstack virtual #640] Do not attach per-row style objects or per-row menu instances during virtual render (perf death); use `columnResizeMode:"onEnd"` unless memoized. [ant, mantine]++### 7.D Pagination vs. infinite scroll vs. load-more (decision tree)+- **Paginate** once an index exceeds ~50 items (concrete Polaris cutoff), and always for "find a specific item / compare distant items / inspect the top few" tasks. [polaris, smashingmagazine]+- **Infinite scroll**: only for exploratory, homogeneous, endless feeds - **never** for search results or comparison tasks. If used, ship `history.pushState()` so the back button restores scroll position (>90% of implementations get this wrong). On mobile, load one larger flat batch (15-30 items), never chunk-lazy-load mid-scroll (fetches during active scroll are unreliable). [nngroup infinite-scrolling, baymard]+- **Load-more button**: the safe middle for finite-but-long lists; user controls the fetch.++### 7.E Selection, bulk actions, and selection persistence+- Row selection supports Shift-click range and select-all. Distinguish "select all N (across pages)" from "select all on this page" in copy. [polaris]+- **Selection persistence (a classic enterprise correctness bug):** preserve selected-row **IDs** across pagination, sort, and filter changes; do not silently drop the selection when the page changes. Show a running "N selected" count that survives navigation.+- During an active bulk operation, disable per-row actions to prevent conflicting mutations.+- **Toolbar action cap: 5 visible primary actions**, then overflow to a menu. [polaris]++### 7.F Filtering, faceting, and search (distinct from each other)+- **Search** (free text) and **filter** (structured predicates) are different controls; do not merge them into one box silently. Match each filter control to its data type (date range, enum multi-select, numeric range). [data-table-mechanics; most systems ship a toolbar-filter component]+- **Applied-filter chips**: show active filters as a removable chip row above the table with a "Clear all," plus (for many facets) a faceted sidebar. This is the now-standard Jira/Linear/Notion pattern; without the chip row the user cannot see or undo what is filtering their data.++### 7.G Cell content+Cells hold ragged real data. Truncate secondary cells per Section 5 (with focus-reachable full text), never identifying cells. Right-align numeric columns and use tabular-nums (Section 4). Empty cell = a consistent "not set" placeholder (an em-dash is banned; use "-" or "Not set"), never a blank that looks like a render bug.++---++## 8. FORMS, VALIDATION & MULTI-STEP FLOWS (Deep-Dive)++### 8.A Label placement+Top-aligned labels by default (fastest to scan, best for localization and mobile). Right-aligned labels only for dense enterprise forms where vertical space is scarce. Left-aligned only to deliberately slow the user down on a careful task. Never right-align labels on a localized product (expansion breaks the column). [lukew web-form, nngroup web-form-design]++### 8.B Validation timing+Validate on **blur** and on **submit**, not on every keystroke of an incomplete value (do not scream "invalid email" at the first character). The exception is a live positive helper like password-strength. Show inline errors next to the field **and** an aggregate error summary at the top on submit, never only one of the two. [nngroup errors-forms, polaris inline-error]++### 8.C Never disable Submit as the only signal (mandatory)+For forms with 5+ fields, **never** make a disabled Submit the only feedback - the user cannot tell what is missing. Let them submit, then show the aggregate error count and focus the first error. A disabled Submit is acceptable only on trivial (<3 field) forms. **Always preserve user input after a failed submit** - never clear the form. [forms-flows, nngroup]++### 8.D Async / remote field validation+Debounce it, **and** cancel superseded requests with `AbortSignal` - an uncancelled slow response can overwrite a newer, correct result (username-availability race). [forms-flows]++### 8.E Autosave (gate by CONSEQUENCE)+- Autosave **per logical field-group**, never whole-form-on-every-keystroke.+- **Never autosave** password, visibility/permission, confidentiality, or financial-impact fields - those require explicit manual confirm (CONSEQUENCE 3).+- Trigger on blur + ~3s after the last keystroke. Show "Saving..." then "Saved <relative time>."+- A failed autosave gets a **persistent** (non-auto-dismissing) toast with retry, never a silent failure.++### 8.F Multi-step flows / wizards+- The step indicator must map to the **real** steps; completed steps are clickable to go back. No fake "Stage 1 / Stage 2" labels - name the actual step. [taste-skill tell parity]+- Fix wizard abandonment by cutting **field count**, not by adding steps. Do not inject mid-flow upsells. [baymard checkout-linear]+- Keep the flow linear; a branching wizard needs a visible map.++### 8.G Destructive / irreversible confirmation (CONSEQUENCE 3, mandatory)+Confirmation dialogs for delete/deploy/charge **default keyboard focus to the safe action (Cancel)**, not the destructive one. Use `role="alertdialog"`, `aria-modal="true"`, and `aria-describedby` pointing at the warning text. For high-consequence deletes, require typing the resource name to enable the destructive button. On close, return focus to the element that opened the dialog (or the next logical element). [w3 alertdialog, radix dialog]++---++## 9. NAVIGATION, OVERLAYS & LAYERING (Deep-Dive)++### 9.A Dialogs / modals+Focus-trap while open, return focus on close, close on Escape, close on overlay click only when non-destructive. `Dialog.Title` and `Dialog.Description` are **never omitted** even if visually hidden (screen readers announce them). [radix dialog, w3 dialog-modal]++### 9.B Toasts / notifications+Default ~5000ms, **pause on hover and focus**, swipe-dismiss threshold ~50px, dismissible manually. Distinguish foreground announcements (user's own action succeeded) from background ones (something changed) for screen-reader priority. Never put a destructive-confirm inside a toast. [radix toast]++### 9.C Menus, dropdowns, tabs, comboboxes+Full keyboard contract: arrow-key navigation, Home/End, type-ahead, roving tabindex (Section 10.D). Tab moves **between** a composite widget and the next content; arrows move **within** it. Menu/tab items that should stay keyboard-reachable use `aria-disabled`, not native `disabled` (which removes them from the tab order). [radix, w3 grid]++### 9.D The z-index / stacking-context system (mandatory, replaces ad-hoc z-index)+- **Assign wide numeric gaps per tier**, defined once as tokens, e.g. base 0, sticky 100, dropdown 1000, sticky-header 1050, overlay/drawer 1100, modal 1200, popover 1300, toast 1400, tooltip 1500. Never hand-tune a single z-index in isolation; change it against the whole scale. Ad-hoc `9999`/`99999` is a Tell.+- **Enumerate every stacking-context trigger** before debugging a layering bug: `position:fixed/sticky` with a z-index, `opacity < 1`, `transform` / `filter` / `will-change` naming a context property, `contain`, `container-type`, `isolation:isolate`, top-layer elements. [mdn stacking-context]+- **Nested stacking contexts are atomic**: a huge z-index on a deeply nested element **cannot** out-rank a shallow ancestor's sibling. If a menu clips behind a header, the fix is the ancestor context, not a bigger number.+- **Overlays layer by open-order**, not static per-type constants: the last-opened overlay wins. Use a layering manager / the platform top-layer (`<dialog>`, popover API) where available.++---++## 10. DENSITY, I18N & ACCESSIBILITY (Deep-Dive)++### 10.A Density as a first-class mode+Offer >= 3 density presets (comfortable / standard / compact) as a real switch that swaps row-height and padding tokens, not a scaled-down zoom. [i18n-a11y-density] Carbon ships 5 row heights; pick the set your DENSITY dial needs.++### 10.B Internationalization text-expansion budget (mandatory)+Design containers with headroom for translation, because English is one of the shortest UI languages:+- German: **+30-40%** typical, up to ~70% worst case.+- French / Russian / Spanish: +20-25%.+- Finnish: up to +100% (doubling).+- CJK: contracts, not expands.+Never hardcode fixed-width text containers (Section 4). Use flex/grid so text reflows instead of clipping. Pseudo-localization (wrap strings in accented padding) is a fast smoke test that catches ~80% of expansion bugs. [crowdin, i18n-a11y-density]++### 10.C RTL+Mirror **directional** icons only (back/forward arrows, chevrons, progress direction). **Never** mirror universal icons (clock, play, checkmark, logos). Numerals keep LTR shaping even inside RTL text. The primary action button moves to the left (the natural end of an RTL reading scan). Progress bars fill right-to-left. [crowdin]++### 10.D The ARIA grid keyboard contract (mandatory for any custom grid/table with focusable cells)+- **Roving tabindex**: exactly one cell has `tabindex="0"`, all others `-1`; the grid container itself is never a tab stop.+- Arrow keys move between cells, **boundary-clamped** (no wrap at row/column edges).+- **Home/End** move within the current row; **Ctrl+Home / Ctrl+End** jump to the grid's first/last cell.+- **Page Up/Down** only in scrollable grids (move ~5 rows).+[w3 grid data-grids] If you use a real design-system Table (Carbon, Fluent, Polaris, Ant), this is handled - do not reinvent it. Reach for the contract only when hand-building a grid.++### 10.E Cross-cutting a11y floors+- Touch targets >= 44-48px (touch), >= 24px (dense desktop). [material3 accessibility]+- `:focus-visible`, never a bare `:focus` that flashes on mouse click; never remove focus outlines without replacing them.+- Every icon-only control has an `aria-label`.+- Locale-aware number/date/currency formatting; never ship ambiguous `01/02/2025`.++---++## 11. ONBOARDING & PROGRESSIVE DISCLOSURE++Dense products overwhelm on first run. Reveal power progressively; earn complexity.++**Progressive disclosure (the default mechanic):**+- Keep advanced controls (bulk edit, column management, saved views, API/webhook config) one interaction away (a "More," an expander, a settings popover), not all on screen at once. Linear's principle: simple to start, grows more powerful. [linear]+- **Rule of thumb: >7 controls in a region is the disclosure trigger.** Group the primary 3-5 actions inline and overflow the rest; surface advanced settings behind a labeled expander, never a mystery-meat gear with no tooltip.+- Disclosure is per-surface, not global: do not hide a control the user just used two clicks ago.++**First-run (mandatory):**+- First run is the **"never-used" empty state** (Section 6.C.1), not a blank grid or a spinner. It states what this surface is in one line and points at the single first action ("Create your first project"), not a menu of ten.+- Seed with sample/demo data only if it is clearly labeled and one-click removable; never leave fake "Acme Inc" rows the user cannot tell from real data.++**Coach marks, tours, checklists (banned unless dismissible):**+- Any coach mark, product tour, or onboarding checklist MUST be skippable on step 1 and dismissible permanently; dismissal persists per user across sessions (never re-fire a dismissed tour). A tour that cannot be skipped, or a checklist with no close affordance, is a **Tell**.+- Max one active tour at a time; never stack a coach mark on top of a modal.+- Tours point at real controls in the real UI; never a fake highlighted screenshot. Return the user to a usable state on exit, not a dead end.+- Segment: returning/experienced users and invited teammates skip the first-run flow; do not re-onboard someone joining an existing populated workspace.++**Empty-to-productive path:** every empty state's CTA leads somewhere that actually creates value in <=3 steps. An onboarding checklist that just links to docs is decoration.++---++## 12. CONTEXT-AWARE PROACTIVITY (Canonical Skeletons to Recognize)++When the Product Read matches one of these, scaffold the whole skeleton, not a fragment:+- **Index/table page**: heading + toolbar (search, filters, primary action, density) + applied-filter chips + Table (sticky header, selection) + pagination footer + the three empty states + error state.+- **List-detail / master-detail**: list region + inspector LayoutPanel that overlays below ~1024px + "nothing selected" empty state.+- **Settings page**: section nav + FormLayout panels + autosave-or-save-bar + a Card only around the danger zone.+- **Multi-step wizard**: real stepper + linear steps + per-step validation + a review step + a non-destructive exit.+- **Dashboard/overview**: KPI tile row (Cards) + widget grid + one or two drill-in Tables (rows).+- **Admin console with bulk actions**: table + selection persistence + bulk action bar (capped at 5 + overflow) + confirmation dialogs.++### 12.A Block Library (reference implementations)+Full component implementations live in the host system, not duplicated here: reach them via your host system's template/skeleton command or its docs (Appendix B). Three high-value skeletons are worked below because they encode the contracts most often gotten wrong; treat them as the canonical shape, adapt to the host system.++**Block 1 - Index + detail-drawer (frame-first):**+```tsx+// Budget the frame first: nav 256 | table flex | inspector 380+<AppShell sideNav={<SideNav>{/* nav */}</SideNav>} contentPadding={0}>+ <Layout>+ <LayoutContent>+ <ToolbarTableFilter /* search + status/priority filters + overflow (cap 5) */ />+ {/* applied-filter chips row + Clear all (Section 7.F) */}+ <Table+ plugins={[useTableStickyColumns, useTableColumnResize /*, pagination */]}+ /* selection persists by row id across page/sort/filter (Section 7.E) */+ />+ {/* pagination footer; three empty states + ErrorState wired per Section 6 */}+ </LayoutContent>+ <LayoutPanel width={380} resizable={{minSizePx: 320, maxSizePx: 480}} hasDivider isScrollable>+ {selected ? <DetailFields item={selected} /> : <EmptyState title="Nothing selected" />}+ </LayoutPanel>+ </Layout>+</AppShell>+// Below ~1024px: LayoutPanel overlays Content; SideNav becomes MobileNav.+```++**Block 2 - Table scroll + sticky header + frozen column (the CSS contract a system's hooks satisfy):**+```css+/* ONE wrapper owns both scroll axes; page body never scrolls sideways (Section 4). */+.table-scroll { overflow: auto; max-block-size: 70vh; } /* bounded height => sticky works */+.table-scroll thead th { position: sticky; inset-block-start: 0; z-index: 20; }+/* Frozen first column: sticky + offset + z + SOLID THEME-TOKEN bg + shadow divider, never border */+.col-frozen {+ position: sticky; inset-inline-start: 0; z-index: 10;+ background: var(--color-surface); /* must also cover hover/selected rows */+ box-shadow: inset -1px 0 0 var(--color-border); /* not border-right (double-renders on scroll) */+}+```++**Block 3 - Truncation contract (single-line + multi-line):**+```css+.cell { min-inline-size: 0; } /* required on EVERY flex ancestor or ellipsis no-ops */+.cell .text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }+.clamp { /* all four props; NO padding on this node */+ display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;+}+```++---++## 13. PERFORMANCE & ACCESSIBILITY GUARDRAILS+- Table load/filter response should feel instant; past ~1s show optimistic/loading feedback, past the thresholds in 6.B escalate.+- Enterprise-grid perf: no per-row style/menu object allocation on render; scoped auto-sizing; `columnResizeMode:"onEnd"` unless memoized; virtualize past ~100-200 rows.+- Motion in product UI is **feedback only**: state transitions, focus movement, a row entering/leaving. No decorative scroll animation, no marquees, no parallax. Respect `prefers-reduced-motion` for everything.+- Core Web Vitals still apply: CLS < 0.1 (skeletons must reserve the real dimensions so content does not jump), INP < 200ms on interactions.++---++## 14. DARK MODE+Token-driven, one theme locked per app (same discipline as taste-skill Section 8/11: no region flips to inverted mid-app). Use the host system's semantic layer tokens (`var(--color-*)`, Carbon `$layer`/`$border-subtle`, etc.), never hardcoded greys. Test tables, frozen columns (the solid background must be a **theme token**, or it bleeds in dark mode), overlays, and focus rings in both modes. Set the theme once at the shell root, never per-section.++---++## 15. PRODUCT-UI AI TELLS (Forbidden Patterns)++Distinct from taste-skill's landing-page tells. These are the signatures of a model faking a product screen. Hard bans unless the brief genuinely demands one.++- **Card soup**: every record wrapped in a Card + Badge. Use rows. (Section 0.C)+- **Fixed-width `<table>` that scrolls the page sideways**: no scroll-owning wrapper. (Section 4)+- **Truncated button label** ("Save chang..."). Size to content. (Section 5.C)+- **Truncated identifying content** (names/IDs/errors) with a hover-only `title`. (Section 5.A-B)+- **`disabled` Submit as the only validation** on a 5+-field form. (Section 8.C)+- **One generic empty state** reused for first-run AND filtered-empty AND load-failure. (Section 6.C-D)+- **"An error occurred"** with no cause, action, or code. (Section 6.D)+- **Skeleton that never resolves**, or a frame-only grey box that does not mirror the real layout. (Section 6.B)+- **Full-page spinner on a cached background refresh** (re-blanking data the user was reading). (Section 6.B)+- **Sticky/frozen column with a transparent background** (content bleeds through on scroll). (Section 7.B)+- **Ad-hoc z-index** (`9999`, `99999`) instead of a tiered token scale. (Section 9.D)+- **Fixed-width badges/labels/tabs** that clip under German/Finnish expansion. (Sections 4, 10.B)+- **Native `disabled` on menu/tab items** that should stay keyboard-reachable (use `aria-disabled`). (Section 9.C)+- **Badge as decoration** and **status dots spammed on every row** (status only, sparingly).+- **Motion for show** in a work tool (decorative scroll/hover animation). (Section 13)+- **Fake step labels** ("Stage 1 / Stage 2"), fake precise numbers, "Jane Doe"/"Acme" placeholder data in a shipped screen.+- **Em-dash (`—`) anywhere visible.** Banned in headers, cells, labels, empty/error copy, tooltips, and as the "not set" cell placeholder. Use a hyphen (`-`). This is the single most-violated Tell; zero tolerance. (taste-skill Section 9.G, house rule)++---++## 16. REFERENCE VOCABULARY (Names the Agent Should Know)+App shell / PageLayout (Header / Content / Pane / Sidebar / Footer) · canonical layouts (list-detail / supporting-pane / feed) · master-detail + inspector · IndexTable / Resource List / DataGrid / Table · frozen (pinned) columns · virtualization · roving tabindex · stacking context · container query · skeleton screen (shape-mirroring) · Blankslate / EmptyState / ErrorState · Overflow / priority-plus · applied-filter chips / faceted search · alertdialog · optimistic vs. pessimistic update · density mode · pseudo-localization · command palette · workspace switcher · job/status tray.++---++## 17. REDESIGN PROTOCOL (Auditing an Existing Dense Screen)+Before touching visual style, audit for the correctness bugs that matter more than aesthetics:+1. **Scroll ownership** violations (page scrolls sideways; nested double-scroll).+2. **Truncation on primary content**; hover-only fallbacks.+3. **Missing state differentiation** (one empty box for three states; no error state; skeleton missing).+4. **Frozen-column bleed-through**; transparent sticky backgrounds.+5. **z-index ad-hockery**; layering bugs from nested stacking contexts.+6. **No i18n buffer**; fixed-width text containers.+7. **Keyboard/a11y gaps**: no roving tabindex, bare `:focus`, icon buttons without labels, disabled submit as only signal.+Fix these first. Only then apply the density/token/visual polish. Preserve the host design system; do not swap Carbon for shadcn as a "redesign."++---++## 18. RELATIONSHIP TO taste-skill + OUT OF SCOPE+- **Hand off to `taste-skill`**: marketing hero sections, landing pages, portfolios, editorial, illustration-heavy brand surfaces. If a screen is half product, half marketing, split it: taste-skill for the marketing sections, this skill for the product surface. Never run both on one component.+- **Hand off to `dataviz`**: chart/graph authoring (color, encoding, axes). This skill covers the table and the dashboard frame around the charts, not the chart internals.+- **Out of scope**: native mobile (iOS/Android) app chrome beyond responsive web (tab bars, native nav) - a different skill's job; flag it, do not silently approximate. Realtime collab primitives (presence, cursors, OT) - different problem class.++---++## 19. FINAL PRE-FLIGHT CHECK++**Run every box. If any fails, the surface is not done.**++- [ ] **Product Read** stated (Section 0.B one-liner)?+- [ ] **Dials** (DENSITY / DATA_COMPLEXITY / CONSEQUENCE) set from the read, not silently baseline?+- [ ] **Frame budgeted in px** before content; shell + landmark regions named (Header/Content/Pane/Sidebar not conflated)?+- [ ] **Rows not cards** for dense data; Card only for widgets; no card soup, no nested cards?+- [ ] **Scroll ownership**: exactly one wrapper per axis, page never scrolls horizontally, sticky scoped to the wrapper?+- [ ] **min-width:0** on every truncating flex text child?+- [ ] **No truncated primary content** (names/IDs/errors/headers) and **no truncated button labels**; every truncation has a focus-reachable full-text fallback?+- [ ] **Line-clamp recipe** complete (all 4 props, no padding on the clamped node)?+- [ ] **Four states designed** (ideal/loading/empty/error) for every data region?+- [ ] **Loading thresholds**: <1s nothing, skeleton mirrors layout, >10s determinate progress, cached refresh never re-blanks?+- [ ] **Three distinct empty states** (first-run / filtered-empty / zero-as-a-win); load failure is an ErrorState with cause + action + code?+- [ ] **Partial/stale/offline states** handled (one failed widget fails in place; cached refresh never re-blanks; offline queues or blocks with notice; optimistic updates have a rollback path)?+- [ ] **Content edge cases**: counts pluralized (0/1/N, no "1 items"); big numbers abbreviated with exact value reachable and never abbreviated where precision matters; missing data has a consistent placeholder distinct from zero/empty?+- [ ] **Permission/plan states** considered (disabled-vs-hidden, read-only, plan-locked) where roles/tiers exist?+- [ ] **Table**: scroll-owning wrapper + bounded height; sticky header; frozen columns have solid theme-token background + inset-shadow divider + z-index; virtualization uses the two-wrapper DOM?+- [ ] **Pagination vs infinite** chosen correctly (paginate >50 / for search; infinite only for feeds with pushState + mobile flat batch)?+- [ ] **Selection persists** across page/sort/filter; bulk toolbar capped at 5 + overflow?+- [ ] **Applied-filter chips** row present when filters exist; search and filter are distinct controls?+- [ ] **Forms**: top labels default; validate on blur+submit; inline + summary errors; input preserved on failed submit; no disabled-submit-as-only-signal on 5+ fields?+- [ ] **Async validation** debounced + AbortSignal-cancelled?+- [ ] **Autosave** per group, not for password/permission/financial fields, with Saving/Saved states + persistent retry on failure?+- [ ] **Destructive confirm** focuses the safe action, `role=alertdialog`, returns focus on close?+- [ ] **Dialogs** trap+return focus, Escape-close, Title/Description present; **toasts** pause on hover, dismissible?+- [ ] **z-index** from a tiered token scale (no 9999); layering bugs traced to stacking contexts, not bigger numbers?+- [ ] **i18n buffer** on every text container (+30-40% DE); no hardcoded fixed-width text; tabular-nums on compared numbers?+- [ ] **RTL** mirrors directional icons only (if RTL in scope)?+- [ ] **Keyboard/a11y**: roving tabindex on custom grids, `:focus-visible`, icon buttons labelled, `aria-disabled` not `disabled` on keyboard-reachable menu items, 44px/24px targets?+- [ ] **Density switch** offered where DENSITY calls for it (mode swap, not zoom)?+- [ ] **Dark mode** one theme locked, frozen-column background is a theme token, tested in both modes?+- [ ] **House system**: props discovered from real docs (nothing invented), no `<div>` for layout, tokens only, Badge for counts only, status via a status indicator?+- [ ] **No product-UI Tells** from Section 15; **zero em-dashes** anywhere visible?+- [ ] **One design system** per app (no Carbon + Fluent mixed)?++If a single box cannot be honestly ticked, fix it before delivering.++---++# APPENDICES - Source-Backed Reference Material++## Appendix A - Install / CLI per system++```bash+# House design system - resolve the real API before writing UI.+# Most systems ship a CLI or a docs site; use whichever exists.+# 1. find the closest shipped page/block template+# 2. study its layout skeleton+# 3. read real props for every component (never invent props)++# IBM Carbon+npm install @carbon/react @carbon/styles+# Microsoft Fluent UI React v9+npm install @fluentui/react-components+# Atlassian Atlaskit (per-component + tokens)+npm install @atlaskit/tokens @atlaskit/dynamic-table+# Shopify Polaris+npm install @shopify/polaris+# GitHub Primer React+npm install @primer/react styled-components+# Radix Primitives + shadcn/ui + TanStack Table+npm install @radix-ui/react-dialog @radix-ui/react-toast @tanstack/react-table+npx shadcn@latest add table dialog+# Material Web (Material 3)+npm install @material/web+# Ant Design / Mantine + Mantine React Table+npm install antd+npm install @mantine/core @mantine/form mantine-react-table+```++## Appendix B - Canonical sources (real URLs, gsearch-verified)++Consolidated primary sources:++**Frame / layout**+- Carbon 2x grid: https://carbondesignsystem.com/elements/2x-grid/usage/+- Primer PageLayout: https://primer.style/product/components/page-layout+- Material 3 canonical layouts: https://m3.material.io/foundations/adaptive-design/canonical-layouts+- Material 3 list-detail: https://m3.material.io/foundations/layout/canonical-examples/list-detail+- Material 3 supporting-pane: https://m3.material.io/foundations/layout/canonical-examples/supporting-pane+- Container queries: https://www.joshwcomeau.com/css/container-queries-unleashed/++**Overflow / truncation**+- Carbon overflow content: https://carbondesignsystem.com/patterns/overflow-content/+- Primer Truncate: https://primer.style/product/components/truncate/+- CSS line-clamp: https://css-tricks.com/line-clampin/++**State matrix**+- Polaris EmptyState: https://polaris-react.shopify.com/components/layout-and-structure/empty-state+- Carbon empty states: https://carbondesignsystem.com/patterns/empty-states-pattern/+- Carbon loading: https://carbondesignsystem.com/patterns/loading-pattern/+- Primer empty states: https://primer.style/product/ui-patterns/empty-states/+- NN/g skeleton screens: https://www.nngroup.com/articles/skeleton-screens/+- NN/g empty-state design: https://www.nngroup.com/articles/empty-state-interface-design/+- Pencil&Paper empty states: https://www.pencilandpaper.io/articles/empty-states+- Polaris error messages: https://polaris-react.shopify.com/content/error-messages++**Data table**+- Carbon data table: https://carbondesignsystem.com/components/data-table/usage/+- Polaris IndexTable: https://polaris-react.shopify.com/components/tables/index-table+- Ant table scroll: https://ant.design/docs/blog/table-scroll-ghost/+- Ant virtual table: https://ant.design/docs/blog/virtual-table/+- TanStack column sizing: https://tanstack.com/table/latest/docs/guide/column-sizing+- Mantine React Table column pinning: https://www.mantine-react-table.com/docs/guides/column-pinning+- NN/g infinite scroll: https://www.nngroup.com/articles/infinite-scrolling-tips/+- Baymard checkout linear / pagination context: https://baymard.com/blog/checkout-process-should-be-linear+- Pagination vs infinite vs load-more: https://www.smashingmagazine.com/2016/03/pagination-infinite-scrolling-load-more-buttons/++**Forms / flows**+- LukeW web form design: https://www.lukew.com/ff/entry.asp?504+- NN/g web form design: https://www.nngroup.com/articles/web-form-design/+- NN/g form errors: https://www.nngroup.com/articles/errors-forms-design-guidelines/+- Polaris inline error: https://polaris-react.shopify.com/components/selection-and-input/inline-error+- Ant / 2x form pattern: https://2x.ant.design/docs/pattern/form+- Mantine form validation: https://mantine.dev/form/validation/++**Overlays / layering / a11y**+- Radix Dialog: https://www.radix-ui.com/primitives/docs/components/dialog+- Radix Toast: https://www.radix-ui.com/primitives/docs/components/toast+- W3C ARIA alertdialog: https://www.w3.org/WAI/ARIA/apg/patterns/alertdialog/+- W3C ARIA dialog-modal: https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/+- W3C ARIA grid data-grids: https://www.w3.org/WAI/ARIA/apg/patterns/grid/examples/data-grids/+- MDN stacking context: https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Positioned_layout/Stacking_context++**Tokens / density / i18n**+- Atlaskit design tokens: https://atlassian.design/foundations/design-tokens+- Atlaskit spacing: https://atlassian.design/foundations/spacing+- Crowdin UI localization: https://crowdin.com/blog/best-practices-for-ui-localization+- Material 3 accessibility (targets): https://m3.material.io/components/buttons/accessibility++**Modern minimal**+- Linear method: https://linear.app/method/introduction+- Vercel design guidelines: https://vercel.com/design/guidelinesdiff --git a/skills/publish-to-confluence/SKILL.md b/skills/publish-to-confluence/SKILL.mdnew file mode 100644index 0000000..b2bd6c2--- /dev/null+++ b/skills/publish-to-confluence/SKILL.md@@ -0,0 +1,261 @@+---+name: publish-to-confluence+description: Publish any markdown file from the vault to Confluence with format conversion and approval gate+roles: [product-manager, engineering-lead, founder]+integrations: [confluence]+---++# COG Publish to Confluence Skill++## When to Invoke+- User wants to publish a document to Confluence+- User says "publish to Confluence", "push to wiki", "send to Confluence", "confluence publish"+- User has a markdown file they want to share with the team on Confluence+- After generating a PRD, release notes, or other document that should go to the wiki++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — no significant benefit for this skill (single sequential operation)+- If `agent_mode: solo` — standard execution++## Command: `/publish-to-confluence`++## Pre-Flight Check++1. **Read `00-inbox/MY-INTEGRATIONS.md`** — Confluence MUST be listed under Active Integrations+ - If Confluence is **not active**: Inform the user and stop.+ ```+ Confluence is not in your active integrations.++ Would you like to:+ a) Set up Confluence integration (I'll add it to MY-INTEGRATIONS.md)+ b) Export the document in a Confluence-compatible format for manual upload+ ```+ - If Confluence is **disabled**: Skip silently per COG conventions. Suggest alternative publishing (HackMD, Notion) if active.++2. **Get current timestamp:** Run `date '+%Y-%m-%d %H:%M'` using Bash++---++## Execution Strategy++### Phase 1: Identify the Source Document++Determine what to publish:++**Option A: User specifies a file path**+```+Read the specified file from the vault.+```++**Option B: User describes the document**+```+Search for matching files:+1. Glob for likely matches in 04-projects/, 05-knowledge/, 01-daily/+2. Present candidates and let user choose+```++**Option C: Just-generated document**+If this skill is invoked right after generating a PRD, release notes, or other document, use that document.++### Phase 2: Configure Publishing Target++Ask the user (if not already provided):++```+Where should this be published in Confluence?++Required:+- Space key: [CUSTOMIZE: YOUR-SPACE-KEY] (or let me search for spaces)+- Parent page: [Page title or ID under which to nest this page]++Optional:+- Page title: [defaults to the document's H1 heading]+- Labels: [Confluence labels to add]+- Publish mode: "create new" or "update existing"+```++**If the user doesn't know the space or parent page:**+```+Use WebFetch to search Confluence:+GET /wiki/rest/api/space?limit=50+- List available spaces for the user to choose++GET /wiki/rest/api/content?spaceKey=[SPACE]&type=page&limit=25+- List pages in the space for parent page selection+```++### Phase 3: Convert Markdown to Confluence Format++Convert the markdown document to Confluence storage format (XHTML):++**Conversion rules:**+| Markdown | Confluence Storage Format |+|----------|--------------------------|+| `# Heading` | `<h1>Heading</h1>` |+| `## Heading` | `<h2>Heading</h2>` |+| `**bold**` | `<strong>bold</strong>` |+| `*italic*` | `<em>italic</em>` |+| `- list item` | `<ul><li>list item</li></ul>` |+| `1. list item` | `<ol><li>list item</li></ol>` |+| `[text](url)` | `<a href="url">text</a>` |+| `` `code` `` | `<code>code</code>` |+| Code blocks | `<ac:structured-macro ac:name="code"><ac:plain-text-body><![CDATA[...]]></ac:plain-text-body></ac:structured-macro>` |+| Tables | `<table><tbody><tr><th>...</th></tr><tr><td>...</td></tr></tbody></table>` |+| `> blockquote` | `<blockquote><p>quote</p></blockquote>` |+| `---` | `<hr />` |+| `- [ ] task` | `<ac:task-list><ac:task><ac:task-status>incomplete</ac:task-status><ac:task-body>task</ac:task-body></ac:task></ac:task-list>` |+| `- [x] task` | Same with `complete` status |+| YAML frontmatter | Strip entirely (not displayed in Confluence) |++**Important conversion notes:**+- Strip YAML frontmatter — it should not appear in the Confluence page+- Preserve table structure carefully+- Convert relative vault links to plain text (they won't work in Confluence)+- Handle nested lists properly+- Preserve emoji characters as-is++### Phase 4: Preview and Approval Gate++**CRITICAL: NEVER publish without explicit user approval.**++Present a summary to the user:++```+Ready to publish to Confluence:++Document: [filename]+Title: [page title]+Space: [space key]+Parent Page: [parent page title]+Mode: [create new / update existing]+Labels: [labels]++Content preview (first 500 chars):+[preview text]++Estimated page size: [approximate word count]++Proceed with publishing? (yes/no)+```++**Wait for explicit "yes" before proceeding.**++### Phase 5: Publish++#### Create New Page+```+Use WebFetch to POST to Confluence REST API:++POST [CUSTOMIZE: your-confluence-url]/wiki/rest/api/content++Headers:+ Content-Type: application/json+ Authorization: [from configured credentials]++Body:+{+ "type": "page",+ "title": "[page title]",+ "space": { "key": "[SPACE_KEY]" },+ "ancestors": [{ "id": "[PARENT_PAGE_ID]" }],+ "body": {+ "storage": {+ "value": "[converted XHTML content]",+ "representation": "storage"+ }+ },+ "metadata": {+ "labels": [+ { "prefix": "global", "name": "[label]" }+ ]+ }+}+```++#### Update Existing Page+```+First, get the current page to obtain the version number:+GET [CUSTOMIZE: your-confluence-url]/wiki/rest/api/content/[PAGE_ID]?expand=version++Then update:+PUT [CUSTOMIZE: your-confluence-url]/wiki/rest/api/content/[PAGE_ID]++Body:+{+ "type": "page",+ "title": "[page title]",+ "version": { "number": [current_version + 1] },+ "body": {+ "storage": {+ "value": "[converted XHTML content]",+ "representation": "storage"+ }+ }+}+```++### Phase 6: Confirm and Update Vault++After successful publishing:++1. **Confirm to the user:**+ ```+ Published successfully!++ Page: [Title]+ URL: [Confluence page URL]+ Space: [Space Key]+ Version: [version number]+ ```++2. **Update the source vault file** (add published metadata to frontmatter):+ ```yaml+ confluence_url: "[page URL]"+ confluence_page_id: "[page ID]"+ confluence_space: "[space key]"+ published_at: "[timestamp]"+ confluence_version: [version number]+ ```++3. **Log the publication** for future reference.++---++## Re-Publishing (Update Flow)++If the vault file already has `confluence_page_id` in its frontmatter:++```+This document was previously published to Confluence:+ URL: [confluence_url]+ Last published: [published_at]++Would you like to:+a) Update the existing Confluence page (increment version)+b) Create a new page (separate copy)+c) Cancel+```++---++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| Confluence not active | Stop and inform user; suggest alternative platforms |+| Confluence API fails | Save the converted XHTML to a file so user can manually paste it |+| Authentication failure | Inform user their Confluence credentials may need refreshing |+| Page already exists (same title) | Ask user: update existing, create with different title, or cancel |+| Very large document | Warn user about page size; suggest splitting into child pages |+| Complex markdown (unsupported elements) | Convert best-effort, warn about any elements that couldn't be converted |++## Error Handling++- **API 403 (Forbidden)**: User may lack write permissions to the target space+- **API 404 (Not Found)**: Space key or parent page ID may be incorrect+- **API 409 (Conflict)**: Page was modified by someone else; fetch latest version and retry+- **Conversion failures**: Fall back to plain text for elements that can't be converted+- **Rate limits**: Retry with backoff+- **Network errors**: Save converted content locally so no work is lostdiff --git a/skills/retro/SKILL.md b/skills/retro/SKILL.mdnew file mode 100644index 0000000..0a1dcfd--- /dev/null+++ b/skills/retro/SKILL.md@@ -0,0 +1,67 @@+---+name: retro+description: >+ CP-7 retrospective: audit checkpoints, evidence quality, action items,+ and harvest candidates. Closes the V-model cycle and feeds the next run.+ Use via /retro after ship, escalate, or significant session.+---++# /retro — CP-7 close the V++Every non-`tiny` shipped or escalated run gets a retro. Retro is **advisory** but strongly expected: it is how the harness improves.++## When to run++- After CP-6 ship (approved publish, merged PR, vault deliverable done)+- After escalate (capture why verifier failed)+- End of an `/ultragoal` phase (one retro per phase)+- Manual: `/retro <run-dir or spec path>`++## Phase 1 — Gather evidence bundle++Read:++1. Spec or card description + acceptance criteria+2. `04-projects/harness/runs/<id>/evidence/` (ledger, checkpoints.tsv, CP-* files)+3. `.claude/logs/loop-ledger.tsv` (last rows for this run)+4. `04-projects/<goal>/STATUS.md` if an ultragoal phase++## Phase 2 — Checkpoint audit++For each CP the lane required, mark Expected vs Actual vs Gap:++| CP | `tiny` | `normal` | `full` |+|---|---|---|---|+| CP-1 spec | skip | required | required |+| CP-3v component | skip | required | required |+| CP-4 integration | skip | skip | required if multi-task |+| CP-5 acceptance | if mutate | required | required |+| CP-6 ship | if external | if external | required |++## Phase 3 — Evidence quality pass++Ask:++- Any AC-n shipped without a PASS evidence row? (traceability violation)+- Any PASS row where observation is tool-return not artifact? (confident-but-unchecked)+- Any criterion that wasn't falsifiable? (fix in next spec)++## Phase 4 — Write retro++Copy `04-projects/harness/templates/retro.md` to:++`04-projects/harness/retro/YYYY-MM-DD-<slug>.md`++Fill all sections. Action items get IDs (`AI-01`…).++## Phase 5 — Feed forward++1. **Harvest**: append action items + lessons to today's harvest staging+2. **Backlog**: add `AI-n` rows to `04-projects/harness/BACKLOG.md` if harness work+3. **STATUS.md**: if an ultragoal phase, advance the phase state + log open `AC-n`+4. **Spec checkpoint log**: update spec `## Checkpoint log` CP-7 row+5. Record: `bash .claude/lib/checkpoint.sh record <run-dir> CP-7 PASS "retro: <path>"`++## Output to the user++TL;DR: outcome, top lesson, top action item, retro path.diff --git a/skills/review-cockpit/SKILL.md b/skills/review-cockpit/SKILL.mdnew file mode 100644index 0000000..78d4a48--- /dev/null+++ b/skills/review-cockpit/SKILL.md@@ -0,0 +1,67 @@+---+name: review-cockpit+description: Produce and continuously maintain ONE living review document for a multi-item session — a cockpit header (Progress checklist, Working folder, Context) plus per-item review cards that you approve or request changes on directly in the doc or side panel. Use whenever a session has multiple deliverables you need to review/approve (meeting-processing + planning, multi-ticket work, briefs with several drafts, any "do X, then plan/draft Y and Z"). The doc is the interaction surface: you edit it (or reply in chat) to approve/change; the agent keeps it live as work progresses.+---++# review-cockpit++## Purpose++A single, living **review document** that doubles as the control surface for a session. Instead of scattering a meeting note here, a ticket there, two drafts in chat, everything lands in **one file** you can open in the Obsidian side panel (or Claude side panel) and drive: see progress at a glance, review each item in place, approve or request changes inline, and watch the doc update as the agent works. Mirrors a "co-work" cockpit (Progress / Working folder / Context).++## When to use++- Any session with **≥2 things you need to review or approve** (the default for "process X then plan/draft Y, Z").+- Meeting-processing + pod planning, multi-ticket runs, briefs with several drafts, spec + plan + drafts.+- NOT for a single trivial deliverable (one file, no approval loop) — a plain file is fine there.++Pairs with `closed-loop` (verification), `harvest` (learnings), and the V-model checkpoints. This skill governs **how the deliverable is presented and driven**, not the verification pipeline.++## The one rule++**One doc per session.** It opens with a cockpit, then one review card per item. Every artifact the session produces is linked from the **Working folder** table (fan-out to sub-files mid-run is fine; the cockpit is the single front door). Never hand the user "see files A, B, C" — hand them the cockpit.++## Structure++Copy `04-projects/harness/templates/session-review.md`. Save the working copy in the relevant project folder as `YYYY-MM-DD-<slug>-review.md` (or `-plan.md`).++**Cockpit (top):**+1. **Status line** — one line: how many items await review + last-updated timestamp.+2. **🧭 Progress** — a checklist, one row per item, each with a status glyph; a text progress bar + "X/N done · A awaiting review · B pending". **Make each item a clickable anchor to its review card** — `[N. Title](#n-title)` using GitHub-slug rules (lowercase, spaces→`-`, drop punctuation/emoji). Keep item headings free of `+ # ← → ( )` so slugs stay clean single-hyphen and the links resolve in Obsidian + the Claude side panel.+3. **📁 Working folder** — table of every artifact produced this session with its `~/vault/...` path or link (meeting note, this doc, evidence dir, external issues/PRs, posted messages).+4. **🔌 Context** — sources the work is grounded in (recordings, Slack threads, issues), tools/connectors used, related tickets.++**Review items (below):** one card per item:+- **Status** — glyph + word (see vocabulary).+- **Action** — what was done or is proposed.+- **Deliverable** — link/path, or an inline draft placed directly under the card so you review it in place (messages to send, doc bodies).+- **Checklist** — the item's acceptance criteria as checkboxes.+- **🗒 Your call** — the approval slot you edit (`approve` / your requested changes).+- **Decision log** — append-only record of what happened / what you decided.++**Footer:** "How to drive this doc" (approve/change mechanics + status vocabulary), so the doc is self-explaining.++**Status vocabulary:** ⏳ pending · 🔄 in progress · 📝 needs review · ✏️ changes requested · ✅ done · ⛔ blocked++## Update protocol (keep it live)++- **After every meaningful step**, refresh: the Progress checklist + bar, the affected item's Status, the Working folder (add new artifacts), and the item's Decision log. Bump the `updated:` frontmatter + status line.+- Prefer targeted `Edit`s over full rewrites so your inline edits/approvals are never clobbered. **Before editing, re-read the file** — you may have typed approvals or change requests into **🗒 Your call** or ticked boxes.+- When you approve an item, execute it, move it to ✅, and log the outcome (with the external link — issue/PR/message URL) in the Decision log.+- When you request changes, set the item to ✏️ changes requested, apply them, re-draft in place, then return it to 📝 needs review.++## Interaction contract++The doc is the shared surface; you drive it two ways, both valid:+- **In the doc / side panel:** you edit **🗒 Your call** or tick checkboxes. Re-read and act.+- **In chat:** "3 is ok", "approve 2 and 4", "change the tone on the requirement comms". Map to item numbers and act.++Distinguish **draft** items (agent proposes, waits — e.g. a Slack message you own sending) from **auto** items (agent may execute directly — e.g. filing a GitHub issue you explicitly asked for). Draft items stay 📝 until approved; auto items go straight to ✅ with the artifact linked. When unsure whether an item is draft or auto, leave it 📝.++## Post-condition++Read-only for the doc itself, but the items it tracks often mutate external state — obey each item's own post-condition (fetch back the issue, confirm the Slack message landed, etc.) and record the verified link in the Decision log. Never mark ✅ from a mutation call alone.++## Optional: rendered view++The markdown doc is primary (you edit it to approve). If you want a richer at-a-glance view, additionally render an HTML **Artifact** of the cockpit (Progress + Working folder + Context + item statuses) — but the markdown stays the source of truth and the editable surface.diff --git a/skills/scout/SKILL.md b/skills/scout/SKILL.mdnew file mode 100644index 0000000..1f0bb68--- /dev/null+++ b/skills/scout/SKILL.md@@ -0,0 +1,201 @@+---+name: scout+description: Evaluate URLs and tools — check vault coverage, assess relevance, recommend save or skip+roles: [all]+integrations: [web-fetch, web-search]+---++# COG Scout Skill++## Purpose+Lightweight URL/tool triage that sits between "ignore" and `/url-dump`. Evaluates whether a URL or tool is worth saving or skipping — checking existing vault coverage, assessing relevance to the user's profile and interests, and recommending a clear next action.++## When to Invoke+- User wants to evaluate a URL or tool before committing to a full save+- User says "scout this", "evaluate this", "should I save this?", "is this relevant?"+- User shares one or more URLs and wants a quick relevance assessment+- User mentions a tool/service name and wants to know if it's worth investigating++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — delegate vault scanning and web fetching to parallel sub-agents (one for vault search, one for content fetch/analysis). Combine results for recommendation.+- If `agent_mode: solo` (default) — handle all scanning and analysis directly in the conversation. No delegation.++## Pre-Flight Check++**Before executing, check for user profile:**++1. Look for `00-inbox/MY-PROFILE.md` and `00-inbox/MY-INTERESTS.md` in the vault+2. If NOT found:+ ```+ Welcome to COG! Scout works best with a profile for relevance matching.++ Would you like to run /onboarding first, or should I evaluate with general criteria?+ ```+3. If found:+ - Read `MY-PROFILE.md` for active projects and role+ - Read `MY-INTERESTS.md` for topic areas+ - Read `00-inbox/MY-INTEGRATIONS.md` for active integrations (check if `web-fetch` and `web-search` are available)++## Boundary with `/url-dump`++**Scout evaluates** ("should I save this?"). **URL-dump saves** ("save this now").++- Scout checks existing coverage, assesses relevance, and recommends an action+- If the recommendation is **Save**, scout hands off to `/url-dump` with pre-filled category+- Users who already know they want to save should use `/url-dump` directly++## Process Flow++### 1. Accept Input++Accept one or more of:+- **URL(s):** Direct links to evaluate+- **Tool/service name(s):** Will search for the tool first+- **Mixed:** Combination of URLs and names++**Prompt (if no input provided):**+```+What URL(s) or tool(s) would you like me to evaluate?+(You can paste URLs, tool names, or a mix)+```++**Batch mode:** Multiple URLs/names in one invocation are processed together with a summary table at the end.++### 2. Vault Coverage Check++For each URL or tool name, search the **entire vault** for existing coverage.++**Search strategy:**+- Extract domain from URL (e.g., `github.com/owner/repo` → search for repo name)+- Search for tool/service name across the whole vault (grep for domain, repo name, tool name)+- Match against URL strings in frontmatter (`url:` fields) and inline links++**If found:**+```+🔍 Existing coverage found for [name]:+- [file path] — saved [date], category: [category]+- [file path] — mentioned in [context]++Want me to check if an update is needed, or skip this one?+```++### 3. Content Fetch & Analysis++**If URL provided and web-fetch is active:**+- Fetch the URL content using WebFetch+- Extract: title, description, content type, author, date++**If tool name provided (no URL):**+- Use WebSearch to find the tool's primary page+- Fetch and analyze the top result++**Content type detection:**+- **Tool/Service:** Software, SaaS, API, library, framework+- **Article/Blog:** Long-form content, tutorial, opinion piece+- **Repository:** GitHub/GitLab repo (extract stars, last commit, language)+- **Research:** Paper, study, academic content+- **News:** Industry news, announcement+- **Reference:** Documentation, spec, standard++### 4. Relevance Assessment++Score relevance against user context:++**Profile Match (from MY-PROFILE.md):**+- Does it relate to an active project? Which one?+- Does it align with the user's role?+- Does it fit the user's tech stack?++**Interest Match (from MY-INTERESTS.md):**+- Does it match any declared interest topics?+- How directly relevant is it?++**Quality Signals:**+- For repos: stars, recent activity, maintainer health+- For tools: pricing model, maturity, adoption+- For articles: author credibility, publication quality, recency+- For all: uniqueness vs. what's already in the vault++### 5. Recommendation++Based on analysis, recommend one of two actions:++#### **Save** — Worth adding to the knowledge base+```+✅ SAVE — [Title/Name]+Category: [suggested category for url-dump]+Relevance: [High/Medium] — [why it matters]+Projects: [affected project(s) if any]++Shall I hand off to /url-dump to save it?+```++#### **Skip** — Not relevant or not worth the time+```+⏭️ SKIP — [Title/Name]+Reason: [clear explanation — wrong stack, low quality, already covered, irrelevant to interests]+```++### 6. Batch Summary (for multiple items)++When processing multiple URLs/tools, end with a summary table:++```markdown+## Scout Summary++| # | Item | Verdict | Reason |+|---|------|---------|--------|+| 1 | [Name 1] | ✅ Save | [brief reason] |+| 2 | [Name 2] | ⏭️ Skip | [brief reason] |++**Actions:**+- [X] items ready to save via /url-dump+```++### 7. Execute Follow-up Actions++Based on user confirmation:+- **Save items:** Hand off to `/url-dump` with pre-filled category suggestion+- **Skip items:** No action needed++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| web-fetch unavailable | Evaluate based on URL structure, domain reputation, and vault search only. Note that content wasn't fetched. |+| web-search unavailable | For tool-name inputs (no URL), ask the user for a direct URL instead. For URL inputs, proceed normally — web-search is not needed. |+| No user profile | Evaluate with general quality/relevance criteria, skip personalized relevance scoring |+| URL is paywalled | Note limitation, evaluate based on available preview and metadata |+| Tool not found via search | Ask user for more context or a direct URL |++## Uncertainty Handling++- **High confidence:** Clear relevance match or clear irrelevance — give direct recommendation+- **Medium confidence:** Partial match — present pros/cons, let user decide+- **Low confidence:** Can't determine relevance — explain what's unclear, ask user for context++## Integration with Other Skills++### Downstream+- **Save** → hands off to `/url-dump` with pre-filled category++### Upstream+- `/daily-brief` may surface new tools/services → user can run `/scout` to evaluate+- `/auto-research` may discover tools during research → scout can triage them++## Success Metrics+- Quick triage (< 1 minute for single URL in solo mode)+- Clear, actionable recommendations+- Accurate vault coverage detection (no duplicate saves)+- Relevance scoring matches user expectations+- Smooth handoff to `/url-dump` when saving++## Philosophy++Scout embodies COG's "evaluate before you accumulate" principle:+- Not everything deserves a bookmark — be selective+- Existing coverage should be surfaced before creating duplicates+- Binary save/skip keeps decisions fast and avoids half-measures+- Clear recommendations reduce decision fatiguediff --git a/skills/taste-skill/SKILL.md b/skills/taste-skill/SKILL.mdnew file mode 100644index 0000000..9b80a8e--- /dev/null+++ b/skills/taste-skill/SKILL.md@@ -0,0 +1,1208 @@+---+name: taste-skill+description: Anti-slop frontend skill for landing pages, portfolios, and redesigns. The agent reads the brief, infers the right design direction, and ships interfaces that do not look templated. Real design systems when applicable, audit-first on redesigns, strict pre-flight check.+---++# tasteskill: Anti-Slop Frontend Skill++> Landing pages, portfolios, and redesigns. Not dashboards, not data tables, not multi-step product UI.+> Every rule below is **contextual**. None of it fires automatically. First read the brief, then pull only what fits.++---++## 0. BRIEF INFERENCE (Read the Room Before Anything Else)++Before touching code or tweaking dials, **infer what the user actually wants**. Most LLM design output is bad because the model jumps to a default aesthetic instead of reading the room.++### 0.A Read these signals first+1. **Page kind** - landing (SaaS / consumer / agency / event), portfolio (dev / designer / creative studio), redesign (preserve vs overhaul), editorial / blog.+2. **Vibe words** the user used - "minimalist", "calm", "Linear-style", "Awwwards", "brutalist", "premium consumer", "Apple-y", "playful", "serious B2B", "editorial", "agency-y", "glassy", "dark tech".+3. **Reference signals** - URLs they linked, screenshots they pasted, products they named, brands they're competing with.+4. **Audience** - B2B procurement panel vs. design-conscious consumer vs. recruiter scanning a portfolio. The audience picks the aesthetic, not your taste.+5. **Brand assets that already exist** - logo, color, type, photography. For redesigns, these are starting material, not optional input (see Section 11).+6. **Quiet constraints** - accessibility-first audiences, public-sector, regulated industries, trust-first commerce, kids' products. These constraints OVERRIDE aesthetic preference.++### 0.B Output a one-line "Design Read" before generating+Before any code, state in one line: **"Reading this as: \<page kind> for \<audience>, with a \<vibe> language, leaning toward \<design system or aesthetic family>."**++Example reads:+- *"Reading this as: B2B SaaS landing for technical buyers, with a Linear-style minimalist language, leaning toward Tailwind utilities + Geist + restrained motion."*+- *"Reading this as: solo designer portfolio for hiring managers, with an editorial / kinetic-type language, leaning toward native CSS + scroll-driven animation + custom typography."*+- *"Reading this as: redesign of a public-sector service site, with a trust-first language, leaning toward GOV.UK Frontend or USWDS."*++### 0.C If the brief is ambiguous, ask one question, do not guess+Ask exactly **one** clarifying question - never a multi-question dump - and only when the design read genuinely diverges. Example: *"Should this feel closer to Linear-clean or Awwwards-experimental?"*++If you can confidently infer from context, **do not ask**. Just declare the design read and proceed.++### 0.D Anti-Default Discipline+Do not default to: AI-purple gradients, centered hero over dark mesh, three equal feature cards, generic glassmorphism on everything, infinite-loop micro-animations everywhere, Inter + slate-900. These are the LLM defaults. Reach past them deliberately based on the design read.++---++## 1. THE THREE DIALS (Core Configuration)++After the design read, set three dials. Every layout, motion, and density decision below is gated by these.++* **`DESIGN_VARIANCE: 8`** - 1 = Perfect Symmetry, 10 = Artsy Chaos+* **`MOTION_INTENSITY: 6`** - 1 = Static, 10 = Cinematic / Physics+* **`VISUAL_DENSITY: 4`** - 1 = Art Gallery / Airy, 10 = Cockpit / Packed Data++**Baseline:** `8 / 6 / 4`. Use these unless the design read overrides them. Do not ask the user to edit this file - overrides happen conversationally.++### 1.A Dial Inference (design read → dial values)+| Signal | VARIANCE | MOTION | DENSITY |+|---|---|---|---|+| "minimalist / clean / calm / editorial / Linear-style" | 5-6 | 3-4 | 2-3 |+| "premium consumer / Apple-y / luxury / brand" | 7-8 | 5-7 | 3-4 |+| "playful / wild / Dribbble / Awwwards / experimental / agency" | 9-10 | 8-10 | 3-4 |+| "landing page / portfolio / marketing site (default)" | 7-9 | 6-8 | 3-5 |+| "trust-first / public-sector / regulated / accessibility-critical" | 3-4 | 2-3 | 4-5 |+| "redesign - preserve" | match existing | +1 | match existing |+| "redesign - overhaul" | +2 | +2 | match existing |++### 1.B Use-Case Presets+| Use case | VARIANCE | MOTION | DENSITY |+|---|---|---|---|+| Landing (SaaS, mainstream) | 7 | 6 | 4 |+| Landing (Agency / creative) | 9 | 8 | 3 |+| Landing (Premium consumer) | 7 | 6 | 3 |+| Portfolio (Designer / studio) | 8 | 7 | 3 |+| Portfolio (Developer) | 6 | 5 | 4 |+| Editorial / Blog | 6 | 4 | 3 |+| Public-sector service | 3 | 2 | 5 |+| Redesign - preserve | match | match+1 | match |+| Redesign - overhaul | +2 | +2 | match |++### 1.C How the Dials Drive Output+Use these (or user-overridden values) as global variables. Cross-references throughout this document refer to these exact variable names - never invent aliases like `LAYOUT_VARIANCE` or `ANIM_LEVEL`.++---++## 2. BRIEF → DESIGN SYSTEM MAP++Once you have the design read (Section 0) and dials (Section 1), pick the right foundation. Do not invent CSS for things that have an official package. Do not pretend an aesthetic trend is an official system.++### 2.A When to reach for a real design system (use official packages)+| Brief reads as… | Reach for | Why |+|---|---|---|+| Microsoft / enterprise SaaS / dashboards | `@fluentui/react-components` or `@fluentui/web-components` | Official Fluent UI, Microsoft tokens, accessibility done |+| Google-ish UI, Material-flavored product | `@material/web` + Material 3 tokens | Official, theme-able via Material Theming |+| IBM-style B2B / enterprise analytics | `@carbon/react` + `@carbon/styles` | Official Carbon, mature data-density patterns |+| Shopify app surfaces | `polaris.js` web components / Polaris React | Required for Shopify admin UI |+| Atlassian / Jira-style product | `@atlaskit/*` + `@atlaskit/tokens` | Official Atlassian DS |+| GitHub-style devtool / community page | `@primer/css` or `@primer/react-brand` | Official Primer; Brand variant for marketing |+| Public-sector UK service | `govuk-frontend` | Legally / regulatorily expected |+| US public-sector / trust-first | `uswds` | Same |+| Fast local-business / agency MVP | Bootstrap 5.3 | Boring, fast, works |+| Modern accessible React foundation | `@radix-ui/themes` | Primitives + polished theme |+| Modern SaaS where you own the components | shadcn/ui (`npx shadcn@latest add ...`) | You own the code, easy to customise; never ship default state |+| Tailwind-based modern SaaS / AI marketing | Tailwind v4 utilities + `dark:` variant | Default for indie + small team builds |++**Honesty rule:** if the brief reads as one of the systems above, install and use the **official** package. Do not recreate its CSS by hand. Do not import a system's tokens but then override 90% of them.++**One system per project.** Do not mix Fluent React with Carbon in the same tree. Do not import shadcn/ui components into a Material 3 app.++### 2.B When the brief is an aesthetic, not a system+For these directions, there is **no single official package**. Build with native CSS + Tailwind + a maintained component library. Be honest in code comments about what is borrowed inspiration vs. official material.++| Aesthetic | Honest implementation |+|---|---|+| Glassmorphism / "frosted glass" | `backdrop-filter`, layered borders, highlight overlays. Provide solid-fill fallback for `prefers-reduced-transparency`. |+| Bento (Apple-style tile grids) | CSS Grid with mixed cell sizes. No single library owns this. |+| Brutalism | Native CSS, monospace, raw borders. No library. |+| Editorial / magazine | Serif type, asymmetric grid, generous whitespace. No library. |+| Dark tech / hacker | Mono + accent neon, terminal motifs. No library. |+| Aurora / mesh gradients | SVG or layered radial gradients. No library. |+| Kinetic typography | Native CSS animations, scroll-driven animations, GSAP for hijacks. No library. |+| **Apple Liquid Glass** | Apple documents this for Apple platforms only. **There is no official `liquid-glass.css`.** Web implementations are approximations using `backdrop-filter` + layered borders + highlights. Label clearly as approximation. |++---++## 3. DEFAULT ARCHITECTURE & CONVENTIONS++Unless the design read picks a real design system (Section 2.A), these are the defaults:++### 3.A Stack+* **Framework:** React or Next.js. Default to Server Components (RSC).+ * **RSC SAFETY:** Global state works ONLY in Client Components. In Next.js, wrap providers in a `"use client"` component.+ * **INTERACTIVITY ISOLATION:** Any component using Motion, scroll listeners, or pointer physics MUST be an isolated leaf with `'use client'` at the top. Server Components render static layouts only.+* **Styling:** **Tailwind v4** (default). Tailwind v3 only if the existing project demands it.+ * For v4: do NOT use `tailwindcss` plugin in `postcss.config.js`. Use `@tailwindcss/postcss` or the Vite plugin.+* **Animation:** **Motion** (the library formerly known as Framer Motion). Import from `motion/react` (`import { motion } from "motion/react"`). The `framer-motion` package still works as a legacy alias - prefer `motion/react` in new code.+* **Fonts:** Always use `next/font` (Next.js) or self-host with `@font-face` + `font-display: swap`. Never link Google Fonts via `<link>` in production.++### 3.B State+* Local `useState` / `useReducer` for isolated UI.+* Global state ONLY for deep prop-drilling avoidance - Zustand, Jotai, or React context.+* **NEVER** use `useState` to track continuous values driven by user input (mouse position, scroll progress, pointer physics, magnetic hover). Use Motion's `useMotionValue` / `useTransform` / `useScroll`. `useState` re-renders the React tree on every change and collapses on mobile.++### 3.C Icons+* **Allowed libraries (priority order):** `@phosphor-icons/react`, `hugeicons-react`, `@radix-ui/react-icons`, `@tabler/icons-react`.+* **Discouraged:** `lucide-react`. Acceptable only when the user explicitly asks for it or the project already depends on it.+* **NEVER hand-roll SVG icons.** If a glyph is missing, install a second library or compose from primitives - do not draw icon paths from scratch.+* **One family per project.** Do not mix Phosphor with Lucide in the same component tree.+* **Standardize `strokeWidth` globally** (e.g. `1.5` or `2.0`).++### 3.D Emoji Policy+Discouraged by default in code, markup, and visible text. Replace symbols with icon-library glyphs. **Override:** allow emojis only when the user explicitly asks for a playful / chat-style / social-native vibe - and even then use them sparingly with intent.++### 3.E Responsiveness & Layout Mechanics+* Standardize breakpoints (`sm 640`, `md 768`, `lg 1024`, `xl 1280`, `2xl 1536`).+* Contain page layouts using `max-w-[1400px] mx-auto` or `max-w-7xl`.+* **Viewport Stability:** NEVER use `h-screen` for full-height Hero sections. ALWAYS use `min-h-[100dvh]` to prevent layout jumping on mobile (iOS Safari address bar).+* **Grid over Flex-Math:** NEVER use complex flexbox percentage math (`w-[calc(33%-1rem)]`). ALWAYS use CSS Grid (`grid grid-cols-1 md:grid-cols-3 gap-6`).++### 3.F Dependency Verification (mandatory)+Before importing ANY 3rd-party library, check `package.json`. If the package is missing, output the install command first. **Never** assume a library exists.++---++## 4. DESIGN ENGINEERING DIRECTIVES (Bias Correction)++LLMs default to clichés. Override these defaults proactively. Each rule has a context-aware override path.++### 4.1 Typography+* **Display / Headlines:** Default `text-4xl md:text-6xl tracking-tighter leading-none`.+* **Body / Paragraphs:** Default `text-base text-gray-600 leading-relaxed max-w-[65ch]`.+* **Sans font choice:**+ * **Discouraged as default:** `Inter`. Pick `Geist`, `Outfit`, `Cabinet Grotesk`, `Satoshi`, or a brand-appropriate serif first.+ * **Override:** Inter is acceptable when the user explicitly asks for a neutral / standard / Linear-style feel, or when the brief is a public-sector / accessibility-first site.+* **Pairings to know:** `Geist` + `Geist Mono`, `Satoshi` + `JetBrains Mono`, `Cabinet Grotesk` + `Inter Tight`, `GT America` + `IBM Plex Mono`.++* **SERIF DISCIPLINE (VERY DISCOURAGED AS DEFAULT):**+ * Serif is **very discouraged as the default font for any project.** "It feels creative / premium / editorial" is NOT a reason to reach for serif. The agent's default mental model that "creative brief = serif" is the single most-tested AI tell in production rounds.+ * **Serif is only acceptable when ONE of these is explicitly true:**+ - The brand brief literally names a serif font, OR+ - The aesthetic family is genuinely editorial / luxury / publication / manuscript / heritage / vintage AND you can articulate why this specific serif fits this specific brand+ * For everything else (creative agency, design studio, modern brand, premium consumer, portfolio, lifestyle), **default sans-serif display** (Geist Display, ABC Diatype, Söhne Breit, Cabinet Grotesk Display, Migra Sans, GT Walsheim, Inter Display, PP Neue Montreal). Sans display fonts are not "boring" — they are the default for the same reason black is the default in fashion.+ * **EMPHASIS RULE (related):** When you want to emphasize a word within a headline (the kinetic "and `spatial` design" type move), use **italic or bold of the SAME font**. Do NOT inject a random serif word into a sans headline (or vice versa) just to add visual interest. Mixed-family emphasis is amateur. Italic/bold emphasis in the same family is the right move.+ * **Specifically BANNED as defaults:** `Fraunces` and `Instrument_Serif` (the two LLM-favorite display serifs).+ * **If a serif is justified** (rare, per the above), rotate from this pool, do NOT reuse the same serif across consecutive projects: PP Editorial New, GT Sectra Display, Cardinal Grotesque, Reckless Neue, Tiempos Headline, Recoleta, Cormorant Garamond, Playfair Display, EB Garamond, IvyPresto, Migra, Editorial Old, Saol Display, Söhne Breit Kursiv, Domaine Display, Canela, Schnyder, Tobias, NB Architekt, ITC Galliard.++* **ITALIC DESCENDER CLEARANCE (mandatory):** When italic is used in display type and the word contains a descender letter (`y g j p q`), `leading-[1]` or `leading-none` will clip the descender. Use `leading-[1.1]` minimum and add `pb-1` or `mb-1` reserve on the wrapping element. Audit every italic word in display headlines before shipping.++### 4.2 Color Calibration+* Max 1 accent color. Saturation < 80% by default.+* **THE LILA RULE:** The "AI Purple / Blue glow" aesthetic is discouraged as a default. No automatic purple button glows, no random neon gradients. Use neutral bases (Zinc / Slate / Stone) with high-contrast singular accents (Emerald, Electric Blue, Deep Rose, Burnt Orange, etc.).+* **Override:** if the brand or brief explicitly asks for purple / violet / lila, embrace it. But execute with intent: consistent palette, harmonised neutrals, restrained gradients. Not generic AI gradient slop.+* **One palette per project.** Do not fluctuate between warm and cool grays within the same project.+* **COLOR CONSISTENCY LOCK (mandatory):** Once an accent color is chosen for a page, it is used on the WHOLE page. A warm-grey site does not suddenly get a blue CTA in section 7. A rose-accented site does not get a teal status badge in the footer. Pick one accent, lock it, audit every component before shipping.++* **PREMIUM-CONSUMER PALETTE BAN (mandatory, second-most-recurring AI-tell):**+ * For premium-consumer briefs (cookware, wellness, artisan, luxury, heritage craft, DTC home goods, etc.) the LLM default is **warm beige/cream + brass/clay/oxblood/ochre + espresso/ink dark text**. Concretely banned hex families as default backgrounds and accents:+ - Backgrounds: `#f5f1ea`, `#f7f5f1`, `#fbf8f1`, `#efeae0`, `#ece6db`, `#faf7f1`, `#e8dfcb` (all "warm paper / cream / chalk / bone")+ - Accents: `#b08947`, `#b6553a`, `#9a2436`, `#9c6e2a`, `#bc7c3a`, `#7d5621` (all "brass / clay / oxblood / ochre")+ - Text: `#1a1714`, `#1a1814`, `#1b1814` (all "espresso / warm near-black")+ * This palette is BANNED as the default reach for premium-consumer briefs. Every premium-consumer site you have ever shipped uses this exact palette. The brand becomes invisible.+ * **Default alternatives (rotate, do not reuse):**+ - **Cold Luxury:** silver-grey + chrome + smoke (think Tesla, Apple Watch Hermes-without-the-leather)+ - **Forest:** deep green + bone + amber accent (think Filson, Patagonia premium)+ - **Black and Tan:** true off-black + warm tan, sharp contrast, no beige+ - **Cobalt + Cream:** saturated blue against a single neutral, no brass+ - **Terracotta + Slate:** warm rust against cool grey, no brass+ - **Olive + Brick + Paper:** muted olive plus brick-red accent+ - **Pure monochrome + single saturated pop:** off-white + off-black + one bright accent (electric blue, emerald, hot pink, etc.)+ * **Palette-rotation rule:** if the previous premium-consumer project you generated used the beige+brass family, this one MUST use a different family. Do not ship the same warm-craft palette twice in a row.+ * **Override:** the beige+brass+espresso palette is acceptable ONLY when the brand brief explicitly names those colors, or when the brand identity is genuinely vintage / artisan / warm-craft AND you can articulate why this specific palette fits this specific brand. Default-reaching for it because "this is a cookware brief" is banned.++### 4.3 Layout Diversification+* **ANTI-CENTER BIAS:** Centered Hero / H1 sections are avoided when `DESIGN_VARIANCE > 4`. Force "Split Screen" (50/50), "Left-aligned content / right-aligned asset", "Asymmetric white-space", or scroll-pinned structures.+* **Override:** centered hero is OK for editorial / manifesto / launch-announcement briefs where the message itself is the design.++### 4.4 Materiality, Shadows, Cards+* Use cards ONLY when elevation communicates real hierarchy. Otherwise group with `border-t`, `divide-y`, or negative space.+* When a shadow is used, tint it to the background hue. No pure-black drop shadows on light backgrounds.+* For `VISUAL_DENSITY > 7`: generic card containers are banned. Data metrics breathe in plain layout.+* **SHAPE CONSISTENCY LOCK (mandatory):** Pick ONE corner-radius scale for the page and stick to it. Options: all-sharp (radius 0), all-soft (radius 12-16px), all-pill (full radius for interactive). Mixed systems are allowed only when there is a documented rule (e.g. "buttons are full-pill, cards are 16px, inputs are 8px") and that rule is followed everywhere. Round buttons in a square layout, or square cards on a pill-button page, is broken design.++### 4.5 Interactive UI States+LLMs default to "static successful state only." Always implement full cycles:+* **Loading:** Skeletal loaders matching the final layout's shape. Avoid generic circular spinners.+* **Empty States:** Beautifully composed; indicate how to populate.+* **Error States:** Clear, inline (forms), or contextual (toasts only for transient).+* **Tactile Feedback:** On `:active`, use `-translate-y-[1px]` or `scale-[0.98]` to simulate a physical push.+* **BUTTON CONTRAST CHECK (mandatory, a11y):** Before shipping any button, verify the button text is readable against the button background. White button + white text, `bg-white` CTA with `text-white` label, transparent button against the page background with no border → all banned. Audit every CTA: contrast ratio WCAG AA min (4.5:1 for body, 3:1 for large text 18px+). Same rule applies to ghost buttons over photographic backgrounds (use a backdrop, scrim, or stroke).+* **CTA BUTTON WRAP BAN (mandatory):** Button text MUST fit on one line at desktop. If a label like "VIEW SELECTED WORK" wraps to 2 or 3 lines, the button is broken. Fix by EITHER shortening the label (3 words max for primary CTAs, ideally 1-2) OR widening the button (do not artificially constrain `max-width` on CTAs). Wrapped CTAs at desktop are a Pre-Flight Fail.+* **NO DUPLICATE CTA INTENT (mandatory):** Two CTAs with the same intent on one page is a Pre-Flight Fail. Examples of same intent: "Get in touch" + "Contact us" + "Let's talk" + "Start a project" + "Start something" + "Reach out" = all "contact" intent → pick ONE label and use it everywhere on the page (nav, hero, footer). Same for "Try free" + "Get started" + "Sign up free" (all "signup" intent) and "View work" + "See selected work" + "Browse projects" (all "portfolio" intent). One label per intent.+* **FORM CONTRAST CHECK (mandatory, a11y):** Form inputs, placeholder text, focus rings, helper text, and error text all pass WCAG AA contrast against the section background. Light placeholders on a near-white form, white form on white page section, form labels grayer than 4.5:1 contrast → all banned. Audit every form before shipping.++### 4.6 Data & Form Patterns+* Label ABOVE input. Helper text optional but present in markup. Error text BELOW input. Standard `gap-2` for input blocks.+* No placeholder-as-label. Ever.++### 4.7 Layout Discipline (Hard Rules. Failing any of these is shipping broken work)++* **Hero MUST fit in the initial viewport.** Headline max 2 lines on desktop, subtext max **20 words** AND max 3-4 lines, CTAs visible without scroll. If the copy is too long: reduce font scale OR cut copy. If you cannot describe the value-prop in 20 words of subtext, the value-prop is unclear, not the rule too tight. Never let the hero overflow and force scroll to find the CTA.+* **Hero font-scale discipline.** Plan font size and image size *together*. If the hero asset is large and the headline is more than 6 words, do not start at `text-7xl/text-8xl`. Default sensible range: `text-4xl md:text-5xl lg:text-6xl` for most heroes; `text-6xl md:text-7xl` only when the headline is 3-5 words. A 4-line hero headline is always a font-size error, never a copy-length error.+* **HERO TOP PADDING CAP (mandatory):** Hero top padding max `pt-24` (≈6rem) at desktop. More than that means the hero content floats halfway down the viewport and reads as a layout bug, not as intentional space. If your hero needs more breathing room, increase font scale or asset size, not top padding.+* **HERO STACK DISCIPLINE (max 4 text elements).** The hero is a single moment, not a feature list. Allowed text elements, max 4 in total:+ 1. Eyebrow (small uppercase label) OR brand strip OR neither - pick zero or one+ 2. Headline (max 2 lines, see above)+ 3. Subtext (max 20 words, max 4 lines)+ 4. CTAs (1 primary + max 1 secondary)+ - **BANNED in the hero:** tiny tagline below CTAs ("Works with GitHub, GitLab, and self-hosted Git"), trust micro-strip ("Used by engineering teams at..."), pricing teaser ("Free for solo, $10/user for teams"), feature bullet list, social-proof avatar row. All of those move to dedicated sections directly below the hero.+ - If you have an eyebrow AND a tagline below CTAs in the same hero, drop the tagline. If you have a brand strip AND a tagline, drop the tagline. One small text element per hero, max.+* **"Used by" / "Trusted by" logo wall belongs UNDER the hero, never inside it.** The hero is for the value prop and primary CTA. The logo wall is a separate section directly below. Do not stuff trust logos into the same flex row as the hero copy.+* **Navigation MUST render on a single line on desktop.** If items don't fit at `lg` (1024px), condense labels, drop secondary items, or move to a hamburger. A two-line nav at desktop is broken design.+* **Navigation height cap: 80px max desktop, default 64-72px.** No huge "agency" nav bars that eat 15% of the viewport.+* **Bento grids MUST have rhythm, not one-sided repetition.** Do not stack 6 left-image / right-text rows. Vary the composition: alternate full-width feature rows, asymmetric tile sizes, vertical breaks.+* **BENTO CELL COUNT RULE (mandatory):** A bento grid has EXACTLY as many cells as you have content for. 3 items → 3 cells (1+2 split, or 2+1, or asymmetric trio). 5 items → 5 cells (2+3, 3+2, hero+4, etc.). If your grid has an empty cell in the middle or at the end, you planned wrong. Re-shape the grid; do not paste a blank tile.+* **Section-Layout-Repetition Ban.** Once you use a layout family for a section (e.g., 3-column-image-cards, full-width-quote, split-text-image), that family can appear at most ONCE on the page. "Selected commissions" must not look like "What we do." A landing page with 8 sections must use at least 4 different layout families.+* **ZIGZAG ALTERNATION CAP (mandatory).** Alternating "left-image + right-text" then "left-text + right-image" zigzag layout = banal. Max 2 sections in a row with this image+text-split pattern. The 3rd consecutive image+text split is a Pre-Flight Fail. Break the pattern with a full-width section, a vertical-stack section, a bento grid, a marquee, or a different layout family.+* **EYEBROW RESTRAINT (mandatory, the #1 violated rule in production tests).** An "eyebrow" is the small uppercase wide-tracking label sitting above a section headline (e.g. `FOUR COLORWAYS`, `SELECTED WORK`, `THE HARDWARE`, `Git-native task management`). Typical CSS signature: `text-[11px] uppercase tracking-[0.18em]`, `font-mono text-[10.5px] uppercase tracking-[0.22em]`. Every AI-built site puts an eyebrow above EVERY section header, producing the same templated rhythm. Hard rule:+ - **Maximum 1 eyebrow per 3 sections.** Hero counts as 1. So a page with 9 sections may use at most 3 eyebrows total.+ - If section A has an eyebrow, the next 2 sections cannot have one.+ - **Pre-Flight Check is mechanical:** count instances of `uppercase tracking` (or similar small-caps mono labels above headlines) across all section components. If count > ceil(sectionCount / 3), the output fails.+ - **What to do instead of an eyebrow:** drop it entirely. The headline alone is enough. If you need to categorize a section, the section's location on the page already categorizes it; no label needed.+* **SPLIT-HEADER BAN (mandatory).** The pattern "left big headline + right small explainer paragraph" as a section header (left col-span-7/8, right col-span-4/5 with a small body paragraph floating in the right column) is **banned as default**. Sections should have ONE focused message. If you genuinely need both a headline and an explainer paragraph, stack them vertically (headline on top, body below, max-width 65ch). Reach for the split-header pattern only when there is a real compositional reason (e.g., the right column carries a visual or interactive element, not just filler text).+* **Bento Background Diversity (mandatory).** Bento and feature-grid sections cannot be 6 white-on-white cards with text inside. At least 2-3 cells in any multi-cell grid need real visual variation: a real image, a brand-appropriate gradient (not AI-purple), a pattern, a tinted background. A cream-on-cream bento with only typography inside reads as boring AI default, even when the rest of the page is good.+* **Mobile collapse must be explicit per section.** For every multi-column layout, declare the `< 768px` fallback in the same component. No "it'll work, Tailwind handles it" assumptions.++### 4.8 Image & Visual Asset Strategy++Landing pages and portfolios are **visual products**. Text-only pages with fake-screenshot divs are slop.++**Priority order for visual assets:**+1. **Image-generation tool first.** If ANY image-gen tool is available in the environment (`generate_image`, MCP image tool, IDE-integrated gen, OpenAI image tools, etc.) you MUST use it to create section-specific assets: hero photography, product shots, texture backgrounds, mood images. Generate at the right aspect ratio for the section. Do not skip this step because hand-rolled CSS feels faster.+2. **Real web images second.** When no gen tool is available, use real photography sources. Acceptable defaults:+ * `https://picsum.photos/seed/{descriptive-seed}/{w}/{h}` for placeholder photography (seed should describe the section, e.g. `marrow-cookware-kitchen`)+ * Actual stock or brand URLs when the brief provides them+ * Open-license sources (Unsplash via direct URL, Pexels) if explicitly allowed+3. **Last resort: tell the user.** If neither is possible, do NOT fill the page with hand-rolled SVG illustrations or div-based "fake screenshots." Instead, leave clearly-labeled placeholder slots (`<!-- TODO: hero product photo, 1600x1200 -->`) and at the end of the response say: *"This page needs real images at: \[list of placements\]. Please generate or provide them."*++**Even minimalist sites need real images.** A pure-text page is not minimalism. It is incomplete work. Even an editorial Linear-style site needs at least 2-3 real images (hero, one product/lifestyle shot, one supporting image). Generate B&W minimalist photography if the brief is restrained; do not skip images entirely because the dial is low.++**Real company logos for social proof.** When the brief calls for a "Trusted by / Used by / Customers" logo wall, do NOT default to plain text wordmarks (`<span>Acme Co</span>` styled in a row). Use real SVG logos:+* **Source: Simple Icons** (`https://cdn.simpleicons.org/{slug}/ffffff` for any color, or `simple-icons` npm package). Covers most known brands.+* **Alternative: devicon** for tech-stack logos (`@svgr/cli` or CDN).+* **Make-up the brand name? Then make-up an SVG mark too.** Generate a simple monogram (one letter in a circle, two-letter ligature, abstract glyph) rendered as an inline `<svg>` matching the page style. Plain text wordmarks for invented brand names look generic.+* **Always** ensure logos render in both light and dark mode (white-on-dark, black-on-light, or single-color theme variable).+* **LOGO-ONLY rule (mandatory):** logo wall = logos and nothing else. Do NOT print industry / category labels below each logo (no `Vercel` + `hosting` underneath, no `Stripe` + `payments`, no `Cloudflare` + `infra`). The logo is the credibility, the label adds nothing the user does not already know. Optional: brand name as alt-text for screen readers, optional link to the brand's site. That is it.++**Hand-rolled illustrations:**+* SVG icons from libraries: fine (see Section 3.C).+* Hand-rolled decorative SVGs (custom illustrations, logos, marks): **strongly discouraged**, never as default. Acceptable only when:+ - The brief explicitly calls for it ("draw me an SVG logo")+ - It's a single, simple geometric mark (a square, a circle, a wordmark in display type)+ - You're confident in the output quality++**Div-based fake screenshots are banned.** A "hand-built product preview" rendered with `<div>` rectangles, fake task lists, fake dashboards, fake terminal windows is a Tell. If you need to show a product:+* Use a real screenshot URL if one exists+* Generate one via image tool+* Use a real component preview (an actual mini-version of the UI inside the page)+* Or skip the preview entirely and use editorial photography++**Hero needs a real visual.** Text + gradient blob is not a hero - it's a placeholder.++### 4.9 Content Density++Landing pages live on the **first impression**, not the full read. Cut ruthlessly.++* **Default content shape per section:** short headline (≤ 8 words) + short sub-paragraph (≤ 25 words) + one visual asset OR one CTA. Anything more must be justified by the section's job.+* **No data-dump sections.** A 20-row publication table, a 30-row award list, a giant pricing matrix on a marketing page = wrong layout. Use:+ - Top 3-5 highlights + "View full list" link+ - Marquee / carousel for breadth+ - Different page entirely if the data is the product+* **Long lists need a different UI component, not a longer list.** Default `<ul>` with bullets / `divide-y` rows is the lazy choice. If you have > 5 items, reach for one of these instead:+ - 2-column split with grouped items+ - Card grid with image + label per item+ - Tabs / accordion if items are categorisable+ - Horizontal scroll-snap pills+ - Carousel for breadth-heavy lists (testimonials, logos, capabilities)+ - Marquee for "lots-of-things-that-don't-need-individual-attention"+ A spec sheet with 10 rows + a hairline under every row is the WORST default. Either group rows into 2-3 chunks with sparse dividers, or move to a card-per-spec layout.+* **Spec sheets specifically (the Marrow-cookware pattern).** A long product specification table with `border-b` on every row is the AI default for cookware / hardware / apparel / artisan-goods briefs. Banned. Concrete alternatives:+ - **2-col card grid:** each spec gets its own card with the spec name, the value (large display number), and a one-line "why it matters" body. Cards arranged 2-col on desktop, 1-col mobile.+ - **Scroll-snap horizontal pills:** each spec is a pill, user can flick through.+ - **Grouped chunks:** group 10 specs into 3 logical clusters (e.g. "Materials", "Cooking", "Warranty"), each cluster gets ONE soft divider and a cluster heading.+ - **Featured-vs-rest:** 3-4 hero specs visualised as large display tiles, the rest collapsed under a "View full specifications" disclosure.++* **COPY SELF-AUDIT (mandatory before ship):** Before declaring any task done, re-read every visible string on the page (headlines, subheads, eyebrows, button labels, body copy, captions, alt text, footer text, error messages). Flag any string that is:+ - **Grammatically broken** ("free on its past", "two plans but one is honest", "to put it on the table" out of context)+ - **Has unclear referents** ("we plan to stay that way" without prior context)+ - **Sounds like AI hallucination** (cute-but-wrong wordplay, forced metaphors that don't track, "elegant nothing" phrases)+ - **Reads like an LLM trying to sound thoughtful** (passive-aggressive humility, fake-craftsman labels, mock-poetic micro-meta)+ Rewrite every flagged string. If unsure whether a string makes sense, replace it with a plain functional sentence. AI-generated cute copy is worse than boring copy.+* **Fake-precise numbers are flagged.** Numbers like `92%`, `4.1×`, `48k`, `5.8 mm`, `13.4 lb` either:+ - Come from real data (brief, brand guidelines, public metrics) - fine+ - Are explicitly labeled as mock (`<!-- mock -->`, "example", "sample data") - fine+ - Are AI-invented spec aesthetics - banned. Don't fake engineering precision the brand doesn't claim.+* **One copy register per page.** Don't mix technical mono ("47 tasks · 0.6 ctx-switches/day"), editorial prose, and marketing punch in the same composition unless the brand voice explicitly calls for it.++### 4.10 Quotes & Testimonials++* **Max 3 lines** of quote body. Never 6. If the original quote is longer → cut it. A landing-page quote is a snippet, not the full review.+* For very small font sizes (e.g. footer-style testimonials), the line cap can stretch slightly. Spirit: "fits in a glance."+* **No em-dashes inside the quote text** as design flourish (long pauses, kinetic em-dashes, em-dash-bullets). See Section 9.G - em-dash is completely banned.+* Attribution: name + role + (optionally) company. Never name only ("- Sarah").+* Quote marks: use real typographic quotes ( " " ) or none at all. Not straight ASCII ( " ).++### 4.11 Page Theme Lock (Light / Dark Mode Consistency)++The page has ONE theme. Sections do not invert.++* If the page is dark mode, ALL sections are dark mode. No light-mode-warm-paper section sandwiched between dark sections (or vice versa). The user must not feel they walked into a different website mid-scroll.+* The exception: if the brief explicitly calls for a "Color Block Story" or "Theme Switch on Scroll" device AND that is a deliberate composition (one full theme switch with a strong transition, not random alternation), it is allowed once per page.+* Default behaviour: pick light, dark, or auto (`prefers-color-scheme`) at the page level and lock it. Section-level background tints within the same theme family are fine (`bg-zinc-950` next to `bg-zinc-900`); flipping to `bg-amber-50` in the middle of a `bg-zinc-950` page is broken.+* When using a design system with built-in theming (Radix Themes, shadcn/ui with `<Theme>`), set the theme ONCE in `layout.tsx` or the page root. Do not let individual sections override.++---++## 5. CONTEXT-AWARE PROACTIVITY++These are tools, not defaults. Use them when the design read calls for them. **None of these fire automatically.**++* **Liquid Glass / Glassmorphism:** Appropriate for premium consumer, Apple-adjacent, luxury brand, or media-overlay vibes. Inappropriate for dashboards, public-sector, or "boring B2B." When used, go beyond `backdrop-blur`: add a 1px inner border (`border-white/10`) and a subtle inner shadow (`shadow-[inset_0_1px_0_rgba(255,255,255,0.1)]`) for physical edge refraction. Provide a solid-fill fallback under `prefers-reduced-transparency`.+* **Magnetic Micro-physics:** Use when `MOTION_INTENSITY > 5` AND the brief reads premium / playful / agency. Implement EXCLUSIVELY with Motion's `useMotionValue` / `useTransform` outside the React render cycle. Never `useState`. See Section 3.B.+* **Perpetual Micro-Interactions** (Pulse, Typewriter, Float, Shimmer, Carousel): Use when `MOTION_INTENSITY > 5` AND the section actively benefits from motion (status indicators, live feeds, AI-feel). **Not every card needs an infinite loop.** If a section is informational, leave it still. Apply Spring Physics (`type: "spring", stiffness: 100, damping: 20`) - no linear easing.+* **"Motion claimed, motion shown."** If `MOTION_INTENSITY > 4`, the page must actually move: entry transitions on hero, scroll-reveal on key sections, hover physics on CTAs, at minimum. A static page that claims `MOTION_INTENSITY: 7` is broken. Conversely, if you cannot ship working motion in the available scope, drop the dial to 3 and ship a clean static page. Never half-build motion that breaks (cut-off ScrollTriggers, jumpy enters, missing cleanups).+* **MOTION MUST BE MOTIVATED (mandatory).** Before adding any animation, ask: "what does this animation communicate?" Valid answers: hierarchy (drawing attention to the right thing), storytelling (revealing content in sequence that matches a narrative), feedback (acknowledging a user action), state transition (showing something changed). Invalid answer: "it looked cool". GSAP everywhere because GSAP is available is amateur. Each ScrollTrigger, each marquee, each pinned section needs a reason. If you cannot articulate the reason in one sentence, drop the animation.+* **MARQUEE MAX-ONE-PER-PAGE (mandatory).** Horizontal scrolling text marquees ("logos endlessly scrolling", "manifesto scrolling sideways", "kinetic word strip") are appropriate at most ONCE per page. Two or more marquees on the same page reads as lazy filler. Pick the one section where the marquee actually serves the content; the others get a different layout.+* **GSAP Sticky-Stack Pattern (when scroll-stack is used).** A "card stack on scroll" must be a REAL sticky-stack, not a sequential reveal list. See Section 5.A below for the canonical code skeleton. Common failure: trigger fires halfway through scroll instead of pinning at viewport top. Fix: `start: "top top"` not `start: "top center"` or `"top 80%"`.+* **GSAP Horizontal-Pan Pattern (when horizontal scroll-hijack is used).** See Section 5.B below for the canonical skeleton. Common failure: animation starts before the section is pinned, so the user sees half a slide. Same fix: `start: "top top"`, pin the wrapper, scrub the inner track.++### 5.A Sticky-Stack - Canonical Skeleton++```tsx+"use client";+import { useRef, useEffect } from "react";+import { gsap } from "gsap";+import { ScrollTrigger } from "gsap/ScrollTrigger";+import { useReducedMotion } from "motion/react";++gsap.registerPlugin(ScrollTrigger);++export function StickyStack({ cards }: { cards: React.ReactNode[] }) {+ const ref = useRef<HTMLDivElement>(null);+ const reduce = useReducedMotion();++ useEffect(() => {+ if (reduce || !ref.current) return;+ const ctx = gsap.context(() => {+ const cardEls = gsap.utils.toArray<HTMLElement>(".stack-card");+ cardEls.forEach((card, i) => {+ if (i === cardEls.length - 1) return;+ ScrollTrigger.create({+ trigger: card,+ start: "top top", // pin at viewport top+ endTrigger: cardEls[cardEls.length - 1],+ end: "top top",+ pin: true,+ pinSpacing: false,+ });+ gsap.to(card, {+ scale: 0.92,+ opacity: 0.55,+ ease: "none",+ scrollTrigger: {+ trigger: cardEls[i + 1],+ start: "top bottom",+ end: "top top",+ scrub: true,+ },+ });+ });+ }, ref);+ return () => ctx.revert();+ }, [reduce]);++ return (+ <div ref={ref} className="relative">+ {cards.map((card, i) => (+ <div+ key={i}+ className="stack-card sticky top-0 min-h-[100dvh] flex items-center justify-center"+ >+ {card}+ </div>+ ))}+ </div>+ );+}+```++Critical points: `start: "top top"`, `pin: true`, every card except the last is pinned, the scale/opacity transform is driven by the NEXT card's scroll trigger (so previous card shrinks as next one arrives).++### 5.B Horizontal-Pan - Canonical Skeleton++```tsx+"use client";+import { useRef, useEffect } from "react";+import { gsap } from "gsap";+import { ScrollTrigger } from "gsap/ScrollTrigger";+import { useReducedMotion } from "motion/react";++gsap.registerPlugin(ScrollTrigger);++export function HorizontalPan({ children }: { children: React.ReactNode }) {+ const wrap = useRef<HTMLDivElement>(null);+ const track = useRef<HTMLDivElement>(null);+ const reduce = useReducedMotion();++ useEffect(() => {+ if (reduce || !wrap.current || !track.current) return;+ const ctx = gsap.context(() => {+ const distance = track.current!.scrollWidth - window.innerWidth;+ gsap.to(track.current, {+ x: -distance,+ ease: "none",+ scrollTrigger: {+ trigger: wrap.current,+ start: "top top", // pin starts when section top hits viewport top+ end: () => `+=${distance}`, // scroll distance = track width minus viewport+ pin: true,+ scrub: 1,+ invalidateOnRefresh: true,+ },+ });+ }, wrap);+ return () => ctx.revert();+ }, [reduce]);++ return (+ <section ref={wrap} className="relative overflow-hidden">+ <div ref={track} className="flex h-[100dvh] items-center">+ {children}+ </div>+ </section>+ );+}+```++Critical points: `start: "top top"`, `pin: true`, `end: "+=${distance}"` (scroll length = horizontal travel needed), `scrub: 1`. The wrapper is pinned, the inner track slides horizontally as the user scrolls vertically.++### 5.C Scroll-Reveal Stagger - Canonical Skeleton (lighter alternative)++For simple "items appear as they enter viewport" (no pinning), prefer Motion's `whileInView` over GSAP - lighter, no ScrollTrigger needed:++```tsx+"use client";+import { motion, useReducedMotion } from "motion/react";++export function RevealStagger({ items }: { items: string[] }) {+ const reduce = useReducedMotion();+ return (+ <ul className="grid gap-6">+ {items.map((item, i) => (+ <motion.li+ key={item}+ initial={reduce ? false : { opacity: 0, y: 24 }}+ whileInView={{ opacity: 1, y: 0 }}+ viewport={{ once: true, amount: 0.3 }}+ transition={{+ duration: 0.6,+ delay: i * 0.06,+ ease: [0.16, 1, 0.3, 1],+ }}+ >+ {item}+ </motion.li>+ ))}+ </ul>+ );+}+```++Use this for: feature lists, testimonial grids, logo walls, anything that just needs "enter on scroll." Save GSAP for actual pin/scrub work.++### 5.D Forbidden Animation Patterns++* **`window.addEventListener("scroll", ...)`** is banned. It runs on every scroll frame, jank-prone, no batching. Use Motion's `useScroll()`, GSAP's `ScrollTrigger`, IntersectionObserver, or CSS `scroll-driven animations` (`animation-timeline: view()`).+* **Custom scroll progress calculations using `window.scrollY`** in React state. Same reason. Re-renders on every frame.+* **`requestAnimationFrame` loops that touch React state.** Use motion values (`useMotionValue` + `useTransform`) instead.+* **Layout Transitions:** Use Motion's `layout` and `layoutId` props for visible state changes (re-ordering lists, expanding modals, shared elements between routes). Do not wrap static content in `layout` props "for safety" - it costs measurement work.+* **Staggered Orchestration:** Use `staggerChildren` (Motion) or CSS cascade (`animation-delay: calc(var(--index) * 100ms)`) for reveal moments where sequence matters. For `staggerChildren`, parent (`variants`) and children MUST share the same Client Component tree.++---++## 6. PERFORMANCE & ACCESSIBILITY GUARDRAILS++### 6.A Hardware Acceleration+* Animate ONLY `transform` and `opacity`. Never animate `top`, `left`, `width`, `height`.+* Use `will-change: transform` sparingly - only on elements that will actually animate.++### 6.B Reduced Motion (mandatory)+* **Any motion above `MOTION_INTENSITY > 3` MUST honor `prefers-reduced-motion`.** This is non-negotiable.+* In Motion: wrap with `useReducedMotion()` and degrade to static.+* In CSS: gate animations behind `@media (prefers-reduced-motion: no-preference)` or provide an override block under `@media (prefers-reduced-motion: reduce)` that disables.+* Infinite loops, parallax, scroll-hijack, and magnetic physics MUST collapse to static / instant under reduced motion.++### 6.C Dark Mode (mandatory for any consumer-facing page)+* Design for **both modes from the start**. Never ship light-only or dark-only without explicit user instruction.+* Use Tailwind `dark:` variant OR CSS variables for tokens. Pick one strategy per project.+* **Do not prescribe specific dark-mode colors here.** The brief decides. Maintain visual hierarchy, brand identity, and WCAG AA contrast (AAA for body) across both modes.+* Respect `prefers-color-scheme: dark`. Default to system preference unless the brand insists on one mode.++### 6.D Core Web Vitals Targets+* **LCP** < 2.5s. Hero image must be `next/image priority` or preloaded.+* **INP** < 200ms. Heavy work off main thread.+* **CLS** < 0.1. Reserve space for images, fonts, embeds.+* Run Lighthouse before declaring a page done.++### 6.E DOM Cost+* Apply grain / noise filters EXCLUSIVELY to fixed, `pointer-events-none` pseudo-elements (e.g., `fixed inset-0 z-[60] pointer-events-none`). NEVER on scrolling containers - continuous GPU repaints destroy mobile FPS.+* Be aware of bundle size. Motion is not tiny. Three.js is large. Lazy-load anything that's not above-the-fold.++### 6.F Z-Index Restraint+NEVER spam arbitrary `z-50` or `z-10`. Use z-index strictly for systemic layer contexts (sticky navbars, modals, overlays, grain). Document the z-index scale in a project constants file.++---++## 7. DIAL DEFINITIONS (Technical Reference)++### DESIGN_VARIANCE (Level 1-10)+* **1-3 (Predictable):** Symmetrical CSS Grid (12-col, equal fr-units), equal paddings, centered alignment.+* **4-7 (Offset):** `margin-top: -2rem` overlaps, varied image aspect ratios (4:3 next to 16:9), left-aligned headers over center-aligned data.+* **8-10 (Asymmetric):** Masonry layouts, CSS Grid with fractional units (`grid-template-columns: 2fr 1fr 1fr`), massive empty zones (`padding-left: 20vw`).+* **MOBILE OVERRIDE:** For levels 4-10, asymmetric layouts above `md:` MUST collapse to strict single-column (`w-full`, `px-4`, `py-8`) on viewports `< 768px`.++### MOTION_INTENSITY (Level 1-10)+* **1-3 (Static):** No automatic animations. CSS `:hover` and `:active` states only. `prefers-reduced-motion` is the default mode anyway.+* **4-7 (Fluid CSS):** `transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1)`. `animation-delay` cascades for load-ins. Focus on `transform` and `opacity`.+* **8-10 (Advanced Choreography):** Complex scroll-triggered reveals, parallax, scroll-driven animation (CSS `animation-timeline` or GSAP ScrollTrigger). Use Motion hooks. **NEVER use `window.addEventListener('scroll')`** - it is a hard ban, not a "prefer-not." See Section 5.D for the allowed alternatives.++### VISUAL_DENSITY (Level 1-10)+* **1-3 (Art Gallery):** Lots of white space. Huge section gaps (`py-32` to `py-48`). Expensive, clean.+* **4-7 (Daily App):** Standard web app spacing (`py-16` to `py-24`).+* **8-10 (Cockpit):** Tight paddings. No card boxes; 1px lines separate data. Mandatory: `font-mono` for all numbers.++---++## 8. DARK MODE PROTOCOL++Dual-mode by default. Never assume light-only unless the brief is print-emulating editorial.++### 8.A Token Strategy (pick one, stick to it)+* **Tailwind `dark:` variant** (default for utility-first projects): every color utility paired with its dark variant (`bg-white dark:bg-zinc-950`, `text-gray-900 dark:text-gray-100`).+* **CSS variables** (for shadcn/ui, Radix Themes, or component libraries with theming): define semantic tokens (`--surface`, `--surface-elevated`, `--text-primary`, `--accent`) and swap values under `[data-theme="dark"]` or `@media (prefers-color-scheme: dark)`.++### 8.B Do Not Prescribe Specific Colors Here+The brief and brand decide. This skill enforces only:+* **Contrast** - WCAG AA minimum for body text, AAA target for hero copy.+* **Hierarchy parity** - visual hierarchy that works in light must work in dark. If a CTA pops in light, it pops in dark.+* **Brand fidelity** - primary brand color stays recognisable. Don't desaturate the brand into a dark mode.+* **No pure `#000000` and no pure `#ffffff`** - use off-black (zinc-950, near-black warm gray) and off-white. Pure values kill depth.++### 8.C Default Mode+Respect `prefers-color-scheme` unless the brand insists. Add a manual toggle if either mode would lose key brand expression.++### 8.D Test in Both Modes Before Finishing+Open the page in both modes during development. Do not ship a page you've only seen in one mode.++---++## 9. AI TELLS (Forbidden Patterns)++Avoid these signatures unless the brief explicitly asks for them.++### 9.A Visual & CSS+* **NO neon / outer glows** by default. Use inner borders or subtle tinted shadows.+* **NO pure black (`#000000`).** Off-black, zinc-950, or charcoal.+* **NO oversaturated accents.** Desaturate to blend with neutrals.+* **NO excessive gradient text** for large headers.+* **NO custom mouse cursors.** Outdated, accessibility-hostile, perf-hostile.++### 9.B Typography+* **AVOID Inter as default.** See Section 4.1. Override path exists.+* **NO oversized H1s** that just scream. Control hierarchy with weight + color, not raw scale.+* **Serif constraints:** Serif for editorial / luxury / publication. Not for dashboards.++### 9.C Layout & Spacing+* **Mathematically perfect** padding and margins. No floating elements with awkward gaps.+* **NO 3-column equal feature cards.** The generic "three identical cards horizontally" feature row is banned. Use 2-column zig-zag, asymmetric grid, scroll-pinned, or horizontal-scroll alternative.++### 9.D Content & Data ("Jane Doe" Effect)+* **NO generic names.** "John Doe", "Sarah Chan", "Jack Su" → use creative, realistic, locale-appropriate names.+* **NO generic avatars.** No SVG "egg" or Lucide user icons → use believable photo placeholders or specific styling.+* **NO fake-perfect numbers.** Avoid `99.99%`, `50%`, `1234567`. Use organic, messy data (`47.2%`, `+1 (312) 847-1928`).+* **NO startup-slop brand names.** "Acme", "Nexus", "SmartFlow", "Cloudly" → invent contextual, premium names that sound real.+* **NO filler verbs.** "Elevate", "Seamless", "Unleash", "Next-Gen", "Revolutionize" → concrete verbs only.++### 9.E External Resources & Components+* **NO hand-rolled SVG icons.** Use Phosphor / HugeIcons / Radix / Tabler. Lucide on explicit request only.+* **Hand-rolled decorative SVGs strongly discouraged** as default (see Section 4.8).+* **NO div-based fake screenshots.** Never build a fake product UI out of `<div>` rectangles to simulate a screenshot. Use real images, generated images, or skip the preview.+* **NO broken Unsplash links.** Use `https://picsum.photos/seed/{descriptive-string}/{w}/{h}`, or generated photo placeholders, or actual assets.+* **shadcn/ui customization:** Allowed, but NEVER in default state. Customize radii, colors, shadows, typography to the project aesthetic.+* **Production-Ready Cleanliness:** Code visually clean, memorable, meticulously refined.++### 9.F Production-Test Tells (banned outright)++These patterns came out of real LLM-generated landing-page tests. They are the signatures the model defaults to when it tries to "look designed." Treat them as hard bans unless the brief explicitly calls for one.++**Hero & top-of-page**+* **NO version labels in the hero.** `V0.6`, `v2.0`, `BETA`, `INVITE-ONLY PREVIEW`, `EARLY ACCESS`, `ALPHA` - banned as default eyebrows. Only acceptable when the brief is explicitly about a product launch / preview status.+* **NO "Brand · No. 01"-style sub-eyebrows.** "Marrow · No. 01 · The 6-quart" type micro-meta lines. Skip them.++**Section numbering & micro-labels**+* **NO section-number eyebrows.** `00 / INDEX`, `001 · Capabilities`, `002 · Featured commission`, `06 · how it works`, `05 · The honest table` - banned. Eyebrows should name the topic in plain language, not enumerate.+* **NO `01 / 4`-style pagination on images or bento tiles.** If the user can count, they don't need the label.+* **NO `Scroll · 001 Capabilities`-style scroll cues.** A simple arrow or "Scroll" is enough; no section-number prefix.+* **NO "Index of Work, 2018 - 2026"-style range labels** as eyebrows. Just say what the section is.++**Separators & dots**+* **The middle-dot (`·`) is rationed.** Maximum 1 per line in metadata strips. Do NOT use it as the default separator for everything ("foo · bar · baz · qux · quux"). If you need a separator family, prefer line breaks, hairlines, or columns.+* **NO decorative colored status dots on every list/nav/badge.** A colored dot before "ONE Q4 SLOT OPEN" or before every nav link, or every task row - banned by default. Acceptable only when the dot conveys actual semantic state (a server status, an availability flag) and is used sparingly.++**Em-dashes & typography flourishes**+* **NO em-dash (`—`) as a design element OR anywhere else.** See Section 9.G below for the complete, non-negotiable ban. The em-dash character is forbidden in headlines, eyebrows, pills, body copy, quotes, attribution, captions, button text, and alt text. Use the regular hyphen (`-`).+* **NO `<br>`-broken-and-italicized headlines** as a default "design move." "for thirty\<br\>*years.*" type splits. Headlines should read naturally first, get clever only when the brief demands it.+* **NO vertical rotated text** ("INDEX OF WORK, 2018 - 2026" rotated 90°). Agency-portfolio cliché. Use it only when the brief is explicitly agency / Awwwards / experimental AND it serves a real composition purpose.+* **NO crosshair / hairline grid lines as decoration.** Vertical and horizontal lines drawn just to make the page "feel designed" - banned. Use them only when they organize real content.++**Fake product previews**+* **NO div-based fake product UI in the hero** (fake task list, fake terminal, fake dashboard built from styled divs). It is the #1 LLM-design Tell. Use a real screenshot, a generated image, a real component preview, or none at all.+* **NO fake version footers** ("v0.6.2-rc.1", "last sync 4s ago · main") inside fake screenshots. Adds nothing, screams AI.++**Marketing-copy Tells**+* **NO "Quietly in use at" / "Quietly trusted by"** social-proof headers. Use natural language: "Trusted by", "Used at", "Customers include", or skip the heading entirely if the logos speak.+* **NO "From the field" / "Field notes" / "Currently on the bench" / "On our desks" / "Loose plates" style poetic labels** on quote, blog, or sidebar sections. Reads as performative-craftsman. Use plain functional labels ("Testimonials", "Latest writing", "Now working on") or skip the label.+* **NO "We respect the French ones"-style** mock-humble industry-references in body copy. Cute and AI-y.+* **NO weather / locale strips** ("LIS 14:23 · 18°C") in headers/footers unless the brief is explicitly about a place / time-zone-distributed studio.+* **NO micro-meta-sentences under eyebrows.** Sentences like *"Each of these is a feature we ship today, not a roadmap promise. The list will stay short on purpose."* sitting under a section heading are clutter. Eyebrow + Headline + Body is enough.+* **NO generic step labels.** "Stage 1 / Stage 2 / Stage 3", "Step 1 / Step 2 / Step 3", "Phase 01 / Phase 02 / Phase 03", "Pass One / Pass Two / Pass Three". Banned. The actual step content is the label. If you must show progression, use the verb-noun directly ("Install", "Configure", "Ship") not "Stage 1: Install".++**Pills, labels and version stamps**+* **NO pills/labels/tags overlaid on images.** No `<span>` overlays on photos with tags like `Brand · 02`, `PLATE · BRAND`, `Field notes - journal`. Either let the image speak alone, or add a caption directly below (outside the image).+* **NO photo-credit captions as decoration.** Strings like `Field study no. 12 · Ines Caetano`, `Plate 03 · House archive`, `Frame XII · 35mm` under stock/picsum images are pretentious. Photo credit is allowed ONLY when there is a real photographer being credited for a real photo (with permission). Otherwise: skip the caption or use a one-line functional caption ("The 6-quart, in Sage.").+* **NO version footers on marketing pages.** Footer strings like `v1.4.2`, `Build 0048`, `last sync 4s ago · main` are CLI / devtool fixtures, not landing-page content. Banned on marketing/landing/portfolio pages.+* **NO "Reservation 412 of 800"-style live-stock counters** as decoration. Only if the brief is explicitly a limited-run waitlist with real data.++**Decoration text strips**+* **NO decoration text strip at hero bottom.** Patterns like `BRAND. MOTION. SPATIAL.`, `TYPE / FORM / MOTION`, `DESIGN · BUILD · SHIP`, `ESTD. 2018 · LISBON · BRAND. MOTION. SPATIAL.` as a small mono-caps strip across the bottom of the hero are an agency-portfolio cliché. Banned by default. Only acceptable when the strip carries real, navigable links (sticky bottom nav) or real status info (cookie banner, build info on a docs site).+* **NO floating top-right sub-text in section headings.** Pattern: section has a giant left-aligned headline; in the top-right corner of the same section header there is a small explainer paragraph floating with no clear alignment to anything else. That floater is the Tell. Either put the sub-text directly under the headline, or build a clean 2-column header (left: headline, right: aligned body), but not a tiny corner paragraph.++**Lists, dividers and scoring**+* **NO `border-t` + `border-b` on every row of a long list / spec table.** Pick one (bottom-border between rows OR top-border above the group) and use it sparsely. A 10-row spec table with hairlines under each row is the laziest layout - see Section 4.9 for alternative UI components.+* **NO scoring/progress bars with filled background tracks** as comparison visuals. If you need to show "X out of Y" comparisons, prefer a number + small icon, or a tiny inline bar WITHOUT a background track. Big filled `bg-zinc-200` tracks with a partial fill on top are dashboard-UI clutter on a landing page.++**Locale, time, scroll cues**+* **Locale / city-name / time / weather strips are banned for 99% of briefs.** "Lisbon, working with founders" in the hero, "1200-690 Lisbon, Portugal" in the footer, "Lisbon 14:23 · 18°C" in the nav. These are agency-portfolio decoration tells. Allowed ONLY when: the brief explicitly describes a globally-distributed studio with timezone-relevant work, OR a travel-focused brand, OR a real-world physical venue. A single contact-address mention in the footer is fine; an atmospheric locale strip is not.+* **Scroll cues are banned.** `Scroll`, `↓ scroll`, `Scroll to explore`, `Scroll to walk through it`, animated mouse-wheel icons. If the user has not scrolled yet, they are looking at the hero. They know what scroll is. The bottom of the viewport does not need a label.+* **ZERO decorative status dots by default.** A coloured dot before nav items, before list rows, before badges, before status labels is a Tell. Only acceptable when conveying real semantic state (a live indicator on actual server status, a live availability flag) and limited to one per page section.++### 9.G EM-DASH BAN (the single most-violated Tell)++**Em-dash (`—`) is COMPLETELY banned.** It is the LLM's signature stylistic crutch and it is the #1 visual Tell in production tests. There is no "limited use" allowance, no "natural language frequency" allowance, no "in body copy is fine" allowance. None.++* **Banned in headlines.** Use a period or a comma.+* **Banned in eyebrows / labels / pills / button text / image captions / nav items.** Replace with line breaks, columns, or hairlines.+* **Banned in body copy.** Restructure the sentence: two sentences with a period, OR a comma, OR parentheses, OR a colon.+* **Banned in quote attribution.** Use a normal hyphen with spaces (` - `) or a line break + smaller-weight name.+* **Banned in en-dash form too (`–`) when used as a separator.** Date ranges (`2018-2026`) use a hyphen. Number ranges (`€40-80k`) use a hyphen.++The ONLY permitted dash characters on the page are:+* Regular hyphen `-` (for compound words, ranges, line dividers in markup)+* Minus sign in math (`-5°C`)++If your output contains a single `—` or `–` anywhere visible to the user, the output fails the Pre-Flight Check and must be rewritten.++This rule is non-negotiable. The agent has historically ignored em-dash limits when phrased as "use sparingly." The phrasing here is binary: zero em-dashes.++---++## 10. REFERENCE VOCABULARY (Pattern Names the Agent Should Know)++This is a vocabulary, not a library. The agent should KNOW these pattern names to communicate about them, design with them in mind, and reach for them when the design read calls for them. **Implementations and code sketches live in the Block Library (Section 12), which is populated iteratively.**++### Hero Paradigms+* **Asymmetric Split Hero** - Text on one side, asset on the other, generous white space.+* **Editorial Manifesto Hero** - Large type, no asset, almost-poster.+* **Video / Media Mask Hero** - Type cut out as mask over video background.+* **Kinetic-Type Hero** - Animated typography as the primary visual.+* **Curtain-Reveal Hero** - Hero parts on scroll like a curtain.+* **Scroll-Pinned Hero** - Hero stays pinned while content scrolls behind.++### Navigation & Menus+* **Mac OS Dock Magnification** - Edge nav, icons scale fluidly on hover.+* **Magnetic Button** - Pulls toward cursor.+* **Gooey Menu** - Sub-items detach like viscous liquid.+* **Dynamic Island** - Morphing pill for status / alerts.+* **Contextual Radial Menu** - Circular menu expanding at click point.+* **Floating Speed Dial** - FAB springing into curved secondary actions.+* **Mega Menu Reveal** - Full-screen dropdown, stagger-fade content.++### Layout & Grids+* **Bento Grid** - Asymmetric tile grouping (Apple Control Center).+* **Masonry Layout** - Staggered grid, no fixed row height.+* **Chroma Grid** - Borders / tiles with subtle animating gradients.+* **Split-Screen Scroll** - Two halves sliding in opposite directions.+* **Sticky-Stack Sections** - Sections that pin and stack on scroll.++### Cards & Containers+* **Parallax Tilt Card** - 3D tilt tracking mouse coordinates.+* **Spotlight Border Card** - Borders illuminate under cursor.+* **Glassmorphism Panel** - Frosted glass with inner refraction.+* **Holographic Foil Card** - Iridescent rainbow shift on hover.+* **Tinder Swipe Stack** - Physical card stack, swipe-away.+* **Morphing Modal** - Button expands into its own dialog.++### Scroll Animations+* **Sticky Scroll Stack** - Cards stick and physically stack.+* **Horizontal Scroll Hijack** - Vertical scroll → horizontal pan.+* **Locomotive / Sequence Scroll** - Video / 3D sequence tied to scrollbar.+* **Zoom Parallax** - Central background image zooming on scroll.+* **Scroll Progress Path** - SVG line drawing along scroll.+* **Liquid Swipe Transition** - Page transition like viscous liquid.++### Galleries & Media+* **Dome Gallery** - 3D panoramic gallery.+* **Coverflow Carousel** - 3D carousel with angled edges.+* **Drag-to-Pan Grid** - Boundless draggable canvas.+* **Accordion Image Slider** - Narrow strips expanding on hover.+* **Hover Image Trail** - Mouse leaves popping image trail.+* **Glitch Effect Image** - RGB-channel shift on hover.++### Typography & Text+* **Kinetic Marquee** - Endless text bands reversing on scroll.+* **Text Mask Reveal** - Massive type as transparent window to video.+* **Text Scramble Effect** - Matrix-style decoding on load / hover.+* **Circular Text Path** - Text curving along spinning circle.+* **Gradient Stroke Animation** - Outlined text with running gradient.+* **Kinetic Typography Grid** - Letters dodging the cursor.++### Micro-Interactions & Effects+* **Particle Explosion Button** - CTA shatters into particles on success.+* **Liquid Pull-to-Refresh** - Reload indicator like detaching droplets.+* **Skeleton Shimmer** - Shifting light reflection across placeholders.+* **Directional Hover-Aware Button** - Fill enters from cursor's exact side.+* **Ripple Click Effect** - Wave from click coordinates.+* **Animated SVG Line Drawing** - Vectors drawing themselves in real time.+* **Mesh Gradient Background** - Organic lava-lamp blobs.+* **Lens Blur Depth** - Background UI blurred to focus foreground action.++### Animation Library Choice+* **Motion (`motion/react`)** - default for UI / Bento / state-change motion.+* **GSAP + ScrollTrigger** - for full-page scrolltelling and scroll hijacks. Isolate in dedicated leaf components with `useEffect` cleanup.+* **Three.js / WebGL** - for canvas backgrounds and 3D scenes. Same isolation rule.+* **NEVER mix GSAP / Three.js with Motion in the same component tree.** They fight over the same frames.++---++## 11. REDESIGN PROTOCOL++This skill handles **greenfield builds AND redesigns**. Misclassifying the mode is the single biggest source of bad redesign output.++### 11.A Detect the Mode (first action)+* **Greenfield** - no existing site, or full overhaul approved. Dial baseline from Section 1.+* **Redesign - Preserve** - modernise without breaking the brand. Audit first, extract brand tokens, evolve gradually.+* **Redesign - Overhaul** - new visual language on top of existing content. Treat as greenfield for visuals; preserve content and IA.++If ambiguous, ask **once**: *"Should this redesign preserve the existing brand, or are we starting visually from scratch?"*++### 11.B Audit Before Touching+Document the current state before proposing changes:+* **Brand tokens** - primary / accent colors, type stack, logo treatment, radii.+* **Information architecture** - page tree, primary nav, key conversion paths.+* **Content blocks** - what exists, what's doing work, what's filler.+* **Patterns to preserve** - signature interactions, recognisable hero, copy voice.+* **Patterns to retire** - AI-slop tells, broken layouts, dead links, generic stock imagery, perf traps.+* **Dial reading of the existing site** - infer current `DESIGN_VARIANCE` / `MOTION_INTENSITY` / `VISUAL_DENSITY`. That's your starting point, not the baseline.+* **SEO baseline** - current ranking pages, meta titles, structured data, OG cards. **SEO migration is the #1 redesign risk.**++### 11.C Preservation Rules+* **Do not change information architecture** unless asked. Keep page slugs, anchor IDs, primary nav labels stable for SEO and muscle memory.+* **Extract brand colors before applying Section 4.2.** A brand that is already purple stays purple - apply the LILA RULE's override.+* **Preserve copy voice** unless asked for a rewrite. Visual modernisation ≠ content rewrite.+* **Honor existing accessibility wins.** Do not regress focus states, alt text, keyboard nav, contrast.+* **Respect existing analytics events.** Do not rename buttons, form fields, section IDs that downstream tracking depends on.++### 11.D Modernisation Levers (priority order)+Apply in order - stop when the brief is satisfied:+1. **Typography refresh** - biggest visual lift per unit of risk.+2. **Spacing & rhythm** - increase section padding, fix vertical rhythm.+3. **Color recalibration** - desaturate, unify neutrals, keep brand accent.+4. **Motion layer** - add `MOTION_INTENSITY`-appropriate micro-interactions to existing components.+5. **Hero & key-section recomposition** - restructure top-of-funnel using Section 10 vocabulary.+6. **Full block replacement** - only when the existing block is unsalvageable.++### 11.E Decision Tree: Targeted Evolution vs Full Redesign+* IA, content, and SEO sound → **targeted evolution** (Levers 1-4). ~70% of value at ~40% of risk.+* Visual debt is structural (broken IA, no design system, broken mobile) → **full redesign** with strict content preservation.+* Brand itself is changing → **greenfield**.++### 11.F What Never Changes Silently+Never modify without explicit user approval:+* URL structure / route slugs.+* Primary nav labels.+* Form field names or order (breaks analytics + autofill).+* Brand logo or wordmark.+* Existing legal / consent / cookie copy.++---++## 12. THE BLOCK LIBRARY (Contract - Implementations Land Here Iteratively)++The Reference Vocabulary (Section 10) names patterns. The Block Library implements them with real props, real motion specs, and real code sketches.++**Status:** schema defined here. Blocks will be added iteratively. Do not freelance new blocks without following this schema.++### 12.A File Location+```+skills/taste-skill/blocks/+ hero/+ asymmetric-split.md+ editorial-manifesto.md+ kinetic-type.md+ ...+ feature/+ bento-grid.md+ sticky-scroll-stack.md+ zig-zag.md+ ...+ social-proof/+ pricing/+ cta/+ footer/+ navigation/+ portfolio/+ transition/+```++### 12.B Required Frontmatter+```yaml+---+name: asymmetric-split-hero+category: hero+dial_compatibility:+ variance: [6, 10]+ motion: [3, 10]+ density: [2, 5]+when_to_use: "Landing pages with one strong asset and one strong message. Default hero for SaaS, agency, premium consumer."+not_for: "Editorial / manifesto launches where the message IS the design."+stack: ["react", "next", "tailwind", "motion"]+---+```++### 12.C Required Body Sections+1. **Visual sketch** - short ASCII or description of the layout.+2. **Props API** - the component's interface.+3. **Code sketch** - minimal working implementation (Server Component default, Client island for motion).+4. **Mobile fallback** - explicit collapse rules for `< 768px`.+5. **Motion variants** - one variant per `MOTION_INTENSITY` band (1-3, 4-7, 8-10). Reduced-motion fallback explicit.+6. **Dark-mode notes** - token strategy specific to this block.+7. **Anti-patterns** - common ways this block goes wrong.+8. **References** - links to real examples in production.++### 12.D Block-Library Discipline+* One block per file. No multi-block files.+* Every block must work standalone (drop it into a page, it renders).+* Every block must pass the Pre-Flight Check (Section 14).+* Blocks that depend on a design system from Section 2.A live under `blocks/<category>/<name>--<system>.md` (e.g. `feature/bento-grid--material.md`).++---++## 13. OUT OF SCOPE++This skill is NOT for:+* Dashboards / dense product UI / admin panels (use Fluent, Carbon, Atlassian, or Polaris from Section 2.A).+* Data tables (use TanStack Table or AG Grid).+* Multi-step forms / wizards (use Form-specific patterns; this skill won't make them better).+* Code editors (use Monaco / CodeMirror with their official skinning).+* Native mobile (use Apple HIG / Material directly).+* Realtime collab UIs (presence, cursors, OT-aware - different problem class).++If the brief is one of the above, **say so explicitly**, point to the right tool, and only apply this skill's marketing-page / about-page / landing-page parts to the surfaces where they apply.++**For dense product UI specifically** (dashboards, data tables, forms, multi-step flows, settings, app shells), the dedicated counterpart to this skill is **`product-ui-taste`** - use it instead of (or alongside, on a split marketing+product screen) this one. It carries the frame-first / rows-not-cards / overflow / state-matrix / data-table / a11y rigor that this skill deliberately leaves out of scope.++---++## 14. FINAL PRE-FLIGHT CHECK++Run this matrix before outputting code. This is the last filter.++**THIS IS NOT OPTIONAL. Run every box. If any box fails, the output is not done.**++- [ ] **Brief inference** declared (Section 0.B one-liner)?+- [ ] **Dial values** explicit and reasoned from the brief, not silently using baseline?+- [ ] **Design system** chosen from Section 2 if applicable, or aesthetic labeled honestly?+- [ ] **Redesign mode** detected and audit performed (if applicable, Section 11)?+- [ ] **ZERO em-dashes (`—`) anywhere on the page.** Headlines, eyebrows, pills, body, quotes, attribution, captions, buttons, alt text. Zero. (Section 9.G - non-negotiable.)+- [ ] **Page Theme Lock**: ONE theme (light, dark, or auto) for the whole page. No section flips to inverted mode mid-page (Section 4.11)?+- [ ] **Color Consistency Lock**: one accent color used identically across all sections (Section 4.2)?+- [ ] **Shape Consistency Lock**: one corner-radius system applied consistently (Section 4.4)?+- [ ] **Button Contrast Check**: every CTA text is readable against its background (no white-on-white, WCAG AA 4.5:1)?+- [ ] **CTA Button Wrap**: no CTA label wraps to 2+ lines at desktop?+- [ ] **Form Contrast Check**: form inputs, placeholders, focus rings, labels all pass WCAG AA against the section background?+- [ ] **Serif discipline**: if a serif is used, it is NOT Fraunces or Instrument_Serif (or it is, with explicit brand justification)? Different serif from your previous project?+- [ ] **Premium-consumer palette check**: if the brief is premium-consumer (cookware / wellness / artisan / luxury), the palette is NOT the AI-default beige+brass+oxblood+espresso family? Different family from your previous premium-consumer project?+- [ ] **Italic descender clearance**: every italic word with `y g j p q` has `leading-[1.1]` min + `pb-1` reserve?+- [ ] **Hero fits the viewport**: headline ≤ 2 lines, subtext ≤ 20 words AND ≤ 4 lines, CTA visible without scroll, font scale planned around image?+- [ ] **Hero top padding**: max `pt-24` at desktop, hero content does not float halfway down the viewport?+- [ ] **Hero stack discipline**: max 4 text elements in hero (eyebrow OR brand strip, headline, subtext, CTAs)? No tiny tagline below CTAs, no trust micro-strip in hero?+- [ ] **EYEBROW COUNT (mechanical)**: count instances of `uppercase tracking` micro-labels above section headlines across all components. Count ≤ ceil(sectionCount / 3)? Hero counts as 1.+- [ ] **Split-Header Ban**: no "left big headline + right small explainer paragraph" pattern as a section header (vertical stack instead)?+- [ ] **Zigzag Alternation Cap**: no 3+ consecutive sections with the same image+text-split layout?+- [ ] **No Duplicate CTA Intent**: no two CTAs with the same intent ("Get in touch" + "Let's talk" both on page = Fail)?+- [ ] **Logo wall = logo only**: no industry / category labels printed below logos?+- [ ] **Bento Background Diversity**: at least 2-3 bento cells have real visual variation (image, gradient, pattern), not all white-on-white text cards?+- [ ] **"Used by / Trusted by" logo wall** lives UNDER the hero, not inside it, uses REAL SVG logos (Simple Icons / devicon) or generated SVG marks, NOT plain text wordmarks?+- [ ] **Copy Self-Audit**: every visible string re-read, no grammatically-broken or AI-hallucinated phrases ("free on its past" type) shipped?+- [ ] **Motion motivated**: every animation can be justified in one sentence (hierarchy / storytelling / feedback / state transition), no GSAP-for-show?+- [ ] **Marquee max-one-per-page**: no two horizontal marquees on the same page?+- [ ] **Navigation on ONE line** at desktop, height ≤ 80px?+- [ ] **Section-Layout-Repetition** check: no two sections share the same layout family (at least 4 different families across 8 sections)?+- [ ] **Bento has rhythm AND exact cell count** (N items → N cells, no empty cells in middle or at end)?+- [ ] **Long lists use the right UI component** (not default `<ul>` with `divide-y` for > 5 items - see Section 4.9 alternatives)?+- [ ] **Real images used** (gen-tool first, then Picsum-seed, then explicit placeholder slots) - NO div-based fake screenshots, NO hand-rolled decorative SVGs, NO pure-text minimalism?+- [ ] **No pills/labels overlaid on images** (no `Plate · Brand`, no `Field notes - journal`)?+- [ ] **No photo-credit captions as decoration** (`Field study no. 12 · Ines Caetano`)?+- [ ] **No version footers** (`v1.4.2`, `Build 0048`) on marketing pages?+- [ ] **No micro-meta-sentences** under eyebrows ("Each of these is a feature we ship today...")?+- [ ] **No decoration text strip at hero bottom** (`BRAND. MOTION. SPATIAL.`)?+- [ ] **No floating top-right sub-text** in section headings?+- [ ] **No scoring/progress bars with filled background tracks** as comparison visuals?+- [ ] **No locale / city-name / time / weather strips** unless brief is genuinely globally-distributed or place-focused?+- [ ] **No scroll cues** (`Scroll`, `↓ scroll`, `Scroll to explore`)?+- [ ] **No version labels in hero** (V0.6, BETA, INVITE-ONLY) unless the brief is a launch?+- [ ] **No section-numbering eyebrows** (`00 / INDEX`, `001 · Capabilities`, `06 · how it works`)?+- [ ] **No decorative dots** (zero by default, only for real semantic state)?+- [ ] **No `border-t` + `border-b` on every row** of long lists / spec tables?+- [ ] **Content density** sane: no 20-row data tables, no fake-precise specs without justification, ≤ 25-word sub-paragraphs by default?+- [ ] **Quotes ≤ 3 lines** of body, attribution clean (no em-dash)?+- [ ] **Motion claimed = motion shown**: if `MOTION_INTENSITY > 4`, page actually animates, not just claimed?+- [ ] **GSAP sticky-stack / horizontal-pan** implemented per Section 5.A / 5.B canonical skeleton (`start: "top top"`, `pin: true`, correct scrub)?+- [ ] **No `window.addEventListener('scroll')`** - using Motion `useScroll()` / ScrollTrigger / IntersectionObserver / CSS scroll-driven animations only?+- [ ] **Reduced motion** wrapped for everything `MOTION_INTENSITY > 3`?+- [ ] **Dark mode** tokens defined and tested in both modes?+- [ ] **Mobile collapse** explicit (`w-full`, `px-4`, `max-w-7xl mx-auto`) for high-variance layouts?+- [ ] **Viewport stability**: `min-h-[100dvh]`, never `h-screen`?+- [ ] **`useEffect` animations** have strict cleanup functions?+- [ ] **Empty / loading / error** states provided?+- [ ] **Cards omitted** in favor of spacing where possible?+- [ ] **Icons** from an allowed library only (Phosphor / HugeIcons / Radix / Tabler), no hand-rolled SVG paths?+- [ ] **Motion** isolated in client-leaf components with `'use client'` at the top, memoized?+- [ ] **No AI Tells** from Section 9 (Inter as default, AI-purple, three-equal cards, Jane Doe, Acme, "Quietly in use at")?+- [ ] **Core Web Vitals** plausibly hit (LCP < 2.5s, INP < 200ms, CLS < 0.1)?+- [ ] **One design system** per project (no Material + shadcn mixed)?++If a single checkbox cannot be honestly ticked, the page is not done. Fix it before delivering.++---++# APPENDICES - Real Source-Backed Reference Material++The sections below are vendored reference content. They give the agent real install commands, real canonical doc links, and real working starter snippets for each design system named in Section 2. Use them to ground decisions in production reality, not training-data fiction.++## Appendix A - Install Commands per Design System++```bash+# Material Web (Material 3)+npm install @material/web++# Fluent UI React (v9)+npm install @fluentui/react-components++# Fluent UI Web Components (framework-free)+npm install @fluentui/web-components @fluentui/tokens++# IBM Carbon+npm install @carbon/react @carbon/styles++# Radix Themes+npm install @radix-ui/themes++# shadcn/ui (open code, owned components)+npx shadcn@latest init+npx shadcn@latest add button card badge separator input++# Primer CSS (GitHub product/devtool UI)+npm install --save @primer/css++# Primer Brand (GitHub marketing UI)+npm install @primer/react-brand++# GOV.UK Frontend+npm install govuk-frontend++# USWDS (US Web Design System)+npm install uswds++# Atlassian Design System (Atlaskit)+yarn add @atlaskit/css-reset @atlaskit/tokens @atlaskit/button @atlaskit/badge @atlaskit/section-message @atlaskit/card++# Bootstrap 5.3+npm install bootstrap++# Shopify Polaris Web Components (Shopify apps only)+# Add this to your app HTML head:+# <meta name="shopify-api-key" content="%SHOPIFY_API_KEY%" />+# <script src="https://cdn.shopify.com/shopifycloud/polaris.js"></script>+```++## Appendix B - Canonical Sources (read these before reinventing)++### Material Web+- https://github.com/material-components/material-web+- https://material-web.dev/theming/material-theming/+- https://m3.material.io/develop/web++### Fluent UI+- https://fluent2.microsoft.design/get-started/develop+- https://fluent2.microsoft.design/components/web/react/+- https://github.com/microsoft/fluentui+- https://learn.microsoft.com/en-us/fluent-ui/web-components/++### Carbon+- https://carbondesignsystem.com/+- https://github.com/carbon-design-system/carbon+- https://carbondesignsystem.com/developing/react-tutorial/overview/+- https://carbondesignsystem.com/developing/web-components-tutorial/overview/++### Shopify Polaris+- https://shopify.dev/docs/api/app-home/web-components+- https://github.com/Shopify/polaris-react+- https://polaris-react.shopify.com/components++### Atlassian+- https://atlassian.design/get-started/develop+- https://atlassian.design/components/button/examples+- https://atlaskit.atlassian.com/packages/design-system/button/example/disabled+- https://atlassian.design/tokens/design-tokens++### Primer+- https://primer.style/+- https://github.com/primer/css+- https://github.com/primer/brand++### GOV.UK+- https://design-system.service.gov.uk/components/button/+- https://design-system.service.gov.uk/styles/layout/+- https://github.com/alphagov/govuk-frontend++### USWDS+- https://designsystem.digital.gov/documentation/developers/+- https://designsystem.digital.gov/components/button/+- https://designsystem.digital.gov/components/card/+- https://github.com/uswds/uswds++### Bootstrap+- https://getbootstrap.com/docs/5.3/layout/grid/+- https://getbootstrap.com/docs/5.3/components/card/++### Tailwind+- https://tailwindcss.com/docs/dark-mode+- https://tailwindcss.com/blog/tailwindcss-v4++### Radix+- https://www.radix-ui.com/themes/docs/components/theme+- https://www.radix-ui.com/themes/docs/components/card+- https://github.com/radix-ui/themes++### shadcn/ui+- https://ui.shadcn.com/docs+- https://ui.shadcn.com/docs/components/card+- https://github.com/shadcn-ui/ui++### Native CSS / W3C standards+- https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Properties/backdrop-filter+- https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-color-scheme+- https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-reduced-motion+- https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Grid_layout+- https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Scroll-driven_animations+- https://drafts.csswg.org/scroll-animations-1/++### Apple Liquid Glass (Apple platforms only)+- https://developer.apple.com/design/human-interface-guidelines/materials+- https://developer.apple.com/documentation/TechnologyOverviews/liquid-glass+- https://developer.apple.com/documentation/TechnologyOverviews/adopting-liquid-glass+- https://developer.apple.com/documentation/SwiftUI/Material++---++## Appendix C - Apple Liquid Glass: Honest Web Approximation++Do **not** treat random CSS snippets as official Apple Liquid Glass.++### What is official+Apple documents Liquid Glass inside Apple's Human Interface Guidelines and Developer Documentation for **Apple platforms**. It is a dynamic material used across Apple platform UI. Apple's native implementation belongs to Apple platform APIs and system components, **not a public web CSS package**.++Relevant official docs:+- Apple Human Interface Guidelines → Materials+- Apple Developer Documentation → Liquid Glass+- Apple Developer Documentation → Adopting Liquid Glass+- SwiftUI → Material++### What is NOT official+There is no `liquid-glass.css` from Apple for normal websites.++A web approximation can use:+- `backdrop-filter`+- transparent backgrounds+- layered borders+- highlight overlays+- gradients+- motion+- strong contrast fallbacks++But that is **web glassmorphism / frosted-glass approximation**, not official Apple Liquid Glass. Label it as such in comments.++### Safer web approximation skeleton++```css+.liquid-glass-web-approx {+ position: relative;+ isolation: isolate;+ overflow: hidden;+ border-radius: 999px;+ border: 1px solid rgb(255 255 255 / .32);+ background:+ linear-gradient(135deg, rgb(255 255 255 / .30), rgb(255 255 255 / .08)),+ rgb(255 255 255 / .12);+ backdrop-filter: blur(24px) saturate(180%) contrast(1.05);+ -webkit-backdrop-filter: blur(24px) saturate(180%) contrast(1.05);+ box-shadow:+ inset 0 1px 0 rgb(255 255 255 / .48),+ inset 0 -1px 0 rgb(255 255 255 / .12),+ 0 18px 60px rgb(0 0 0 / .18);+}++.liquid-glass-web-approx::before {+ content: "";+ position: absolute;+ inset: 0;+ z-index: -1;+ border-radius: inherit;+ background:+ radial-gradient(circle at 20% 0%, rgb(255 255 255 / .55), transparent 34%),+ linear-gradient(90deg, rgb(255 255 255 / .18), transparent 42%, rgb(255 255 255 / .14));+ pointer-events: none;+}++.liquid-glass-web-approx::after {+ content: "";+ position: absolute;+ inset: 1px;+ border-radius: inherit;+ border: 1px solid rgb(255 255 255 / .14);+ pointer-events: none;+}++@media (prefers-color-scheme: dark) {+ .liquid-glass-web-approx {+ border-color: rgb(255 255 255 / .18);+ background:+ linear-gradient(135deg, rgb(255 255 255 / .16), rgb(255 255 255 / .04)),+ rgb(15 23 42 / .42);+ box-shadow:+ inset 0 1px 0 rgb(255 255 255 / .22),+ 0 18px 60px rgb(0 0 0 / .42);+ }+}++@media (prefers-reduced-transparency: reduce) {+ .liquid-glass-web-approx {+ background: rgb(255 255 255 / .96);+ backdrop-filter: none;+ -webkit-backdrop-filter: none;+ }+}+```++**Important:** `prefers-reduced-transparency` has uneven browser support; test it. Always provide enough contrast even without blur.++---++**End of appendices.** Install commands above are reality anchors. The Apple Liquid Glass skeleton is a labeled approximation, not an Apple-issued package. For canonical docs per design system, consult the system's official docs (links in Section 2 plus Appendix B).diff --git a/skills/team-brief/SKILL.md b/skills/team-brief/SKILL.mdnew file mode 100644index 0000000..1e2ee9b--- /dev/null+++ b/skills/team-brief/SKILL.md@@ -0,0 +1,892 @@+---+name: team-brief+description: Generate daily team intelligence brief by cross-referencing GitHub, Linear, Slack, PostHog, meetings, and braindumps with two-way Linear sync-back+roles: [product-manager, engineering-lead, founder]+integrations: [github, linear, slack, posthog, hackmd]+---++# COG Team Intelligence Brief Skill++## When to Invoke+- User says "team brief", "team update", "what did we ship", "standup prep"+- User wants to know what the dev team is working on+- User needs cross-referenced GitHub + Linear + Slack intelligence+- Morning routine for product/engineering leads++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use the full parallel agent execution strategy below (6 agents)+- If `agent_mode: solo` — run data collection sequentially in the main conversation. Skip Phase 3.5 (Linear sync-back) and Phase 3.7 (HackMD publish) to keep it fast.++## Purpose+Generate a concise daily team intelligence brief focused on what we're doing, what needs attention, and what's falling through the cracks. Cross-references Linear work tracking, Slack discussions, GitHub activity, PostHog product analytics, braindumps, and recent meetings to surface insights, flag mismatches, and keep the team aligned.++**Monday = Week Start Brief:** If today is Monday, the brief covers Friday through Sunday (the full weekend window). All date ranges, queries, and language should reflect "since Friday" / "over the weekend" instead of "yesterday." This captures anything that happened Friday afternoon, weekend deploys, or async discussions.++**This is NOT an industry news report.** News/market intelligence belongs in the weekly brief.++## Command: `/team-brief`++## Voice & Tone++You're not a reporting tool — you're a teammate who happens to have read every Slack thread, every PR, and every meeting note. Write like someone who genuinely cares about the team succeeding.++**Do:**+- Be direct and opinionated. If something looks off, say it plainly.+- Celebrate wins. When the team ships something great, acknowledge it.+- Connect the dots. Don't just list facts — explain why they matter together.+- Use natural language. "We shipped v1.2.0 with 11 PRs — solid day" not "11 PRs were merged across the reporting period."+- Be concise but warm. Short sentences, clear thinking, no fluff.+- Flag risks honestly. "This worries me" or "worth keeping an eye on" — not corporate hedging.+- Show you understand the business context. Reference growth targets, customer feedback, strategy when relevant.++**Don't:**+- Write like a project management dashboard. No "REPORT_GENERATED_AT" energy.+- Be overly formal. No "It is recommended that the team consider..."+- Add filler. If there's nothing to say, don't pad it.+- Be passive. "The PR remains unreviewed" → "Nobody's reviewed this yet — it's been 3 days."+- Use unnecessary labels or tags. Let the writing speak for itself.++**Example tone:**+> Good day yesterday — we cut v1.2.0 with the new workflow, caching fix, and a bunch of UX polish. 11 PRs merged by 4 people. The team is shipping.+>+> But we have a problem: two discovery calls in a row ended with the prospect unable to log in. The onboarding flow just doesn't work. We're building features for users who can't get through the front door.++---++## Parallel Agent Team Execution Strategy++**The daily brief MUST use parallel agents to maximize speed and efficiency.**++When `/daily-brief` is invoked, the orchestrator (main agent) should:++### Phase 1: Setup (Orchestrator — Sequential, Fast)+1. Determine today's date and the **lookback start date**:+ - **If today is Monday:** lookback = last Friday (3 days ago). Set `LOOKBACK_DATE` to Friday's date. This is a **Week Start Brief**.+ - **Any other day:** lookback = yesterday. Set `LOOKBACK_DATE` to yesterday's date. This is a standard **Daily Brief**.+ - All dates in YYYY-MM-DD format.+2. Check available integrations via ToolSearch ("slack"), ToolSearch ("linear"), and ToolSearch ("posthog")+3. Check for meeting notes in `[CUSTOMIZE: path/to/meetings/]` matching dates from `LOOKBACK_DATE` through today+4. Check for recent braindumps in `[CUSTOMIZE: path/to/braindumps/]` matching dates from `LOOKBACK_DATE` through today++### Phase 2: Parallel Data Collection (Spawn 6 Agents Simultaneously)+**Launch ALL of these agents in a single message using the Task tool with `run_in_background: true`:**++#### Agent 1: "github-analyst" (subagent_type: general-purpose)+```+Query GitHub for dev team activity on [CUSTOMIZE: your-org/your-repo].+Lookback start date: [INSERT LOOKBACK_DATE].+Today's date: [INSERT TODAY_DATE].+Brief type: [Daily Brief / Week Start Brief (Monday)]++Run these gh CLI commands (all date filters use LOOKBACK_DATE as the start):++1. PRs merged since lookback:+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state merged --search "merged:>=[LOOKBACK_DATE]" --json number,title,author,mergedAt,labels --limit 50++2. PRs opened since lookback:+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state open --search "created:>=[LOOKBACK_DATE]" --json number,title,author,createdAt,labels --limit 20++3. ALL open PRs (for stale PR detection):+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state open --json number,title,author,createdAt,reviewDecision,labels,updatedAt --limit 50++4. PR review comments since lookback (to cross-reference with Slack discussions):+ gh api repos/[CUSTOMIZE: your-org/your-repo]/pulls/comments --jq '[.[] | select(.created_at >= "[LOOKBACK_DATE]")] | .[] | {pr_url: .pull_request_url, body: .body[0:200], user: .user.login, created_at: .created_at}'++5. Issues closed since lookback:+ gh issue list --repo [CUSTOMIZE: your-org/your-repo] --state closed --search "closed:>=[LOOKBACK_DATE]" --json number,title,labels --limit 20++6. Issues opened since lookback:+ gh issue list --repo [CUSTOMIZE: your-org/your-repo] --state open --search "created:>=[LOOKBACK_DATE]" --json number,title,labels --limit 20++7. Commits since lookback:+ gh api repos/[CUSTOMIZE: your-org/your-repo]/commits --jq '[.[] | select(.commit.author.date >= "[LOOKBACK_DATE]")] | .[] | {sha: .sha[0:7], message: .commit.message | split("\n")[0], author: .commit.author.name, date: .commit.author.date}'++ANALYSIS REQUIRED — Don't just list data, provide insights:++A) **Stale PR Detection**: Flag any open PR created more than 3 days ago with no review decision or with CHANGES_REQUESTED for more than 2 days. Calculate days since creation/last update.++B) **Velocity Snapshot**: How many PRs merged, commits pushed, contributors active. If Monday (weekend window), note the multi-day period and don't compare to a single-day baseline — instead comment on weekend activity level (busy weekend vs. quiet weekend).++C) **Review Bottleneck**: Count PRs waiting for review (REVIEW_REQUIRED). If >5, flag as bottleneck.++D) **PR Comment Themes**: Summarize the key topics being discussed in PR reviews (architecture concerns, bugs, design patterns, etc.)++Return structured data AND insights.+```++#### Agent 2: "slack-monitor" (subagent_type: general-purpose)+*Only spawn if Slack MCP is available*+```+Check Slack [CUSTOMIZE: your-team-channel] channel for key discussions since [LOOKBACK_DATE].+Brief type: [Daily Brief / Week Start Brief (Monday)]+If Monday: cover Friday through Sunday — there may be more threads than usual.++Instructions:+1. Use ToolSearch to load Slack tools+2. Read recent messages from [CUSTOMIZE: your-team-channel] channel (get enough to cover since [LOOKBACK_DATE])+3. For each significant discussion thread, extract:+ - Topic / what was discussed+ - Decisions made or agreements reached+ - Action items mentioned (who agreed to do what)+ - Blockers raised+ - Customer feedback or external links shared+ - Any specific features, PRs, or technical topics referenced++CRITICAL: For each action item or decision, note:+- WHO is responsible+- WHAT they agreed to do+- Whether it references a specific PR, feature, or technical area++Also extract:+- Links shared (competitive intel, articles, tools)+- Questions that were asked but NOT answered+- Discussions that seemed unresolved++Return structured output with clear separation between:+1. Decisions & Agreements (with responsible person)+2. Action Items (with owner)+3. Blockers & Escalations+4. Unresolved Discussions+5. External Links & Intel Shared+6. Feature/Technical Topics Discussed (for cross-referencing with GitHub)+```++#### Agent 3: "meeting-reviewer" (subagent_type: general-purpose)+```+Check for meeting notes and standup notes since [LOOKBACK_DATE].+Brief type: [Daily Brief / Week Start Brief (Monday)]+If Monday: check Friday, Saturday, and Sunday for any meeting notes.++Instructions:+1. Look for meeting files in [CUSTOMIZE: path/to/meetings/] with dates from [LOOKBACK_DATE] through today+2. Use Glob to find files: [CUSTOMIZE: path/to/meetings/][LOOKBACK_DATE]*.md (and if Monday, also check Saturday and Sunday dates)+3. Also check [CUSTOMIZE: path/to/checkins/] for recent daily checkins+4. Read any found files++For each meeting/standup found, extract:+- Decisions made+- Action items assigned (WHO + WHAT)+- Features or changes discussed+- Priorities set+- Deadlines mentioned+- Any commitments like "I'll make a quick change to X" or "Let's update Y today"++Return structured list of:+1. Meeting summaries with date+2. All action items with owners+3. All discussed features/changes (for cross-referencing with GitHub PRs/commits and Linear issues)+4. Priorities and deadlines mentioned+```++#### Agent 4: "linear-tracker" (subagent_type: general-purpose)+*Only spawn if Linear MCP is available*+```+Query Linear for work tracking data since [LOOKBACK_DATE].+Brief type: [Daily Brief / Week Start Brief (Monday)]+If Monday: cover Friday through Sunday.++=== CONTEXT OPTIMIZATION RULES (CRITICAL — reduces token usage by ~70%) ===++**DEFAULT FILTERS — apply to ALL list_issues calls:**+- ALWAYS exclude issues with state "Done", "Completed", "Canceled", or "Archived" UNLESS they were updated since [LOOKBACK_DATE] (i.e., only show recently-completed wins, not old closed work).+- ALWAYS set limit: 50 on any list call to prevent overflow.+- NEVER make redundant queries — if you already fetched issues updated since lookback, do NOT re-fetch the same issues in a separate "completed" query. Filter from the data you already have.++**DATA EXTRACTION — from every API response, extract ONLY these fields per issue:**+- identifier (e.g., [CUSTOMIZE: PROJ]-123)+- title+- state (name only)+- priority (number + label)+- assignee (name only)+- updatedAt+- project (name only)+- labels (names only)++Discard everything else (full descriptions, URLs, metadata blobs, nested objects). This is critical — raw Linear responses are 50-100KB each and most of that data is unused.++**QUERY CONSOLIDATION — use minimal API calls:**+Do NOT make 5+ separate list_issues calls. Instead:++Instructions:+1. Use ToolSearch to load Linear tools (search "+linear list issues", "+linear list initiatives", "+linear list milestones", "+linear list projects")+2. Query the following data using Linear MCP tools:++ === ISSUE-LEVEL DATA (2-3 calls max) ===++ a) Issues updated since lookback (THE main query — covers most needs):+ Use mcp__claude_ai_Linear__list_issues with updatedAt: "[LOOKBACK_DATE]", limit: 50.+ From this ONE response, extract: recently completed issues (wins), issues that moved to In Progress, issues still in Todo, new issues created.++ b) High-priority/urgent + blocked issues (only if not already captured above):+ Use mcp__claude_ai_Linear__list_issues with priority: 1 (Urgent), limit: 30.+ Only query this separately if the main query didn't surface urgent items.++ c) Blocked/stuck issues:+ Look for issues with state "blocked" or "In Progress" with no updates in >2 days. Use the data from query (a) first — only make a separate query if needed.++ === CYCLE & SPRINT DATA (1 call) ===++ d) Current cycle progress:+ Use mcp__claude_ai_Linear__list_teams to get team IDs, then mcp__claude_ai_Linear__list_cycles with type: "current" for each team. This shows sprint/cycle health.++ === INITIATIVE DATA (1-2 calls) ===++ e) All active initiatives:+ Use mcp__claude_ai_Linear__list_initiatives with includeProjects: true to get initiative names, target dates, health status, progress, and linked projects.+ Do NOT call get_initiative for each individual initiative — the list call with includeProjects gives enough data.++ === PROJECT DATA (SKIP separate call) ===++ f) Project data comes from the initiatives query above (includeProjects: true). Do NOT make a separate list_projects call — it returns ~37KB of mostly unused data.++ === MILESTONE DATA (1 call only if needed) ===++ g) Only query milestones if an initiative is At Risk or has an approaching target date (≤14 days). Otherwise skip — milestone data is verbose and rarely actionable day-to-day.++3. For each significant issue, note ONLY:+ - Issue identifier, title, assignee name, status, priority, project name+ - Whether it has linked PRs (just note yes/no + PR number, don't include full URLs)++4. Build an INITIATIVE HEALTH MAP from the data you already have (do NOT make additional queries):+ For each initiative, compile:+ - Total issues across linked projects (completed / in-progress / todo / blocked)+ - Projects status breakdown+ - Key blockers+ - Days until target date++ANALYSIS REQUIRED:+A) **Cycle Health**: What % of the current cycle is complete? Are we on pace? How many issues remain vs. days left?+B) **Work Distribution**: Who has the most issues assigned? Anyone overloaded or idle?+C) **Blocked Items**: List anything stuck with reasons if available.+D) **Priority Mismatches**: Any urgent/high-priority issues with no recent activity? Flag them.+E) **New Work vs Planned**: How many issues were created since lookback vs. what was already planned in the cycle? Is scope creeping?+F) **Completed Work**: Celebrate — list what got done and by whom.+G) **Initiative Progress**: For each initiative, report health (on track / at risk / off track) based on:+ - % of issues completed vs. days remaining to target date+ - Number of blocked items+ - Whether projects under the initiative are progressing+H) **Milestone Status**: Only flag milestones that are overdue or at risk. Skip healthy milestones.+I) **Project Rollup**: For each project, summarize progress % and whether it's contributing to initiative goals.++Return structured data AND insights, including the initiative health map.+IMPORTANT: Your total output should be under 5KB of text. Summarize, don't dump raw data.+```++#### Agent 5: "braindump-reviewer" (subagent_type: general-purpose)+```+Check for recent braindumps since [LOOKBACK_DATE].+Brief type: [Daily Brief / Week Start Brief (Monday)]+If Monday: check Friday through Sunday.++Instructions:+1. Use Glob to find braindump files matching recent dates:+ - [CUSTOMIZE: path/to/braindumps/]braindump-[LOOKBACK_DATE through TODAY]*.md+2. Read any found files++For each braindump found, extract:+- Core themes and strategic thinking+- Decisions being considered or made+- Product direction signals+- Concerns or risks flagged+- Ideas that should be connected to current work+- Any references to specific features, PRs, or team members++Return structured list of:+1. Braindump summaries with date and source+2. Strategic insights and product direction signals+3. Concerns/risks that should appear in the brief+4. Connections to current engineering work (for cross-referencing with GitHub/Linear)+```++#### Agent 6: "posthog-analyst" (subagent_type: general-purpose)+*Only spawn if PostHog MCP is available*+```+Query PostHog for HIGH-LEVEL product metrics only.+Project ID: [CUSTOMIZE: your-posthog-project-id], Dashboard ID: [CUSTOMIZE: your-posthog-dashboard-id].+Lookback start date: [INSERT LOOKBACK_DATE].+Today's date: [INSERT TODAY_DATE].+Brief type: [Daily Brief / Week Start Brief (Monday)]++=== CONTEXT OPTIMIZATION RULES (CRITICAL) ===+- DO NOT query for errors or error details. Skip list-errors entirely.+- DO NOT fetch insights-get-all (returns huge payload of all saved insights). Only use the dashboard.+- DO NOT include raw query results in your output. Summarize into 1-2 lines per metric.+- Your total output should be under 3KB of text.++Instructions:+1. Use ToolSearch to load PostHog tools (search "+posthog")+2. Run ONLY these queries:++ === DASHBOARD OVERVIEW (1 call) ===++ a) Get the main dashboard:+ Use mcp__posthog__dashboard-get with dashboard_id: [CUSTOMIZE: your-posthog-dashboard-id].+ Extract only: visitor count, signup count, core event count, and any trend data shown.++ === KEY METRICS (3 HogQL queries — combine into period comparison) ===++ b) Current period metrics (single combined query):+ Use mcp__posthog__query-run with a HogQL query:+ SELECT+ countIf(DISTINCT person_id, event = '$pageview') as visitors,+ countIf(event = '$pageview') as pageviews,+ countIf(DISTINCT person_id, event = 'user_signed_up') as signups,+ countIf(event = '[CUSTOMIZE: your_core_event]') as core_events,+ countIf(DISTINCT person_id, event = '[CUSTOMIZE: your_core_event]') as core_event_users+ FROM events+ WHERE timestamp >= '[LOOKBACK_DATE]'++ c) Previous period metrics (for % change calculation):+ Run the same query for the PREVIOUS equivalent period.+ If daily: day before lookback. If Monday (Fri-Sun): previous Fri-Sun.++ d) Top features (lightweight):+ Use mcp__posthog__query-run:+ SELECT event, count() as count, count(DISTINCT person_id) as unique_users+ FROM events+ WHERE timestamp >= '[LOOKBACK_DATE]' AND event NOT LIKE '$%'+ GROUP BY event ORDER BY count DESC LIMIT 10++ANALYSIS — Return ONLY high-level insights (no raw data dumps):++A) **Metric Summary**: 1 line each for visitors, sign-ups, core events with ↑↓→ trend and % change.+B) **Anomalies**: Only flag metrics with >20% change. If none, say "No anomalies."+C) **Top Features**: List top 5 features by usage, 1 line each.+D) **One-liner Assessment**: "Product health: [good/concerning/needs attention] — [why in 1 sentence]"++Return a concise summary, NOT raw query results. Target ~1KB output max.+```++### Phase 3: Assembly & Cross-Reference Synthesis (Orchestrator — After All Agents Complete)++This is the most critical phase. The orchestrator must:++1. **Collect results** from all background agents using Read on their output files++2. **Cross-reference Linear ↔ GitHub** (the core alignment check):+ - Match Linear issues to corresponding PRs/commits (by title, description, or explicit references)+ - Flag Linear issues marked "In Progress" with NO corresponding PR or commit (work claimed but not started in code)+ - Flag PRs that have NO corresponding Linear issue (untracked work — could be fine, just note it)+ - Flag Linear issues marked "Done" but PR still open or unmerged (status mismatch)+ - Note issues where Linear priority doesn't match PR urgency (e.g., Urgent in Linear but PR unreviewed for days)++3. **Cross-reference Slack ↔ GitHub ↔ Linear**:+ - Match Slack discussion topics to related PRs/commits AND Linear issues+ - Combine related insights into unified items (e.g., "Credit system: [CUSTOMIZE: PROJ]-45 in progress + discussed in Slack 22 replies + PR #930 has CHANGES_REQUESTED")+ - Flag if Slack discussions mention work that has NO corresponding PR, commit, OR Linear issue+ - Flag if PRs exist that were NOT discussed in Slack (silent work — could be fine, just note it)++4. **Cross-reference Meetings ↔ GitHub ↔ Linear**:+ - Check if action items from yesterday's meetings/standups have corresponding PRs, commits, OR Linear issues+ - Flag any discussed changes with NO GitHub or Linear activity+ - Note completed action items (discussed AND shipped AND tracked)+ - Check if meeting-assigned priorities match Linear priority settings++5. **Cross-reference Braindumps ↔ Current Work**:+ - Connect strategic thinking from braindumps to active Linear issues and GitHub PRs+ - Surface braindump concerns that aren't reflected in any current tracked work+ - Flag if braindumps mention direction changes that contradict current sprint priorities++6. **Cross-reference Linear Cycle ↔ Overall Progress**:+ - Report cycle health (% complete, days remaining, pace)+ - Flag if scope is creeping (new issues added mid-cycle)+ - Highlight blocked items that are holding up cycle completion++7. **Cross-reference Initiatives ↔ Projects ↔ Issues**:+ - For each initiative, roll up project and issue data to compute real health:+ - Count completed vs total issues across all linked projects+ - Check if milestones are on track or overdue+ - Identify which projects are driving progress vs. stalled+ - Flag initiatives where computed health differs from reported health+ - Flag initiatives approaching target date with low completion %++8. **Cross-reference PostHog ↔ GitHub ↔ Slack**:+ - **Feature Releases ↔ Metrics**: Correlate recently merged PRs with PostHog metric changes. Did a feature ship and usage go up? Or did it ship and nothing changed (adoption problem)?+ - **Error Spikes ↔ Deployments**: Match PostHog error spikes to recently merged PRs. If errors increased after a specific merge, flag it as a potential regression.+ - **Slack Complaints ↔ PostHog Data**: If Slack discussions mention user issues, check if PostHog error data or funnel drop-offs confirm the problem.+ - **Metric Anomalies ↔ Known Changes**: If visitors/sign-ups changed significantly, cross-reference with GitHub activity and Slack.+ - **Feature Adoption ↔ Initiative Goals**: Map PostHog feature usage data to Linear initiative KPIs. Flag gaps.+ - **Activation Funnel ↔ Onboarding Work**: If the funnel is leaking, check if any PRs or Linear issues address it. Flag the gap if nothing is being worked on.++9. **Generate the brief** following the Content Structure below, with insights FIRST and details LAST. **Use the Voice & Tone guidelines** — write like a teammate, not a dashboard.++10. **Save** to `[CUSTOMIZE: path/to/briefs/]daily-brief-YYYY-MM-DD.md` with proper metadata++11. **Present** a concise summary to the user++### Phase 3.5: Linear Sync-Back (Orchestrator — After Cross-Reference, Before Slack)++**This phase writes data BACK to Linear to keep it up-to-date with reality from GitHub, Slack, and meetings.**++Use ToolSearch to load the necessary Linear update tools: "+linear update issue", "+linear update initiative", "+linear update project", "+linear create comment", "+linear create attachment", "+linear save status update", "+linear update milestone".++#### Step 1: PR ↔ Issue Linkage+For each merged or open PR found in the GitHub data:+1. Extract Linear issue references from PR title/body/branch (patterns: `[CUSTOMIZE: PROJ]-123`)+2. For each matched Linear issue:+ - Use `mcp__claude_ai_Linear__create_attachment` to attach the PR URL to the issue (if not already linked). Use format:+ - url: `https://github.com/[CUSTOMIZE: your-org/your-repo]/pull/XXX`+ - title: "PR #XXX: [PR title]"+ - Check if the issue already has this PR attached (via `get_issue` attachments) — skip if already linked to avoid duplicates++#### Step 2: Issue Status Sync from GitHub+Based on the cross-reference data from Phase 3:+1. **PR merged → Issue still "In Progress"**: Use `mcp__claude_ai_Linear__update_issue` to transition the issue to "Done" state. Add a comment: "Automatically marked done — PR #XXX merged on [date]."+2. **PR opened → Issue still "Todo"/"Backlog"**: Use `mcp__claude_ai_Linear__update_issue` to transition to "In Progress". Add a comment: "Marked in progress — PR #XXX opened."+3. **PR has CHANGES_REQUESTED → Issue marked "In Review"**: Keep issue status, but add a comment noting the review feedback if not already commented.++**Safety rules:**+- Only auto-transition issues where the PR-to-issue link is unambiguous (exact issue prefix match)+- Never transition issues backward (e.g., don't move "Done" back to "In Progress")+- If multiple PRs reference the same issue, only mark "Done" when ALL related PRs are merged+- Log every status change made for the brief summary++#### Step 3: Initiative Status Updates+For each active initiative, compose and post a status update using `mcp__claude_ai_Linear__save_status_update`:+1. Gather from the cross-reference:+ - What shipped since lookback (merged PRs mapped to this initiative's projects)+ - Current blockers across the initiative's projects+ - Cycle progress for the initiative's issues+ - Key Slack discussions relevant to this initiative+2. Compose a concise status update (3-5 bullet points):+ ```+ **[DATE] Daily Update**+ • Shipped: [list key PRs/features merged]+ • In Progress: [key items being worked on]+ • Blocked: [any blockers, or "None"]+ • Health: [On Track / At Risk / Off Track] — [1-line reasoning]+ • Next: [what's expected to ship next]+ ```+3. Use `mcp__claude_ai_Linear__save_status_update` to post the update to the initiative+4. If the initiative health has clearly changed based on data, use `mcp__claude_ai_Linear__update_initiative` to update the health field++#### Step 4: Milestone Progress Check+For each milestone in active projects:+1. Count completed vs total issues within the milestone+2. If a milestone's target date is approaching (≤7 days away) and completion is <70%, flag it+3. If a milestone is overdue (past target date with incomplete issues), use `mcp__claude_ai_Linear__update_milestone` to update its status/description with a note+4. Include milestone health in the initiative status update++#### Step 5: Project Status Sync+For each active project:+1. If all issues in a project are "Done" and the project status is still "In Progress", flag for status update+2. If a project has >50% blocked issues, note this in the initiative status update+3. Update project descriptions or summaries only if there's a significant status change++#### Sync-Back Summary+After all sync-back operations, compile a summary of what was updated:+- Issues status-synced: [count] (list issue IDs and new states)+- PRs linked: [count] (list PR#→issue mappings)+- Initiative updates posted: [count]+- Milestones flagged: [count]+- Any errors encountered during sync++Include this summary in the brief under a "Linear Sync Report" section.++### Phase 3.7: HackMD Publish (After Linear Sync-Back, Before Slack)++**This phase publishes the full daily brief to HackMD so it can be shared with the team via a link.**++The HackMD API token is stored in `.claude/settings/hackmd-token` (one line, no whitespace). Read it with: `cat .claude/settings/hackmd-token | tr -d '\n'`. Alternatively check env var `HACKMD_API_TOKEN`.++**API Details:**+- Base URL: `https://api.hackmd.io/v1`+- Auth header: `Authorization: Bearer <HACKMD_API_TOKEN>`++**Steps:**++1. **Create the note** via `POST https://api.hackmd.io/v1/notes` with:+ ```json+ {+ "title": "Daily Brief — [DAY_NAME], [FULL_DATE]",+ "readPermission": "signed_in",+ "writePermission": "owner",+ "commentPermission": "disabled",+ "content": "placeholder"+ }+ ```+ - `readPermission: "signed_in"` means any HackMD user with the link can view+ - Extract the `id` and `publishLink` from the response++2. **Update the note content** via `PATCH https://api.hackmd.io/v1/notes/<id>` with the full brief markdown content:+ - Read the saved brief from `[CUSTOMIZE: path/to/briefs/]daily-brief-YYYY-MM-DD.md`+ - Use Python to JSON-encode the content and write to a temp file+ - Send via `curl -X PATCH ... -d @/tmp/hackmd-payload.json`++3. **Store the HackMD link** for use in the Slack message AND the local brief file:+ - The `publishLink` from step 1 (format: `https://hackmd.io/@[CUSTOMIZE: your-hackmd-username]/<shortId>`)+ - This link will be included in the Slack highlight message+ - **Write the link back into the local `.md` file's frontmatter** by adding/updating `hackmd_url: <publishLink>` in the YAML frontmatter. Insert it after the `created:` field. Use the Edit tool to do this — do NOT rewrite the entire file.++4. **If HackMD API fails**, log the error and continue — the brief should still be posted to Slack without the link. Note in the Slack message: "(HackMD link unavailable)"++**Implementation pattern (Bash):**+```bash+# Step 1: Create note+curl -s -X POST 'https://api.hackmd.io/v1/notes' \+ -H "Authorization: Bearer $HACKMD_API_TOKEN" \+ -H 'Content-Type: application/json' \+ -d '{"title":"...","readPermission":"owner","writePermission":"owner","commentPermission":"disabled","content":"placeholder"}'++# Step 2: Prepare payload and update+python3 -c "+import json+with open('[CUSTOMIZE: path/to/briefs/]daily-brief-YYYY-MM-DD.md') as f:+ content = f.read()+with open('/tmp/hackmd-payload.json', 'w') as f:+ json.dump({'content': content}, f)+"+curl -s -X PATCH "https://api.hackmd.io/v1/notes/<id>" \+ -H "Authorization: Bearer $HACKMD_API_TOKEN" \+ -H 'Content-Type: application/json' \+ -d @/tmp/hackmd-payload.json+```++### Phase 4: Slack Highlights (After brief is saved — preview before posting)++After presenting the brief summary to the user, **always compose and show the Slack highlight message for preview**. Display the exact message the user will see in Slack, then ask: "Ready to post this to #[CUSTOMIZE: your-team-channel]? (or edit anything first)"++**Do NOT post until the user explicitly confirms.** If they suggest edits, adjust and show the updated preview. Only post after they say yes/confirm/looks good/send it/etc.++1. **Compose a Slack-native highlight message** — NOT the full brief, just the most important bits the team should see. Keep it short enough that people actually read it.++2. **Once user confirms**, use ToolSearch to load Slack send tool, then post via `mcp__claude_ai_Slack__slack_send_message` to the [CUSTOMIZE: your-team-channel] channel.++3. **Slack message format** (adapt based on actual content — this is a template, not a rigid format):++**For Monday (Week Start Brief):**+```+:calendar: *Week Start Brief — [DATE] (covering Fri–Sun)*++*Weekend recap:* [X] PRs merged since Friday. [Brief summary of what got done.] :rocket:++*What shipped:*+• [Feature/PR 1 with <https://github.com/[CUSTOMIZE: your-org/your-repo]/pull/XXX|#XXX> link] — [1-line description]+• [Feature/PR 2 with link] — [1-line description]+• [Feature/PR 3 with link] — [1-line description]++---++:rotating_light: *Heads up:*+• [Most important alert with PR links and context]+• [Second alert — include who's involved and what's needed]+• [Third alert if relevant]++---++:mag: *Key discussions from Slack:*+• *[Topic 1]:* [2-3 sentence summary of the discussion, decisions made, and any open questions.]+• *[Topic 2]:* [Summary with context]++:clipboard: *Open action items:*+• [Person] — [What they need to do] ([source: meeting/Slack thread])+• [Person] — [What they need to do]++---++:bar_chart: *Product pulse:*+• [X] visitors ([↑/↓X%]), [X] sign-ups, [X] core events ([↑/↓X%]) | [Any notable anomaly]++:chart_with_upwards_trend: *This week's focus:*+• [Key priority or theme for the week]++:zap: *Quick wins:*+• <https://github.com/[CUSTOMIZE: your-org/your-repo]/pull/XXX|#XXX> and <...|#YYY> are approved — just need someone to merge.++:link: *Full brief:* [HACKMD_PUBLISH_LINK]+```++**For regular days:**+```+:newspaper: *Daily Brief — [DATE]*++*What shipped:* [X] PRs merged. :rocket:+• [Feature/PR 1 with <https://github.com/[CUSTOMIZE: your-org/your-repo]/pull/XXX|#XXX> link] — [1-line description]+• [Feature/PR 2 with link] — [1-line description]++---++:rotating_light: *Heads up:*+• [Alert 1 with PR links, context, and who needs to act]+• [Alert 2 with details]++---++:mag: *Key discussions:*+• *[Topic]:* [2-3 sentence summary — what was discussed, any decisions, open questions.]++:clipboard: *Action items:*+• [Person] — [Task] ([from meeting/Slack])++---++:bar_chart: *Product pulse:* [X] visitors ([↑/↓X%]) | [X] core events ([↑/↓X%]) | [Any notable anomaly]++:zap: *Quick wins:*+• <https://github.com/[CUSTOMIZE: your-org/your-repo]/pull/XXX|#XXX> and <...|#YYY> are approved — just need someone to merge.++:link: *Full brief:* [HACKMD_PUBLISH_LINK]+```++4. **Rules for the Slack message:**+ - Max 30 lines for Monday briefs, max 20 lines for regular days. More detail than before, but still scannable.+ - Lead with the positive (what shipped) before the problems.+ - Only include alerts that actually need the team's attention today.+ - Don't dump raw PR tables, but DO list shipped PRs with 1-line descriptions so people know what actually changed.+ - Summarize key Slack discussions — the team often misses threads. A 2-3 sentence recap of important conversations adds real value.+ - Include action items with owners so people know what's expected of them.+ - Use plain language, no project-management-speak. "Nobody's reviewed #930 yet" not "REVIEW_REQUIRED status persists."+ - If there's nothing urgent, keep it short: "Good day, we shipped X, nothing on fire."+ - Reference specific people only when it's constructive (celebrating a win or when they're the clear owner of a follow-up). Don't publicly call people out for missing deadlines.+ - **ALWAYS embed GitHub links for PR references.** Use Slack link format: `<https://github.com/[CUSTOMIZE: your-org/your-repo]/pull/XXX|#XXX>`. Never use bare `#930` — make it clickable.+ - **ALWAYS include the HackMD link** at the end of the Slack message as `:link: *Full brief:* [HACKMD_URL]`. This is how the team accesses the full detailed brief.++### Phase Timing+- Phase 1: ~10 seconds+- Phase 2: ~60-90 seconds (all 6 agents run in parallel)+- Phase 3: ~45 seconds (6-way cross-referencing and assembly, including PostHog ↔ GitHub correlation)+- Phase 3.5: ~30-45 seconds (Linear sync-back — PR linkage, status sync, initiative updates)+- Phase 3.7: ~10 seconds (HackMD publish — create private note, upload full brief content)+- Phase 4: ~10 seconds (Slack post with HackMD link, after user confirms)+- **Total: ~3-4 minutes** (+ Slack post if requested)++---++## Content Structure (PRIORITY ORDER — Important First, Details Last)++### 1. Opening (1-2 sentences)+Quick vibe check. Was it a good shipping day? Quiet? Lots of discussion but no merges? Set the context in plain language.++**If Monday (Week Start Brief):** Frame the opening around the weekend + set the tone for the week ahead. Example: "Happy Monday — the team stayed busy over the weekend with 6 PRs merged. Here's what happened since Friday and what's on deck for the week."++**Regular day example:**+> Solid day — v1.2.0 shipped with 11 PRs merged. The team is moving fast on features. But we've got a growing problem on the onboarding side that needs attention before we lose more prospects.++### 2. Heads Up (Top Alerts)+Things that need attention today. Keep to 3-5 max. Write them as things a teammate would flag in standup, not as system alerts.++**Types (in priority order):**+- Initiative health degradation (initiative moved from On Track to At Risk, or milestone overdue)+- Blocked/urgent Linear issues with no progress+- Stale PRs (open > 3 days without review, or CHANGES_REQUESTED > 2 days)+- Linear ↔ GitHub status mismatches (e.g., Linear says "Done" but PR still open)+- Milestone approaching deadline with low completion (≤7 days, <70%)+- Missing follow-through (discussed in meeting/Slack but no GitHub/Linear activity)+- Review bottlenecks (>5 PRs waiting for review)+- Cycle health warnings (behind pace, scope creep)+- Mismatches between agreements and actions+- Unresolved blockers from Slack+- Critical bugs or issues+- PRs not linked to Linear issues (untracked work)+- PostHog error spikes correlated with recent deploys (potential regression)+- Significant metric drops (visitors, sign-ups down >20%)+- Funnel drop-offs with no corresponding Linear issue (untracked product gap)++**Example:**+> **Onboarding is broken** — Two prospects in a row got stuck at sign-up during discovery calls. No fix PR exists for either issue.+>+> **Review backlog is getting out of hand** — 22 open PRs, 16 of them stale. Some are 100+ days old. We should do a quick triage to close the dead ones.+>+> **API docs (#930)** need reviewer feedback resolved before we merge the implementation (#933). Let's not build on an uncertain foundation.++### 3. Key Insights (Synthesized, Cross-Referenced)+Combined intelligence from Slack + GitHub + Meetings. Group RELATED items together. This is where the cross-referencing shines — connect the dots between what was discussed and what actually happened in code.++### 4. What Shipped+Celebrate the wins. Brief summary of merged PRs. Group by theme if possible rather than just listing.++### 5. What's In Progress+Open PRs with review status AND corresponding Linear issue status. Flag age and anything that looks stuck. Show alignment between Linear status and actual PR state.++### 6. Initiative Health Dashboard+For each active initiative, show a quick-glance status:++**Format:**+> **Initiative Name** — Health: On Track | 23% complete | 76 days remaining+> - Projects: Project A (In Progress, 40%), Project B (In Progress, 15%)+> - Milestones: Milestone 1 (due Mar 15 — on track), Milestone 2 (due Mar 30 — at risk)+> - Shipped today: PR #945 (feature X), PR #948 (feature Y)+> - Blockers: None++### 7. Cycle & Sprint Health+Current Linear cycle progress — % complete, days remaining, scope changes. Flag if the team is on pace or falling behind.++### 8. Team Snapshot+Quick velocity numbers — not exhaustive, just enough to get a pulse. Include both GitHub metrics (PRs, commits) and Linear metrics (issues completed, cycle progress).++### 9. Product Metrics (from PostHog)+Quick snapshot of how the product is actually performing with real user data. This grounds the engineering activity in business reality.++**Format:**+> **Visitors:** 342 (↑12% vs previous day) | **Sign-ups:** 8 (↓25%) | **Core Events:** 156 (↑34%) | **Errors:** 3 new+>+> **What the numbers say:** Core events jumped after we shipped the loop detection fix (PR #942) — users are getting further into workflows without hitting errors. Sign-ups dipped but that might just be a quiet day.+>+> **Feature adoption:** `new-feature` used by 23 unique users (good early traction). `onboarding-flow` still showing 40% drop-off at email verification step.+>+> **Error watch:** 3 new `TypeError` errors in `/api/execute` since yesterday's deploy. Correlates with PR #935 merge.++**Rules:**+- Only include this section if PostHog data is available+- Always show trend direction (↑ ↓ →) with % change+- Correlate metric changes with shipped PRs when possible+- Flag error spikes and link them to recent deployments+- Keep it to 4-6 lines max — detailed analytics belong in a separate analysis++### 10. Linear Sync Report+Summary of what the daily brief sync-back updated in Linear:+- **Issues synced**: X issues had status updated (list issue IDs and new states)+- **PRs linked**: X PRs linked to Linear issues (list mappings)+- **Initiative updates posted**: X initiatives received status updates+- **Milestones flagged**: X milestones at risk or overdue+- **Errors**: Any sync failures (or "All clean")++### 11. Strategic Context (from Braindumps)+Key insights from recent braindumps that connect to current work. This gives the brief depth beyond just "what happened" — it adds "why it matters" from the product lead's own thinking.++### 12. Yesterday's Discussions (Reference)+Detailed Slack discussion summaries. This is the appendix — people who want depth can read here.++### 13. Meeting Follow-Up Tracker+Action items from recent meetings tracked against actual GitHub/Slack/Linear activity. Use status indicators to show progress at a glance.++---++## Metadata Template+```yaml+---+type: daily-brief+brief_type: daily / week-start # "week-start" if Monday, "daily" otherwise+domain: shared+date: YYYY-MM-DD+lookback_from: YYYY-MM-DD # Friday's date if Monday, yesterday otherwise+created: YYYY-MM-DD HH:MM+tags:+ - daily-brief+ - team-intelligence+data_sources:+ github: true+ slack: true/false+ linear: true/false+ posthog: true/false+ meetings: true/false+ braindumps: true/false+linear_sync:+ issues_synced: X+ prs_linked: X+ initiative_updates_posted: X+ milestones_flagged: X+ errors: []+initiatives:+ - name: "[CUSTOMIZE: Your Initiative 1]"+ health: on_track / at_risk / off_track+ progress_pct: X+ days_remaining: X+ projects_count: X+ blocked_issues: X+ - name: "[CUSTOMIZE: Your Initiative 2]"+ health: on_track / at_risk / off_track+ progress_pct: X+ days_remaining: X+ projects_count: X+ blocked_issues: X+linear_cycle:+ name: "Cycle X"+ progress_pct: X+ days_remaining: X+ scope_changes: X # issues added mid-cycle+posthog_metrics:+ visitors: X+ visitors_change_pct: X # vs previous period+ signups: X+ signups_change_pct: X+ core_events: X+ core_events_change_pct: X+ new_errors: X+ top_feature: "feature_name"+ anomalies: [] # list of metrics with >20% change+hackmd_url: "" # HackMD publish link, populated in Phase 3.7+stale_prs: X+review_bottleneck: true/false+missing_followups: X+linear_blocked_issues: X+---+```++## Synthesis Rules++### Cross-Referencing Logic+1. **Linear issue + corresponding PR** → Link them together in Linear (Phase 3.5). Flag status mismatches (e.g., Linear says "Done" but PR is still open)+2. **Linear issue "In Progress" + No PR/commit** → Flag as "claimed but no code yet" (could be early, but worth noting if >1 day)+3. **PR exists + No Linear issue** → Note as untracked work. Not necessarily bad, but should be in Linear going forward+4. **Slack topic mentions a PR number or Linear issue** → Link them together in Key Insights+5. **Slack discussion about a feature** + **PR and/or Linear issue exists** → Unified insight combining all three signals+6. **Meeting action item** + **No matching PR/commit AND no Linear issue** → Flag as missing follow-up (nothing tracked anywhere)+7. **Meeting action item** + **Linear issue exists but no PR** → Tracked but not started — note status+8. **Slack agreement** + **GitHub/Linear activity contradicts it** → Flag as mismatch+9. **Multiple Slack threads about same topic** → Consolidate into single insight+10. **Braindump mentions a feature/direction** + **Linear/GitHub has related work** → Connect strategic thinking to execution+11. **Braindump raises concern** + **No Linear issue or PR addressing it** → Flag as "strategic gap — thinking exists but no tracked work"+12. **Linear urgent/high-priority issue** + **No recent activity (>2 days)** → Flag as stalled critical work+13. **PR merged + Linear issue still open** → Auto-transition to "Done" in Phase 3.5 and note in sync report+14. **PR opened + Linear issue in "Todo"** → Auto-transition to "In Progress" in Phase 3.5+15. **Initiative target date approaching + low project completion** → Flag initiative health as "At Risk" and update in Linear+16. **Milestone overdue + incomplete issues** → Flag milestone and update in Linear+17. **Completed work maps to an initiative's project** → Include in initiative status update posted to Linear+18. **Merged PR + PostHog metric spike** → Correlate — the feature likely drove the change. Include in "What Shipped" with impact data+19. **Merged PR + PostHog error spike** → Flag as potential regression in Heads Up. Include error details and PR link+20. **PostHog sign-up/core-event drop + No obvious cause** → Flag as anomaly in Product Metrics. Check if it's a weekend/holiday pattern or a real problem+21. **PostHog feature low adoption + Related initiative targets growth** → Flag gap between what's being built and what users are actually using+22. **PostHog funnel drop-off + No Linear issue addressing it** → Flag as untracked product gap — users are struggling but nobody's working on it+23. **Slack user complaint + PostHog error data confirms** → Elevated priority — real user impact verified by data++### Stale PR Rules+- **> 3 days old** with REVIEW_REQUIRED → Flag as stale+- **> 2 days** with CHANGES_REQUESTED and no new commits → Flag as stale+- **> 5 days old** regardless of status → Flag as long-hanging+- Include link and responsible person in alert++### Initiative Health Rules+- **On Track**: ≥60% of expected pace (issues completed proportional to time elapsed vs target date), no critical blockers+- **At Risk**: 40-60% of expected pace, OR ≥2 blocked issues, OR milestone overdue+- **Off Track**: <40% of expected pace, OR ≥3 blocked issues across projects, OR multiple milestones overdue+- Health assessment uses REAL data (issue counts, milestone dates) not just reported status++### Priority Ordering+When multiple alerts exist, order by:+1. Initiative health degradation (initiative moved to At Risk or Off Track)+2. Blockers (Linear blocked issues or something that can't proceed)+3. PostHog error spikes correlated with recent deploys (potential regression — users affected NOW)+4. Milestone overdue or at risk (time-sensitive, affects initiative health)+5. Linear ↔ GitHub mismatches (status drift between systems)+6. Significant metric drops (visitors, sign-ups down >20% — could indicate a real problem)+7. Stale/aging PRs (time-sensitive, getting worse)+8. Missing follow-ups (commitments not met — no Linear issue AND no PR)+9. Cycle health warnings (behind pace, scope creep)+10. Review bottlenecks (slowing team velocity)+11. Strategic gaps (braindump concerns with no tracked work)+12. Funnel drop-offs with no tracked work (product gap)+13. Informational mismatches (good to know)++---++## Fallback Behavior+- **Slack unavailable**: Skip Slack sections, run GitHub + Linear + meetings only. Note: `slack: unavailable`+- **Linear unavailable**: Skip Linear sections, run GitHub + Slack + meetings. Note: `linear: unavailable`. Flag this — Linear is now the primary work tracker+- **PostHog unavailable**: Skip Product Metrics section, run other agents. Note: `posthog: unavailable`. The brief will still be useful without it.+- **No meetings found**: Skip meeting follow-up section, proceed with other sources+- **No braindumps found**: Skip strategic context section — this is optional enrichment, not critical+- **GitHub unavailable** (rare): Note error, skip dev activity+- **Never fabricate data** — if a query fails, say so explicitly++## Error Handling+- If gh CLI commands fail, report the error and skip that data point+- If Linear MCP tools fail, report the error and note which queries failed. Try individual queries even if batch fails+- If Slack MCP is slow, set a reasonable timeout and proceed without it+- If no meeting files found for yesterday, check day-before-yesterday as fallback+- If no braindump files found, skip silently — braindumps are written ad-hoc, not every day+- **Linear sync-back errors**: If a write-back operation fails, log the error in the sync report but do NOT retry aggressively — continue with remaining sync operations. The brief should still be generated even if some sync-back steps fail.+- **Duplicate prevention**: Before creating an attachment (PR link) on an issue, check existing attachments to avoid duplicates. Before posting an initiative status update, check if one was already posted today to avoid spam.+- **Status transition safety**: Never auto-transition an issue to a state that would lose information. If unsure about a transition, log it as "recommended" in the sync report rather than executing it.diff --git a/skills/ultragoal/SKILL.md b/skills/ultragoal/SKILL.mdnew file mode 100644index 0000000..4f4c8ac--- /dev/null+++ b/skills/ultragoal/SKILL.md@@ -0,0 +1,157 @@+---+name: ultragoal+description: >+ Run a large, multi-session goal (e.g. shipping a whole side product) through the full V-model+ closed loop, one phase at a time, with cross-session state and a final+ north-star acceptance gate. Ultragoals never downgrade the lane: every+ phase runs CP-1→CP-6 with adversarial verification. Use via /ultragoal.+---++# Ultragoal — the closed loop for goals too big to ship in one run++An **ultragoal** is the term for a north-star that spans many sessions: fork the repos, combine the strong parts, ship one product. A normal `/execute` run is one task through the loop. An ultragoal is a *chain of phases*, each of which is its own full closed-loop run, tracked so any cold session can resume.++**Core rule (from dwarves-kit, adopted fully): the worker never grades its own homework, and wrongness compounds across sessions — so verify every phase, not just the end.**++## When to use++- `/ultragoal <name>` — resume or advance an existing ultragoal+- `/ultragoal new "<north-star>"` — charter a new one+- `/ultragoal status` — report all ultragoals from the registry+- Trigger phrases: "make this an ultragoal", "this is a long-running goal", "combine these into one product over time"++Do **not** use for single-run work — that is `/execute`. Rule of thumb: if it needs a phase decomposition and won't finish today, it is an ultragoal.++## Files (one goal = one folder)++| File | Role |+|---|---|+| `04-projects/harness/ultragoals.md` | Registry: every ultragoal, status, current phase |+| `04-projects/<goal>/spec.md` | Contract: north-star + `AC-n` acceptance criteria + phases `P0…Pn` + traceability matrix |+| `04-projects/<goal>/STATUS.md` | Living ledger: phase state, current phase, open `AC-n`, next action (resume from here) |+| `04-projects/<goal>/evidence/P<n>/` | Per-phase evidence bundle (ledger.md + CP-* files) |++Code, if any, lives outside the vault (e.g. `~/code/<goal>/`) — the spec/status/evidence stay in the vault.++## Phase 0 — Charter (`/ultragoal new`)++1. Interview the user for the **north-star** in one sentence (what "done" looks like).+2. Write `04-projects/<goal>/spec.md` from `04-projects/harness/templates/SPEC-template.md`:+ - North-star statement+ - Falsifiable `AC-n` acceptance criteria (these define done for the *whole* goal)+ - Phase decomposition `P0…Pn` — each phase is a shippable increment mapped to a subset of `AC-n`+ - Traceability matrix (`AC-n` ↔ phase ↔ status)+3. Create `STATUS.md` (see template below) and add a row to the registry.++Record: `bash .claude/lib/checkpoint.sh record 04-projects/<goal>/evidence/P0 CP-1 PASS "N criteria, M phases"`++## The phase loop (every phase, no lane downgrade)++Each phase runs the **full** closed loop. Do not shortcut with `tiny`. Ultragoals are `full` lane by construction.++```+select next phase from STATUS.md+ │+ ▼+CP-2 PLAN tasks for this phase ↔ AC-n → evidence/P<n>/CP-2-plan.md+ │+ ▼+CP-3 BUILD worker implements (traced to AC-n); returns paths only+ │+ ▼+CP-3v VERIFY task-verifier (fresh context, read-only) → evidence rows per AC-n+ │ ├── FAIL:fixable → fix-agent (max 2) → re-verify+ │ └── FAIL:escalate → stop, escalate to the user+ ▼+CP-4 INTEGRATE integration-verifier → does this phase wire correctly with prior phases?+ │ (always run for ultragoals — cross-phase regression is the main risk)+ ▼+CP-5 ACCEPT observe the artifact (curl / screenshot / re-fetch), not the tool return+ │ EVIDENCE AC-n | CP-5 | PASS | <observation> | <artifact>+ ▼+CP-6 SHIP external mutation? → Review Gate: you approve. Internal? → auto.+ │+ ▼+update STATUS.md (phase → done, advance current phase, log open AC-n)+ │+ ▼+CP-7 RETRO /retro 04-projects/<goal>/evidence/P<n> → harvest + STATUS+```++Merge every verifier's `EVIDENCE` rows into `evidence/P<n>/ledger.md`.++## The two acceptance gates++1. **Per-phase (CP-5):** every `AC-n` this phase claims has a PASS row before the phase is marked done.+2. **North-star (final):** before the ultragoal is declared complete, spawn a fresh-context verifier whose only job is to check the spec matrix — **every** `AC-n` across all phases has ≥1 PASS evidence row. Any `AC-n` without one is a gap, not a ship. This is the ultragoal-level analogue of CP-5.++```+North-star acceptance:+ read spec.md matrix (all AC-n)+ read every evidence/P*/ledger.md+ for each AC-n: assert ≥1 PASS row exists, artifact re-observed+ any miss → list open AC-n, STATUS stays "in progress", do NOT declare done+```++## The HTML report (regenerate at every phase gate + final)++Every ultragoal carries a single self-contained HTML report that **covers everything**: north-star, live status, all phases, the full `AC-n` traceability table with pass/open/fail, evidence rows per phase (with screenshots embedded as `data:` URIs), and the open-items / next-action block. It is the human-readable face of the evidence ledger.++- **Template:** `04-projects/harness/templates/report.html` (house style, theme-aware, rows-not-cards). Copy it, then fill every `{{token}}` and `<!-- FILL -->` / `<!-- REPEAT -->` block from `spec.md` + `STATUS.md` + `evidence/P*/`. You fill it by editing — do not build a parser.+- **Deliverable path:** `04-projects/<goal>/report.html`. One file, overwritten each phase (it always reflects current truth).+- **When:** regenerate at each phase gate (CP-6) and again at final north-star acceptance. The final report must show every `AC-n` with a PASS row — if any pill is `open`, the goal is not done.+- **Self-contained only:** inline everything, embed screenshots as `data:` URIs, so it also works when published as an Artifact (external hosts are blocked). Before publishing as an Artifact, load the `artifact-design` skill.+- **Surface it:** `SendUserFile 04-projects/<goal>/report.html` (display: render) so the user can open it, or publish via `Artifact` for a shareable link.++## STATUS.md template++```markdown+# <Goal> — status ledger++North-star: <one sentence>+Spec: 04-projects/<goal>/spec.md · Registry: 04-projects/harness/ultragoals.md+Current phase: P<n> · Overall: <not-started|in-progress|blocked|done>++## Phases+| Phase | AC covered | State | Evidence | Notes |+|---|---|---|---|---|+| P0 | AC-1,AC-2 | done | evidence/P0/ | <one line> |+| P1 | AC-3 | in-progress | evidence/P1/ | <what's left> |++## Open AC-n (no PASS row yet)+- AC-3 — <why still open>++## Next action (resume cold from here)+<the single next concrete step + any user-gated decision waiting>+```++## Resuming cold (most common entry)++`/ultragoal <name>` with no other context:+1. Read `04-projects/<goal>/STATUS.md` → "Next action" and "Open AC-n".+2. Read the spec's phase for the current phase only (progressive disclosure).+3. Run the phase loop for the current phase.+4. Never re-do a phase already marked `done` unless integration verify caught a regression.++## Rules++- **Never downgrade the lane.** Even a one-line phase inside an ultragoal runs CP-3v + CP-4. The point is compounding correctness.+- **UI/UX phases verify visually.** If a phase touches a UI/UX flow, capture rendered evidence with browser-harness (`evidence_shot` / `FlowRecorder.save_gif` / `pixel_diff`), read the image, fix any visual defect, and re-capture — do not accept a DOM check. Media lands in `evidence/P<n>/` and feeds `report.html`. See CLAUDE.md → Visual Verification.+- **Fresh-context verifiers.** `task-verifier`, `integration-verifier`, north-star verifier get paths only — never paste worker output in (CLAUDE.md fresh-context isolation).+- **Read-only verifiers.** They cannot edit files or mutate external state.+- **Gate all external.** Any publish / deploy / push waits at CP-6 for the user (Review Gate = your approval).+- **One STATUS.md is the source of truth** for where the goal stands. Update it at the end of every phase or it drifts.+- Model routing per CLAUDE.md: Sonnet workers build/collect/verify; Opus lead reasons, decomposes, synthesizes.++## Escalation template++```+ULTRAGOAL ESCALATED — <goal> / P<n>+Last CP: <CP-id> | Open AC: <list without PASS rows>+Evidence: 04-projects/<goal>/evidence/P<n>/+Decision needed: <one question>+```++## Registered ultragoals++Live list: `04-projects/harness/ultragoals.md`. Each ultragoal gets its own `04-projects/<goal>/` folder holding `spec.md`, `STATUS.md`, `evidence/`, and `report.html`.diff --git a/skills/update-cog/SKILL.md b/skills/update-cog/SKILL.mdnew file mode 100644index 0000000..f3f62bd--- /dev/null+++ b/skills/update-cog/SKILL.md@@ -0,0 +1,101 @@+---+name: update-cog+description: Check for and apply upstream COG framework updates (skills, docs, scripts) without touching personal content+roles: [all]+integrations: [git]+---++# COG Update Skill++## Purpose+Help the user update their COG framework files (skills, documentation, scripts) from the official upstream repository without risking their personal content (braindumps, profiles, notes).++## When to Invoke+- User asks to "update COG", "check for updates", or "get latest COG version"+- User mentions wanting new skills or features from upstream+- User asks about their COG version++## Process Flow++### 1. Check Current Version+Read `COG-VERSION` from the vault root. If it doesn't exist, inform the user they may be on an older version that predates version tracking.++### 2. Ensure Upstream Remote+```bash+# Add the upstream remote if not already present+git remote get-url cog-upstream 2>/dev/null || \+ git remote add cog-upstream https://github.com/huytieu/COG-second-brain.git++# Fetch latest+git fetch cog-upstream main --quiet+```++### 3. Compare Versions+```bash+# Local version+cat COG-VERSION++# Upstream version+git show cog-upstream/main:COG-VERSION+```++If versions match, tell the user they're up to date.++### 4. Show What Changed+For each framework file, compare local vs upstream:+```bash+git diff HEAD..cog-upstream/main -- <file>+```++**Framework files** (safe to update — never contain user content):+- Core docs: `README.md`, `SETUP.md`, `AGENTS.md`, `GEMINI.md`, `CHANGELOG.md`, `CONTRIBUTING.md`+- Skills: `.claude/skills/*/SKILL.md`+- Powers: `.kiro/powers/*/POWER.md`+- Gemini: `.gemini/commands/*.toml`, `.gemini/skills/*.md`+- Config: `.claude-plugin/plugin.json`, `marketplace-entry.json`, `.gitignore`+- Scripts: `cog-update.sh`+- Version: `COG-VERSION`++### 5. Detect Customizations+Before updating, check if the user has customized any framework files:+```bash+# Compare user's file against the version they originally got+git diff cog-upstream/main -- <file>+```++If a file has local customizations, warn the user and offer options:+- **Keep yours**: Skip this file+- **Use upstream**: Overwrite with the new version+- **Backup + update**: Save current as `<file>.backup-YYYYMMDD` then update++### 6. Apply Updates+For files the user approves:+```bash+# Surgical file replacement — no merge, no rebase, zero conflict risk+git checkout cog-upstream/main -- <file>+```++### 7. Verify & Summarize+After updating:+- Show the new version number+- List all files that were updated+- List any files the user chose to skip+- Suggest committing the update:+ ```+ git add -A && git commit -m "Update COG framework to v<new-version>"+ ```++## Alternative: Shell Script+For users who prefer a non-AI update, mention the update script:+```bash+./cog-update.sh # Interactive+./cog-update.sh --check # Just check for updates+./cog-update.sh --dry-run # Preview changes+./cog-update.sh --force # Update everything+```++## Important Notes+- **Content folders are NEVER touched**: `00-inbox/`, `01-daily/`, `02-personal/`, `03-professional/`, `04-projects/`, `05-knowledge/`, `06-templates/` contain user data and are always ignored+- **The .gitignore is designed** so content folders are excluded from upstream tracking (only `.gitkeep` files are tracked)+- **The update script updates itself** — `cog-update.sh` is in the framework file list+- **No merge conflicts possible** — this uses `git checkout` for surgical file replacement, not `git merge` or `git rebase`diff --git a/skills/update-knowledge-base/SKILL.md b/skills/update-knowledge-base/SKILL.mdnew file mode 100644index 0000000..3353de3--- /dev/null+++ b/skills/update-knowledge-base/SKILL.md@@ -0,0 +1,361 @@+---+name: update-knowledge-base+description: Maintain and update product knowledge base from releases, features, and project changes with optional wiki sync+roles: [product-manager, engineering-lead, founder]+integrations: [github, linear, jira, confluence, notion]+---++# COG Update Knowledge Base Skill++## When to Invoke+- After a release — update product knowledge with new features and changes+- User says "update knowledge base", "update KB", "sync knowledge", "update product docs"+- Periodic maintenance — ensure knowledge base reflects current product state+- After major feature launches, architecture changes, or deprecations++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — use parallel agents to scan multiple sources and update multiple knowledge files simultaneously+- If `agent_mode: solo` — process updates sequentially, one knowledge file at a time++## Command: `/update-knowledge-base`++## Pre-Flight Check++1. **Read `00-inbox/MY-INTEGRATIONS.md`** for active data sources and publishing targets+2. **Read `00-inbox/MY-PROFILE.md`** for active projects+3. **Get current timestamp:** Run `date '+%Y-%m-%d %H:%M'` using Bash+4. **Scan existing knowledge base:** Glob `05-knowledge/**/*.md` to understand current state++---++## Execution Strategy++### Phase 1: Determine Update Scope++Ask the user (or infer from context):++```+What triggered this knowledge base update?++a) New release shipped (I'll pull changes from release notes and tracker)+b) Feature launched or updated (I'll document the feature)+c) Architecture or technical change (I'll update technical knowledge)+d) Periodic review (I'll scan for anything that's changed since last update)+e) Custom — describe what needs updating+```++### Phase 2: Gather Update Data++#### Team Mode (parallel agents)++Launch data-gathering agents using the Task tool with `run_in_background: true`:++**Agent: "release-scanner"** (for release-triggered updates)+```+Scan recent releases and release notes for knowledge base updates.++1. Check vault for recent release notes:+ Glob: 04-projects/*/release-notes/*.md+ Read the most recent release notes for each active project++2. If GitHub is active:+ gh release list --repo [CUSTOMIZE: your-org/your-repo] --limit 5 --json tagName,name,body,publishedAt+ Get the latest release details++3. If Linear is active:+ Use ToolSearch to load Linear tools+ Check recently completed cycles and milestones for shipped features++Extract from each source:+- New features added (name, description, user impact)+- Features modified (what changed)+- Features deprecated or removed+- Technical changes (architecture, API, infrastructure)+- Bug fixes that affect documented behavior++Return: structured list of knowledge updates needed+```++**Agent: "existing-kb-auditor"**+```+Audit the current knowledge base for staleness and gaps.++1. Read all files in 05-knowledge/:+ Glob: 05-knowledge/**/*.md++2. For each file, extract:+ - Last updated date (from frontmatter or file modification)+ - Topics covered+ - Products/features documented+ - Any [TODO] or [OUTDATED] markers++3. Cross-reference with active projects from MY-PROFILE.md:+ - Are all active projects represented in the KB?+ - Are there KB entries for discontinued/inactive projects?++4. Check for:+ - Files not updated in >90 days (potentially stale)+ - Topics mentioned in recent release notes but missing from KB+ - Contradictions between KB entries and recent changes++Return: staleness report, gap analysis, and recommended updates+```++**Agent: "tracker-feature-collector"** (for feature-triggered updates)+```+Collect current feature/product state from project trackers.++If Linear is active:+1. Use ToolSearch to load Linear tools+2. List all projects and their current status: mcp__claude_ai_Linear_2__list_projects+3. List all initiatives: mcp__claude_ai_Linear_2__list_initiatives+4. For key initiatives, get details: mcp__claude_ai_Linear_2__get_initiative++If GitHub is active:+1. Check repo README and docs for current feature descriptions+2. Review recent PRs that touch documentation:+ gh pr list --repo [CUSTOMIZE: your-org/your-repo] --state merged --search "label:docs merged:>=[30_DAYS_AGO]" --json number,title,body --limit 20++Return: current product/feature state for knowledge base comparison+```++#### Solo Mode+Run the most relevant agent sequentially based on the update trigger.++### Phase 3: Identify Knowledge Updates++Compare gathered data against existing knowledge base to determine:++1. **New entries needed** — features, products, or topics not yet documented+2. **Updates needed** — existing entries that need modification+3. **Deprecation/removal** — entries for features that no longer exist+4. **Gap filling** — missing context, examples, or cross-references++Present the update plan to the user:++```+Knowledge Base Update Plan:++NEW entries to create:+1. [Topic] — [reason: new feature in v[X]]+2. [Topic] — [reason: gap identified]++UPDATES to existing entries:+1. 05-knowledge/[file].md — [what needs changing]+2. 05-knowledge/[file].md — [what needs changing]++DEPRECATION candidates:+1. 05-knowledge/[file].md — [reason: feature removed in v[X]]++STALE entries (>90 days, may need review):+1. 05-knowledge/[file].md — last updated [date]++Proceed with these updates? (yes / modify plan / skip specific items)+```++**Wait for user approval before making changes.**++### Phase 4: Execute Updates++#### 4.1 Create New Knowledge Entries++For each new entry, use this template:++```markdown+---+type: knowledge+domain: [product/technical/process/architecture]+project: [project-name]+topic: [topic name]+created: [YYYY-MM-DD HH:MM]+last_updated: [YYYY-MM-DD]+source: [release-notes/feature-launch/manual/periodic-review]+version: "1.0"+tags: ["#knowledge", "#[project]", "#[topic-area]"]+related:+ - [path to related KB entry]+ - [path to related project file]+---++# [Topic Title]++## Overview+[Clear, concise description of the topic — what it is, why it matters]++## Current State+[How this feature/system/process works as of the last update]++### Key Details+- **[Detail 1]:** [Value/description]+- **[Detail 2]:** [Value/description]+- **[Detail 3]:** [Value/description]++## History+| Date | Version | Change | Source |+|------|---------|--------|--------|+| [Date] | [Version] | [What changed] | [Release notes / PR / manual] |++## Related+- [Link to related KB entries]+- [Link to PRDs if applicable]+- [Link to project files]++## Notes+[Additional context, caveats, or open questions]++---++*Last updated: [YYYY-MM-DD] | Source: [what triggered this update]*+```++Save to: `05-knowledge/[domain]/[topic-slug].md`++```bash+mkdir -p "05-knowledge/[domain]"+```++#### 4.2 Update Existing Entries++For each update:+1. Read the existing file+2. Update the relevant sections+3. Add a row to the History table+4. Update `last_updated` in frontmatter+5. Update `version` (increment minor version)++#### 4.3 Mark Deprecations++For deprecated entries:+1. Add `status: deprecated` to frontmatter+2. Add a deprecation notice at the top of the file:+ ```markdown+ > **DEPRECATED:** This feature was removed/replaced in [version/date]. See [replacement link] for the current approach.+ ```+3. Do NOT delete the file — historical context is valuable++### Phase 5: Generate Update Summary++Create an update log:++```markdown+---+type: kb-update-log+date: [YYYY-MM-DD]+created: [YYYY-MM-DD HH:MM]+trigger: [release/feature/periodic/manual]+tags: ["#knowledge", "#update-log"]+---++# Knowledge Base Update — [YYYY-MM-DD]++## Trigger+[What caused this update: release X.Y.Z / feature launch / periodic review]++## Changes Made++### New Entries+| File | Topic | Domain | Source |+|------|-------|--------|--------|+| [path] | [topic] | [domain] | [source] |++### Updated Entries+| File | Changes | Previous Version | New Version |+|------|---------|-----------------|-------------|+| [path] | [summary of changes] | [old ver] | [new ver] |++### Deprecated Entries+| File | Reason | Replacement |+|------|--------|-------------|+| [path] | [reason] | [link to replacement or N/A] |++## Knowledge Base Health+- **Total entries:** [N]+- **Updated this session:** [N]+- **Created this session:** [N]+- **Deprecated this session:** [N]+- **Stale entries remaining (>90 days):** [N]+- **Coverage:** [assessment of how well the KB covers active projects]++---++*Generated by COG Knowledge Base Updater*+```++Save to: `05-knowledge/_logs/kb-update-YYYY-MM-DD.md`++```bash+mkdir -p "05-knowledge/_logs"+```++### Phase 6: Optional Wiki Sync (requires approval)++If Confluence or Notion is active, offer to sync updated entries:++```+Knowledge base updated locally. Would you like to sync to your wiki?++Active wiki platforms:+- [Confluence / Notion — whichever is active]++Options:+a) Sync all changed entries to [platform]+b) Sync specific entries only+c) Skip wiki sync (vault-only)+```++**NEVER auto-publish. Wait for explicit approval.**++#### Confluence Sync+Use the `/publish-to-confluence` skill pattern for each entry being synced.++#### Notion Sync+```+1. Use ToolSearch to load Notion tools+2. Search for existing pages matching the KB entry: mcp__claude_ai_Notion__notion-search+3. If exists: update with mcp__claude_ai_Notion__notion-update-page+4. If new: create with mcp__claude_ai_Notion__notion-create-pages+```++---++## Knowledge Base Organization++Recommended `05-knowledge/` structure:++```+05-knowledge/+ _logs/ # Update logs+ kb-update-YYYY-MM-DD.md+ product/ # Product features, capabilities, roadmap+ [feature-name].md+ technical/ # Architecture, APIs, infrastructure+ [system-name].md+ process/ # Team processes, workflows, conventions+ [process-name].md+ domain/ # Domain knowledge, industry context+ [topic-name].md+ integrations/ # Integration docs, API references+ [integration-name].md+```++---++## Fallback Behavior++| Scenario | Behavior |+|----------|----------|+| No trackers active | Work from vault data only (release notes, PRDs, project files) |+| No existing KB entries | Create the initial knowledge base structure and first entries |+| Wiki sync fails | All changes are already saved locally; inform user to sync manually |+| Very large KB (>50 files) | Process in batches, prioritize most recently changed entries |+| No recent changes found | Report that KB is up to date; suggest periodic review topics |+| Conflicting information | Flag conflicts for user resolution rather than auto-resolving |++## Error Handling++- **File conflicts**: If an update would contradict a recent manual edit, present both versions to the user+- **Context overflow**: Process knowledge files in batches of 10+- **Stale data sources**: Warn if tracker data seems outdated (API issues)+- **Missing project context**: Ask user to clarify which project the knowledge relates todiff --git a/skills/url-dump/SKILL.md b/skills/url-dump/SKILL.mdnew file mode 100644index 0000000..068817c--- /dev/null+++ b/skills/url-dump/SKILL.md@@ -0,0 +1,459 @@+---+name: url-dump+description: Quick capture URLs with automatic content extraction, insights, and categorization into knowledge booklets+roles: [all]+integrations: [web-fetch]+---++# COG URL Dump Skill++## Purpose+Transform raw URLs into structured, insightful knowledge entries through intelligent content extraction, categorization, and integration with the user's knowledge base. Quick capture with automatic insight generation.++## When to Invoke+- User shares a URL they want to save+- User says "save this link", "bookmark this", "url dump", or "save for later"+- User pastes a URL and wants to capture it+- User wants to organize web resources into their knowledge base++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — delegate content extraction, analysis, and categorization to a sub-agent while handling user interaction directly. The sub-agent fetches URL content, generates insights, and returns structured results for filing.+- If `agent_mode: solo` (default) — handle everything directly in the conversation. No delegation.++## Pre-Flight Check++**Before executing, check for user profile:**++1. Look for `00-inbox/MY-PROFILE.md` in the vault+2. If NOT found:+ ```+ Welcome to COG! It looks like this is your first time.++ Before we start, let's quickly set up your profile (takes 2 minutes).++ Would you like to run onboarding first, or should I proceed with default settings?+ ```+3. If found:+ - Read the profile to get user's interests and projects+ - Use interests to help with auto-categorization+ - Check for existing booklet categories in `05-knowledge/booklets/`++## Process Flow++### 1. User Interaction & Input Collection+- Accept URL(s) from the user (single URL or batch)+- Optionally accept user's quick note about why they're saving this+- Accept any format: bare URL, markdown link, or with notes++**Prompt:**+```+What URL(s) would you like to save?+(You can paste one or more URLs, optionally with a note about why you're saving it)+```++### 2. URL Validation & Fetch+- Validate URL format+- Check if URL is accessible+- Detect duplicate URLs in existing knowledge base+- Fetch the web page content++#### Content Extraction+Extract from the page:+- **Page Title:** [extracted-title]+- **Meta Description:** [if available]+- **Author:** [if detected]+- **Published Date:** [if detected]+- **Word Count:** [estimated]+- **Read Time:** [X minutes]+- **Main Content:** [extracted body text]+- **Key Headings:** [list of H1/H2s]++### 3. Category Selection++**Default Categories:**+- **Articles & Blogs:** Long-form content, tutorials, opinion pieces+- **Tools & Resources:** Software, utilities, services, APIs+- **Reference:** Documentation, specs, standards+- **Research:** Papers, studies, academic content+- **Inspiration:** Design, ideas, creative references+- **Videos & Media:** YouTube, podcasts, multimedia+- **News & Updates:** Industry news, announcements+- **Project-Specific:** Related to a specific project (offer project list from MY-PROFILE.md)+- **To Review:** Unsure, save for later categorization++**Custom Categories:**+- Check `05-knowledge/booklets/` for existing custom categories+- Offer to create new category if needed++**Auto-suggestion:** Based on content analysis, suggest the most likely category but let user confirm or change.++### 4. Content Analysis and Processing++#### Phase 1: Content Classification+Determine:+- **Content Category:** [article|tool|reference|research|video|news|etc]+- **Primary Topics:** [topic1, topic2, topic3]+- **Tone:** [informative|opinion|tutorial|news|etc]+- **Quality Assessment:** [high|medium|low]+- **Credibility Indicators:** [author credentials, citations, etc]++#### Phase 2: Insight Extraction+Generate:+- **Executive Summary:** [2-3 sentences]+- **Key Insights:**+ 1. [Insight 1 with context]+ 2. [Insight 2 with context]+ 3. [Insight 3 with context]+- **Notable Quotes:** [if any stand out]+- **Action Items:** [practical takeaways]++#### Phase 3: Relevance Assessment+Analyze:+- **User Interest Match:** [high|medium|low] - [which interests from profile]+- **Project Relevance:** [project-name] - [why relevant]+- **Knowledge Gap:** [yes|no] - [what gap it fills]+- **Timeliness:** [evergreen|current|dated]+- **Uniqueness:** [novel|common|duplicate-adjacent]++#### Phase 4: Cross-Reference+Identify connections to:+- **Related Bookmarks:** [existing similar saves]+- **Related Braindumps:** [if content connects]+- **Related Projects:** [if applicable]+- **Suggested Tags:** [tag1, tag2, tag3]++### 5. Generate Structured Output++Create bookmark file with this structure:++```markdown+---+type: "url-bookmark"+category: "[category-name]"+domain: "[source-domain.com]"+date_saved: "YYYY-MM-DD"+date_accessed: "YYYY-MM-DD HH:MM"+url: "[original-url]"+title: "[page-title]"+author: "[author-if-available]"+published: "[publish-date-if-available]"+tags: ["#bookmark", "#category-tag", "#topic-tags"]+relevance: "[high|medium|low]"+status: "unread"+related_projects: ["project1", "project2"]+confidence: "[high|medium|low]"+---++# [Title]++## Quick Summary+[2-3 sentence summary of the content]++## Key Insights+- **Insight 1:** [description with context]+- **Insight 2:** [description with context]+- **Insight 3:** [description with context]++## Why This Matters+[Connection to user's interests/projects. What makes this worth saving?]++## User Note+[Original user note if provided, otherwise omit section]++## Content Highlights+[Key excerpts or quotes from the content - 200-400 words max]++## Practical Takeaways+- [ ] [Action item 1 if applicable] 📅 [YYYY-MM-DD = date +1 week from today]+- [ ] [Action item 2 if applicable] 📅 [YYYY-MM-DD = date +1 week from today]++## Related Knowledge+- **Similar Bookmarks:** [[bookmark1]], [[bookmark2]]+- **Connected Projects:** [[project1]]+- **Related Notes:** [[note1]], [[note2]]++## Source Details+| Field | Value |+|-------|-------|+| Domain | [domain] |+| Author | [author or "Unknown"] |+| Published | [date or "Unknown"] |+| Word Count | [~X words] |+| Read Time | [~X minutes] |++## Processing Notes+- **Extracted:** [timestamp]+- **Category Confidence:** [percentage]+- **Review Needed:** [yes|no] - [reason if yes]++---++*Processed by COG URL Curator*+```++Save to appropriate location:+- **Standard:** `05-knowledge/booklets/[category-slug]/[title-slug]-YYYY-MM-DD.md`+- **Project-specific:** `04-projects/[project-slug]/resources/[title-slug]-YYYY-MM-DD.md`+- **Mixed/Unclear:** `00-inbox/url-[title-slug]-YYYY-MM-DD.md`++### 6. Tool/Resource Special Handling++For tools and software, use enhanced template:++```markdown+---+type: "url-tool"+category: "tools"+domain: "[domain]"+url: "[url]"+title: "[tool-name]"+date_saved: "YYYY-MM-DD"+pricing: "[free|freemium|paid|enterprise]"+tags: ["#tool", "#category-tags"]+status: "to-evaluate"+---++# [Tool Name]++## What It Does+[1-2 sentence description]++## Key Features+- Feature 1+- Feature 2+- Feature 3++## Use Cases+- Use case 1+- Use case 2++## Pricing+[Pricing details if available]++## Why It's Relevant+[Connection to user's work/interests]++## Evaluation Status+- [ ] Sign up / try demo 📅 [YYYY-MM-DD = date +3 days from today]+- [ ] Test key features 📅 [YYYY-MM-DD = date +1 week from today]+- [ ] Compare with alternatives 📅 [YYYY-MM-DD = date +1 week from today]+- [ ] Decision: [use|pass|revisit] 📅 [YYYY-MM-DD = date +2 weeks from today]++## Notes+[Space for user's evaluation notes]++---++*Processed by COG URL Curator*+```++### 7. Batch Processing++For multiple URLs:++```+Processing [X] URLs...++1. [URL 1] → [category] → Saved to [path]+2. [URL 2] → [category] → Saved to [path]+3. [URL 3] → [category] → Saved to [path]++Summary:+- Articles: 2 saved+- Tools: 1 saved+- Total: 3 URLs processed+```++### 8. Confirm Completion+- Confirm file(s) created+- Show user: "URL saved to [file path]"+- Show quick summary: title, category, key insight preview+- Ask if they want to:+ - Add another URL+ - Deep-dive into the content+ - Connect to specific project or braindump++## Booklet Structure++URLs are organized into "booklets" (category folders):++```+05-knowledge/+└── booklets/+ ├── articles/+ │ ├── _index.md (category overview - auto-created)+ │ └── [article-entries].md+ ├── tools/+ │ ├── _index.md+ │ └── [tool-entries].md+ ├── reference/+ │ ├── _index.md+ │ └── [reference-entries].md+ ├── research/+ │ ├── _index.md+ │ └── [research-entries].md+ ├── inspiration/+ │ ├── _index.md+ │ └── [inspiration-entries].md+ ├── videos/+ │ ├── _index.md+ │ └── [video-entries].md+ └── [custom-category]/+ ├── _index.md+ └── [entries].md+```++### Category Index Template++When creating a new category, also create an index file:++```markdown+---+type: "booklet-index"+category: "[category-name]"+created: "YYYY-MM-DD"+last_updated: "YYYY-MM-DD"+entry_count: 0+---++# [Category Name] Booklet++## Description+[What this category contains]++## Recent Additions+[Auto-updated list - most recent 10 entries]++## Top Entries+[Manually curated or most-accessed entries]++## Tags in This Category+[List of common tags used]++## Related Categories+- [[other-category-1]]+- [[other-category-2]]+```++## YAML Formatting Requirements++**CRITICAL:** All YAML frontmatter must use proper Obsidian-compatible formatting:+- All string values MUST be quoted with double quotes+- Arrays MUST use quoted strings: `["item1", "item2", "item3"]`+- URLs MUST be quoted to handle special characters+- Boolean values should NOT be quoted: `true` or `false`+- Ensure proper YAML syntax to prevent parsing errors in Obsidian++**Examples:**+```yaml+# CORRECT+type: "url-bookmark"+url: "https://example.com/path?query=value"+tags: ["#bookmark", "#article", "#ai"]+relevance: "high"+reviewed: false++# INCORRECT+type: url-bookmark+url: https://example.com/path?query=value+tags: [#bookmark, #article, #ai]+relevance: high+reviewed: "false"+```++## Verification Protocols++### Content Accuracy+- **Title Verification:** Ensure extracted title matches page+- **Author Attribution:** Verify author if stated+- **Date Accuracy:** Confirm publication date if shown+- **Summary Fidelity:** Ensure summary accurately represents content++### Categorization Verification+- **Category Fit:** Confirm content matches selected category+- **Tag Relevance:** Verify tags accurately describe content+- **Interest Alignment:** Confirm relevance assessment is accurate+- **Project Connection:** Verify project relevance if claimed++### Quality Checks+- **Completeness:** All required fields populated+- **Formatting:** Proper markdown and YAML syntax+- **Links:** All internal links valid+- **Metadata:** Frontmatter properly formatted++## Uncertainty Handling++### When Content is Unclear+- **Paywalled Content:** Note limitation, extract available preview+- **Dynamic Content:** Note if content may change+- **Complex Content:** Flag for manual review if needed+- **Non-English:** Note language, provide translation if possible++### Confidence Indicators+- **High Confidence (90%+):** Clear content with obvious categorization+- **Medium Confidence (70-89%):** Generally clear with some ambiguity+- **Low Confidence (50-69%):** Significant ambiguity requiring user input+- **Very Low Confidence (<50%):** Major uncertainty, save to inbox++Always explicitly state confidence levels and reasoning in processing notes.++## Loop Engineering++URL capture is a **fetch-retry loop with a quality gate**, not a single fetch-and-file. See `.claude/skills/loop-engineering/SKILL.md` for the shared vocabulary.++**The loop (per URL):** fetch → if the fetch fails or returns an empty/blocked body, retry a different way (https vs http, reader mode, an archive snapshot) → once content is present, run the quality gate → file it, or escalate to the user / save to inbox with a Review Needed flag.++**The verifier (deterministic):**+- Fetch returned a non-empty body (not a paywall stub or error page).+- Required fields are populated: title, at least one key insight, a category.+- YAML frontmatter is valid (see YAML Formatting Requirements).+- Category confidence clears the threshold. Below ~70%, the loop does not silently guess.++**Termination conditions (layered):**+- **Goal met:** content extracted and the quality gate passes → save to the category folder.+- **Retry cap:** stop after ~3 fetch attempts → save what was extracted with a low-confidence flag (see Uncertainty Handling), do not invent missing fields.+- **Hard stop on paywall / login wall:** note the limitation, capture the available preview, do not loop forever.+- **Human escalation:** confidence below threshold → present the best guess and ask the user to confirm category, rather than filing it wrong.++**Patterns:** reflect-retry (each failed fetch picks a different method) + evaluator (the quality gate) + human-in-the-loop (low-confidence escalation).++**In-loop context:** once insights and metadata are extracted, drop the raw page body. For batch input, process each URL as its own independent loop so one bad URL never stalls the rest.++## Integration with Other Skills++### Immediate Follow-up+After URL capture, suggest:+- `/braindump` - Capture thoughts about the URL+- `/knowledge-consolidation` - Integrate into knowledge frameworks+- Daily brief will surface relevant saved URLs++### Cross-Referencing+Automatically check for connections to:+- Active projects (from MY-PROFILE.md)+- Recent braindumps+- Competitive watchlist companies (if exists)+- User interests++## Success Metrics+- Speed of capture (< 30 seconds for single URL)+- Accurate categorization with user confirmation+- Useful insight extraction+- Proper integration with existing knowledge+- Easy retrieval and discovery later+- High confidence in extractions++## Learning and Adaptation++### Pattern Learning+- Track which bookmarks get revisited+- Learn user's categorization preferences+- Improve relevance scoring based on engagement+- Refine insight extraction based on what user finds useful++### Continuous Improvement+- Monitor categorization accuracy over time+- Adapt to user's preferred tag taxonomy+- Learn domain-specific terminology+- Improve cross-referencing accuracydiff --git a/skills/weekly-checkin/SKILL.md b/skills/weekly-checkin/SKILL.mdnew file mode 100644index 0000000..ed816e6--- /dev/null+++ b/skills/weekly-checkin/SKILL.md@@ -0,0 +1,446 @@+---+name: weekly-checkin+description: Cross-domain pattern analysis and strategic reflection for weekly review+roles: [all]+integrations: []+---++# COG Weekly Check-in Skill++## Purpose+Comprehensive weekly review and analysis integrating insights across all domains (personal, professional, projects) with pattern recognition and strategic planning.++## When to Invoke+- User wants to do their weekly review+- User says "weekly checkin", "weekly review", "reflect on my week"+- End of week reflection time+- User wants to analyze patterns across the week++## Agent Mode Awareness++**Check `agent_mode` in `00-inbox/MY-PROFILE.md` frontmatter:**+- If `agent_mode: team` — delegate domain-specific analysis to sub-agents (e.g., one for personal patterns, one for professional review, one per active project). Each agent scans relevant braindumps/briefs and returns insights. Combine into the weekly synthesis.+- If `agent_mode: solo` (default) — handle all scanning and analysis directly in the conversation. No delegation.++## Pre-Flight Check++**Check for user profile (optional but enhances experience):**++1. Look for `00-inbox/MY-PROFILE.md` in the vault+2. If found:+ - Read user's name for personalization+ - Read active projects to review project-specific progress+ - Tailor reflection questions to user's role and projects++**Get current timestamp (REQUIRED before generating any files):**++1. Run `date '+%Y-%m-%d %H:%M'` using Bash to get the actual current date and time+2. Store this value and use it for the `created:` frontmatter field+3. NEVER guess or fabricate the time — always use the value returned by the `date` command++## Process Flow++### 1. Gather Context++Scan recent files from the past week:+- Daily briefs in `01-daily/briefs/`+- Braindumps in `02-personal/braindumps/`, `03-professional/braindumps/`, `04-projects/*/braindumps/`+- Previous check-ins in `01-daily/checkins/`++If `MY-PROFILE.md` available:+- Use user's name for personalization+- Reference their active projects+- Tailor questions to their role++### 2. Guided Reflection++Lead user through reflection questions in a warm, conversational tone:++#### Overall Week Assessment+**Ask:**+- "How would you rate this week on a 1-5 scale? Why that rating?"+- "What were your biggest wins this week?"+- "What were your main challenges?"++**Listen for:**+- Overall sentiment and energy+- Key accomplishments they're proud of+- Obstacles they faced+- Emotional tone of the week++#### Domain Reviews++**Personal Domain:**+**Ask:**+- "How did you take care of yourself this week?"+- "Any personal growth or insights?"+- "How were your energy levels and well-being?"++**Professional Domain:**+**Ask:**+- "What did you accomplish at work? Any standout moments?"+- "How did things go with your team or colleagues?"+- "Any professional development or learning?"++**Projects Domain (if applicable):**+For each active project from MY-PROFILE.md:+**Ask:**+- "How did [project name] progress this week?"+- "What moved forward? What's blocking you?"+- "Any new insights or direction changes?"++#### Pattern Recognition++**Ask:**+- "Looking at your braindumps this week, did you notice any recurring themes?"+- "How did your energy levels vary throughout the week?"+- "Any connections between different areas of your life - personal, professional, projects?"+- "What surprised you this week?"++**Help identify:**+- Themes they might not see themselves+- Patterns across domains+- Evolution of thinking+- Cross-domain connections++#### Forward Planning++**Ask:**+- "What are your top 3 priorities for next week?"+- "Anything from this week you want to carry forward?"+- "What do you want to do differently next week?"+- "What success would look like next week?"++**Help with:**+- Clarifying priorities+- Being specific about goals+- Identifying experiments to try+- Setting measurable outcomes++### 3. Generate Weekly Check-in Document++Based on the conversation, create a structured check-in document:++```markdown+---+type: "weekly-checkin"+domain: "integrated"+date: "YYYY-MM-DD"+week_of: "YYYY-MM-DD"+created: "YYYY-MM-DD HH:MM"+tags: ["#weekly-checkin", "#reflection", "#planning"]+domains_analyzed: ["personal", "professional", "projects"]+rating: [1-5]+braindumps_reviewed: [count]+briefs_reviewed: [count]+---++# Weekly Check-in - Week of [Date]++## Executive Summary++**Week Rating:** [1-5] ⭐ - [User's reasoning in their words]++**In Three Words:** [word1], [word2], [word3]++**Key Highlights:**+- [Win 1 - specific and celebratory]+- [Win 2 - acknowledge effort and outcome]+- [Win 3 if applicable]++**Main Challenges:**+- [Challenge 1 - honest and clear]+- [Challenge 2 - what made it difficult]++---++## Domain Reviews++### 💭 Personal++**Wellness & Self-Care:**+[User's reflection on personal wellness, relationships, health]++**Energy Patterns:**+- [Observations about energy levels throughout the week]+- [What energized them]+- [What drained them]++**Personal Growth:**+- [Insights or realizations]+- [New habits or changes]++**Rating:** [1-5] ⭐++---++### 💼 Professional++**Accomplishments:**+[User's reflection on work accomplishments, projects completed, milestones reached]++**Team & Collaboration:**+[Insights about team dynamics, meetings, relationships]++**Challenges & Learnings:**+[What was difficult and what they learned]++**Professional Development:**+[Skills developed, knowledge gained]++**Rating:** [1-5] ⭐++---++### 🎯 Projects++[For each active project:]++#### [Project Name]++**Progress This Week:**+- [What moved forward - be specific]+- [Milestones achieved]+- [Decisions made]++**Current Status:** [On track | Needs attention | Blocked | Pivoting]++**Blockers:**+- [What's in the way - if any]+- [Dependencies waiting on]++**Insights & Direction:**+[Any strategic insights or direction changes]++**Next Steps:**+- [ ] [Specific next action 1] 📅 [YYYY-MM-DD = date of next Monday]+- [ ] [Specific next action 2] 📅 [YYYY-MM-DD = date of next Friday]+- [ ] [Specific next action 3] 📅 [YYYY-MM-DD = date +1 week from today]++**Rating:** [1-5] ⭐++---++## 🔍 Pattern Recognition++### Recurring Themes+[Themes identified across all braindumps and activities this week:]+1. **[Theme 1]:** [Description and significance]+2. **[Theme 2]:** [Description and significance]+3. **[Theme 3]:** [Description and significance]++### Energy & Productivity Patterns+- **Peak Times:** [When they were most productive/energized]+- **Low Points:** [When energy dipped]+- **Factors:** [What influenced energy - sleep, meetings, deep work, etc.]++### Cross-Domain Insights+[Connections between personal, professional, and project domains:]+- [Connection 1 - e.g., "Personal stress affecting project focus"]+- [Connection 2 - e.g., "Professional wins boosting personal confidence"]+- [Connection 3 - e.g., "Project learning applying to work"]++### Thinking Evolution+[How their thinking or approach evolved during the week:]+- [Evolution 1]+- [Evolution 2]++---++## 📅 Forward Planning++### Priorities for Next Week++**Top 3 Must-Do:**+1. [Priority 1 - specific and actionable]+2. [Priority 2 - specific and actionable]+3. [Priority 3 - specific and actionable]++**Why These Matter:**+[Brief explanation of strategic importance]++### Carry Forward Items+- [ ] [Unresolved item from this week - with context] 📅 [YYYY-MM-DD = date of next Monday]+- [ ] [Ongoing task - with next action] 📅 [YYYY-MM-DD = mid-next-week]+- [ ] [Follow-up needed - with who/what] 📅 [YYYY-MM-DD = date +1 week from today]++### Experiments & Changes++**What to Try Differently:**+- [Experiment 1 - be specific about what and why]+- [Experiment 2 - what you hope to learn]++**What to Keep Doing:**+- [Practice 1 that's working well]+- [Habit 2 to maintain]++**What to Stop:**+- [Thing 1 that's not serving you]+- [Practice 2 to eliminate]++### Success Criteria for Next Week++**I'll know next week was successful if:**+- [Measurable outcome 1]+- [Measurable outcome 2]+- [Qualitative measure 3]++---++## 📊 Week in Review++**Documents Analyzed:**+- [X] braindumps reviewed+- [X] daily briefs reviewed+- [X] previous check-ins referenced++**Time Analysis:**+- Braindumps: [count] across [domains]+- Most active domain: [domain name]+- Dominant themes: [top 2-3 themes]++**Sentiment Trend:**+[Overall emotional trajectory of the week - growing, stable, declining, mixed]++---++## 💡 Insights & Notes++### Strategic Observations+[Higher-level observations about trajectory, patterns, or strategic direction]++### Questions for Deeper Reflection+- [Question 1 that emerged during review]+- [Question 2 for future consideration]++### Gratitude & Appreciation+[Optional - what they're grateful for or who they want to acknowledge]++---++*Generated by COG Weekly Check-in Skill | Integrating insights across all domains*+```++Save to: `01-daily/checkins/weekly-checkin-YYYY-MM-DD.md`++### 4. Confirm Completion++After creating the check-in:+- Confirm file was created+- Show user: "Weekly check-in saved to [file path]"+- Highlight 1-2 key patterns spotted+- Offer to review patterns across multiple weeks if helpful+- Ask if they want to capture any follow-up thoughts via braindump skill++## Loop Engineering++The weekly check-in pairs a **per-domain scan loop** with a **human-in-the-loop reflection**, gated by a coverage checklist. See `.claude/skills/loop-engineering/SKILL.md` for the shared vocabulary.++**The scan loop (gather phase):** scan each domain's recent files → aggregate candidate themes → run the coverage check → if a domain or active project is thin, scan it more deeply before moving on. In `agent_mode: team`, fan this out as one worker per domain (orchestrator-workers); each returns its themes only.++**The reflection loop (guided phase):** this is human-in-the-loop by design. Ask, listen, reflect back, ask the targeted follow-up. The loop continues until the coverage checklist is satisfied or the user signals they are done. Do not rush it and do not force positivity.++**The verifier (deterministic checklist):**+- Every active project in `MY-PROFILE.md` has a Projects section addressed.+- Each domain (personal / professional / projects) was actually covered, not skipped.+- At least the recurring themes the scan surfaced were raised with the user.++**Termination conditions (layered):**+- **Coverage complete:** checklist satisfied → generate the check-in document.+- **User signals done:** respect it; generate with what you have and note any thin spots.+- **No-progress / terse answers:** if follow-ups keep returning little, stop probing that thread and offer to skip it rather than grinding. Escalation here means handing the choice back to the user.++**Patterns:** orchestrator-workers (team-mode domain scans) + human-in-the-loop (reflection) + completeness checklist (the verifier).++**In-loop context:** capture answers into the check-in structure as the conversation goes, so a long reflection does not lose early answers.++## Conversational Guidelines++### Do:+- Have a warm, empathetic, conversational tone+- Ask thoughtful follow-up questions based on user's answers+- Help identify patterns they might not see themselves+- Be honest and objective in summarizing their reflections+- Celebrate wins genuinely and specifically+- Acknowledge challenges without sugar-coating or minimizing+- Show curiosity about their experiences+- Reflect back what you're hearing for validation++### Don't:+- Rush through the questions+- Make assumptions about what matters to them+- Judge their answers or week rating+- Over-structure their free-form reflections+- Force positivity if they had a tough week+- Dismiss their challenges or concerns+- Skip the emotional/energy assessment+- Be clinical or robotic in tone++## Pattern Recognition Techniques++### Frequency Analysis+- What themes come up repeatedly across braindumps?+- Which topics get the most attention?+- What's mentioned but not deeply explored?++### Temporal Clustering+- What insights emerged together in time?+- How did thinking evolve from Monday to Friday?+- Were there inflection points during the week?++### Domain Correlation+- What patterns cross personal/professional/project boundaries?+- How do domains influence each other?+- Where is there alignment or tension?++### Contradiction Analysis+- Where does thinking conflict with actions?+- Are there competing priorities?+- What tensions exist between domains?++### Energy Pattern Detection+- When was energy highest/lowest?+- What activities energized vs. drained?+- How did energy affect productivity and insights?++## Integration with Other Skills++### Pattern Analysis+Review multiple weekly check-ins to:+- Spot long-term patterns (monthly, quarterly)+- Track goal progress over time+- Identify seasonal or cyclical patterns+- Use knowledge-consolidation skill to extract frameworks++### Project Tracking+Weekly check-ins provide:+- Historical record of project progress+- Evolution of thinking on projects+- Correlation between project work and other domains+- Context for future project analysis++### Knowledge Building+Check-ins feed into:+- Personal development patterns+- Strategic thinking evolution+- Decision-making frameworks+- Life/work balance insights++## Success Metrics+- User completes meaningful reflection+- Patterns identified and documented+- Clear priorities set for next week+- User feels heard and understood+- File saved with complete information+- Cross-domain insights revealed+- Actionable next steps defined++## Philosophy++The weekly check-in skill embodies COG's integrated intelligence approach:+- Holistic view across all life domains+- Pattern recognition over isolated events+- Strategic reflection driving tactical planning+- Emotional and practical dimensions both honored+- Thinking evolution tracked and celebrated+- Self-awareness as foundation for growth