@prismer/runtime 2.0.8 → 2.2.55

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (119) hide show
  1. package/CHANGELOG.md +3430 -0
  2. package/README.md +34 -12
  3. package/apc/skills/FIELD-DICTIONARY.md +111 -0
  4. package/apc/skills/bug-reproduce/SKILL.md +150 -0
  5. package/apc/skills/bug-reproduce/skill.json +96 -0
  6. package/apc/skills/code-review/SKILL.md +198 -0
  7. package/apc/skills/code-review/skill.json +124 -0
  8. package/apc/skills/design-review/SKILL.md +122 -0
  9. package/apc/skills/design-review/skill.json +88 -0
  10. package/apc/skills/doc-sync/SKILL.md +168 -0
  11. package/apc/skills/doc-sync/skill.json +81 -0
  12. package/apc/skills/env-doctor/SKILL.md +194 -0
  13. package/apc/skills/env-doctor/skill.json +209 -0
  14. package/apc/skills/git-ops/SKILL.md +189 -0
  15. package/apc/skills/git-ops/skill.json +94 -0
  16. package/apc/skills/impact-trace/SKILL.md +168 -0
  17. package/apc/skills/impact-trace/skill.json +104 -0
  18. package/apc/skills/observability/SKILL.md +195 -0
  19. package/apc/skills/observability/skill.json +116 -0
  20. package/apc/skills/release-db-config-sync/SKILL.md +186 -0
  21. package/apc/skills/release-db-config-sync/skill.json +109 -0
  22. package/apc/skills/release-ota-promote/SKILL.md +195 -0
  23. package/apc/skills/release-ota-promote/skill.json +176 -0
  24. package/apc/skills/release-preflight/SKILL.md +174 -0
  25. package/apc/skills/release-preflight/skill.json +175 -0
  26. package/apc/skills/release-rollback/SKILL.md +214 -0
  27. package/apc/skills/release-rollback/skill.json +230 -0
  28. package/apc/skills/release-tag/SKILL.md +194 -0
  29. package/apc/skills/release-tag/skill.json +94 -0
  30. package/apc/skills/releasing-prod/SKILL.md +49 -0
  31. package/apc/skills/releasing-test/SKILL.md +135 -0
  32. package/apc/skills/sdk-release/SKILL.md +200 -0
  33. package/apc/skills/spec-intake/SKILL.md +169 -0
  34. package/apc/skills/spec-intake/skill.json +93 -0
  35. package/apc/skills/test-result-feedback/SKILL.md +239 -0
  36. package/apc/skills/test-result-feedback/skill.json +193 -0
  37. package/apc/skills/test-runner/SKILL.md +169 -0
  38. package/apc/skills/test-runner/skill.json +103 -0
  39. package/apc/skills/ui-align/SKILL.md +209 -0
  40. package/apc/skills/ui-align/skill.json +114 -0
  41. package/apc/skills/ui-canvas/SKILL.md +148 -0
  42. package/apc/skills/ui-canvas/skill.json +127 -0
  43. package/built-in-skills/agent-coordination/SKILL.md +59 -37
  44. package/built-in-skills/agent-meta/SKILL.md +1 -0
  45. package/built-in-skills/assets/SKILL.md +8 -6
  46. package/built-in-skills/browser-use/SKILL.md +93 -0
  47. package/built-in-skills/canvas-design/SKILL.md +1 -0
  48. package/built-in-skills/claim-agent-ownership/SKILL.md +3 -2
  49. package/built-in-skills/claude-api/SKILL.md +1 -0
  50. package/built-in-skills/codebase-design/DEEPENING.md +37 -0
  51. package/built-in-skills/codebase-design/DESIGN-IT-TWICE.md +44 -0
  52. package/built-in-skills/codebase-design/LICENSE +21 -0
  53. package/built-in-skills/codebase-design/SKILL.md +116 -0
  54. package/built-in-skills/conversation-compaction/SKILL.md +114 -0
  55. package/built-in-skills/council-creator/SKILL.md +426 -0
  56. package/built-in-skills/diagnosing-bugs/LICENSE +21 -0
  57. package/built-in-skills/diagnosing-bugs/SKILL.md +136 -0
  58. package/built-in-skills/diagnosing-bugs/scripts/hitl-loop.template.sh +41 -0
  59. package/built-in-skills/doc-coauthoring/SKILL.md +1 -0
  60. package/built-in-skills/document-generation/SKILL.md +105 -0
  61. package/built-in-skills/domain-modeling/ADR-FORMAT.md +47 -0
  62. package/built-in-skills/domain-modeling/CONTEXT-FORMAT.md +60 -0
  63. package/built-in-skills/domain-modeling/LICENSE +21 -0
  64. package/built-in-skills/domain-modeling/SKILL.md +76 -0
  65. package/built-in-skills/frontend-design/SKILL.md +1 -0
  66. package/built-in-skills/human-approval/SKILL.md +17 -2
  67. package/built-in-skills/image-generate/SKILL.md +103 -302
  68. package/built-in-skills/image-generate/scripts/generate-and-deliver.mjs +289 -0
  69. package/built-in-skills/ingest/SKILL.md +13 -45
  70. package/built-in-skills/internal-comms/SKILL.md +1 -0
  71. package/built-in-skills/liteparse/SKILL.md +130 -110
  72. package/built-in-skills/mcp-builder/SKILL.md +1 -0
  73. package/built-in-skills/memory/SKILL.md +420 -55
  74. package/built-in-skills/memory-dream/SKILL.md +339 -0
  75. package/built-in-skills/office-artifacts/SKILL.md +17 -4
  76. package/built-in-skills/okr/SKILL.md +154 -0
  77. package/built-in-skills/persona/SKILL.md +81 -0
  78. package/built-in-skills/persona-generator/SKILL.md +296 -0
  79. package/built-in-skills/pkf-svg/SKILL.md +253 -0
  80. package/built-in-skills/pkf-writing/SKILL.md +236 -0
  81. package/built-in-skills/prismer-im-collab/SKILL.md +26 -6
  82. package/built-in-skills/proactivity/SKILL.md +84 -0
  83. package/built-in-skills/remotion/SKILL.md +431 -0
  84. package/built-in-skills/role-builder/SKILL.md +203 -0
  85. package/built-in-skills/role-builder/scripts/author-role.mjs +334 -0
  86. package/built-in-skills/role-builder/scripts/ingest-role.mjs +223 -0
  87. package/built-in-skills/role-builder/scripts/instantiate-and-run.mjs +290 -0
  88. package/built-in-skills/role-builder/scripts/operation-harness.mjs +267 -0
  89. package/built-in-skills/skill-authoring/SKILL.md +110 -100
  90. package/built-in-skills/skill-authoring/skill.json +3 -3
  91. package/built-in-skills/skill-builder/SKILL.md +171 -0
  92. package/built-in-skills/skill-builder/scripts/ingest.mjs +265 -0
  93. package/built-in-skills/skill-creator/SKILL.md +165 -423
  94. package/built-in-skills/skill-creator/references/external-library-import.md +110 -0
  95. package/built-in-skills/skill-creator/scripts/import-library.mjs +475 -0
  96. package/built-in-skills/slack-gif-creator/SKILL.md +20 -0
  97. package/built-in-skills/tasks/SKILL.md +38 -23
  98. package/built-in-skills/tdd/LICENSE +21 -0
  99. package/built-in-skills/tdd/SKILL.md +110 -0
  100. package/built-in-skills/tdd/mocking.md +59 -0
  101. package/built-in-skills/tdd/refactoring.md +10 -0
  102. package/built-in-skills/tdd/tests.md +61 -0
  103. package/built-in-skills/team/SKILL.md +2 -1
  104. package/built-in-skills/web-artifacts-builder/SKILL.md +1 -0
  105. package/built-in-skills/webapp-testing/SKILL.md +1 -0
  106. package/built-in-skills/wechat-pay/SKILL.md +59 -0
  107. package/dist/cli.cjs +71872 -19960
  108. package/dist/cli.js +71803 -19846
  109. package/dist/index.cjs +72010 -19966
  110. package/dist/index.d.cts +4258 -712
  111. package/dist/index.d.ts +4258 -712
  112. package/dist/index.js +72156 -20118
  113. package/package.json +37 -6
  114. package/plugins/memory/prismer/__init__.py +1211 -0
  115. package/plugins/memory/prismer/plugin.yaml +8 -0
  116. package/plugins/memory/prismer/tool-schemas.generated.json +249 -0
  117. package/plugins/tools/prismer-recall/__init__.py +282 -0
  118. package/plugins/tools/prismer-recall/plugin.yaml +15 -0
  119. package/built-in-skills/memory-curation/SKILL.md +0 -135
