@neikyun/ciel 6.11.2 → 6.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/assets/.claude/agents/ciel-critic.md +71 -12
  2. package/assets/.claude/agents/ciel-explorer.md +59 -18
  3. package/assets/.claude/agents/ciel-improver.md +6 -3
  4. package/assets/.claude/agents/ciel-researcher.md +85 -25
  5. package/assets/.claude/hooks/block-destructive.sh +2 -2
  6. package/assets/.claude/hooks/check-test-first.sh +2 -2
  7. package/assets/.claude/hooks/memory-bootstrap.sh +0 -0
  8. package/assets/.claude/hooks/memory-engine.py +82 -15
  9. package/assets/.claude/hooks/post-tool-write.sh +32 -0
  10. package/assets/.claude/hooks/pre-agent-gate.sh +11 -6
  11. package/assets/.claude/hooks/pre-compact.sh +18 -0
  12. package/assets/.claude/hooks/pre-tool-write.sh +56 -31
  13. package/assets/.claude/hooks/session-start.sh +22 -1
  14. package/assets/.claude/hooks/session-version-check.sh +1 -1
  15. package/assets/.claude/hooks/stop.sh +104 -0
  16. package/assets/.claude/hooks/subagent-stop.sh +54 -0
  17. package/assets/.claude/hooks/track-file.sh +2 -2
  18. package/assets/.claude/hooks/user-prompt-submit.sh +11 -15
  19. package/assets/.claude/settings.json +18 -4
  20. package/assets/AGENTS.md +1 -1
  21. package/assets/CLAUDE.md +103 -175
  22. package/assets/commands/ciel-audit.md +58 -399
  23. package/assets/commands/ciel-create-skill.md +24 -38
  24. package/assets/commands/ciel-eval.md +25 -37
  25. package/assets/commands/ciel-init.md +36 -126
  26. package/assets/commands/ciel-status.md +22 -19
  27. package/assets/commands/ciel-update.md +20 -39
  28. package/assets/platforms/opencode/.opencode/agents/ciel-researcher.md +71 -895
  29. package/assets/platforms/opencode/.opencode/commands/ciel-audit.md +58 -296
  30. package/assets/platforms/opencode/.opencode/commands/ciel-create-skill.md +24 -46
  31. package/assets/platforms/opencode/.opencode/commands/ciel-eval.md +25 -45
  32. package/assets/platforms/opencode/.opencode/commands/ciel-init.md +36 -131
  33. package/assets/platforms/opencode/.opencode/commands/ciel-status.md +22 -24
  34. package/assets/platforms/opencode/.opencode/commands/ciel-update.md +20 -40
  35. package/assets/platforms/opencode/AGENTS.md +4 -4
  36. package/assets/rules/security.md +30 -0
  37. package/assets/rules/testing.md +23 -0
  38. package/assets/skills/agile/SKILL.md +42 -0
  39. package/assets/skills/alerting/SKILL.md +55 -0
  40. package/assets/skills/api-design/SKILL.md +46 -0
  41. package/assets/skills/appsec/SKILL.md +43 -0
  42. package/assets/skills/architecture/SKILL.md +74 -0
  43. package/assets/skills/backend/SKILL.md +41 -0
  44. package/assets/skills/backup-recovery/SKILL.md +42 -0
  45. package/assets/skills/caching/SKILL.md +44 -0
  46. package/assets/skills/cdn/SKILL.md +42 -0
  47. package/assets/skills/chaos/SKILL.md +41 -0
  48. package/assets/skills/cicd-pipeline/SKILL.md +56 -0
  49. package/assets/skills/cloud/SKILL.md +42 -0
  50. package/assets/skills/code-quality/SKILL.md +42 -0
  51. package/assets/skills/code-review/SKILL.md +41 -0
  52. package/assets/skills/communication/SKILL.md +42 -0
  53. package/assets/skills/containers/SKILL.md +42 -0
  54. package/assets/skills/cqrs/SKILL.md +41 -0
  55. package/assets/skills/crypto/SKILL.md +46 -0
  56. package/assets/skills/data-engineering/SKILL.md +42 -0
  57. package/assets/skills/database-design/SKILL.md +46 -0
  58. package/assets/skills/ddd/SKILL.md +45 -0
  59. package/assets/skills/deployment-strategies/SKILL.md +51 -0
  60. package/assets/skills/desktop/SKILL.md +42 -0
  61. package/assets/skills/devsecops/SKILL.md +43 -0
  62. package/assets/skills/event-driven/SKILL.md +46 -0
  63. package/assets/skills/frontend/SKILL.md +41 -0
  64. package/assets/skills/functional/SKILL.md +42 -0
  65. package/assets/skills/high-availability/SKILL.md +42 -0
  66. package/assets/skills/iac/SKILL.md +46 -0
  67. package/assets/skills/logging/SKILL.md +46 -0
  68. package/assets/skills/meta/ciel-improve/SKILL.md +127 -0
  69. package/assets/skills/meta/learnings-capture/SKILL.md +105 -0
  70. package/assets/skills/meta/patch-spec/patch-spec.md +50 -0
  71. package/assets/skills/meta/skill-creator/SKILL.md +115 -0
  72. package/assets/skills/meta/skill-freshness-auditor/SKILL.md +164 -0
  73. package/assets/skills/meta/skill-variant-evaluator/SKILL.md +100 -0
  74. package/assets/skills/meta/skills-first-design-auditor/SKILL.md +192 -0
  75. package/assets/skills/ml-engineering/SKILL.md +42 -0
  76. package/assets/skills/mobile/SKILL.md +42 -0
  77. package/assets/skills/monitoring/SKILL.md +54 -0
  78. package/assets/skills/networking/SKILL.md +42 -0
  79. package/assets/skills/nosql/SKILL.md +41 -0
  80. package/assets/skills/oop-solid/SKILL.md +42 -0
  81. package/assets/skills/performance/SKILL.md +41 -0
  82. package/assets/skills/reactive/SKILL.md +42 -0
  83. package/assets/skills/release-management/SKILL.md +51 -0
  84. package/assets/skills/research/fact-check-claims/SKILL.md +98 -0
  85. package/assets/skills/research/research-forums/SKILL.md +103 -0
  86. package/assets/skills/research/research-github-issues/SKILL.md +103 -0
  87. package/assets/skills/research/research-web-sources/SKILL.md +108 -0
  88. package/assets/skills/research/synthesize-findings/SKILL.md +112 -0
  89. package/assets/skills/research/validate-source-credibility/SKILL.md +103 -0
  90. package/assets/skills/resilience/SKILL.md +41 -0
  91. package/assets/skills/serverless/SKILL.md +42 -0
  92. package/assets/skills/servers/SKILL.md +41 -0
  93. package/assets/skills/sql/SKILL.md +45 -0
  94. package/assets/skills/supply-chain/SKILL.md +41 -0
  95. package/assets/skills/system-design/SKILL.md +91 -0
  96. package/assets/skills/tech-leadership/SKILL.md +46 -0
  97. package/assets/skills/testing/SKILL.md +41 -0
  98. package/assets/skills/tracing/SKILL.md +36 -0
  99. package/assets/skills/utility/branch-cleaner/SKILL.md +195 -0
  100. package/assets/skills/utility/branch-setup/SKILL.md +144 -0
  101. package/assets/skills/utility/changelog-updater/SKILL.md +125 -0
  102. package/assets/skills/utility/commit-writer/SKILL.md +154 -0
  103. package/assets/skills/utility/issue-closer/SKILL.md +106 -0
  104. package/assets/skills/utility/issue-creator/SKILL.md +200 -0
  105. package/assets/skills/utility/pr-merger/SKILL.md +189 -0
  106. package/assets/skills/utility/pr-opener/SKILL.md +180 -0
  107. package/assets/skills/utility/release-publisher/SKILL.md +224 -0
  108. package/assets/skills/workflow/ciel-dev-process/SKILL.md +94 -0
  109. package/assets/skills/workflow/faire-gatekeeper/SKILL.md +3 -1
  110. package/assets/skills/workflow/prouver-verifier/SKILL.md +11 -2
  111. package/dist/cli/check.d.ts.map +1 -1
  112. package/dist/cli/check.js +11 -2
  113. package/dist/cli/check.js.map +1 -1
  114. package/dist/cli/claude.d.ts.map +1 -1
  115. package/dist/cli/claude.js +0 -2
  116. package/dist/cli/claude.js.map +1 -1
  117. package/dist/cli/init.d.ts.map +1 -1
  118. package/dist/cli/init.js +11 -2
  119. package/dist/cli/init.js.map +1 -1
  120. package/dist/cli/opencode.d.ts.map +1 -1
  121. package/dist/cli/opencode.js +2 -1
  122. package/dist/cli/opencode.js.map +1 -1
  123. package/package.json +1 -1
  124. package/assets/commands/ciel-migrate.md +0 -35
  125. package/assets/commands/ciel-refresh.md +0 -91
