用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/duc01226/EasyPlatform --skill docs-init命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
基于 SOC 职业分类
| name | docs-init |
| version | 2.0.0 |
| description | [Documentation] Use when you need to initialize project reference docs via hook + scan skills. |
| disable-model-invocation | false |
Goal: Initialize project reference documentation by verifying the session-init-docs.cjs hook has created placeholder files, then running scan skills to populate them.
Workflow:
session-init-docs.cjs hook has created placeholder docs in docs/Key Rules:
/scan-* skill that populates itBe skeptical. Apply critical thinking, sequential thinking. Every claim needs traced proof, confidence percentages (Idea should be more than 80%).
Check that session-init-docs.cjs has created the project reference docs declared for the project:
docs/project-config.json and use referenceDocs[*].filename as the source of truth.referenceDocs is empty or missing, use DEFAULT_REFERENCE_DOCS from .claude/hooks/lib/session-init-helpers.cjs.docs/project-reference/ files. Add or correct the project config/template entry first, then rerun the session-init/docs-init path.Common mappings when configured:
docs/project-reference/project-structure-reference.md -> /scan --target=project-structure
docs/project-reference/backend-patterns-reference.md -> /scan --target=backend-patterns
docs/project-reference/seed-test-data-reference.md -> /scan --target=seed-test-data
docs/project-reference/frontend-patterns-reference.md -> /scan --target=frontend-patterns
docs/project-reference/integration-test-reference.md -> /scan --target=integration-tests
docs/project-reference/feature-spec-reference.md -> /scan --target=feature-spec
docs/project-reference/spec-system-reference.md -> static template (no scan skill)
docs/project-reference/spec-principles.md -> static template (no scan skill)
docs/project-reference/workflow-spec-test-code-cycle-reference.md -> static template (no scan skill)
docs/project-reference/code-review-rules.md -> /scan --target=code-review-rules
docs/project-reference/scss-styling-guide.md -> /scan --target=scss-styling
docs/project-reference/design-system/README.md -> /scan --target=design-system
docs/project-reference/e2e-test-reference.md -> /scan --target=e2e-tests
docs/project-reference/domain-entities-reference.md -> /scan --target=domain-entities
docs/project-reference/docs-index-reference.md -> /scan --target=docs-index
docs/project-reference/lessons.md -> /learn (managed separately)
If configured files are missing, the hook should create them on next prompt/session start. Verify by checking docs/project-reference/ against the configured filenames.
Read the first 512 bytes of each file. If it contains <!-- Fill in your project's details below. -->, it is still a placeholder and needs scanning.
Use AskUserQuestion to present:
For each selected scan target, invoke it via the Skill tool (e.g., /scan --target=backend-patterns).
See .claude/skills/shared/sdd-artifact-contract.md → "AI-SDD Mandates (M1-M6)" for BLOCKING criteria. After the scan skills generate/populate the reference docs, gate the generated output:
spec-principles.md extension) keep narrative and headings free of framework/product/language/design-pattern names and source identifiers; those appear only in evidence carriers ([Source: namespace/service/id], **Evidence**), frontmatter, and Mermaid. Authority: docs/project-reference/spec-principles.md §3.FR-/BR-/OP-/TC-) are the primary spine and [Source: namespace/service/id] (a stack-portable abstract anchor — never physical code coordinates or repository-root paths; physical coords live only in the provenance sidecar) is the secondary carrier.Verification step (run after generation): Run the exact SDD compliance verifier documented by the project and resolve any failures before declaring init complete. Do not invent a verifier command; if the verifier or project config is not yet initialized, record that and re-run once available.
Reference doc definitions are in docs/project-config.json under referenceDocs. The hook reads this config to determine which files to create. Static local-extension docs use .claude/templates/reference-docs/ templates. See .claude/hooks/session-init-docs.cjs for the full implementation.
[IMPORTANT] Use
TaskCreateto break ALL work into small tasks BEFORE starting — including tasks for each file read. This prevents context loss from long files. For simple tasks, AI MUST ATTENTION ask user whether to skip.
AI Mistake Prevention — Failure modes to avoid on every task:
Re-read files after context changes. Context compaction, resume, or long-running work can make memory stale; verify current files before acting. Verify generated content against source evidence. AI hallucinates APIs, names, claims, and document facts. Check the relevant source before documenting or referencing. Check downstream references before deleting or renaming. Removing an artifact can stale docs, generated mirrors, configs, and callers; map references first. Trace the full impact chain after edits. Changing a definition can miss derived outputs and consumers. Follow the affected chain before declaring done. Verify ALL affected outputs, not just the first. One green check is not all green checks; validate every output surface the change can affect. Assume existing values are intentional — ask WHY before changing. Before changing a constant, limit, flag, wording, or pattern, read nearby context and history. Surface ambiguity before acting — don't pick silently. Multiple valid interpretations require an explicit question or stated assumption with risk. Keep shared guidance role-relevant. Universal guidance must help every receiving skill or agent; code-specific obligations belong only in code-specific protocols.
Critical Thinking Mindset — Apply critical thinking, sequential thinking. Every claim needs traced proof, confidence >80% to act. Anti-hallucination: Never present guess as fact — cite sources for every claim, admit uncertainty freely, self-check output for errors, cross-reference independently, stay skeptical of own confidence — certainty without evidence root of all hallucination.
MUST ATTENTION apply critical + sequential thinking — every claim needs appropriate traced evidence (file:line for repo/code claims; source URL or artifact section for research, product, content, and docs claims); confidence >80% to act, <60% DO NOT recommend. Anti-hallucination: never present guess as fact, admit uncertainty freely, cross-reference independently, stay skeptical of own confidence.
MUST ATTENTION apply AI mistake prevention — verify generated content against evidence, trace downstream references before deleting or renaming, verify all affected outputs, re-read files after context loss, and surface ambiguity before acting.
Protocols in force (concise digest of the SYNC/shared blocks this skill carries):
Critical Thinking: Apply critical + sequential thinking; cite proof, confidence >80% to act.
AI Mistake Prevention: verify generated content against evidence, trace downstream references, verify all affected outputs, re-read after context loss, surface ambiguity.
MANDATORY IMPORTANT MUST ATTENTION break work into small todo tasks using TaskCreate BEFORE starting
MANDATORY IMPORTANT MUST ATTENTION search codebase for 3+ similar patterns before creating new code
MANDATORY IMPORTANT MUST ATTENTION cite file:line evidence for every claim (confidence >80% to act)
MANDATORY IMPORTANT MUST ATTENTION add a final review todo task to verify work quality
[TASK-PLANNING] Before acting, analyze task scope and systematically break it into small todo tasks and sub-tasks using TaskCreate.