@fenglimg/fabric-cli 2.0.0-rc.22 → 2.0.0-rc.25
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 +1 -2
- package/dist/{chunk-4HC5ZK7H.js → chunk-AXKII55Y.js} +6 -6
- package/dist/{chunk-ZSESMG6L.js → chunk-COI5VDFU.js} +0 -12
- package/dist/{chunk-KZ2YITOS.js → chunk-STLR2GHP.js} +137 -1
- package/dist/{config-AYP5F72E.js → config-XGUUAYX6.js} +1 -1
- package/dist/{doctor-HIX2FFEP.js → doctor-DXKPYPRC.js} +245 -14
- package/dist/index.js +10 -7
- package/dist/{install-WJZQZM7D.js → install-S2J76N2B.js} +106 -67
- package/dist/onboard-coverage-JJ5NGU7I.js +213 -0
- package/dist/{plan-context-hint-RYVSMULL.js → plan-context-hint-KPGOW3QC.js} +1 -1
- package/dist/{serve-6PPQX7AW.js → serve-NPCI342P.js} +1 -1
- package/dist/{uninstall-L2HEEOU3.js → uninstall-MQM6NUFM.js} +2 -2
- package/package.json +3 -3
- package/templates/hooks/archive-hint.cjs +463 -0
- package/templates/hooks/configs/claude-code.json +3 -3
- package/templates/hooks/configs/codex-hooks.json +3 -3
- package/templates/hooks/fabric-hint.cjs +153 -93
- package/templates/hooks/lib/cite-contract-reminder.cjs +173 -0
- package/templates/hooks/lib/cite-line-parser.cjs +118 -0
- package/templates/skills/fabric-archive/SKILL.md +696 -7
- package/templates/skills/fabric-import/SKILL.md +26 -4
- package/templates/skills/fabric-review/SKILL.md +1 -1
- package/dist/chunk-PSVKSMRO.js +0 -896
|
@@ -144,7 +144,8 @@ Rendering rule:
|
|
|
144
144
|
|
|
145
145
|
Protected tokens (`fab_extract_knowledge`, `fab_review`, `relevance_scope`,
|
|
146
146
|
`relevance_paths`, `broad`, `narrow`, `source_sessions`, `proposed_reason`,
|
|
147
|
-
`session_context`, `
|
|
147
|
+
`session_context`, `intent_clues`, `tech_stack`, `impact`, `must_read_if`,
|
|
148
|
+
`pending_path`, `layer`, `team`, `personal`,
|
|
148
149
|
`knowledge_scope_degraded`, `MUST`, `NEVER`, `.fabric/knowledge/`, etc.)
|
|
149
150
|
are NEVER translated — they appear verbatim in both language variants.
|
|
150
151
|
The bilingualization scope is prose ONLY.
|
|
@@ -305,7 +306,28 @@ mcp__fabric__fab_extract_knowledge({
|
|
|
305
306
|
// session_context cites the commit / doc origin so future-self reviewers
|
|
306
307
|
// know this is an LLM-mined entry rather than a live-session capture.
|
|
307
308
|
proposed_reason: "<inferred per Step 2.1.5 — varies>",
|
|
308
|
-
session_context: "Imported from git log analysis. Origin: commit <sha7> (<subject 30 chars>). No live session — see commit body for full context."
|
|
309
|
+
session_context: "Imported from git log analysis. Origin: commit <sha7> (<subject 30 chars>). No live session — see commit body for full context.",
|
|
310
|
+
// v2.0.0-rc.23 TASK-006 (a-C1): four OPTIONAL structured triage fields.
|
|
311
|
+
// Inference for the import path (no live session, only commit/doc evidence):
|
|
312
|
+
// intent_clues: pull from commit subject/body — when is this rule worth
|
|
313
|
+
// consulting? (e.g. ["editing retry/backoff logic"]). Omit if unclear.
|
|
314
|
+
// tech_stack: derived from extensions in `recent_paths` (.ts→typescript;
|
|
315
|
+
// package.json→nodejs; pyproject.toml→python; etc.). Omit if mixed.
|
|
316
|
+
// impact: quote the commit body's "fixes …" / "prevents …" clause
|
|
317
|
+
// when present (e.g. ["thundering-herd outage on retry"]). Omit if
|
|
318
|
+
// the body has no impact statement.
|
|
319
|
+
// must_read_if: ONE strong trigger, ≤160 chars, from the commit's
|
|
320
|
+
// primary touched-path family (e.g. "touching retry / backoff logic
|
|
321
|
+
// in packages/server/"). Omit if no single path family dominates.
|
|
322
|
+
// ALL FOUR ARE OPTIONAL — omit any field that cannot be inferred cleanly
|
|
323
|
+
// from commit/doc text alone. None participate in the idempotency_key hash
|
|
324
|
+
// (server formula: sha256({source_session, type, slug})), so subsequent
|
|
325
|
+
// imports with refined inference do NOT split a single pending entry into
|
|
326
|
+
// duplicates.
|
|
327
|
+
intent_clues: ["<inferred trigger if commit body suggests one>"],
|
|
328
|
+
tech_stack: ["<lang/framework from recent_paths extensions>"],
|
|
329
|
+
impact: ["<consequence stated in commit body / doc>"],
|
|
330
|
+
must_read_if: "<one-line strongest trigger from commit's touched-path family>"
|
|
309
331
|
})
|
|
310
332
|
```
|
|
311
333
|
|
|
@@ -644,7 +666,7 @@ The contract: re-invoking fabric-import after ANY interruption (Ctrl-C, crash, n
|
|
|
644
666
|
- NEVER populate `relevance_paths` with a non-empty array on import — every call from this skill MUST pass `relevance_paths: []`. Do not derive paths from `git log --name-only`, `git show --stat`, commit subjects/bodies, or the path of a mined Markdown file.
|
|
645
667
|
- NEVER copy fabric-archive's Phase 1.5 scope-decision logic (narrow-vs-broad rules, public-prefix generalization, glob blacklist) into this skill — that logic requires a live `edit_paths` signal from an active session, which fabric-import does not have.
|
|
646
668
|
- Narrowing of imported entries happens out-of-band through `fab_review action="modify"` (issued by user via `fabric-review`), NOT inside this skill.
|
|
647
|
-
- MUST preserve protected tokens exactly: `stable_id`, `pending_path`, `layer`, `team`, `personal`, `knowledge_proposed`, `fab_extract_knowledge`, `fab_review`, `MUST`, `NEVER`, `phase`, `.import-state.json`, `relevance_scope`, `relevance_paths`, `broad`, `narrow`, `source_sessions`, `proposed_reason`, `session_context`.
|
|
669
|
+
- MUST preserve protected tokens exactly: `stable_id`, `pending_path`, `layer`, `team`, `personal`, `knowledge_proposed`, `fab_extract_knowledge`, `fab_review`, `MUST`, `NEVER`, `phase`, `.import-state.json`, `relevance_scope`, `relevance_paths`, `broad`, `narrow`, `source_sessions`, `proposed_reason`, `session_context`, `intent_clues`, `tech_stack`, `impact`, `must_read_if`.
|
|
648
670
|
|
|
649
671
|
## Output Contract
|
|
650
672
|
|
|
@@ -766,7 +788,7 @@ Skill output (broad+[] mandatory; the doc's own path stays in `recent_paths` for
|
|
|
766
788
|
|
|
767
789
|
```ts
|
|
768
790
|
mcp__fabric__fab_extract_knowledge({
|
|
769
|
-
|
|
791
|
+
source_sessions: ["fabric-import-2026-05-10"],
|
|
770
792
|
recent_paths: ["docs/architecture.md"], // provenance only
|
|
771
793
|
user_messages_summary: "选择单体架构而非微服务:3 人团队无法承担多服务运维成本,且主要性能瓶颈在 DB 吞吐而非应用层水平扩展。src=docs/architecture.md",
|
|
772
794
|
type: "decisions",
|
|
@@ -52,7 +52,7 @@ If `.fabric/fabric-config.json` is missing or unreadable, use defaults silently.
|
|
|
52
52
|
### UX i18n Policy (5-class bilingualization)
|
|
53
53
|
|
|
54
54
|
The skill consults `fabric_language` from `.fabric/fabric-config.json`
|
|
55
|
-
(固化于 init 时,via `
|
|
55
|
+
(固化于 init 时,via `lib/detect-language.ts:detectExistingLanguage`; default `"en"` when no
|
|
56
56
|
CJK signal is detected in README + docs/; may resolve to `"match-existing"`,
|
|
57
57
|
`"zh-CN"`, `"en"`, or `"zh-CN-hybrid"`). All user-facing text in the
|
|
58
58
|
following 5 categories MUST be rendered in the resolved language:
|