@@ -0,0 +1,42 @@
1
+ ---
2
+ name: reactive
3
+ description: "Programmation Reactive — observables, streams, RxJS, backpressure, event sourcing, flux de donnees. A charger quand on utilise un paradigme reactif ou des streams."
4
+ ---
5
+
6
+ # Programmation Reactive
7
+
8
+ **Principe premier :** La programmation reactive n'est pas "utiliser RxJS" — c'est traiter les donnees comme un flux continu plutot que comme des valeurs ponctuelles. Dans un modele imperatif, tu demandes la valeur (`let x = getValue()`). Dans un modele reactif, tu t'abonnes au changement (`stream.subscribe(x => ...)`). La difference fondamentale : le code reactif se declare une fois et reagit a N evenements, le code imperatif repond a chaque evenement individuellement. Le piege : la complexite explose avec le nombre de streams. Sans gestion de la backpressure (producteur plus rapide que le consommateur) et du cycle de vie (unsubscribe), les streams deviennent une source de fuites memoire et de bugs subtils.
9
+
10
+ ## Checklist
11
+ - [ ] Les streams sont unsubscribed proprement (`takeUntil`, `async pipe`, `DisposeBag`) — zero fuite memoire
12
+ - [ ] La backpressure est geree : le consommateur controle le debit (`buffer`, `throttle`, `sample`, `request(n)`)
13
+ - [ ] Les operateurs sont composees en pipeline lisible — pas de callback hell reactive
14
+ - [ ] Les erreurs sont propagees dans le stream — pas de `try/catch` autour de `.subscribe()`
15
+ - [ ] Les streams partages sont multicastes (`share`, `shareReplay`) — pas de side effect par souscripteur
16
+ - [ ] Les valeurs initiales sont definies (`BehaviorSubject`, `startsWith`) — pas de "le stream emet dans 5 secondes"
17
+ - [ ] Le debounce/throttle est utilise pour les evenements frequents (input utilisateur, scroll) — pas de traitement par frappe
18
+
19
+ ## Anti-patterns
20
+ ### Nested subscribes
21
+ **Ce qu'on voit :** `stream1.subscribe(x => { stream2.subscribe(y => { stream3.subscribe(z => { doSomething(x,y,z) }) }) })`. Trois niveaux de souscriptions imbriquees.
22
+ **Pourquoi c'est dangereux :** c'est le callback hell version reactive. Chaque subscribe est un effet de bord. Impossible de unsubcribe proprement. La gestion d'erreur est cassee. Si `stream1` emet pendant que `stream2` n'a pas fini → race condition. Le code est illisible et indetachable.
23
+ **Faire plutot :** `combineLatest([stream1, stream2, stream3]).pipe(takeUntil(destroy$)).subscribe(([x,y,z]) => doSomething(x,y,z))`. Un seul subscribe. Flat/compose, never nest.
24
+
25
+ ### Pas de gestion de backpressure
26
+ **Ce qu'on voit :** un stream de clics souris a 1000 events/s. Le consommateur traite chaque event (appel API). La file d'attente memoire explose.
27
+ **Pourquoi c'est dangereux :** le producteur et le consommateur ont des vitesses differentes. Sans backpressure, le consommateur est inonde. Memoire → ∞. L'app freeze. Le comportement est non deterministe (depend de la charge).
28
+ **Faire plutot :** `sampleTime(200)` (prendre un event toutes les 200ms), `debounceTime(300)` (attendre 300ms de silence), `throttleTime(500)` (max 1 emission toutes les 500ms). Le consommateur controle le debit, pas le producteur.
29
+
30
+ ### RxJS partout
31
+ **Ce qu'on voit :** tout est un observable. `Observable.of(42)`, `Observable.from([1,2,3])`. Même les valeurs synchrones passent par des streams.
32
+ **Pourquoi c'est dangereux :** la programmation reactive ajoute de la complexite cognitive et un surcout de performance. Pour des donnees synchrones (un tableau, une variable), un observable est un marteau-piqueur pour ouvrir une noix. Le code devient plus dur a lire sans benefice.
33
+ **Faire plutot :** utiliser les observables la ou l'asynchronisme et le temps sont intrinseques : evenements utilisateur, websockets, reponses serveur, timers. Pour le synchrone, les structures de donnees normales suffisent.
34
+
35
+ ## Patterns
36
+ ### takeUntil pour le cleanup
37
+ **Quand :** tout abonnement qui a une duree de vie < l'application (composant Angular, ecran React).
38
+ **Comment :** `destroy$ = new Subject<void>()`. Tous les pipelines se terminent par `.pipe(takeUntil(this.destroy$))`. Dans `ngOnDestroy` / `useEffect` cleanup : `this.destroy$.next(); this.destroy$.complete()`. Tous les abonnements sont nettoyes en une ligne.
39
+
40
+ ### Event bus central
41
+ **Quand :** communication entre composants non relies (pas de parent-enfant).
42
+ **Comment :** un `Subject` ou `EventEmitter` partage. Les producteurs emettent, les consommateurs souscrivent. Chaque message est un type specifique (pas de `any`). Le bus est mockable en test. Alternative a Redux pour les cas simples ou la communication est le seul besoin.
@@ -0,0 +1,51 @@
1
+ ---
2
+ name: release-management
3
+ description: "Release Management — releases as contracts, semver as communication, pre-release channels (alpha/beta/rc), signed provenance, changelog as consumer signal. À charger quand on prépare une release."
4
+ ---
5
+
6
+ # Release Management
7
+
8
+ **Principe premier :** Une release est un contrat avec les consommateurs. Le numéro de version n'est pas un compteur — c'est un signal. MAJOR veut dire "tu dois migrer, voici comment". MINOR veut dire "nouveau, sans risque, upgrade". PATCH veut dire "sécurité ou bug, fais-le maintenant". Si tes numéros de version ne communiquent pas ça, ils ne servent à rien. Le changelog est la partie visible de ce contrat — sans lui, les consommateurs ne savent pas ce qui a changé et n'upgraderont pas.
9
+
10
+ ## Checklist
11
+ - [ ] La version suit semver strict : MAJOR (breaking API), MINOR (nouveau compatible), PATCH (bug/security)
12
+ - [ ] Chaque breaking change a un guide de migration (pas juste "changed X" — quoi changer, ligne par ligne)
13
+ - [ ] Des pre-release channels existent : alpha (instable, dev), beta (feature-complete, testable), rc (release candidate, plus de bugs connus)
14
+ - [ ] Le changelog est lisible par un humain — pas un dump de commits, pas de jargon interne
15
+ - [ ] Les artefacts sont signés ET vérifiables (Cosign/Sigstore, checksums SHA256, SBOM)
16
+ - [ ] Le tag Git est signé ET correspond exactement au commit du build (pas de tag après coup)
17
+ - [ ] Les releases sont immutables — jamais de repush d'un tag, jamais de republish d'un package
18
+
19
+ ## Anti-patterns
20
+ ### Version bloquée
21
+ **Ce qu'on voit :** `"version": "1.0.0"` dans package.json depuis 2 ans. 47 commits, des breaking changes, des nouvelles features — la version n'a jamais bougé.
22
+ **Pourquoi c'est dangereux :** la version ne communique plus rien. Les consommateurs ne savent pas s'ils peuvent upgrade. Certains pinent au commit, d'autres prennent `latest` et cassent. Le projet perd la confiance de son écosystème.
23
+ **Faire plutôt :** version bump à chaque release. Automatiser via conventional commits + semantic-release. Chaque merge sur main → version calculée → changelog mis à jour → release. Zéro intervention humaine.
24
+
25
+ ### Changelog = dump de commits
26
+ **Ce qu'on voit :** CHANGELOG.md copié-collé depuis `git log --oneline`. "fix: bug", "wip", "cleanup", "fix test" — l'utilisateur ne comprend rien.
27
+ **Pourquoi c'est dangereux :** un changelog illisible est pire qu'inexistant. Il donne l'illusion d'information. Le consommateur doit lire le diff pour comprendre ce qui a changé — exactement ce que le changelog devait éviter.
28
+ **Faire plutôt :** changelog structuré : Added, Changed, Deprecated, Removed, Fixed, Security. Chaque entrée est une phrase compréhensible par un utilisateur du projet. Le changelog répond à : "Qu'est-ce que je dois faire pour upgrade ?"
29
+
30
+ ### Pre-release sauté
31
+ **Ce qu'on voit :** `1.0.0-alpha.1` existe, puis directement `1.0.0`. Pas de beta, pas de RC. 6 mois entre alpha et stable.
32
+ **Pourquoi c'est dangereux :** les early adopters sont punis. Ils testent l'alpha, trouvent des bugs, mais n'ont jamais de version stable de leurs retours. Ils arrêtent de tester les pre-releases. La release stable sort sans validation réelle.
33
+ **Faire plutôt :** pipeline de maturité : alpha (semaine 1, cassant) → beta (semaine 2-3, testable, feedback) → rc (semaine 4, gel, uniquement bugfixes) → stable. Chaque étape a des consommateurs différents : devs internes → early adopters → tout le monde.
34
+
35
+ ### Artefact mutable
36
+ **Ce qu'on voit :** `npm publish` puis `npm publish` à nouveau sur la même version parce que "j'ai oublié un fichier". Ou `git tag -d v1.2.3 && git tag v1.2.3`.
37
+ **Pourquoi c'est dangereux :** un artefact mutable détruit la reproductibilité. Le hash que tu as vérifié hier n'est plus valide aujourd'hui. Impossible de faire un audit. Les mirrors de registre ont des versions différentes. C'est un cauchemar de debugging.
38
+ **Faire plutôt :** une version = un artefact = un hash, pour toujours. Si bug → nouvelle version (1.2.4, pas 1.2.3 repush). La plupart des registres permettent de "deprecate" sans "unpublish".
39
+
40
+ ## Patterns
41
+ ### Conventional Commits → release automatisée
42
+ **Quand :** tout projet avec plus d'un mainteneur.
43
+ **Comment :** `feat:` → MINOR bump, `fix:` → PATCH bump, `feat!:` ou `BREAKING CHANGE:` → MAJOR bump. `semantic-release` lit l'historique de commits depuis la dernière release, calcule la version, génère le changelog, publie. Configuré une fois, oublié.
44
+
45
+ ### Pre-release channels
46
+ **Quand :** projet avec breaking changes fréquents ou base d'utilisateurs qui teste les versions beta.
47
+ **Comment :** `1.0.0-alpha.1` → tags `alpha` instables. `1.0.0-beta.1` → tag `beta`, feature-complete. `1.0.0-rc.1` → tag `rc`, plus de bugs connus. `1.0.0` → tag `latest`. Les consommateurs choisissent leur niveau de risque : `npm install pkg@beta` ou `npm install pkg@latest`.
48
+
49
+ ### Migration guide
50
+ **Quand :** tout MAJOR bump.
51
+ **Comment :** un fichier `MIGRATION.md` ou section dans le changelog. Format : "Avant → Après" pour chaque breaking change. Exemple de code avant, exemple après. Pourquoi le changement a été fait (pas juste "changed"). Liste des choses à vérifier après migration.
@@ -0,0 +1,98 @@
1
+ ---
2
+ name: fact-check-claims
3
+ description: Before asserting any API/version/behavior claim in code or reports, greps the source code or fetches docs to verify. Guards against "false confidence" — confident assertions without evidence. Invoked before any assertion is committed to final output.
4
+ allowed-tools: Read, Grep, WebFetch
5
+ context: fork
6
+ agent: researcher
7
+ ---
8
+
9
+ # fact-check-claims — Verify before asserting
10
+
11
+ ## What this covers
12
+ Meta-research skill #6 of 6. The guard against false confidence. LLMs routinely state confidently wrong things — DB column names, function signatures, response shapes. This skill demands proof.
13
+
14
+ ## Core principle
15
+ **VERIFIED or not. There is no "probably true."** If you can't point to evidence (file:line or URL), mark it UNVERIFIED.
16
+
17
+ ## Inputs
18
+
19
+ ```
20
+ CLAIM: [the specific assertion to verify]
21
+ CONTEXT: [what's being built that relies on this claim]
22
+ SOURCES_TO_CHECK: [optional list of files/URLs to verify against]
23
+ ```
24
+
25
+ ## Process
26
+
27
+ ### 1. Classify the claim type
28
+
29
+ | Type | Verify against |
30
+ |------|----------------|
31
+ | Code (function signature, import) | `Read` + `Grep` on actual source |
32
+ | DB (table/column exists) | Migration files or `pg_attribute` |
33
+ | API (response shape, status) | `curl` real endpoint or fixtures |
34
+ | Version behavior | WebFetch official changelog |
35
+ | Environment (Node version, etc.) | Workflow / Dockerfile / CI config |
36
+
37
+ ### 2. Verify from authoritative source
38
+
39
+ Run the appropriate verification command. Record the evidence.
40
+
41
+ ### 3. Produce verification record
42
+
43
+ ```
44
+ VERIFIED — with evidence (file:line or URL + quote)
45
+ UNVERIFIED — source not available, state explicitly
46
+ CONTRADICTED — evidence says otherwise
47
+ ```
48
+
49
+ Never mark as VERIFIED without evidence.
50
+
51
+ ## Common patterns
52
+
53
+ ### Good fact-check
54
+
55
+ ```
56
+ ## FACT CHECK
57
+
58
+ Claim: "The users table has a 'last_login' column"
59
+
60
+ Result: VERIFIED
61
+
62
+ Evidence:
63
+ - migration/20260315_add_last_login.sql:3 — `ALTER TABLE users ADD COLUMN last_login TIMESTAMPTZ`
64
+ - pg_attribute confirms: users.last_login exists (type: timestamptz, notnull: false)
65
+ ```
66
+
67
+ ### Bad fact-check
68
+
69
+ ```
70
+ The users table probably has a last_login column. I remember seeing it.
71
+ ```
72
+
73
+ Problems: no evidence, "probably" = UNVERIFIED, no file:line reference.
74
+
75
+ ## Anti-patterns
76
+
77
+ - **"Probably true"** — VERIFIED or not. Assumed-true = UNVERIFIED.
78
+ - **URL alone as evidence** — weak; include the specific quote/line
79
+ - **Compound claims not broken down** — "users table has id, email, last_login" → 3 claims
80
+ - **Version-specific without version check** — "In Ktor 3.0, X works" → verify in changelog
81
+ - **Memory substitution** — if source isn't accessible, mark UNVERIFIED
82
+
83
+ ## How to verify
84
+
85
+ - [ ] Claim classified (code/DB/API/version/environment)?
86
+ - [ ] Verification command run (grep/read/curl/webfetch)?
87
+ - [ ] Result is VERIFIED / UNVERIFIED / CONTRADICTED?
88
+ - [ ] VERIFIED claims have file:line or URL + quote?
89
+ - [ ] Compound claims broken into atomic parts?
90
+ - [ ] Version-specific claims include version number?
91
+
92
+ ## When triggered
93
+
94
+ - Before `synthesize-findings` finalizes any assertion
95
+ - Before code generation asserts behavior the researcher might be wrong about
96
+ - When user says "are you sure?"
97
+ - When `relire-critic` produces a RISQUE questioning an assertion
98
+ - Automatically on assertions about DB schemas, imports, response shapes
@@ -0,0 +1,103 @@
1
+ ---
2
+ name: research-forums
3
+ description: Fallback research source when official docs and GitHub issues are silent — searches StackOverflow, Reddit, Hacker News, and dev.to for community discussion. Lower priority than official sources but valuable for edge cases. Always followed by validate-source-credibility.
4
+ allowed-tools: WebSearch
5
+ context: fork
6
+ agent: researcher
7
+ ---
8
+
9
+ # research-forums — Community discussion fallback
10
+
11
+ ## What this covers
12
+ Meta-research skill #3 of 6. When official docs + GitHub issues don't resolve the question, community forums often have the answer. But quality is uneven — `validate-source-credibility` is mandatory after this.
13
+
14
+ ## Core principle
15
+ **Community knowledge supplements official docs, never replaces them.** If a forum answer contradicts official docs, trust docs.
16
+
17
+ ## Inputs
18
+
19
+ ```
20
+ TECHNOLOGY: [lib name]
21
+ VERSION: [version if relevant]
22
+ QUESTION: [specific question]
23
+ ```
24
+
25
+ ## Process
26
+
27
+ ### 1. StackOverflow
28
+
29
+ Queries:
30
+ - `site:stackoverflow.com <lib> <feature> <version>`
31
+ - `site:stackoverflow.com [<lib>] <question>`
32
+
33
+ Priority signals:
34
+ - Accepted answer (green checkmark)
35
+ - Answer with > 50 upvotes
36
+ - Answer from recognized maintainer
37
+
38
+ ### 2. Reddit
39
+
40
+ Subs: `r/programming`, stack-specific (`r/typescript`, `r/golang`, `r/reactjs`, etc.)
41
+
42
+ Priority signals: upvote ratio > 0.9, top comment explains tradeoffs.
43
+
44
+ ### 3. Hacker News
45
+
46
+ - `site:news.ycombinator.com <lib> <feature>`
47
+ - Priority: 100+ points + quality discussion
48
+
49
+ ### 4. dev.to, medium, maintainer blogs
50
+
51
+ - Recent posts (< 18 months) usually more reliable
52
+ - Look for author bio matching lib committer
53
+
54
+ ## Common patterns
55
+
56
+ ### Good forum research
57
+
58
+ ```
59
+ ## FORUMS RESEARCH — Vitest 3
60
+
61
+ ### StackOverflow
62
+ - https://stackoverflow.com/q/12345 — 89 upvotes, accepted — vi.hoisted() required for mock variables in Vitest 3
63
+
64
+ ### Reddit
65
+ - https://reddit.com/r/vitest/comments/abc — 45 upvotes, 23 comments — consensus: vi.spyOn > vi.mock for most cases
66
+
67
+ ### CONSENSUS
68
+ - Use vi.hoisted() for variables referenced in vi.mock()
69
+ - Prefer vi.spyOn over vi.mock for testing interactions
70
+
71
+ ### DISAGREEMENTS
72
+ - Whether to use global vs per-test setup: SO says global, Reddit says per-test — depends on test isolation needs
73
+ ```
74
+
75
+ ### Bad forum research
76
+
77
+ ```
78
+ Found some stuff on StackOverflow. People say use vi.mock.
79
+ ```
80
+
81
+ Problems: no URLs, no upvote counts, no consensus analysis, no disagreement detection.
82
+
83
+ ## Anti-patterns
84
+
85
+ - **Credibility not validated** — follow-up with `validate-source-credibility` on any non-official finding
86
+ - **Stale answers accepted** — reject if older than 2 years unless fundamentals unchanged
87
+ - **Forum > docs** — if forum answer contradicts official docs → trust docs
88
+ - **Single-source treated as fact** — one SO answer is a hypothesis, not an answer
89
+ - **No cross-reference** — corroborate with at least one other source before treating as fact
90
+
91
+ ## How to verify
92
+
93
+ - [ ] ≥ 1 forum source found?
94
+ - [ ] Each source has URL + upvote/engagement signal?
95
+ - [ ] Staleness check performed (< 2 years)?
96
+ - [ ] Consensus and disagreements identified?
97
+ - [ ] validate-source-credibility will be invoked for non-official findings?
98
+
99
+ ## When triggered
100
+
101
+ - `researcher` agent when `research-web-sources` and `research-github-issues` didn't resolve
102
+ - User asks for "community perspective" or "what do other people do"
103
+ - Niche library with sparse docs
@@ -0,0 +1,103 @@
1
+ ---
2
+ name: research-github-issues
3
+ description: Searches GitHub issues for error symptoms and library API usage questions, detecting open issues, closed-with-workaround, or PR-in-progress status. Triggered when task involves an external library with a reported symptom. Invoked by the researcher agent as parallel research to official docs.
4
+ allowed-tools: WebFetch, WebSearch
5
+ context: fork
6
+ agent: researcher
7
+ ---
8
+
9
+ # research-github-issues — GitHub issues prior art
10
+
11
+ ## What this covers
12
+ Meta-research skill #2 of 6. When official docs don't cover an edge case, GitHub issues often have the answer — someone else hit the same problem.
13
+
14
+ ## Core principle
15
+ **Every bug you encounter, someone else encountered first.** GitHub issues are the world's largest debugging knowledge base. Check before investigating from scratch.
16
+
17
+ ## Inputs
18
+
19
+ ```
20
+ TECHNOLOGY: [lib name + repo path, e.g. "ktor" / "ktorio/ktor"]
21
+ VERSION: [exact installed version]
22
+ SYMPTOM: [error message OR unexpected behavior description]
23
+ ```
24
+
25
+ ## Process
26
+
27
+ ### 1. Identify the repo
28
+
29
+ From the lib name, resolve to the GitHub repo. Check `package.json` `repository` field for canonical URL.
30
+
31
+ ### 2. Search issues
32
+
33
+ Queries (via WebSearch or WebFetch):
34
+ - `site:github.com/<repo>/issues <symptom>`
35
+ - `site:github.com/<repo>/issues <feature> <version>`
36
+
37
+ Include both `is:open` and `is:closed`.
38
+
39
+ ### 3. Classify each relevant issue
40
+
41
+ - **Open + active** → known problem, official fix pending → workaround needed now
42
+ - **Closed + merged fix** → version N included fix; check if our version ≥ N
43
+ - **Closed with workaround** → apply workaround (cite link)
44
+ - **Closed as "not a bug"** → our usage is wrong (read the comment)
45
+ - **Closed as duplicate** → follow to the parent issue
46
+
47
+ ### 4. Check linked PRs
48
+
49
+ If an issue references a PR, check the PR:
50
+ - Merged → fix is in release vX.Y
51
+ - Draft → fix is in progress
52
+ - Closed unmerged → fix abandoned, need workaround
53
+
54
+ ## Common patterns
55
+
56
+ ### Good GitHub issues research
57
+
58
+ ```
59
+ ## GITHUB ISSUES RESEARCH — @auth/core
60
+
61
+ ### Relevant issues
62
+ | # | Title | Status | Our impact |
63
+ |---|-------|--------|-----------|
64
+ | #1234 | useSession throws on expired tokens | closed in v4.0.1 | Our version is 4.0.0 — upgrade needed |
65
+ | #5678 | OAuth callback fails with PKCE | open | Matches our symptom — apply workaround |
66
+
67
+ ### Workarounds applicable
68
+ - Add `skipCSRFCheck: true` to OAuth config — source: #5678 comment by maintainer
69
+
70
+ ### Fix version ranges
71
+ - useSession fix in v4.0.1 — our version: v4.0.0 — suggest upgrade
72
+ ```
73
+
74
+ ### Bad research
75
+
76
+ ```
77
+ Found some issues. One was closed. Should be fine.
78
+ ```
79
+
80
+ Problems: no issue numbers, no status classification, no version check, no workarounds.
81
+
82
+ ## Anti-patterns
83
+
84
+ - **No links** — every issue reference needs a URL
85
+ - **Single comment as truth** — check for maintainer response + consensus
86
+ - **Ignoring version ranges** — "fixed in 3.x" could mean 3.0 or 3.5 — read the changelog
87
+ - **Treating community workaround as gospel** — verify it works; prefer official fix
88
+ - **Empty result fabricated** — if no relevant issues found, report "no matches"
89
+
90
+ ## How to verify
91
+
92
+ - [ ] ≥ 1 GitHub issue found and classified?
93
+ - [ ] Each issue has URL, status, and impact assessment?
94
+ - [ ] Version ranges checked (our version vs fix version)?
95
+ - [ ] Workarounds documented with source links?
96
+ - [ ] Linked PRs checked (merged/draft/closed)?
97
+
98
+ ## When triggered
99
+
100
+ - `researcher` agent when TASK mentions a symptom / error message
101
+ - Standard/Critical tasks using a library that's not purely internal
102
+ - When `research-web-sources` docs are silent on an edge case
103
+ - User request: "check if this is a known issue"
@@ -0,0 +1,108 @@
1
+ ---
2
+ name: research-web-sources
3
+ description: Fetches official documentation via WebFetch and searches best practices via WebSearch for a specific library+version. Produces findings with version-stamped URLs and at least 1 anti-pattern. Invoked in the RECHERCHE step by the researcher agent.
4
+ allowed-tools: WebSearch, WebFetch
5
+ context: fork
6
+ agent: researcher
7
+ ---
8
+
9
+ # research-web-sources — Official docs + best practices
10
+
11
+ ## What this covers
12
+ Meta-research skill #1 of 6. Fetches the primary source (official docs) + best-practice articles for a specific library+version. This is the highest-credibility research step — if official docs answer the question, stop here.
13
+
14
+ ## Core principle
15
+ **Official docs are the source of truth.** If docs exist and answer the question, don't search further. Escalate to GitHub issues and forums only when docs are silent.
16
+
17
+ ## Inputs
18
+
19
+ ```
20
+ TASK: [1-sentence description]
21
+ TECHNOLOGY: [lib name]
22
+ VERSION: [exact installed version — from avec-quoi-versioner]
23
+ QUESTION: [specific question]
24
+ ```
25
+
26
+ ## Process
27
+
28
+ ### 1. Fetch official documentation
29
+
30
+ - Primary: WebFetch the official docs URL
31
+ - If docs for the exact version aren't available, fetch the latest + note the version gap
32
+ - Focus on the specific API/feature in question — don't fetch whole doc site
33
+
34
+ ### 2. WebSearch for best practices
35
+
36
+ Queries (run at least 2):
37
+ - `[feature] [lib] [version] best practices`
38
+ - `[feature] [lib] idiomatic way`
39
+
40
+ ### 3. Identify framework philosophy
41
+
42
+ From docs: how does this framework WANT this problem solved? Not just what the API is — the intended approach.
43
+
44
+ ### 4. Extract anti-patterns (MANDATORY — at least 1)
45
+
46
+ Queries:
47
+ - `[lib] [feature] common mistakes anti-patterns`
48
+ - `[lib] [version] pitfalls avoid`
49
+
50
+ Cite at least one documented anti-pattern with source URL.
51
+
52
+ ## Common patterns
53
+
54
+ ### Good research output
55
+
56
+ ```
57
+ ## RESEARCH — React 19
58
+
59
+ ### FINDINGS
60
+ - Server Components are the default in React 19 — no "use client" needed for static rendering
61
+ - `use()` hook replaces useEffect for data fetching in client components
62
+ - Source: https://react.dev/reference/rsc/server-components (React 19.0)
63
+
64
+ ### ANTI-PATTERNS À ÉVITER
65
+ - useEffect + fetch waterfall — use Server Components instead — official docs
66
+ - "use server" on components — this directive is for Server Functions, not components — react.dev
67
+
68
+ ### PHILOSOPHY DU FRAMEWORK
69
+ React 19 pushes data fetching to the server. Client components handle interactivity only.
70
+ ```
71
+
72
+ ### Bad research output
73
+
74
+ ```
75
+ FINDINGS:
76
+ - React is good for UI
77
+ - You can use hooks
78
+ ```
79
+
80
+ Problems: no version, no specific API, no source URLs, no anti-patterns.
81
+
82
+ ## Anti-patterns
83
+
84
+ - **No version stamp** — every finding must include the version it applies to
85
+ - **Filling gaps with assumptions** — if docs don't cover it, say so explicitly
86
+ - **Preamble** — return only the structured report, no "I found that..."
87
+ - **Fetching entire doc site** — focus on the specific API/feature in question
88
+ - **Minimum output not met** — ≥ 1 WebSearch result + ≥ 1 documented finding required
89
+
90
+ ## How to verify
91
+
92
+ - [ ] ≥ 1 WebSearch performed?
93
+ - [ ] ≥ 1 finding with version stamp?
94
+ - [ ] ≥ 1 anti-pattern cited?
95
+ - [ ] Source URLs present?
96
+ - [ ] Framework philosophy stated (1-2 sentences)?
97
+ - [ ] No preamble (structured report only)?
98
+
99
+ ## When triggered
100
+
101
+ - `researcher` agent, RECHERCHE step on Standard/Critical tasks
102
+ - User explicit request: "research <lib> <feature>"
103
+ - When task mentions a library that's not fully understood
104
+
105
+ ## References
106
+
107
+ - Tier-1 source credibility — validate-source-credibility skill
108
+ - Ciel waterfall: research-web-sources → research-github-issues → research-forums → synthesize-findings
@@ -0,0 +1,112 @@
1
+ ---
2
+ name: synthesize-findings
3
+ description: Merges outputs from research-web-sources, research-github-issues, and research-forums into a single structured report with FINDINGS / ANTI-PATTERNS / PHILOSOPHY / API SURFACE / UNCERTAINTIES sections. Cross-references conflicting claims and deduplicates. Produces the final research deliverable.
4
+ ---
5
+
6
+ # synthesize-findings — Merge research into one report
7
+
8
+ ## What this covers
9
+ Meta-research skill #5 of 6. After parallel research skills have produced raw findings, this skill merges them into the single canonical format that the `researcher` agent returns.
10
+
11
+ ## Core principle
12
+ **Conflicts are signals, not noise.** When two sources disagree, that disagreement is the most valuable finding. Surface it, don't hide it.
13
+
14
+ ## Inputs
15
+
16
+ ```
17
+ WEB_RESULTS: [output of research-web-sources — or "none"]
18
+ GITHUB_RESULTS: [output of research-github-issues — or "none"]
19
+ FORUM_RESULTS: [output of research-forums — or "none"]
20
+ CREDIBILITY_SCORES: [output of validate-source-credibility for low-tier sources]
21
+ ```
22
+
23
+ ## Process
24
+
25
+ ### 1. Deduplicate
26
+
27
+ Same claim from multiple sources → merge, cite all sources ordered by credibility tier (highest first).
28
+
29
+ ### 2. Resolve conflicts
30
+
31
+ When two sources disagree:
32
+ - Higher credibility tier wins (official docs > forum)
33
+ - Newer wins among same tier
34
+ - Both recent Tier 1 but disagree → flag as uncertainty
35
+ - Version-specific → align to installed version
36
+
37
+ ### 3. Populate canonical sections
38
+
39
+ - **FINDINGS**: positive statements with version + source
40
+ - **ANTI-PATTERNS À ÉVITER**: what NOT to do, with reason + source
41
+ - **PHILOSOPHY DU FRAMEWORK**: how the framework wants this solved (1-2 sentences)
42
+ - **API SURFACE**: verified imports / signatures / response shapes
43
+ - **INCERTITUDES**: unresolved questions, conflicts, version gaps
44
+
45
+ ### 4. Apply credibility filter
46
+
47
+ Any finding sourced only from Tier 4/5 without Tier 1/2 cross-reference → demote to INCERTITUDE.
48
+
49
+ ### 5. Enforce minimum gate
50
+
51
+ Output is incomplete if ANY of:
52
+ - 0 findings
53
+ - 0 anti-patterns
54
+ - No philosophy statement
55
+ - No version stamp on any finding
56
+
57
+ ## Common patterns
58
+
59
+ ### Good synthesis
60
+
61
+ ```
62
+ ## FINDINGS
63
+ - React 19 Server Components are the default — no "use client" needed for static rendering [v19.0]
64
+ Source: https://react.dev/reference/rsc/server-components (Tier 1)
65
+ - `use()` hook replaces useEffect for data fetching [v19.0]
66
+ Source: react.dev (Tier 1) + SO #12345 89 upvotes (Tier 3)
67
+
68
+ ## ANTI-PATTERNS À ÉVITER
69
+ - useEffect + fetch waterfall — use Server Components instead — react.dev
70
+ - "use server" on components — directive is for Server Functions — react.dev
71
+
72
+ ## PHILOSOPHY DU FRAMEWORK
73
+ React 19 pushes data fetching to the server. Client components handle interactivity only.
74
+
75
+ ## API SURFACE (verified)
76
+ - `use()` — react.dev/reference/react/use
77
+ - Server Components — `async function Component()` without "use client"
78
+
79
+ ## INCERTITUDES
80
+ - Migration path from useEffect-based data fetching: docs show examples but no automated codemod exists
81
+ ```
82
+
83
+ ### Bad synthesis
84
+
85
+ ```
86
+ React is good. Use Server Components. Don't use useEffect.
87
+ ```
88
+
89
+ Problems: no version, no sources, no anti-patterns, no uncertainties.
90
+
91
+ ## Anti-patterns
92
+
93
+ - **Inventing findings** — if research didn't produce a finding, leave it empty
94
+ - **No citations** — every finding has a URL or file:line
95
+ - **Empty INCERTITUDES** — suspicious. Research rarely resolves everything.
96
+ - **Conflicts hidden** — when sources disagree, surface it as INCERTITUDE
97
+ - **Output too long** — ≤ 500 tokens (researcher returns this to main session)
98
+
99
+ ## How to verify
100
+
101
+ - [ ] All 3 research inputs consumed (or marked "none")?
102
+ - [ ] FINDINGS have version stamps + source URLs?
103
+ - [ ] ≥ 1 anti-pattern documented?
104
+ - [ ] PHILOSOPHY stated (1-2 sentences)?
105
+ - [ ] Conflicts surfaced as INCERTITUDES?
106
+ - [ ] Output ≤ 500 tokens?
107
+ - [ ] Minimum gate passed (findings + anti-patterns + philosophy + versions)?
108
+
109
+ ## When triggered
110
+
111
+ - By `researcher` agent at the end of its research pipeline
112
+ - User request: "summarize research findings on X"