@@ -0,0 +1,136 @@
1
+ ---
2
+ name: diagnosing-bugs
3
+ scope: coding
4
+ source: https://github.com/mattpocock/skills (MIT, © 2026 Matt Pocock)
5
+ description: Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.
6
+ ---
7
+
8
+ # Diagnosing Bugs
9
+
10
+ A discipline for hard bugs. Skip phases only when explicitly justified.
11
+
12
+ When exploring the codebase, read `CONTEXT.md` (if it exists) to get a clear mental model of the relevant modules, and check ADRs in the area you're touching.
13
+
14
+ ## Phase 1 — Build a feedback loop
15
+
16
+ **This is the skill.** Everything else is mechanical. If you have a **tight** pass/fail signal for the bug — one that goes red on _this_ bug — you will find the cause; bisection, hypothesis-testing, and instrumentation all just consume it. If you don't have one, no amount of staring at code will save you.
17
+
18
+ Spend disproportionate effort here. **Be aggressive. Be creative. Refuse to give up.**
19
+
20
+ ### Ways to construct one — try them in roughly this order
21
+
22
+ 1. **Failing test** at whatever seam reaches the bug — unit, integration, e2e.
23
+ 2. **Curl / HTTP script** against a running dev server.
24
+ 3. **CLI invocation** with a fixture input, diffing stdout against a known-good snapshot.
25
+ 4. **Headless browser script** (Playwright / Puppeteer) — drives the UI, asserts on DOM/console/network.
26
+ 5. **Replay a captured trace.** Save a real network request / payload / event log to disk; replay it through the code path in isolation.
27
+ 6. **Throwaway harness.** Spin up a minimal subset of the system (one service, mocked deps) that exercises the bug code path with a single function call.
28
+ 7. **Property / fuzz loop.** If the bug is "sometimes wrong output", run 1000 random inputs and look for the failure mode.
29
+ 8. **Bisection harness.** If the bug appeared between two known states (commit, dataset, version), automate "boot at state X, check, repeat" so you can `git bisect run` it.
30
+ 9. **Differential loop.** Run the same input through old-version vs new-version (or two configs) and diff outputs.
31
+ 10. **HITL bash script.** Last resort. If a human must click, drive _them_ with `scripts/hitl-loop.template.sh` so the loop is still structured. Captured output feeds back to you.
32
+
33
+ Build the right feedback loop, and the bug is 90% fixed.
34
+
35
+ ### Tighten the loop
36
+
37
+ Treat the loop as a product. Once you have _a_ loop, **tighten** it:
38
+
39
+ - Can I make it faster? (Cache setup, skip unrelated init, narrow the test scope.)
40
+ - Can I make the signal sharper? (Assert on the specific symptom, not "didn't crash".)
41
+ - Can I make it more deterministic? (Pin time, seed RNG, isolate filesystem, freeze network.)
42
+
43
+ A 30-second flaky loop is barely better than no loop; a 2-second deterministic one is tight — a debugging superpower.
44
+
45
+ ### Non-deterministic bugs
46
+
47
+ The goal is not a clean repro but a **higher reproduction rate**. Loop the trigger 100×, parallelise, add stress, narrow timing windows, inject sleeps. A 50%-flake bug is debuggable; 1% is not — keep raising the rate until it's debuggable.
48
+
49
+ ### When you genuinely cannot build a loop
50
+
51
+ Stop and say so explicitly. List what you tried. Ask the user for: (a) access to whatever environment reproduces it, (b) a captured artifact (HAR file, log dump, core dump, screen recording with timestamps), or (c) permission to add temporary production instrumentation. Do **not** proceed to hypothesise without a loop.
52
+
53
+ ### Completion criterion — a tight loop that goes red
54
+
55
+ Phase 1 is done when the loop is **tight** and **red-capable**: you can name **one command** — a script path, a test invocation, a curl — that you have **already run at least once** (paste the invocation and its output), and that is:
56
+
57
+ - [ ] **Red-capable** — it drives the actual bug code path and asserts the **user's exact symptom**, so it can go red on this bug and green once fixed. Not "runs without erroring" — it must be able to _catch this specific bug_.
58
+ - [ ] **Deterministic** — same verdict every run (flaky bugs: a pinned, high reproduction rate, per above).
59
+ - [ ] **Fast** — seconds, not minutes.
60
+ - [ ] **Agent-runnable** — you can run it unattended; a human in the loop only via `scripts/hitl-loop.template.sh`.
61
+
62
+ If you catch yourself reading code to build a theory before this command exists, **stop — jumping straight to a hypothesis is the exact failure this skill prevents.** No red-capable command, no Phase 2.
63
+
64
+ ## Phase 2 — Reproduce + minimise
65
+
66
+ Run the loop. Watch it go red — the bug appears.
67
+
68
+ Confirm:
69
+
70
+ - [ ] The loop produces the failure mode the **user** described — not a different failure that happens to be nearby. Wrong bug = wrong fix.
71
+ - [ ] The failure is reproducible across multiple runs (or, for non-deterministic bugs, reproducible at a high enough rate to debug against).
72
+ - [ ] You have captured the exact symptom (error message, wrong output, slow timing) so later phases can verify the fix actually addresses it.
73
+
74
+ ### Minimise
75
+
76
+ Once it's red, shrink the repro to the **smallest scenario that still goes red**. Cut inputs, callers, config, data, and steps **one at a time**, re-running the loop after each cut — keep only what's load-bearing for the failure.
77
+
78
+ Why bother: a minimal repro shrinks the hypothesis space in Phase 3 (fewer moving parts left to suspect) and becomes the clean regression test in Phase 5.
79
+
80
+ Done when **every remaining element is load-bearing** — removing any one of them makes the loop go green.
81
+
82
+ Do not proceed until you have reproduced **and** minimised.
83
+
84
+ ## Phase 3 — Hypothesise
85
+
86
+ Generate **3–5 ranked hypotheses** before testing any of them. Single-hypothesis generation anchors on the first plausible idea.
87
+
88
+ Each hypothesis must be **falsifiable**: state the prediction it makes.
89
+
90
+ > Format: "If <X> is the cause, then <changing Y> will make the bug disappear / <changing Z> will make it worse."
91
+
92
+ If you cannot state the prediction, the hypothesis is a vibe — discard or sharpen it.
93
+
94
+ **Show the ranked list to the user before testing.** They often have domain knowledge that re-ranks instantly ("we just deployed a change to #3"), or know hypotheses they've already ruled out. Cheap checkpoint, big time saver. Don't block on it — proceed with your ranking if the user is AFK.
95
+
96
+ ## Phase 4 — Instrument
97
+
98
+ Each probe must map to a specific prediction from Phase 3. **Change one variable at a time.**
99
+
100
+ Tool preference:
101
+
102
+ 1. **Debugger / REPL inspection** if the env supports it. One breakpoint beats ten logs.
103
+ 2. **Targeted logs** at the boundaries that distinguish hypotheses.
104
+ 3. Never "log everything and grep".
105
+
106
+ **Tag every debug log** with a unique prefix, e.g. `[DEBUG-a4f2]`. Cleanup at the end becomes a single grep. Untagged logs survive; tagged logs die.
107
+
108
+ **Perf branch.** For performance regressions, logs are usually wrong. Instead: establish a baseline measurement (timing harness, `performance.now()`, profiler, query plan), then bisect. Measure first, fix second.
109
+
110
+ ## Phase 5 — Fix + regression test
111
+
112
+ Write the regression test **before the fix** — but only if there is a **correct seam** for it.
113
+
114
+ A correct seam is one where the test exercises the **real bug pattern** as it occurs at the call site. If the only available seam is too shallow (single-caller test when the bug needs multiple callers, unit test that can't replicate the chain that triggered the bug), a regression test there gives false confidence.
115
+
116
+ **If no correct seam exists, that itself is the finding.** Note it. The codebase architecture is preventing the bug from being locked down. Flag this for the next phase.
117
+
118
+ If a correct seam exists:
119
+
120
+ 1. Turn the minimised repro into a failing test at that seam.
121
+ 2. Watch it fail.
122
+ 3. Apply the fix.
123
+ 4. Watch it pass.
124
+ 5. Re-run the Phase 1 feedback loop against the original (un-minimised) scenario.
125
+
126
+ ## Phase 6 — Cleanup + post-mortem
127
+
128
+ Required before declaring done:
129
+
130
+ - [ ] Original repro no longer reproduces (re-run the Phase 1 loop)
131
+ - [ ] Regression test passes (or absence of seam is documented)
132
+ - [ ] All `[DEBUG-...]` instrumentation removed (`grep` the prefix)
133
+ - [ ] Throwaway prototypes deleted (or moved to a clearly-marked debug location)
134
+ - [ ] The hypothesis that turned out correct is stated in the commit / PR message — so the next debugger learns
135
+
136
+ **Then ask: what would have prevented this bug?** If the answer involves architectural change (no good test seam, tangled callers, hidden coupling) hand off to the `/improve-codebase-architecture` skill with the specifics. Make the recommendation **after** the fix is in, not before — you have more information now than when you started.
@@ -0,0 +1,41 @@
1
+ #!/usr/bin/env bash
2
+ # Human-in-the-loop reproduction loop.
3
+ # Copy this file, edit the steps below, and run it.
4
+ # The agent runs the script; the user follows prompts in their terminal.
5
+ #
6
+ # Usage:
7
+ # bash hitl-loop.template.sh
8
+ #
9
+ # Two helpers:
10
+ # step "<instruction>" → show instruction, wait for Enter
11
+ # capture VAR "<question>" → show question, read response into VAR
12
+ #
13
+ # At the end, captured values are printed as KEY=VALUE for the agent to parse.
14
+
15
+ set -euo pipefail
16
+
17
+ step() {
18
+ printf '\n>>> %s\n' "$1"
19
+ read -r -p " [Enter when done] " _
20
+ }
21
+
22
+ capture() {
23
+ local var="$1" question="$2" answer
24
+ printf '\n>>> %s\n' "$question"
25
+ read -r -p " > " answer
26
+ printf -v "$var" '%s' "$answer"
27
+ }
28
+
29
+ # --- edit below ---------------------------------------------------------
30
+
31
+ step "Open the app at http://localhost:3000 and sign in."
32
+
33
+ capture ERRORED "Click the 'Export' button. Did it throw an error? (y/n)"
34
+
35
+ capture ERROR_MSG "Paste the error message (or 'none'):"
36
+
37
+ # --- edit above ---------------------------------------------------------
38
+
39
+ printf '\n--- Captured ---\n'
40
+ printf 'ERRORED=%s\n' "$ERRORED"
41
+ printf 'ERROR_MSG=%s\n' "$ERROR_MSG"
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  name: doc-coauthoring
3
+ scope: persistence
3
4
  description: Guide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision docs, or similar structured content. This workflow helps users efficiently transfer context, refine content through iteration, and verify the doc works for readers. Trigger when user mentions writing docs, creating proposals, drafting specs, or similar documentation tasks.
4
5
  ---
5
6
 
@@ -0,0 +1,105 @@
1
+ ---
2
+ name: document-generation
3
+ scope: common
4
+ description: Generate Word/PDF documents with correct CJK fonts (no tofu boxes). Industry-standard font semantics — 宋体/黑体/SimSun/Times New Roman resolve to the Noto CJK faces installed in the image via fontconfig aliases. Use whenever the task produces a .docx, .pdf, or rendered document containing Chinese/Japanese/Korean text.
5
+ ---
6
+
7
+ # Document Generation (Word / PDF, CJK-safe)
8
+
9
+ The image ships `python-docx` + `reportlab` and the full Noto CJK family
10
+ (Sans + Serif, .ttc). Font semantics are handled by
11
+ `/etc/fonts/conf.d/99-cjk-semantics.conf` — renderers resolve conventional
12
+ Chinese font names to the right Noto face automatically. Do NOT install extra
13
+ font packages; use the mapping below.
14
+
15
+ ## Font semantics (industry-standard mapping)
16
+
17
+ | Scenario | Conventional name | Resolves to (image) |
18
+ | --- | --- | --- |
19
+ | 官文/学术正文(宋体等效) | 宋体 / SimSun / Times New Roman | **Noto Serif CJK SC** |
20
+ | 标题/正文(黑体等效) | 黑体 / SimHei | **Noto Sans CJK SC** |
21
+ | 楷体(无开源 Noto 楷体,Serif 兜底) | 楷体 / KaiTi / 仿宋 | Noto Serif CJK SC |
22
+ | 代码/等宽 | Courier New / Monospace | DejaVu Sans Mono + Noto fallback |
23
+
24
+ Rule of thumb: **serif (Noto Serif CJK SC) for official/academic documents,
25
+ sans (Noto Sans CJK SC) for UI/headings** — same convention as Times New Roman
26
+ vs Arial in Western docs.
27
+
28
+ ## Word (.docx) — python-docx
29
+
30
+ Word stores font *names*, not glyphs — the rendering machine resolves them.
31
+ Two cases:
32
+
33
+ **A. User opens the docx on their desktop (Word/WPS has 宋体/SimSun)** — write
34
+ conventional names so it renders correctly on THEIR machine:
35
+
36
+ ```python
37
+ from docx import Document
38
+ from docx.shared import Pt
39
+ from docx.enum.text import WD_ALIGN_PARAGRAPH
40
+
41
+ doc = Document()
42
+ # set east-asian font properly (both ascii + eastAsia, or Word ignores it):
43
+ style = doc.styles['Normal']
44
+ style.font.name = 'Times New Roman' # ascii
45
+ style.font.size = Pt(12)
46
+ style.element.rPr.rFonts.set('{http://schemas.openxmlformats.org/wordprocessingml/2006/main}eastAsia', '宋体')
47
+ p = doc.add_paragraph('中文正文——宋体五号')
48
+ doc.save('/workspace/output.docx')
49
+ ```
50
+
51
+ **B. The sandbox itself must render/convert the docx to PDF** — use Noto names
52
+ so fontconfig resolves locally (LibreOffice may not be installed; prefer
53
+ generating PDF directly with reportlab instead of converting).
54
+
55
+ ## PDF — weasyprint (HTML→PDF, PREFERRED — industry standard for CJK)
56
+
57
+ **reportlab cannot render Noto CJK** (CFF/PostScript outlines — a reportlab
58
+ limitation, verified 2026-08-07). The industry-standard CJK PDF path is
59
+ **HTML/CSS → weasyprint**: CSS font-family resolves via fontconfig, the
60
+ aliases make conventional names work directly, and it ships in the image.
61
+
62
+ ```python
63
+ from weasyprint import HTML
64
+
65
+ html = '''<html><head><style>
66
+ body { font-family: '宋体', 'Noto Serif CJK SC', serif; font-size: 12pt; }
67
+ h1 { font-family: '黑体', 'Noto Sans CJK SC', sans-serif; }
68
+ code { font-family: 'Courier New', monospace; }
69
+ </style></head><body>
70
+ <h1>中文标题——黑体</h1>
71
+ <p>中文正文——宋体等效。混合 ASCII text works too.</p>
72
+ </body></html>'''
73
+ HTML(string=html).write_pdf('/workspace/output.pdf')
74
+ ```
75
+
76
+ pandoc is also present — `pandoc input.md -o output.pdf
77
+ --pdf-engine=weasyprint` is a valid markdown→PDF pipeline.
78
+
79
+ ## PDF — reportlab (programmatic; ASCII/Latin only for CJK)
80
+
81
+ reportlab 5.0 rejects Noto CJK .ttc files (`postscript outlines are not
82
+ supported` — CFF outlines). Use reportlab only for Latin/ASCII documents, or
83
+ for PDFs whose text never contains CJK. For CJK content use weasyprint above.
84
+
85
+ ```html
86
+ <style>
87
+ body { font-family: '宋体', 'Noto Serif CJK SC', serif; font-size: 12pt; }
88
+ h1 { font-family: '黑体', 'Noto Sans CJK SC', sans-serif; }
89
+ </style>
90
+ ```
91
+
92
+ ## Verification
93
+
94
+ ```bash
95
+ fc-match '宋体' # → Noto Serif CJK SC (alias working)
96
+ fc-match '黑体' # → Noto Sans CJK SC
97
+ fc-list | grep -c 'Noto.*CJK' # faces present
98
+ ```
99
+
100
+ ## Output contract
101
+
102
+ - Deliver the file as a task asset (`cloud file send` / attach) — never paste
103
+ document content as chat text.
104
+ - Verify the PDF opens (pdfplumber is installed) and contains the expected
105
+ Chinese text — tofu boxes are a FAIL, not a delivery.
@@ -0,0 +1,47 @@
1
+ # ADR Format
2
+
3
+ ADRs live in `docs/adr/` and use sequential numbering: `0001-slug.md`, `0002-slug.md`, etc.
4
+
5
+ Create the `docs/adr/` directory lazily — only when the first ADR is needed.
6
+
7
+ ## Template
8
+
9
+ ```md
10
+ # {Short title of the decision}
11
+
12
+ {1-3 sentences: what's the context, what did we decide, and why.}
13
+ ```
14
+
15
+ That's it. An ADR can be a single paragraph. The value is in recording *that* a decision was made and *why* — not in filling out sections.
16
+
17
+ ## Optional sections
18
+
19
+ Only include these when they add genuine value. Most ADRs won't need them.
20
+
21
+ - **Status** frontmatter (`proposed | accepted | deprecated | superseded by ADR-NNNN`) — useful when decisions are revisited
22
+ - **Considered Options** — only when the rejected alternatives are worth remembering
23
+ - **Consequences** — only when non-obvious downstream effects need to be called out
24
+
25
+ ## Numbering
26
+
27
+ Scan `docs/adr/` for the highest existing number and increment by one.
28
+
29
+ ## When to offer an ADR
30
+
31
+ All three of these must be true:
32
+
33
+ 1. **Hard to reverse** — the cost of changing your mind later is meaningful
34
+ 2. **Surprising without context** — a future reader will look at the code and wonder "why on earth did they do it this way?"
35
+ 3. **The result of a real trade-off** — there were genuine alternatives and you picked one for specific reasons
36
+
37
+ If a decision is easy to reverse, skip it — you'll just reverse it. If it's not surprising, nobody will wonder why. If there was no real alternative, there's nothing to record beyond "we did the obvious thing."
38
+
39
+ ### What qualifies
40
+
41
+ - **Architectural shape.** "We're using a monorepo." "The write model is event-sourced, the read model is projected into Postgres."
42
+ - **Integration patterns between contexts.** "Ordering and Billing communicate via domain events, not synchronous HTTP."
43
+ - **Technology choices that carry lock-in.** Database, message bus, auth provider, deployment target. Not every library — just the ones that would take a quarter to swap out.
44
+ - **Boundary and scope decisions.** "Customer data is owned by the Customer context; other contexts reference it by ID only." The explicit no-s are as valuable as the yes-s.
45
+ - **Deliberate deviations from the obvious path.** "We're using manual SQL instead of an ORM because X." Anything where a reasonable reader would assume the opposite. These stop the next engineer from "fixing" something that was deliberate.
46
+ - **Constraints not visible in the code.** "We can't use AWS because of compliance requirements." "Response times must be under 200ms because of the partner API contract."
47
+ - **Rejected alternatives when the rejection is non-obvious.** If you considered GraphQL and picked REST for subtle reasons, record it — otherwise someone will suggest GraphQL again in six months.
@@ -0,0 +1,60 @@
1
+ # CONTEXT.md Format
2
+
3
+ ## Structure
4
+
5
+ ```md
6
+ # {Context Name}
7
+
8
+ {One or two sentence description of what this context is and why it exists.}
9
+
10
+ ## Language
11
+
12
+ **Order**:
13
+ {A one or two sentence description of the term}
14
+ _Avoid_: Purchase, transaction
15
+
16
+ **Invoice**:
17
+ A request for payment sent to a customer after delivery.
18
+ _Avoid_: Bill, payment request
19
+
20
+ **Customer**:
21
+ A person or organization that places orders.
22
+ _Avoid_: Client, buyer, account
23
+ ```
24
+
25
+ ## Rules
26
+
27
+ - **Be opinionated.** When multiple words exist for the same concept, pick the best one and list the others under `_Avoid_`.
28
+ - **Keep definitions tight.** One or two sentences max. Define what it IS, not what it does.
29
+ - **Only include terms specific to this project's context.** General programming concepts (timeouts, error types, utility patterns) don't belong even if the project uses them extensively. Before adding a term, ask: is this a concept unique to this context, or a general programming concept? Only the former belongs.
30
+ - **Group terms under subheadings** when natural clusters emerge. If all terms belong to a single cohesive area, a flat list is fine.
31
+
32
+ ## Single vs multi-context repos
33
+
34
+ **Single context (most repos):** One `CONTEXT.md` at the repo root.
35
+
36
+ **Multiple contexts:** A `CONTEXT-MAP.md` at the repo root lists the contexts, where they live, and how they relate to each other:
37
+
38
+ ```md
39
+ # Context Map
40
+
41
+ ## Contexts
42
+
43
+ - [Ordering](./src/ordering/CONTEXT.md) — receives and tracks customer orders
44
+ - [Billing](./src/billing/CONTEXT.md) — generates invoices and processes payments
45
+ - [Fulfillment](./src/fulfillment/CONTEXT.md) — manages warehouse picking and shipping
46
+
47
+ ## Relationships
48
+
49
+ - **Ordering → Fulfillment**: Ordering emits `OrderPlaced` events; Fulfillment consumes them to start picking
50
+ - **Fulfillment → Billing**: Fulfillment emits `ShipmentDispatched` events; Billing consumes them to generate invoices
51
+ - **Ordering ↔ Billing**: Shared types for `CustomerId` and `Money`
52
+ ```
53
+
54
+ The skill infers which structure applies:
55
+
56
+ - If `CONTEXT-MAP.md` exists, read it to find contexts
57
+ - If only a root `CONTEXT.md` exists, single context
58
+ - If neither exists, create a root `CONTEXT.md` lazily when the first term is resolved
59
+
60
+ When multiple contexts exist, infer which one the current topic relates to. If unclear, ask.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Matt Pocock
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,76 @@
1
+ ---
2
+ name: domain-modeling
3
+ scope: coding
4
+ source: https://github.com/mattpocock/skills (MIT, © 2026 Matt Pocock)
5
+ description: Build and sharpen a project's domain model. Use when the user wants to pin down domain terminology or a ubiquitous language, record an architectural decision, or when another skill needs to maintain the domain model.
6
+ ---
7
+
8
+ # Domain Modeling
9
+
10
+ Actively build and sharpen the project's domain model as you design. This is the *active* discipline — challenging terms, inventing edge-case scenarios, and writing the glossary and decisions down the moment they crystallise. (Merely *reading* `CONTEXT.md` for vocabulary is not this skill — that's a one-line habit any skill can do. This skill is for when you're changing the model, not just consuming it.)
11
+
12
+ ## File structure
13
+
14
+ Most repos have a single context:
15
+
16
+ ```
17
+ /
18
+ ├── CONTEXT.md
19
+ ├── docs/
20
+ │ └── adr/
21
+ │ ├── 0001-event-sourced-orders.md
22
+ │ └── 0002-postgres-for-write-model.md
23
+ └── src/
24
+ ```
25
+
26
+ If a `CONTEXT-MAP.md` exists at the root, the repo has multiple contexts. The map points to where each one lives:
27
+
28
+ ```
29
+ /
30
+ ├── CONTEXT-MAP.md
31
+ ├── docs/
32
+ │ └── adr/ ← system-wide decisions
33
+ ├── src/
34
+ │ ├── ordering/
35
+ │ │ ├── CONTEXT.md
36
+ │ │ └── docs/adr/ ← context-specific decisions
37
+ │ └── billing/
38
+ │ ├── CONTEXT.md
39
+ │ └── docs/adr/
40
+ ```
41
+
42
+ Create files lazily — only when you have something to write. If no `CONTEXT.md` exists, create one when the first term is resolved. If no `docs/adr/` exists, create it when the first ADR is needed.
43
+
44
+ ## During the session
45
+
46
+ ### Challenge against the glossary
47
+
48
+ When the user uses a term that conflicts with the existing language in `CONTEXT.md`, call it out immediately. "Your glossary defines 'cancellation' as X, but you seem to mean Y — which is it?"
49
+
50
+ ### Sharpen fuzzy language
51
+
52
+ When the user uses vague or overloaded terms, propose a precise canonical term. "You're saying 'account' — do you mean the Customer or the User? Those are different things."
53
+
54
+ ### Discuss concrete scenarios
55
+
56
+ When domain relationships are being discussed, stress-test them with specific scenarios. Invent scenarios that probe edge cases and force the user to be precise about the boundaries between concepts.
57
+
58
+ ### Cross-reference with code
59
+
60
+ When the user states how something works, check whether the code agrees. If you find a contradiction, surface it: "Your code cancels entire Orders, but you just said partial cancellation is possible — which is right?"
61
+
62
+ ### Update CONTEXT.md inline
63
+
64
+ When a term is resolved, update `CONTEXT.md` right there. Don't batch these up — capture them as they happen. Use the format in [CONTEXT-FORMAT.md](./CONTEXT-FORMAT.md).
65
+
66
+ `CONTEXT.md` should be totally devoid of implementation details. Do not treat `CONTEXT.md` as a spec, a scratch pad, or a repository for implementation decisions. It is a glossary and nothing else.
67
+
68
+ ### Offer ADRs sparingly
69
+
70
+ Only offer to create an ADR when all three are true:
71
+
72
+ 1. **Hard to reverse** — the cost of changing your mind later is meaningful
73
+ 2. **Surprising without context** — a future reader will wonder "why did they do it this way?"
74
+ 3. **The result of a real trade-off** — there were genuine alternatives and you picked one for specific reasons
75
+
76
+ If any of the three is missing, skip the ADR. Use the format in [ADR-FORMAT.md](./ADR-FORMAT.md).
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  name: frontend-design
3
+ scope: coding
3
4
  description: Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, artifacts, posters, or applications (examples include websites, landing pages, dashboards, React components, HTML/CSS layouts, or when styling/beautifying any web UI). Generates creative, polished code and UI design that avoids generic AI aesthetics.
4
5
  license: Complete terms in LICENSE.txt
5
6
  ---
@@ -1,10 +1,25 @@
1
1
  ---
2
2
  name: human-approval
3
- description: Request human approval before performing a SAFETY-CRITICAL, IRREVERSIBLE, or SCOPE-EXPANDING action — submit a structured context (action, scope, risk, consequence) plus options, then STOP the current turn. The platform redispatches the agent after the human decides. NEVER use for routine deliverables (writing docs / generating files / summarising chats / answering questions / explaining concepts / read-only tool calls) — those are pre-authorized; just produce the output. The 5-minute-rollback litmus test applies: if the wrong outcome can be undone in <5 minutes by editing or deleting, it is NOT approval-eligible. Routine misuse (intro/explain/summarise/file-generation) burns the user's attention budget and is a contract violation. Executes via `cloud approval` CLI.
3
+ scope: common
4
+ description: "Request human approval before performing a SAFETY-CRITICAL, IRREVERSIBLE, or SCOPE-EXPANDING action — submit a structured context (action, scope, risk, consequence) plus options, then STOP the current turn. The platform redispatches the agent after the human decides. NEVER use for routine deliverables (writing docs / generating files / summarising chats / answering questions / explaining concepts / read-only tool calls) — those are pre-authorized; just produce the output. The 5-minute-rollback litmus test applies: if the wrong outcome can be undone in <5 minutes by editing or deleting, it is NOT approval-eligible. Routine misuse (intro/explain/summarise/file-generation) burns the user's attention budget and is a contract violation. Executes via `cloud approval` CLI."
4
5
  ---
5
6
 
6
7
  # Human Approval
7
8
 
9
+ > **Autonomous by default (release203).** Agents operate autonomously. Do
10
+ > NOT request approval for routine tool use, running commands, or delivering
11
+ > artifacts (`cloud deliver`). Only use this skill for genuinely high-risk
12
+ > actions, and only when your role is explicitly configured for it. If your
13
+ > `approvalPolicy` is `autonomous`, you should essentially never reach for
14
+ > this skill — just do the work and report the result.
15
+ >
16
+ > **Anti-confabulation rule.** NEVER claim to be "waiting for human
17
+ > approval" / "等待人工确认" unless you ACTUALLY invoked the approval tool
18
+ > (`cloud approval request` / `prismer.approval.request_human_approval`) and
19
+ > received a real `approvalId`. Narrating an approval pause you never
20
+ > triggered is a hallucination — it strands the user with a phantom gate
21
+ > that nothing will ever clear.
22
+
8
23
  Some actions need a human in the loop **before** they execute: production deploys, large credit spend, deleting data, scope-expanding decisions. This skill submits a structured request and **halts the current turn**. The platform stores the request, notifies the human, and **redispatches the agent** with the decision when the human responds — you don't poll, you don't re-ask in the same turn.
9
24
 
10
25
  ## When to use
@@ -51,7 +66,7 @@ back in under 5 minutes by editing or deleting something?**"
51
66
 
52
67
  Mis-using `human-approval` for routine work burns the user's attention
53
68
  budget, breaks chat flow, and signals lack of agent confidence — all
54
- three are real costs. The role templates (CEO / engineer / marketer /
69
+ three are real costs. The role templates (Team Manager / engineer / marketer /
55
70
  researcher / verifier) carry an explicit `operatingPrinciples` line as
56
71
  of 2.0.8: "Never trigger human-approval for routine deliverables".
57
72