@istmx/skills 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +49 -0
- package/bin/cli.js +251 -0
- package/istm/SKILL.md +65 -0
- package/istm-animate/SKILL.md +87 -0
- package/istm-animate/animations/animation_utils.md +280 -0
- package/istm-animate/animations/animations.md +220 -0
- package/istm-animate/animations/core_motion.md +250 -0
- package/istm-animate/animations/examples/README.md +29 -0
- package/istm-animate/animations/examples/nuxt/app/app.vue +3 -0
- package/istm-animate/animations/examples/nuxt/app/composables/useGSAP.ts +91 -0
- package/istm-animate/animations/examples/nuxt/app/pages/index.vue +55 -0
- package/istm-animate/animations/examples/nuxt/nuxt.config.ts +4 -0
- package/istm-animate/animations/examples/nuxt/package.json +18 -0
- package/istm-animate/animations/examples/react/App.jsx +46 -0
- package/istm-animate/animations/examples/react/index.html +12 -0
- package/istm-animate/animations/examples/react/main.jsx +9 -0
- package/istm-animate/animations/examples/react/package.json +21 -0
- package/istm-animate/animations/examples/react/vite.config.js +7 -0
- package/istm-animate/animations/examples/vanilla/index.html +33 -0
- package/istm-animate/animations/examples/vanilla/main.js +36 -0
- package/istm-animate/animations/examples/vue/app.vue +47 -0
- package/istm-animate/animations/examples/vue/index.html +15 -0
- package/istm-animate/animations/examples/vue/main.js +9 -0
- package/istm-animate/animations/examples/vue/package.json +19 -0
- package/istm-animate/animations/examples/vue/vite.config.js +7 -0
- package/istm-animate/animations/framework_motion.md +262 -0
- package/istm-animate/animations/motion.csv +17 -0
- package/istm-animate/animations/motion.md +11 -0
- package/istm-animate/animations/motion_catalog.json +226 -0
- package/istm-animate/animations/motion_performance.md +75 -0
- package/istm-animate/animations/motion_plugins.md +429 -0
- package/istm-animate/animations/react_animations.md +132 -0
- package/istm-animate/animations/scroll_trigger_effects.md +291 -0
- package/istm-animate/animations/timeline_sequencing.md +103 -0
- package/istm-architecture/SKILL.md +109 -0
- package/istm-architecture/frameworks/angular.csv +51 -0
- package/istm-architecture/frameworks/astro.csv +54 -0
- package/istm-architecture/frameworks/avalonia.csv +57 -0
- package/istm-architecture/frameworks/flutter.csv +53 -0
- package/istm-architecture/frameworks/javafx.csv +76 -0
- package/istm-architecture/frameworks/jetpack-compose.csv +53 -0
- package/istm-architecture/frameworks/laravel.csv +51 -0
- package/istm-architecture/frameworks/nextjs.csv +53 -0
- package/istm-architecture/frameworks/nuxtjs.csv +59 -0
- package/istm-architecture/frameworks/react-native.csv +52 -0
- package/istm-architecture/frameworks/react.csv +54 -0
- package/istm-architecture/frameworks/svelte.csv +54 -0
- package/istm-architecture/frameworks/swiftui.csv +51 -0
- package/istm-architecture/frameworks/uwp.csv +56 -0
- package/istm-architecture/frameworks/vue.csv +50 -0
- package/istm-architecture/frameworks/winui.csv +60 -0
- package/istm-architecture/frameworks/wpf.csv +57 -0
- package/istm-architecture/templates/agents.md +229 -0
- package/istm-architecture/templates/architecture.md +111 -0
- package/istm-architecture/templates/design.md +138 -0
- package/istm-architecture/templates/project-overview.md +215 -0
- package/istm-awwward-designer/SKILL.md +43 -0
- package/istm-awwward-designer/libraries/threejs.csv +54 -0
- package/istm-awwward-designer/references/accessibility.md +774 -0
- package/istm-awwward-designer/references/anim-anti-patterns.md +576 -0
- package/istm-awwward-designer/references/animation-map.md +166 -0
- package/istm-awwward-designer/references/animation-standards.md +86 -0
- package/istm-awwward-designer/references/anti-patterns.md +191 -0
- package/istm-awwward-designer/references/color-systems.md +604 -0
- package/istm-awwward-designer/references/css-performance.md +477 -0
- package/istm-awwward-designer/references/descender-safety.md +490 -0
- package/istm-awwward-designer/references/design-audit.md +93 -0
- package/istm-awwward-designer/references/font-loading.md +378 -0
- package/istm-awwward-designer/references/image-optimization.md +440 -0
- package/istm-awwward-designer/references/invention-gate.md +356 -0
- package/istm-awwward-designer/references/micro-interactions.md +825 -0
- package/istm-awwward-designer/references/page-transitions.md +365 -0
- package/istm-awwward-designer/references/performance-standards.md +79 -0
- package/istm-awwward-designer/references/quality-gate.md +103 -0
- package/istm-awwward-designer/references/responsive-design.md +778 -0
- package/istm-awwward-designer/references/scoring-guide.md +201 -0
- package/istm-awwward-designer/references/scroll-patterns.md +668 -0
- package/istm-awwward-designer/references/stitch-brief.md +124 -0
- package/istm-awwward-designer/references/tech-stack.md +204 -0
- package/istm-awwward-designer/references/technical-audit.md +133 -0
- package/istm-awwward-designer/references/technique-families.md +293 -0
- package/istm-awwward-designer/references/testing.md +535 -0
- package/istm-awwward-designer/references/text-animation.md +585 -0
- package/istm-awwward-designer/references/typography.md +504 -0
- package/istm-awwward-designer/references/usability-audit.md +108 -0
- package/istm-awwward-designer/references/visual-standards.md +97 -0
- package/istm-design/SKILL.md +98 -0
- package/istm-design/colors/color_theory.md +293 -0
- package/istm-design/colors/colors.csv +193 -0
- package/istm-design/colors/colors_catalog.json +4034 -0
- package/istm-design/colors/palette.json +21 -0
- package/istm-design/styles/design_system.md +288 -0
- package/istm-design/styles/html-tailwind.csv +56 -0
- package/istm-design/styles/nuxt-ui.csv +71 -0
- package/istm-design/styles/product_design.md +55 -0
- package/istm-design/styles/shadcn.csv +61 -0
- package/istm-design/styles/style.md +12 -0
- package/istm-design/styles/styles.csv +85 -0
- package/istm-design/styles/styles_catalog.json +2018 -0
- package/istm-design/styles/ui-reasoning.csv +162 -0
- package/istm-design/styles/uno.csv +60 -0
- package/istm-design/typography/font_and_font.md +10 -0
- package/istm-design/typography/google-fonts.csv +1924 -0
- package/istm-design/typography/sans_serif_fonts.md +112 -0
- package/istm-design/typography/typography.csv +75 -0
- package/istm-design/typography/typography_catalog.json +964 -0
- package/istm-design/ux/app-interface.csv +31 -0
- package/istm-design/ux/charts.csv +26 -0
- package/istm-design/ux/icons.csv +106 -0
- package/istm-design/ux/landing.csv +35 -0
- package/istm-design/ux/products.csv +193 -0
- package/istm-design/ux/react-performance.csv +45 -0
- package/istm-design/ux/responsive_rules.md +62 -0
- package/istm-design/ux/storytelling.md +47 -0
- package/istm-design/ux/ux-guidelines.csv +100 -0
- package/istm-design/ux/ux_guidelines.json +1190 -0
- package/istm-system-design/SKILL.md +88 -0
- package/istm-system-design/principles/01-architecture-patterns.md +24 -0
- package/istm-system-design/principles/02-database-selection.md +32 -0
- package/istm-system-design/principles/03-api-design.md +25 -0
- package/istm-system-design/principles/04-authentication-security.md +23 -0
- package/istm-system-design/principles/05-caching-performance.md +21 -0
- package/istm-system-design/principles/06-asynchronous-processing.md +17 -0
- package/istm-system-design/principles/07-infrastructure-deployment.md +22 -0
- package/istm-system-design/principles/08-low-level-design.md +35 -0
- package/istm-system-design/principles/09-state-management.md +14 -0
- package/istm-system-design/principles/10-error-handling-and-logging.md +26 -0
- package/istm-system-design/principles/11-testing-strategy.md +18 -0
- package/istm-system-design/principles/12-seo-and-web-vitals.md +18 -0
- package/istm-system-design/stacks/SETUP.md +82 -0
- package/istm-system-design/stacks/STACK.md +67 -0
- package/istm-system-design/stacks/WORKFLOW.md +84 -0
- package/istm-system-design/templates/api-route.ts.template +32 -0
- package/istm-system-design/templates/migrations.md.template +30 -0
- package/istm-system-design/templates/schema.drizzle.ts.template +17 -0
- package/istm-system-design/templates/schema.prisma.template +28 -0
- package/istm-system-design/templates/trpc-router.ts.template +22 -0
- package/istm-system-design/templates/zod-validators.ts.template +14 -0
- package/istm-workflow/istm-audit/SKILL.md +108 -0
- package/istm-workflow/istm-audit/agent-prompt.md +393 -0
- package/istm-workflow/istm-audit/agents/openai.yaml +7 -0
- package/istm-workflow/istm-audit/modes/area.md +19 -0
- package/istm-workflow/istm-audit/modes/gapfill.md +12 -0
- package/istm-workflow/istm-audit/modes/greenfield.md +24 -0
- package/istm-workflow/istm-audit/modes/tool-skills.md +39 -0
- package/istm-workflow/istm-audit/modes/whole-repo.md +5 -0
- package/istm-workflow/istm-audit/patterns/clean-architecture.md +15 -0
- package/istm-workflow/istm-audit/patterns/domain-driven.md +16 -0
- package/istm-workflow/istm-audit/patterns/functional.md +16 -0
- package/istm-workflow/istm-audit/patterns/solid-oop.md +17 -0
- package/istm-workflow/istm-check/SKILL.md +52 -0
- package/istm-workflow/istm-check/agents/openai.yaml +7 -0
- package/istm-workflow/istm-check/modes/review.md +156 -0
- package/istm-workflow/istm-check/modes/verify.md +197 -0
- package/istm-workflow/istm-check/review-agent-prompt.md +57 -0
- package/istm-workflow/istm-check/review-guide.md +133 -0
- package/istm-workflow/istm-craft/SKILL.md +37 -0
- package/istm-workflow/istm-craft/agent-modes/architecture.md +73 -0
- package/istm-workflow/istm-craft/agent-modes/cross-cutting.md +65 -0
- package/istm-workflow/istm-craft/agent-modes/enhancement.md +45 -0
- package/istm-workflow/istm-craft/agent-modes/feature.md +85 -0
- package/istm-workflow/istm-craft/agent-prompt.md +249 -0
- package/istm-workflow/istm-craft/agents/openai.yaml +7 -0
- package/istm-workflow/istm-craft/internal/after-subagent.md +90 -0
- package/istm-workflow/istm-craft/internal/design-conversation.md +140 -0
- package/istm-workflow/istm-craft/internal/tool-discovery.md +58 -0
- package/istm-workflow/istm-craft/spec-template.md +278 -0
- package/istm-workflow/istm-debug/SKILL.md +102 -0
- package/istm-workflow/istm-debug/agents/openai.yaml +7 -0
- package/istm-workflow/istm-develop/SKILL.md +144 -0
- package/istm-workflow/istm-develop/agents/openai.yaml +7 -0
- package/istm-workflow/istm-develop/checklist.md +95 -0
- package/istm-workflow/istm-develop/flow/build.md +133 -0
- package/istm-workflow/istm-develop/flow/git.md +34 -0
- package/istm-workflow/istm-develop/logical-guide.md +99 -0
- package/istm-workflow/istm-develop/ui/existing.md +23 -0
- package/istm-workflow/istm-develop/ui/generate.md +131 -0
- package/istm-workflow/istm-develop/ui/image.md +41 -0
- package/istm-workflow/istm-develop/ui/implementation.md +281 -0
- package/istm-workflow/istm-develop/ui/mcp.md +11 -0
- package/istm-workflow/istm-develop/ui-guide.md +164 -0
- package/istm-workflow/istm-document/SKILL.md +123 -0
- package/istm-workflow/istm-document/agent-prompt.md +57 -0
- package/istm-workflow/istm-document/agents/openai.yaml +7 -0
- package/istm-workflow/istm-document/templates/changelog.md +54 -0
- package/istm-workflow/istm-document/templates/postmortem.md +58 -0
- package/istm-workflow/istm-document/templates/pr.md +43 -0
- package/istm-workflow/istm-document/templates/release-note.md +41 -0
- package/istm-workflow/istm-scope/SKILL.md +100 -0
- package/istm-workflow/istm-scope/agents/openai.yaml +7 -0
- package/istm-workflow/istm-scope/approaches/facade.md +33 -0
- package/istm-workflow/istm-scope/approaches/journey.md +31 -0
- package/istm-workflow/istm-scope/approaches/skateboard.md +33 -0
- package/istm-workflow/istm-scope/approaches/tracer-bullet.md +34 -0
- package/istm-workflow/istm-scope/modes/add.md +14 -0
- package/istm-workflow/istm-scope/modes/plan-brownfield.md +11 -0
- package/istm-workflow/istm-scope/modes/plan-greenfield.md +20 -0
- package/istm-workflow/istm-scope/modes/plan-monorepo.md +8 -0
- package/istm-workflow/istm-scope/modes/plan.md +120 -0
- package/istm-workflow/istm-scope/modes/replan.md +13 -0
- package/istm-workflow/istm-scope/scope-template.md +148 -0
- package/istm-workflow/istm-sync/SKILL.md +166 -0
- package/istm-workflow/istm-sync/agent-prompt.md +211 -0
- package/istm-workflow/istm-sync/agents/openai.yaml +7 -0
- package/istm-workflow/istm-test/SKILL.md +233 -0
- package/istm-workflow/istm-test/agent-prompt.md +62 -0
- package/istm-workflow/istm-test/agents/openai.yaml +7 -0
- package/istm-workflow/istm-test/modes/setup.md +97 -0
- package/istm-workflow/istm-test/writing-guide.md +196 -0
- package/package.json +35 -0
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
# /develop: UI track guide
|
|
2
|
+
|
|
3
|
+
UI build track for `/develop`, read after the spec gate (`SKILL.md` Step 0) classifies a task as UI: components, pages, or full layouts with semantic HTML, design tokens, and strict accessibility. Any web stack (Next.js, Vite, Nuxt, Svelte, plain HTML). The project's `.istm-context/design.md` holds the art direction (character, the build mandate, composition and component rules, and pointers to where the real tokens live); the token values themselves live in the project's CSS (`globals.css` / tailwind config), never duplicated in `.istm-context/design.md`. Read the bar below before you build anything.
|
|
4
|
+
|
|
5
|
+
## The bar: read this first, it is the definition of done
|
|
6
|
+
|
|
7
|
+
You are a senior product designer shipping a real product, not a developer wiring a form. Every UI page must leave as a complete, professional product surface, the quality you would expect from a top product or from Claude's own chat app, never a bare minimum stub. This is not optional styling advice. It is the definition of done for a UI build, committed here, before you start, so it cannot get crowded out by the token and accessibility rules later in this guide.
|
|
8
|
+
|
|
9
|
+
**Design first, then integrate.** The same model produces beautiful UI in a chat app and plain UI in a codebase because the codebase makes it satisfy tokens, libraries, and accessibility before it has designed anything, and the ambition dies. Build in two passes:
|
|
10
|
+
1. **Design the surface** (bold, complete, opinionated), as if you were shipping it standalone, to the agreed design system. Compose the whole page (`ui/implementation.md` Phase 0).
|
|
11
|
+
2. **Integrate it** into the codebase: installed styling library, real tokens, semantic HTML, accessibility, responsive (Phases 1 to 5).
|
|
12
|
+
|
|
13
|
+
**Disqualifiers, any one means NOT done, fix before you report:**
|
|
14
|
+
- a lone centered form or single input box floating on an empty page
|
|
15
|
+
- large dead zones, or content stranded in a narrow column with blank canvas around it
|
|
16
|
+
- naked / unstyled / full bleed elements (a raw black bar, an unstyled header, a default browser control)
|
|
17
|
+
- default only styling (one flat button, hairline default borders, system font, no considered accent, no depth)
|
|
18
|
+
- missing states (no empty / loading / error) or orphaned controls (a toggle or quick action with nothing around it)
|
|
19
|
+
- a bare functional widget where a product would ship a full surface (brand, real copy, layout, supporting content, footer)
|
|
20
|
+
|
|
21
|
+
**Prove it before you report.** Before declaring the UI done, audit the build yourself against these disqualifiers and against the page's `.istm-context/design.md` mandate, and fix every hit. When you have a browser or screenshot tool, render the page and look at it, the way a designer checks their own work, and fix any visual defect you see (the only reliable way to catch a broken render like a stray black bar). Say in the report what you audited.
|
|
22
|
+
|
|
23
|
+
## Design source (route by what you were given)
|
|
24
|
+
|
|
25
|
+
1. **Figma connected (the spec says use it)** → pull the real design from Figma, build to the frames. Route: `ui/mcp.md`.
|
|
26
|
+
2. **Image provided (pasted in chat, not a repo file)** → replicate it pixel perfect. The image is both the look and the composition, so match it faithfully and do NOT embellish beyond it. Tokenize what you see (values into CSS, character into `.istm-context/design.md`) and derive the responsive and accessible behavior a single screenshot cannot show. Route: `ui/image.md`.
|
|
27
|
+
3. **A design system already exists** (`.istm-context/design.md` + tokens in CSS) → design the new page WITHIN that system, at the bar above: a full professional surface, consistent with what is already shipped. Route: `ui/existing.md`.
|
|
28
|
+
4. **Nothing provided** → establish the design system first (the `frontend-design` skill when available, else derive it from the rules in `ui/generate.md` B2 and verify its contrast), record it in `.istm-context/design.md` (character + mandate + pointers) with the tokens written to CSS, then build to the bar above, maximalist and complete. Route: `ui/generate.md`.
|
|
29
|
+
|
|
30
|
+
Cases 3 and 4 get the full chat app treatment (bold, complete, product level); case 2 gets faithful fidelity; case 1 gets Figma fidelity. Follow the source the spec recorded; never default to Figma just because an MCP is connected.
|
|
31
|
+
|
|
32
|
+
All paths converge on: component or screen → stack detection → styling library → dark mode → token sync → font → the implementation phases.
|
|
33
|
+
|
|
34
|
+
## How the UI build fits the project's approach
|
|
35
|
+
|
|
36
|
+
The UI build serves the project's build approach (read in `SKILL.md` Step 2), never dictates one. Shell first on placeholder data, wired later, is the Facade mode: one strategy, not the universal default. An end to end / tracer bullet slice lands the data layer in the same pass, so bind to the real source; a Journey completes the whole user path for the phase. The phases below apply under every approach; only when real data arrives differs. No recorded approach: build the UI as part of a coherent end to end slice.
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
## Portability (any OS, any agent)
|
|
41
|
+
|
|
42
|
+
Any Agent Skills client, macOS/Linux/Windows. Detection snippets (`find`, `cat | grep`, `cp`) are POSIX reference, not literal scripts: use your agent's own cross platform file tools to find files and read `package.json`/config. Bundled files (`checklist.md`, `ui/*.md`) are paths relative to this skill's folder, read on demand: read this guide's phases as reached, not all up front. The UI build runs inline (it is interactive); heavy code exploration (finding existing components/tokens to match) goes to a read only subagent per `SKILL.md` Step 2.5. App code/CSS is inherently cross platform. No interactive question picker: ask the prompts as plain text with the same options.
|
|
43
|
+
|
|
44
|
+
## Step 0: Where the design comes from (one decision, made once)
|
|
45
|
+
|
|
46
|
+
Check the governing spec first (`/develop` read it in Step 2). The design source is the engineer's choice and `/architect` already grilled them on it, so follow what the spec recorded, never ask again, and never default to Figma just because an MCP is connected.
|
|
47
|
+
|
|
48
|
+
Route on what the spec recorded, using the *Design source* table above:
|
|
49
|
+
- Figma or another design MCP → `ui/mcp.md`.
|
|
50
|
+
- A screenshot or a pasted image → `ui/image.md`.
|
|
51
|
+
- An existing design system, or "extract from existing UI" → **Step 0.1**.
|
|
52
|
+
- A described direction, a brand or site URL, or nothing at all → `ui/generate.md` (B1 finds the direction, B2 derives and verifies the tokens into CSS and the character into `.istm-context/design.md`), then implement.
|
|
53
|
+
|
|
54
|
+
No spec governs this UI, or the spec is silent on the design system → fall through to the detection in Steps 0.1 to 0.3. If detection settles nothing, ask *"How should I get the design for this?"* with options **From Figma (its MCP)** · **From a screenshot / images** · **From the existing `.istm-context/design.md` / current UI** · **No design, suggest a direction** (the picker adds Other), then proceed by their pick.
|
|
55
|
+
|
|
56
|
+
## Step 0.1: Check for existing .istm-context/design.md
|
|
57
|
+
|
|
58
|
+
File search for `.istm-context/design.md` within about 3 levels of the project root, ignoring `node_modules`, `.git`, `.claude`. Found: validate; a real one has a `character` and a `## Build mandate` (art direction) and points at the CSS for tokens. Empty, or only a stub: treat as not found and warn the user. (An older `.istm-context/design.md` that still carries inline `colors:` / `typography:` value blocks is still valid; treat the CSS as authoritative for values.)
|
|
59
|
+
|
|
60
|
+
Found and valid → **Design.md path**, skip Steps 1 onward.
|
|
61
|
+
Not found → **Step 0.2 (brownfield check)**.
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## Step 0.2: Brownfield check (no .istm-context/design.md, but is there existing UI?)
|
|
66
|
+
|
|
67
|
+
Before generating a fresh design system, check for an existing visual language to match; a new one over an existing app clashes with what's shipped. File search (ignoring `node_modules`) for:
|
|
68
|
+
- Styling/token files: `globals.css`, `tokens.css`, `theme.*`, `tailwind.config.*`.
|
|
69
|
+
- Component directories: a `components/` tree or a `ui` directory.
|
|
70
|
+
|
|
71
|
+
Found (brownfield): ask before proceeding, via your agent's interactive option picker (`AskUserQuestion` on Claude Code) or plain text options with the same choices:
|
|
72
|
+
- **question**: "There's no `.istm-context/design.md`, but this project already has UI. How should I get the design system?"
|
|
73
|
+
- **header**: "Design system"
|
|
74
|
+
- **options**:
|
|
75
|
+
1. `Extract from existing code`: "Recommended, capture the design direction from the current tokens/components into `.istm-context/design.md`, pointing at the existing CSS tokens, so new UI matches what's shipped." → **Step 0.3**.
|
|
76
|
+
2. `Use a reference`: "I'll give a screenshot, a `.istm-context/design.md` URL, or a site to work from." → **Step 1**.
|
|
77
|
+
3. `Match a specific file`: "Build to mirror an existing component/page I name; I'll point you at it." → read that file's styles, treat them as the local source of truth.
|
|
78
|
+
|
|
79
|
+
No existing UI (greenfield) → **Step 0.5**.
|
|
80
|
+
|
|
81
|
+
### Step 0.3: Capture the design direction from existing code
|
|
82
|
+
|
|
83
|
+
The existing CSS / Tailwind config already holds the token values (the source of truth); do not copy them into `.istm-context/design.md`. Read the token files and 3 to 5 representative components/pages to read the *system*, then write `.istm-context/design.md` as art direction (per `ui/generate.md` B2's schema): `source: extracted-from-code`, the character you observe, the composition and component patterns the app already uses, the build mandate, and a pointer to the CSS token file. Inconsistent codebase: note the dominant patterns and the variance. Show a short summary, confirm before building, then implement to the direction with the CSS as the token source of truth.
|
|
84
|
+
|
|
85
|
+
---
|
|
86
|
+
|
|
87
|
+
## Step 0.5: Component or screen?
|
|
88
|
+
|
|
89
|
+
Determines prop API design, routing integration, file placement.
|
|
90
|
+
|
|
91
|
+
| Prompt contains | Build type |
|
|
92
|
+
|---|---|
|
|
93
|
+
| "screen", "page", "layout", "route", "dashboard", "view" | **Screen** |
|
|
94
|
+
| "component", "button", "card", "input", "modal", "badge", "dropdown", "toggle", "chip" | **Component** |
|
|
95
|
+
| Ambiguous | Ask |
|
|
96
|
+
|
|
97
|
+
If ambiguous, ask (as above):
|
|
98
|
+
```
|
|
99
|
+
"Is this a reusable component or a full page?"
|
|
100
|
+
- Reusable component: isolated, takes props, no routing
|
|
101
|
+
- Full page / screen: owns layout, integrates with router
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
**Component rules** (apply throughout all phases): define the `interface Props` before any markup; named export from its own file; no router imports, no page level data fetching inside the component; Storybook present (`*.stories.*`) → create a story file alongside; file naming matches the convention of existing components.
|
|
105
|
+
|
|
106
|
+
**Screen rules** (apply throughout all phases): integrate with the detected router (Next.js App Router, Vite React Router, Nuxt, SvelteKit); include loading, error, and empty states at page level; wrap with the existing layout component if the project has one.
|
|
107
|
+
|
|
108
|
+
---
|
|
109
|
+
|
|
110
|
+
## Stack detection
|
|
111
|
+
|
|
112
|
+
File search near the project root (ignoring `node_modules`) for a framework config (`next.config.*`, `vite.config.*`, `nuxt.config.*`, `svelte.config.*`); read `package.json` dependencies for `next`, `vite`, `nuxt`, `svelte`, or `astro`. The framework affects routing integration, image primitives, and font loading.
|
|
113
|
+
|
|
114
|
+
---
|
|
115
|
+
|
|
116
|
+
## Styling library, dark mode, and icon detection
|
|
117
|
+
|
|
118
|
+
Using your file search and read tools (ignoring `node_modules`):
|
|
119
|
+
- **Styling**: `package.json` dependencies for `@shadcn`, `@radix-ui`, `@mui`, `antd`, `@chakra-ui`, `@mantine`, `styled-components`, `@emotion`, `tailwindcss`; a `components/ui` directory (shadcn); any `*.module.css` / `*.module.scss` files.
|
|
120
|
+
- **Dark mode strategy**: `next-themes` in `package.json`; `darkMode` setting in any `tailwind.config.*`.
|
|
121
|
+
- **Icon library**: `package.json` dependencies for `lucide-react`, `@heroicons`, `phosphor-react`, `@phosphor-icons`, `react-icons`, `@tabler/icons`.
|
|
122
|
+
|
|
123
|
+
**Styling decision:**
|
|
124
|
+
|
|
125
|
+
| Detected | Approach |
|
|
126
|
+
|---|---|
|
|
127
|
+
| `components/ui/` (shadcn) | Use shadcn primitives with `cn()` + Tailwind token classes |
|
|
128
|
+
| `tailwindcss` only | Utility classes only, no `style={}` props |
|
|
129
|
+
| `*.module.css` | One `.module.css` per component |
|
|
130
|
+
| `styled-components` / `@emotion` | Tagged template literals referencing CSS variables |
|
|
131
|
+
| Nothing | Semantic HTML + external CSS referencing CSS custom properties |
|
|
132
|
+
|
|
133
|
+
Common cases, not exhaustive. Another styling library installed (UnoCSS, Panda, `vanilla-extract`, Stylex, …): use it, follow its idiom. The rule is "use what's installed, the way it's meant to be used," never "only these."
|
|
134
|
+
|
|
135
|
+
**Dark mode strategy:**
|
|
136
|
+
|
|
137
|
+
| Detected | Approach |
|
|
138
|
+
|---|---|
|
|
139
|
+
| `next-themes` in package.json | `.dark {}` class only, no `@media` as primary |
|
|
140
|
+
| `darkMode: 'class'` in tailwind config | `.dark {}` class only |
|
|
141
|
+
| `darkMode: 'media'` in tailwind config | `@media (prefers-color-scheme: dark)` |
|
|
142
|
+
| Nothing detected | Both: `@media` query + `.dark {}` fallback |
|
|
143
|
+
|
|
144
|
+
**Icon library:** use whatever is installed. Nothing installed: note it in the report; never emoji or placeholder SVGs. Icon size always references a spacing token, never hardcoded. Decorative icons: `aria-hidden="true"`. Standalone interactive icons: visually hidden label or `aria-label` on the wrapping button.
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
## Step 1: Load the selected UI path
|
|
149
|
+
|
|
150
|
+
Based on the checks above, read exactly one source file:
|
|
151
|
+
|
|
152
|
+
- `ui/mcp.md` when Figma or another design MCP is the source.
|
|
153
|
+
- `ui/image.md` when a screenshot or image is the source.
|
|
154
|
+
- `ui/existing.md` when an existing `.istm-context/design.md` or current UI is the source.
|
|
155
|
+
- `ui/generate.md` when there is no source: it finds a direction, then derives and verifies the system.
|
|
156
|
+
|
|
157
|
+
After the selected source has resolved tokens, assets, and design direction, read `ui/implementation.md` and follow it through the implementation phases and report. Do not read the other source files unless the source changes.
|
|
158
|
+
|
|
159
|
+
## Reference files
|
|
160
|
+
|
|
161
|
+
- Accessibility checklist: `checklist.md`
|
|
162
|
+
- Project design system: `./.istm-context/design.md` (art direction and the build mandate; token values live in CSS)
|
|
163
|
+
- UI source routes: `ui/mcp.md`, `ui/image.md`, `ui/existing.md`, `ui/generate.md`
|
|
164
|
+
- UI implementation phases and report: `ui/implementation.md`
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: document
|
|
3
|
+
allowed-tools: Bash, Read, Grep, Glob, Write, Edit, Agent, AskUserQuestion
|
|
4
|
+
description: "Run /document `pr` | `changelog` | `release-note` | `postmortem` (or let it ask) to write the human facing prose about a change. Drafts from the real commits and diff, writing to the right place. Does not write code, tests, or specs."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Output style (plain words, no dashes, no hyphens)
|
|
8
|
+
|
|
9
|
+
<!-- OUTPUT-STYLE:START -->
|
|
10
|
+
Write everything this skill produces, files and messages alike, in plain simple language. Keep technical terms that carry real meaning; explain each in plain words. Never use a dash or a hyphen as punctuation: no em dash, no en dash, and no hyphenated compounds. Write `read only`, not `read-only`. Say it in simple words, or reword the sentence. Code, file paths, command flags, and values other skills match on keep their hyphens. Use short sentences, commas, or parentheses. Clear beats clever.
|
|
11
|
+
<!-- OUTPUT-STYLE:END -->
|
|
12
|
+
|
|
13
|
+
## What this skill does
|
|
14
|
+
|
|
15
|
+
**Your role:** the technical writer who writes from the record, not from imagination, and writes for the reader, not the author. Every sentence traces to something that actually happened (a commit, a diff, an incident fact you were given), and every document is pitched at whoever has to act on it: a reviewer needs the *why* and the risk, an end user needs the *what changed for me*, a team reading a postmortem needs the honest causal chain. You never invent a timeline entry, a cause, or a change that isn't in the source.
|
|
16
|
+
|
|
17
|
+
Generates one of four document types from the real change history. The main thread writes the document itself; the only thing it may offload is reading, and only for a very large diff, to a read only `scout` subagent on the cheapest model (Claude Code: `haiku`):
|
|
18
|
+
|
|
19
|
+
| Type | Source | Audience | Output |
|
|
20
|
+
|---|---|---|---|
|
|
21
|
+
| `pr` | branch commits + diff vs base | reviewers | PR title + body (chat; optionally `gh pr` create/edit) |
|
|
22
|
+
| `changelog` | merged change | developers | entry appended to `CHANGELOG.md` (Keep a Changelog) |
|
|
23
|
+
| `release-note` | a tag/version range | end users | `.istm-context/releases/<version>.md` (or chat) |
|
|
24
|
+
| `postmortem` | an incident (described by the engineer, plus any /debug record) | team | `.istm-context/postmortems/<date>-<slug>.md` |
|
|
25
|
+
|
|
26
|
+
Acts. Asks at most one question (which type) when it can't be inferred, and (for postmortems) asks for the incident facts it can't read from git.
|
|
27
|
+
|
|
28
|
+
## Artifact ownership
|
|
29
|
+
|
|
30
|
+
PR text, `CHANGELOG.md`, `.istm-context/releases/`, `.istm-context/postmortems/` (owned by this skill). It writes nothing else.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## Portability (any OS, any agent)
|
|
35
|
+
|
|
36
|
+
Written for any Agent Skills client on macOS, Linux, or Windows:
|
|
37
|
+
- **Commands**: `git` (and optionally `gh`) are the only CLIs, and behave the same on every OS, run the `git` lines as shown. Other shell snippets are POSIX **reference**, not literal scripts: don't assume `find`, `grep`, `sed`, `cat`, `test`/`[ ]`, `command -v`, or `node -e` exist. Use your agent's own cross platform file tools (read, search/glob, write) for those, and apply branching logic yourself rather than via shell `if`/variables/redirects.
|
|
38
|
+
- **Bundled files**: referenced by paths relative to this skill's folder. The main thread resolves this skill's folder to an **absolute path** (it already resolves these relative paths, so it knows the folder) and reads them itself at write time (Step 3): `agent-prompt.md` and the one template for the chosen type.
|
|
39
|
+
- **No interactive question support?** The doc type pick uses an interactive picker where the agent has one; without it, ask the doc type question as plain text with the same options.
|
|
40
|
+
|
|
41
|
+
## Execution
|
|
42
|
+
|
|
43
|
+
### 1. Determine the document type
|
|
44
|
+
|
|
45
|
+
- If passed as an argument (`pr`, `changelog`, `release-note`, `postmortem`): use it.
|
|
46
|
+
- Otherwise infer from context where obvious (on a feature branch ahead of base → `pr`; just tagged a version → `release-note`), then **confirm or ask** with one question. Mark the inferred type `(recommended)`; the picker adds a free text custom slot last automatically. Present these as your agent's interactive option picker (`AskUserQuestion` on Claude Code), or as plain text options with the same choices (custom option last) if it has none:
|
|
47
|
+
|
|
48
|
+
```
|
|
49
|
+
"What should I write?"
|
|
50
|
+
header: "Doc type"
|
|
51
|
+
options:
|
|
52
|
+
- label: "PR description" → pr # mark (recommended) if inferred
|
|
53
|
+
- label: "Changelog entry" → changelog
|
|
54
|
+
- label: "Release notes" → release-note
|
|
55
|
+
- label: "Postmortem" → postmortem
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### 2. Gather the source material
|
|
59
|
+
|
|
60
|
+
Collect the lightweight history below, then read the diff and files yourself at write time (a `scout` subagent may do the reading for a very large diff).
|
|
61
|
+
|
|
62
|
+
Run these `git`/`gh` commands as shown; do the steps that are not commands with your agent's own file tools and your own branching logic.
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
# base branch: use `main` if it exists, otherwise `master`
|
|
66
|
+
git rev-parse --verify main
|
|
67
|
+
# current branch
|
|
68
|
+
git rev-parse --abbrev-ref HEAD
|
|
69
|
+
|
|
70
|
+
# pr / changelog: the branch change set (BASE = the base branch above)
|
|
71
|
+
git log --oneline "BASE..HEAD"
|
|
72
|
+
git diff --name-only "BASE...HEAD"
|
|
73
|
+
|
|
74
|
+
# release-note: needs tags. List them; if there are none, fall back gracefully (treat as NO_TAGS).
|
|
75
|
+
git tag --sort=-creatordate
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
- **context for the "why"**: list the spec files under `.istm-context/specs/` (names starting with a digit) and take the 3 most recently modified (paths only) using your file/glob tools.
|
|
79
|
+
- **pr only: three checks** (record each result for step 2's edge handling):
|
|
80
|
+
- Is `gh` available on this system? (GH_INSTALLED)
|
|
81
|
+
- Does the repo have a git remote? Run `git remote`; a result that is not empty means HAS_REMOTE.
|
|
82
|
+
- Does a PR already exist? Run `gh pr view --json number -q .number`. If it prints a PR number, treat that as PR_EXISTS; if it errors/prints nothing, no PR exists.
|
|
83
|
+
|
|
84
|
+
**Per type edge handling the main thread resolves before writing:**
|
|
85
|
+
- **`release-note` range**: if tags exist, the range is `<previous-tag>..<latest-tag>` (or a range the engineer named). **If `NO_TAGS`**, don't guess, ask: "No version tags found. Give me a version name and range (e.g. `v1.0.0`, covering `<commit>..HEAD`), or I'll cover all commits since the first one." Pass the resolved range/version to the subagent.
|
|
86
|
+
- **pr + gh**: only offer to create/update the PR via `gh` when **`GH_INSTALLED` and `HAS_REMOTE`**. If `PR_EXISTS`, the action is `gh pr edit` (update the body), **not** `gh pr create`. If gh isn't usable or no remote, the PR text is chat only, don't attempt `gh`. **Always confirm before running `gh` and before any push** (opening/updating a PR is an outward action): show the body, then ask. This holds regardless of the `.istm-context/agents.md` `## Git` setting; the setting decides whether the workflow drives PRs at all (`integration: off` → produce the text, never push or open a PR unless the engineer asks here).
|
|
87
|
+
- **postmortem**: git won't contain the incident narrative. Ask the engineer for the essentials if not already provided: what broke, when (with timezone), user impact, how it was detected, and the root cause/fix (point them to any `/debug` output if it exists). Pass their account as the incident facts. The subagent must not invent timeline entries or causes beyond what they give.
|
|
88
|
+
|
|
89
|
+
### 3. Write the document (main thread)
|
|
90
|
+
|
|
91
|
+
Resolve this skill's folder to an absolute path (you already resolve these relative paths, so you know the folder) and Read `agent-prompt.md` and the **one** template for the chosen type, `templates/<type>.md`, now (only now, at write time). Follow `agent-prompt.md` and write the document yourself. Do not spawn a writer; for a postmortem, the root cause synthesis is yours to reason through carefully on the main thread.
|
|
92
|
+
|
|
93
|
+
The inputs to apply:
|
|
94
|
+
1. Document type + its template (the chosen one only; read it)
|
|
95
|
+
2. Source: commit list, diff command, and (postmortem) the incident facts. Read the diff yourself; for a very large diff (e.g. >25 files), offload the reading to a `scout` subagent (haiku) that returns a compact summary by file group/feature, and write from that
|
|
96
|
+
3. Project context contents (project name, conventions), read `.istm-context/agents.md`, or `CLAUDE.md` fallback, + recent spec paths for the "why"
|
|
97
|
+
4. Output target for the type and today's date
|
|
98
|
+
5. **pr**: the gh action, `none (chat-only)` | `gh pr create` | `gh pr edit` (from the `GH_INSTALLED`/`HAS_REMOTE`/`PR_EXISTS` checks)
|
|
99
|
+
6. **changelog**: **match the existing `CHANGELOG.md` format** if the file exists (don't impose Keep a Changelog over a different established style)
|
|
100
|
+
7. **`release-note`**: the resolved version + range
|
|
101
|
+
|
|
102
|
+
### 4. Relay the result
|
|
103
|
+
|
|
104
|
+
```
|
|
105
|
+
## /document complete
|
|
106
|
+
|
|
107
|
+
**Type**: <pr | changelog | release-note | postmortem>
|
|
108
|
+
**Written to**: <PR body shown below | CHANGELOG.md | .istm-context/releases/<v>.md | .istm-context/postmortems/<file>>
|
|
109
|
+
|
|
110
|
+
<for pr: the title + body, ready to paste, or "PR #N updated" if gh was used>
|
|
111
|
+
<for the others: a 2 to 3 line preview + the file path>
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
For `pr`, always show the full text in chat (so it's usable even without `gh`). For the file types, show a short preview and the path. This skill does not commit, push, or merge. It produces the prose.
|
|
115
|
+
|
|
116
|
+
**Tick the scope box (closing gate).** If the documented feature has a row in `.istm-context/scope/`, tick its `Document it` box and confirm it in the report ("Scope: ticked `Document it`"). No matching row → say so. This is the only scope edit `/document` makes; it writes no code or specs.
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## Reference files
|
|
121
|
+
|
|
122
|
+
- `agent-prompt.md`: the writing guide the main thread reads and follows at write time (Step 3)
|
|
123
|
+
- `templates/`: one structure file per type (`pr.md`, `changelog.md`, `release-note.md`, `postmortem.md`); the main thread reads only the chosen one at write time
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# Document Writing Guide (main thread)
|
|
2
|
+
|
|
3
|
+
You, the main thread, read and follow this at write time (Step 3). Read each ALL_CAPS placeholder as the matching input you gathered in the earlier steps. Read the **one** template for the chosen document type alongside it.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are a precise technical writer. You write clear, honest prose grounded in what actually changed, never invented features, never marketing fluff for a developer audience, never vague filler. You match the structure of the provided template exactly.
|
|
8
|
+
|
|
9
|
+
## Document type
|
|
10
|
+
|
|
11
|
+
TYPE (one of: pr, changelog, release-note, postmortem)
|
|
12
|
+
|
|
13
|
+
## Structure to follow (the template for this type)
|
|
14
|
+
|
|
15
|
+
TEMPLATE_CONTENT
|
|
16
|
+
<!-- The main model supplies the chosen template here: an absolute path for you to Read, or its pasted full contents. -->
|
|
17
|
+
|
|
18
|
+
## Source material
|
|
19
|
+
|
|
20
|
+
- **Commits**: COMMITS (these are hints, not truth; commit subjects are often terse or sloppy)
|
|
21
|
+
- **See the diff with**: DIFF_COMMAND (the diff is the source of truth, read it to ground every statement; read changed files where you need detail)
|
|
22
|
+
- **Large change?**: LARGE_DIFF_NOTE (if set, summarise by file-group/feature instead of reading every line, you have a bounded context window)
|
|
23
|
+
- **Incident facts** (postmortem only): INCIDENT_FACTS
|
|
24
|
+
- **Version / range** (release-note only): VERSION_RANGE
|
|
25
|
+
|
|
26
|
+
## Context
|
|
27
|
+
|
|
28
|
+
- **Project (.istm-context/agents.md, inlined)**: PROJECT_CONTEXT
|
|
29
|
+
- **Recent spec paths (the "why", read only if you need the rationale)**: SPEC_PATHS
|
|
30
|
+
- **Today**: DATE
|
|
31
|
+
|
|
32
|
+
## Output
|
|
33
|
+
|
|
34
|
+
- **Target**: OUTPUT_TARGET
|
|
35
|
+
- `pr` → return the title and body as text (always). Then, per **GH_ACTION**: `none` = chat-only, do not touch gh; `gh pr create` = create the PR with this body; `gh pr edit` = update the existing PR's body. Never run a gh command other than the one in GH_ACTION.
|
|
36
|
+
- `changelog` → **Edit** `CHANGELOG.md`. If the file exists, **match its existing format and section style** (per CHANGELOG_FORMAT_NOTE), do not impose a different convention. Only if it does not exist, create it with a Keep a Changelog header. Add the entry under the current unreleased/top section.
|
|
37
|
+
- `release-note` → **Write** `.istm-context/releases/<version>.md` (create the directory if missing).
|
|
38
|
+
- `postmortem` → **Write** `.istm-context/postmortems/<DATE>-<slug>.md` (create the directory if missing).
|
|
39
|
+
- **GH_ACTION** (pr only): GH_ACTION
|
|
40
|
+
- **CHANGELOG_FORMAT_NOTE** (changelog only): CHANGELOG_FORMAT_NOTE
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## How to proceed
|
|
45
|
+
|
|
46
|
+
1. Read the diff (and changed files as needed) so every statement is backed by a real change. For a postmortem, build the narrative from INCIDENT_FACTS, not the diff.
|
|
47
|
+
2. Write strictly to the template's structure, same sections, same order. Fill every section; if a section genuinely has nothing, write "None" rather than padding.
|
|
48
|
+
3. Use the spec rationale for the "why" when the template asks for motivation; don't speculate beyond it.
|
|
49
|
+
4. Write to the correct target for the type. Keep prose tight, no restating the same point, no boilerplate.
|
|
50
|
+
5. Return the compact summary the SKILL expects: for `pr`, the full title + body; for the others, a 2 to 3 line preview and the file path written.
|
|
51
|
+
|
|
52
|
+
### Honesty & safety rules (do not break)
|
|
53
|
+
|
|
54
|
+
- **Ground every claim in the diff.** Describe only what the change actually does. Never claim a performance win, security fix, or behaviour change you cannot point to in the diff. When commit messages and the diff disagree, the diff wins.
|
|
55
|
+
- **No invention.** For a postmortem, never fabricate timeline entries, timestamps, or root causes. Write "Unknown, to investigate" for anything not in INCIDENT_FACTS. For release notes, translate real changes into user benefit without overstating.
|
|
56
|
+
- **Never leak secrets.** If the diff contains credentials, tokens, API keys, connection strings, or private URLs, do **not** reproduce them in any document, refer to them generically ("rotated the API credentials") and flag that a secret appeared in the diff.
|
|
57
|
+
- **Idempotency (changelog).** Read the existing `CHANGELOG.md` first. If an equivalent entry for this change is already present, do not add a duplicate, adjust or skip. Running it again must not pile up repeated lines.
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# OpenAI Codex adapter. This file supplies the interface metadata Codex shows in
|
|
2
|
+
# its agent picker. The skill's actual instructions live in ../SKILL.md, which the
|
|
3
|
+
# Agent Skills client installs alongside this file and loads when the skill runs.
|
|
4
|
+
interface:
|
|
5
|
+
display_name: "Document"
|
|
6
|
+
short_description: "Draft PRs and release notes"
|
|
7
|
+
default_prompt: "Run the document skill: read its SKILL.md, then draft the human facing writeup for this change from the real commits and diff."
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# Changelog Template
|
|
2
|
+
|
|
3
|
+
Append an entry to `CHANGELOG.md` at the repo root. Use the **Edit** tool to insert under the current unreleased/top section. Do not rewrite existing entries.
|
|
4
|
+
|
|
5
|
+
**Match the existing file first.** If `CHANGELOG.md` already exists, follow *its* structure and wording style (heading levels, section names, date format, bullet phrasing) per CHANGELOG_FORMAT_NOTE (do not impose the format below over a different established one). The format below is the default **only when creating the file fresh**.
|
|
6
|
+
|
|
7
|
+
**Idempotency.** Read the existing entries before adding. If an equivalent line for this change is already under the unreleased section, do not add a duplicate.
|
|
8
|
+
|
|
9
|
+
## If CHANGELOG.md does not exist
|
|
10
|
+
|
|
11
|
+
Create it with this header, then add the entry:
|
|
12
|
+
|
|
13
|
+
```markdown
|
|
14
|
+
# Changelog
|
|
15
|
+
|
|
16
|
+
All notable changes to this project are documented in this file.
|
|
17
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
18
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
19
|
+
|
|
20
|
+
## [Unreleased]
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## Entry format
|
|
24
|
+
|
|
25
|
+
Add lines under the correct subheading inside `## [Unreleased]` (create the subheading if absent). Categories, in this order:
|
|
26
|
+
|
|
27
|
+
```markdown
|
|
28
|
+
## [Unreleased]
|
|
29
|
+
|
|
30
|
+
### Added
|
|
31
|
+
- <new capability, user-facing phrasing>
|
|
32
|
+
|
|
33
|
+
### Changed
|
|
34
|
+
- <change in existing behaviour>
|
|
35
|
+
|
|
36
|
+
### Deprecated
|
|
37
|
+
- <soon-to-be-removed feature>
|
|
38
|
+
|
|
39
|
+
### Removed
|
|
40
|
+
- <removed feature>
|
|
41
|
+
|
|
42
|
+
### Fixed
|
|
43
|
+
- <bug fix, describe the bug, not the code>
|
|
44
|
+
|
|
45
|
+
### Security
|
|
46
|
+
- <vulnerability addressed>
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Rules:
|
|
50
|
+
- One bullet per notable change. Skip refactors that are internal only and do not affect users or integrators.
|
|
51
|
+
- Write from the reader's perspective: "Added pagination to the orders endpoint", not "Added `limit` param to `getOrders`".
|
|
52
|
+
- Map the change to the right category. A fix is `Fixed`; a new flag is `Added`; a behaviour change is `Changed`.
|
|
53
|
+
- Only include categories that have entries. Don't leave empty headings.
|
|
54
|
+
- Reference a spec or issue number in parentheses when it adds traceability, e.g. "(see spec 0007)".
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Postmortem Template
|
|
2
|
+
|
|
3
|
+
Write a blameless incident postmortem to `.istm-context/postmortems/<DATE>-<slug>.md`. Build it from INCIDENT_FACTS (the engineer's account) plus any root cause detail in the diff or a /debug record. Blameless means: focus on systems and contributing factors, never on individuals.
|
|
4
|
+
|
|
5
|
+
## Structure
|
|
6
|
+
|
|
7
|
+
```markdown
|
|
8
|
+
# Postmortem: <short incident title> (<DATE>)
|
|
9
|
+
|
|
10
|
+
| | |
|
|
11
|
+
|---|---|
|
|
12
|
+
| **Severity** | <SEV1 to SEV4 / critical to low> |
|
|
13
|
+
| **Duration** | <start → resolution, with timezone> |
|
|
14
|
+
| **User impact** | <who was affected and how, be specific and quantified if known> |
|
|
15
|
+
| **Status** | Resolved / Monitoring |
|
|
16
|
+
|
|
17
|
+
## Summary
|
|
18
|
+
|
|
19
|
+
<3 to 5 sentences a busy reader can absorb: what happened, the impact, the root cause, and the fix.>
|
|
20
|
+
|
|
21
|
+
## Timeline
|
|
22
|
+
|
|
23
|
+
_All times <timezone>._
|
|
24
|
+
|
|
25
|
+
- **<time>**: <event: what happened or was observed>
|
|
26
|
+
- **<time>**: <detection: how the team found out>
|
|
27
|
+
- **<time>**: <key diagnostic or mitigation step>
|
|
28
|
+
- **<time>**: <resolution>
|
|
29
|
+
|
|
30
|
+
## Root cause
|
|
31
|
+
|
|
32
|
+
<The actual technical cause, the chain from trigger to failure. Distinguish the trigger from the underlying weakness that let it become an incident.>
|
|
33
|
+
|
|
34
|
+
## Contributing factors
|
|
35
|
+
|
|
36
|
+
- <what made it worse, slower to detect, or harder to fix, e.g. missing alert, no timeout, unclear ownership>
|
|
37
|
+
|
|
38
|
+
## What went well
|
|
39
|
+
|
|
40
|
+
- <fast detection, clean rollback, good tooling (credit the system, not heroes)>
|
|
41
|
+
|
|
42
|
+
## Action items
|
|
43
|
+
|
|
44
|
+
| Action | Type | Owner | Priority |
|
|
45
|
+
|---|---|---|---|
|
|
46
|
+
| <specific, verifiable fix> | Prevent / Detect / Mitigate | <role/team> | <P0 to P2> |
|
|
47
|
+
|
|
48
|
+
## Lessons
|
|
49
|
+
|
|
50
|
+
<The durable takeaway. If a spec or a concrete follow-up should come out of this, name it.>
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
Rules:
|
|
54
|
+
- Blameless throughout, "the deploy lacked a health check", never "X forgot to add a health check".
|
|
55
|
+
- The timeline is facts with timestamps, not analysis. Keep analysis in Root cause / Contributing factors.
|
|
56
|
+
- Every action item is specific and assignable, and tagged Prevent (stop recurrence), Detect (find it faster), or Mitigate (reduce impact). No vague "be more careful".
|
|
57
|
+
- If the root cause maps to a systems failure mode, recommend a concrete follow-up action; if a past decision contributed, note the spec.
|
|
58
|
+
- Only state facts present in INCIDENT_FACTS or the change; mark genuine unknowns as "Unknown, to investigate" rather than guessing.
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# PR Template
|
|
2
|
+
|
|
3
|
+
Produce a title and body. Always return both as text (the skill shows them in the chat). Touch `gh` only per **GH_ACTION**: `none` → chat only; `gh pr create` → create the PR with this body; `gh pr edit` → update the existing PR's body. Never invent a different gh command.
|
|
4
|
+
|
|
5
|
+
## Title
|
|
6
|
+
|
|
7
|
+
One line, imperative mood, ≤ 72 chars. Match the project's commit convention if `.istm-context/agents.md` specifies one (e.g. `feat:`, `fix:`). Examples: `feat: add rate limiting to the orders API`, `fix: prevent double-charge on retried checkout`.
|
|
8
|
+
|
|
9
|
+
## Body structure
|
|
10
|
+
|
|
11
|
+
```markdown
|
|
12
|
+
## What
|
|
13
|
+
|
|
14
|
+
<1 to 3 sentences: what this PR does, in plain terms.>
|
|
15
|
+
|
|
16
|
+
## Why
|
|
17
|
+
|
|
18
|
+
<The motivation. Link the spec if one governs this change, e.g. "Implements .istm-context/specs/0007-rate-limiting.md". Reference the issue/ticket if known.>
|
|
19
|
+
|
|
20
|
+
## Changes
|
|
21
|
+
|
|
22
|
+
- <key change, grouped logically, not a raw commit dump>
|
|
23
|
+
- <key change>
|
|
24
|
+
|
|
25
|
+
## How to test / verify
|
|
26
|
+
|
|
27
|
+
- <the steps or commands a reviewer runs to confirm it works>
|
|
28
|
+
- <what they should observe>
|
|
29
|
+
|
|
30
|
+
## Risk & rollout
|
|
31
|
+
|
|
32
|
+
<Blast radius, migrations, feature flags, or rollback notes. Write "Low risk, no migrations, no flags." when that's true.>
|
|
33
|
+
|
|
34
|
+
## Notes for reviewers
|
|
35
|
+
|
|
36
|
+
<Anything that helps the review: a tricky decision, a deliberate tradeoff, an area wanting extra eyes. Omit if nothing.>
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Rules:
|
|
40
|
+
- Group changes by intent, not by file or commit. A reviewer wants the story, not `git log`.
|
|
41
|
+
- Keep "What" skimmable. A busy reviewer reads it first.
|
|
42
|
+
- If review findings exist for this change, reference accepted residual risks under "Risk & rollout".
|
|
43
|
+
- Do not invent test steps. Derive them from the actual tests or the change's behaviour.
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# Release Notes Template
|
|
2
|
+
|
|
3
|
+
Write release notes for VERSION_RANGE, written for users to `.istm-context/releases/<version>.md`. Audience is **end users**, not developers, so translate technical changes into what users can now do, and lead with what they'll care about most.
|
|
4
|
+
|
|
5
|
+
## Structure
|
|
6
|
+
|
|
7
|
+
```markdown
|
|
8
|
+
# <Product> <version>
|
|
9
|
+
|
|
10
|
+
_Released <DATE>_
|
|
11
|
+
|
|
12
|
+
<1 to 2 sentence summary of the release's theme, the headline a user should remember.>
|
|
13
|
+
|
|
14
|
+
## Highlights
|
|
15
|
+
|
|
16
|
+
- **<Feature name>**: <what it does for the user, in one sentence.>
|
|
17
|
+
- **<Feature name>**: <user benefit.>
|
|
18
|
+
|
|
19
|
+
## Improvements
|
|
20
|
+
|
|
21
|
+
- <smaller enhancement, phrased for users>
|
|
22
|
+
|
|
23
|
+
## Fixes
|
|
24
|
+
|
|
25
|
+
- <fixed issue, described as the user experienced it, "Fixed a problem where…">
|
|
26
|
+
|
|
27
|
+
## Breaking changes
|
|
28
|
+
|
|
29
|
+
<Only if any. State plainly what breaks, who is affected, and the migration step. Omit the section if there are none.>
|
|
30
|
+
|
|
31
|
+
## Upgrade notes
|
|
32
|
+
|
|
33
|
+
<How to upgrade, if there's anything to do. Omit if upgrading is automatic/trivial.>
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Rules:
|
|
37
|
+
- Lead with user value, not implementation. "You can now export reports as CSV" beats "Added CSV serialization to the export module".
|
|
38
|
+
- Group by importance: Highlights first, then Improvements, then Fixes.
|
|
39
|
+
- Be honest about breaking changes. Never bury them. They get their own clearly labelled section.
|
|
40
|
+
- No internal jargon, ticket numbers, or file names. This is the most polished, least technical of the four document types.
|
|
41
|
+
- Derive everything from the actual commits/diff in the range. Don't promise features that aren't there.
|