{"id":"79adb83e-21ec-4b8e-b894-b444a329f42c","entityType":"agent","slug":"clawhub-handsomestwei-patent-disclosure-skill","name":"中国专利.Skill","canonicalUrl":"https://www.xpersona.co/agent/clawhub-handsomestwei-patent-disclosure-skill","canonicalPath":"/agent/clawhub-handsomestwei-patent-disclosure-skill","generatedAt":"2026-10-09T19:09:22.686Z","source":"CLAWHUB","claimStatus":"UNCLAIMED","verificationTier":"NONE","summary":{"evidence":{"source":"CLAWHUB","verified":false,"confidence":"medium","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":null},"description":"中国专利技能：挖掘专利点与编写交底书（发明/实用/外观），把已有交底改写成申请文件四件套，也可按材料交底申请一起做，按著录字段检索公布公告，通俗解读专利，对照审查口径出政策简报，辅助审查答复。| China patents skill: mine patent points and draft disclosures, rewrite an existing disclosure into application documents, or chain disclosure-then-application from inventor materials in one pass (ask wh","descriptionLabel":"Source description","evidenceSummary":"Capability contract not published. No trust telemetry is available yet. 3.1K downloads reported by the source. Last updated 10/9/2026.","installCommand":"clawhub skill install s17cne95kry5y91xh399564e9584ejmf:patent-disclosure-skill","sourceUrl":"https://clawhub.ai/handsomestwei/patent-disclosure-skill","homepage":"https://clawhub.ai/handsomestwei/skills/patent-disclosure-skill","primaryLinks":[{"label":"View on ClawHub","url":"https://clawhub.ai/handsomestwei/patent-disclosure-skill","kind":"source"},{"label":"Homepage","url":"https://clawhub.ai/handsomestwei/skills/patent-disclosure-skill","kind":"homepage"}],"safetyScore":84,"overallRank":62,"popularityScore":40,"trustScore":null,"claimedByName":null,"isOwner":false,"seoDescription":"中国专利.Skill technical dossier on Xpersona with agent coverage, OPENCLEW support, and live trust metadata."},"coverage":{"evidence":{"source":"public-profile","verified":false,"confidence":"medium","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":null},"protocols":[{"protocol":"OPENCLEW","label":"OpenClaw","status":"self-declared","notes":"Declared in the public agent profile."}],"capabilities":[],"verifiedCount":0,"selfDeclaredCount":1,"capabilityMatrix":{"rows":[{"key":"OPENCLEW","type":"protocol","support":"unknown","confidenceSource":"profile","notes":"Listed on profile"}],"flattenedTokens":"protocol:OPENCLEW|unknown|profile"}},"adoption":{"evidence":{"source":"CLAWHUB","verified":false,"confidence":"medium","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":null},"stars":null,"forks":null,"downloads":3105,"packageName":null,"latestVersion":"4.5.0","tractionLabel":"3.1K downloads"},"release":{"evidence":{"source":"CLAWHUB","verified":false,"confidence":"medium","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":null},"lastUpdatedAt":"2026-10-09T09:47:04.262Z","lastCrawledAt":"2026-10-09T09:47:04.262Z","lastIndexedAt":null,"nextCrawlAt":"2026-10-10T09:47:04.262Z","lastVerifiedAt":null,"highlights":[{"version":"4.5.0","createdAt":"2026-09-07T08:12:06.771Z","changelog":"Major update: Adds support for patent application drafting and full-chain docketing. - Introduced the new \"申请文件\" (patent-application) subskill for generating formal application documents (claims/spec/abstract/figures) from an existing disclosure. - Added the \"案卷\" (docket) subskill to chain disclosure drafting and application writing in a single workflow, with up to three issue-list refinement rounds. - Strictly separated cross-skill tool usage and clarified explicit user intent is required to trigger application or docketing workflows. - Enhanced routing logic and documentation to reflect new subskills, required inputs, and expanded outputs directory (including `outputs/patent-application/` and `outputs/docket/`). - Updated and expanded prompts, schemas, references, and tests for patent-application processes. - Cleaned up obsolete/extraneous files to reflect new skill structure.","fileCount":356,"zipByteSize":3518892},{"version":"4.0.0","createdAt":"2026-09-02T09:04:44.134Z","changelog":"**Major update: Overhauled skill structure and routing for clearer modularity and improved feature separation.** - Split core features into specialized sub-skills/packages: disclosure, search, reading, exam-policy briefing, and OA response. - New dedicated SKILL.md files for each function; routing layer guides to the correct sub-skill by user intent. - Disclosure, bibliographic search, patent reading, policy briefs, and office-action support now modular and triggered only by explicit user requests. - Revised directory structure: all prompts, tools, and outputs organized by function for clarity and future extension. - Updated environment and execution instructions for consistency across platforms and stable script invocation. - Significantly updated documentation to reflect these structural and behavioral changes.","fileCount":187,"zipByteSize":1339992},{"version":"3.9.0","createdAt":"2026-08-28T01:26:12.447Z","changelog":"- 新增 OA 审查答复支持经验手册/实务书自动抽取与“book-to-skill”辅助，入口扩展至手册沉淀与策略蒸馏。 - 增加 oa/ingest_playbook.md、oa_playbook.schema.yaml 及相关 Python 工具，实现实务手册入库与结构化标签/schema 支持。 - 查新（prior art search）提升为“两段式”：先关键词检索分类号（IPC/LOC），再二轮同分类精准查新，补足不足项自动优化检索流程。 - 命令参数说明等多处细节修正：中英文增强与“经验手册”入口说明，OA 功能默认需复核草稿。","fileCount":167,"zipByteSize":1288196},{"version":"3.7.0","createdAt":"2026-08-26T08:44:32.443Z","changelog":"Version 3.7.0 - 实用结构线稿新增独立拼装模块，支持部件子SVG分文件、总图引用和件号叠加（prompts/shared/structure_lineart_compose.md，tools/shared/structure_lineart_compose.py，schemas/structure_lineart_compose.schema.yaml）。 - 实用结构线稿描述、原理和流程全面更新，SOP细化，现强制分SVG部件，避免整体base64嵌入。 - 工具与流程文档同步完善，交底图示、线稿门禁与拼装逻辑更明确。","fileCount":162,"zipByteSize":1264787},{"version":"3.6.0","createdAt":"2026-08-18T07:15:56.372Z","changelog":"**Mandatory lineart generation for all patent disclosure outputs; improved CAD/STEP handling; expanded toolchain.** - 线稿（lineart）为外观和实用新型交底书必做环节，自动规划并生图，CAD 投影/截图明确不得当线稿入文。 - 外观线稿与干净实拍须同时入文与交底 Word 文件；仅用户明确拒绝或环境变量设置时可跳过线稿生图。 - 实用结构线稿推荐叠加精确引出线锚点（overlay），严格对齐部件名并有轮次校对流程，禁止件号二次生图。 - CAD/STEP 流程拆分，交底成果落盘后才提示进一步开启解析，环境自动判断、免强制指定 Python 版本，禁止为 CAD 安装 matplotlib。 - 新增和优化工具链：通用 image_gen、SVG 截图、cad_venv 环境工具、结构引出线叠标","fileCount":157,"zipByteSize":1233228},{"version":"3.5.0","createdAt":"2026-08-15T14:17:52.396Z","changelog":"Version 3.5.0 - Reorganized and clarified directory structure; removed legacy docs and non-essential images. - Added foundational data assets for glossary, exam opinions, and patents in `assets/obsidian/`. - Introduced new shared tooling for chemistry/formula/unit processing and UTF-8 stdio support. - Enabled browser-based rendering for diagrams with Playwright integration and bundled `mermaid.min.js`. - Updated routing: skills for policy sniffing and office action now require explicit user trigger. - Expanded and clarified Windows/PowerShell error handling guidance for subprocess tools.","fileCount":147,"zipByteSize":1205130},{"version":"3.4.0","createdAt":"2026-08-11T09:18:28.505Z","changelog":"Version 3.4.0 introduces major modularization, adds policy/office-action modules, and enhances file organization. - Refactored the skill into fully modular single-responsibility components (prompts/disclosure, reader, shared, evolution, oa). - Added new routers and prompts for policy/evolution tracking (mode C) and office action/case library support (mode D); these are opt-in and do not run by default. - Introduced explicit directories and type-specific flows for invention, utility model, and design disclosures. - Enhanced support and guidance for design/utility lineart, CAD/STEP integration, and workflow guardrails. - Obsidian vault and patent reader functions improved with updated setup guides and file mapping. - Documentation and references expanded, with user-facing and internal guides reorganized for clarity.","fileCount":147,"zipByteSize":3339066},{"version":"2.0.0","createdAt":"2026-07-24T10:02:53.553Z","changelog":"2.0.0 adds patent plain-language reading and Obsidian graph tools, expands all workflows. - 新增专利通俗解读模式：直接读懂已有专利，自动生成叙事笔记与 Obsidian Canvas 知识图谱，辅助公开线索抓取","fileCount":68,"zipByteSize":247713}]},"execution":{"evidence":{"source":"CLAWHUB","verified":false,"confidence":"low","updatedAt":null,"emptyReason":"No published capability contract is available yet."},"installCommand":"clawhub skill install s17cne95kry5y91xh399564e9584ejmf:patent-disclosure-skill","setupComplexity":"low","setupSteps":["Install using `clawhub skill install s17cne95kry5y91xh399564e9584ejmf:patent-disclosure-skill` in an isolated environment before connecting it to live workloads.","No published capability contract is available yet, so validate auth and request/response behavior manually.","Review the upstream CLAWHUB listing at https://clawhub.ai/handsomestwei/patent-disclosure-skill before using production credentials."],"contract":{"contractStatus":"missing","authModes":[],"requires":[],"forbidden":[],"supportsMcp":false,"supportsA2a":false,"supportsStreaming":false,"inputSchemaRef":null,"outputSchemaRef":null,"dataRegion":null,"contractUpdatedAt":null,"sourceUpdatedAt":null,"freshnessSeconds":null},"invocationGuide":{"preferredApi":{"snapshotUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/snapshot","contractUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/contract","trustUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/trust"},"curlExamples":["curl -s \"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/snapshot\"","curl -s \"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/contract\"","curl -s \"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/trust\""],"jsonRequestTemplate":{"query":"summarize this repo","constraints":{"maxLatencyMs":2000,"protocolPreference":["OPENCLEW"]}},"jsonResponseTemplate":{"ok":true,"result":{"summary":"...","confidence":0.9},"meta":{"source":"CLAWHUB","generatedAt":"2026-10-09T19:09:22.682Z"}},"retryPolicy":{"maxAttempts":3,"backoffMs":[500,1500,3500],"retryableConditions":["HTTP_429","HTTP_503","NETWORK_TIMEOUT"]}},"endpoints":{"dossierUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/dossier","snapshotUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/snapshot","contractUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/contract","trustUrl":"https://www.xpersona.co/api/v1/agents/clawhub-handsomestwei-patent-disclosure-skill/trust"}},"reliability":{"evidence":{"source":"runtime-metrics","verified":false,"confidence":"low","updatedAt":null,"emptyReason":"No trust, reliability, or runtime telemetry is available."},"trust":{"status":"unavailable","handshakeStatus":"UNKNOWN","verificationFreshnessHours":null,"reputationScore":null,"p95LatencyMs":null,"successRate30d":null,"fallbackRate":null,"attempts30d":null,"trustUpdatedAt":null,"trustConfidence":"unknown","sourceUpdatedAt":null,"freshnessSeconds":null},"decisionGuardrails":{"doNotUseIf":["Contract metadata is missing or unavailable for deterministic execution."],"safeUseWhen":[],"riskFlags":["missing_or_unavailable_contract","trust_data_unavailable","schema_references_missing"],"operationalConfidence":"low"},"executionMetrics":{"observedLatencyMsP50":null,"observedLatencyMsP95":null,"estimatedCostUsd":null,"uptime30d":null,"rateLimitRpm":null,"rateLimitBurst":null,"lastVerifiedAt":null,"verificationSource":null},"runtimeMetrics":{"successRate":null,"avgLatencyMs":null,"avgCostUsd":null,"hallucinationRate":null,"retryRate":null,"disputeRate":null,"p50Latency":null,"p95Latency":null,"lastUpdated":null}},"benchmarks":{"evidence":{"source":"no-benchmark-data","verified":false,"confidence":"low","updatedAt":null,"emptyReason":"No benchmark suites or observed failure patterns are available."},"suites":[],"failurePatterns":[]},"artifacts":{"evidence":{"source":"CLAWHUB","verified":false,"confidence":"medium","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":null},"readme":"Skill: 中国专利.Skill\n\nOwner: handsomestwei\n\nSummary: 中国专利技能：挖掘专利点与编写交底书（发明/实用/外观），把已有交底改写成申请文件四件套，也可按材料交底申请一起做，按著录字段检索公布公告，通俗解读专利，对照审查口径出政策简报，辅助审查答复。| China patents skill: mine patent points and draft disclosures, rewrite an existing disclosure into application documents, or chain disclosure-then-application from inventor materials in one pass (ask wh\n\nTags: latest:4.5.0\n\nVersion history:\n\nv4.5.0 | 2026-09-07T08:12:06.771Z | user\n\nMajor update: Adds support for patent application drafting and full-chain docketing.\n\n- Introduced the new \"申请文件\" (patent-application) subskill for generating formal application documents (claims/spec/abstract/figures) from an existing disclosure.\n- Added the \"案卷\" (docket) subskill to chain disclosure drafting and application writing in a single workflow, with up to three issue-list refinement rounds.\n- Strictly separated cross-skill tool usage and clarified explicit user intent is required to trigger application or docketing workflows.\n- Enhanced routing logic and documentation to reflect new subskills, required inputs, and expanded outputs directory (including `outputs/patent-application/` and `outputs/docket/`).\n- Updated and expanded prompts, schemas, references, and tests for patent-application processes.\n- Cleaned up obsolete/extraneous files to reflect new skill structure.\n\nv4.0.0 | 2026-09-02T09:04:44.134Z | user\n\n**Major update: Overhauled skill structure and routing for clearer modularity and improved feature separation.**\n\n- Split core features into specialized sub-skills/packages: disclosure, search, reading, exam-policy briefing, and OA response.\n- New dedicated SKILL.md files for each function; routing layer guides to the correct sub-skill by user intent.\n- Disclosure, bibliographic search, patent reading, policy briefs, and office-action support now modular and triggered only by explicit user requests.\n- Revised directory structure: all prompts, tools, and outputs organized by function for clarity and future extension.\n- Updated environment and execution instructions for consistency across platforms and stable script invocation.\n- Significantly updated documentation to reflect these structural and behavioral changes.\n\nv3.9.0 | 2026-08-28T01:26:12.447Z | user\n\n- 新增 OA 审查答复支持经验手册/实务书自动抽取与“book-to-skill”辅助，入口扩展至手册沉淀与策略蒸馏。\n- 增加 oa/ingest_playbook.md、oa_playbook.schema.yaml 及相关 Python 工具，实现实务手册入库与结构化标签/schema 支持。\n- 查新（prior art search）提升为“两段式”：先关键词检索分类号（IPC/LOC），再二轮同分类精准查新，补足不足项自动优化检索流程。\n- 命令参数说明等多处细节修正：中英文增强与“经验手册”入口说明，OA 功能默认需复核草稿。\n\nv3.7.0 | 2026-08-26T08:44:32.443Z | user\n\nVersion 3.7.0\n\n- 实用结构线稿新增独立拼装模块，支持部件子SVG分文件、总图引用和件号叠加（prompts/shared/structure_lineart_compose.md，tools/shared/structure_lineart_compose.py，schemas/structure_lineart_compose.schema.yaml）。\n- 实用结构线稿描述、原理和流程全面更新，SOP细化，现强制分SVG部件，避免整体base64嵌入。\n- 工具与流程文档同步完善，交底图示、线稿门禁与拼装逻辑更明确。\n\nv3.6.0 | 2026-08-18T07:15:56.372Z | user\n\n**Mandatory lineart generation for all patent disclosure outputs; improved CAD/STEP handling; expanded toolchain.**\n\n- 线稿（lineart）为外观和实用新型交底书必做环节，自动规划并生图，CAD 投影/截图明确不得当线稿入文。\n- 外观线稿与干净实拍须同时入文与交底 Word 文件；仅用户明确拒绝或环境变量设置时可跳过线稿生图。\n- 实用结构线稿推荐叠加精确引出线锚点（overlay），严格对齐部件名并有轮次校对流程，禁止件号二次生图。\n- CAD/STEP 流程拆分，交底成果落盘后才提示进一步开启解析，环境自动判断、免强制指定 Python 版本，禁止为 CAD 安装 matplotlib。\n- 新增和优化工具链：通用 image_gen、SVG 截图、cad_venv 环境工具、结构引出线叠标\n\nv3.5.0 | 2026-08-15T14:17:52.396Z | user\n\nVersion 3.5.0\n\n- Reorganized and clarified directory structure; removed legacy docs and non-essential images.\n- Added foundational data assets for glossary, exam opinions, and patents in `assets/obsidian/`.\n- Introduced new shared tooling for chemistry/formula/unit processing and UTF-8 stdio support.\n- Enabled browser-based rendering for diagrams with Playwright integration and bundled `mermaid.min.js`.\n- Updated routing: skills for policy sniffing and office action now require explicit user trigger.\n- Expanded and clarified Windows/PowerShell error handling guidance for subprocess tools.\n\nv3.4.0 | 2026-08-11T09:18:28.505Z | user\n\nVersion 3.4.0 introduces major modularization, adds policy/office-action modules, and enhances file organization.\n\n- Refactored the skill into fully modular single-responsibility components (prompts/disclosure, reader, shared, evolution, oa).\n- Added new routers and prompts for policy/evolution tracking (mode C) and office action/case library support (mode D); these are opt-in and do not run by default.\n- Introduced explicit directories and type-specific flows for invention, utility model, and design disclosures.\n- Enhanced support and guidance for design/utility lineart, CAD/STEP integration, and workflow guardrails. \n- Obsidian vault and patent reader functions improved with updated setup guides and file mapping.\n- Documentation and references expanded, with user-facing and internal guides reorganized for clarity.\n\nv2.0.0 | 2026-07-24T10:02:53.553Z | user\n\n2.0.0 adds patent plain-language reading and Obsidian graph tools, expands all workflows.\n\n- 新增专利通俗解读模式：直接读懂已有专利，自动生成叙事笔记与 Obsidian Canvas 知识图谱，辅助公开线索抓取\n\nv1.9.0 | 2026-07-15T08:20:42.631Z | user\n\nVersion 1.9.0\n\n- 优化：查询结果就绪判定\n- 优化：源链接澄清\n\nv1.8.9 | 2026-05-28T02:51:56.603Z | user\n\n- Added new tool: `tools/math_render.py` for handling mathematical formula rendering.\n- Updated SKILL.md:\n  - Main process now references Section §7.7 \"符号与公式体例\" for symbol and formula conventions.\n  - In Agent checklist, added requirements for formula symbol table (§3.4.1), standardized LaTeX delimiters, consistent symbol usage (3.5), and formula correctness review per §8.2 of `disclosure_self_check.md`.\n- Improves accuracy and consistency for mathematical formulas and symbols in patent disclosures.\n\nv1.8.7 | 2026-05-23T09:46:56.249Z | user\n\nVersion 1.8.7\n\n- 增加权利要求偏向点交互\n\nv1.8.4 | 2026-04-21T07:31:52.592Z | user\n\nVersion 1.8.5\n\n- 关键字检索拆分成多轮单个单词，避免子agent被超时自动关闭；\n- 增强图片生成像素；\n- 优化图片插入\n\nv1.8.3 | 2026-04-16T02:58:02.915Z | user\n\n- 引入了中国专利公布公告查新专用工具：新增 cnipa_epub_search.py 等，支持自动拉取及解析专利要点摘要\n- 查新流程更新：明确要求优先通过 cnipa_epub_search.py 获取摘要并理解后填写专利区别点，异常才降级 WebSearch\n- 工具依赖调整：tools 目录下新增 requirements-cnipa.txt，需单独安装\n- 主流程和自用清单同步强化中国专利查新的处理规范\n\nv1.8.1 | 2026-04-08T06:51:42.640Z | user\n\nVersion 1.8.1\n\n-  技能描述精简\n\nv1.8.0 | 2026-04-08T06:13:04.954Z | auto\n\nVersion 1.8.0 of patent-disclosure-skill\n\n- **Enhanced documentation:** SKILL.md extensively reorganized and expanded to clarify the full end-to-end process for patent mining and disclosure drafting.\n- **Stepwise workflow details:** Now includes precise mapped steps, prompt files, and tool/script usage for each process phase, especially Office document handling.\n- **Improved iteration protocol:** Clearly explains iteration triggers, naming conventions with timestamps, and document versioning so drafts are not overwritten.\n- **Mermaid diagram workflow:** Mandates default PNG rendering for system/process diagrams in Word export and fallback handling for mermaid errors.\n- **Explicit compliance checklist:** Adds a comprehensive agent workflow checklist for consistency and document quality assurance.\n- **Tool integration notes:** Specifies priority and fallback for Office extraction tools, and clarifies handling when using external skills (e.g., MiniMax).\n\nArchive index:\n\nArchive v4.5.0: 356 files, 3518892 bytes\n\nFiles: INSTALL.md (14202b), README.md (9447b), requirements.txt (1138b), skill-card.md (3201b), SKILL.md (6991b), skills/patent-application/prompts/claim_strategy.md (1803b), skills/patent-application/prompts/claims_builder.md (1946b), skills/patent-application/prompts/consistency.md (1701b), skills/patent-application/prompts/design_application.md (2026b), skills/patent-application/prompts/figures.md (3164b), skills/patent-application/prompts/guardrails.md (3600b), skills/patent-application/prompts/intake.md (929b), skills/patent-application/prompts/issues.md (1862b), skills/patent-application/prompts/iteration_context.md (663b), skills/patent-application/prompts/iteration.md (2075b), skills/patent-application/prompts/material_gate.md (740b), skills/patent-application/prompts/numeral_register.md (875b), skills/patent-application/prompts/self_check.md (2056b), skills/patent-application/prompts/specification_builder.md (5669b), skills/patent-application/README.md (1329b), skills/patent-application/references/design_view_cnipa.md (2826b), skills/patent-application/references/disclosure_to_spec_map.md (1941b), skills/patent-application/references/promo_terms.yaml (2465b), skills/patent-application/references/schemas/application_plan.schema.yaml (1978b), skills/patent-application/references/schemas/invention_figures.schema.yaml (1974b), skills/patent-application/references/schemas/numeral_register.schema.yaml (859b), skills/patent-application/references/schemas/README.md (533b), skills/patent-application/SKILL.md (2144b), skills/patent-application/tests/test_audit_claims.py (3072b), skills/patent-application/tests/test_invention_figures.py (8769b), skills/patent-application/tests/test_lexicon.py (1478b), skills/patent-application/tests/test_material_gate.py (4259b), skills/patent-application/tests/test_math_to_omml.py (748b), skills/patent-application/tests/test_numeral_register.py (2881b), skills/patent-application/tests/test_support_and_antecedent.py (3971b), skills/patent-application/tools/__init__.py (72b), skills/patent-application/tools/audit_claims.py (8012b), skills/patent-application/tools/check_numeral_register.py (10861b), skills/patent-application/tools/check_support.py (8906b), skills/patent-application/tools/compose_application_figure.py (4882b), skills/patent-application/tools/emit_application_docx.py (1928b), skills/patent-application/tools/iteration_dialog_log.py (2660b), skills/patent-application/tools/lexicon.py (1100b), skills/patent-application/tools/material_gate.py (10384b), skills/patent-application/tools/math_to_omml.py (9648b), skills/patent-application/tools/md_to_docx.py (44807b), skills/patent-application/tools/README.md (1696b), skills/patent-application/tools/render_invention_figures.py (23085b), skills/patent-application/tools/stdio_utf8.py (1394b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/docs/architecture.md (2159b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/docs/README.md (1112b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/docs/sample_architecture_review.docx (38804b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/docs/sample_assets/sample_fig_modules.png (2540b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/docs/sample_assets/sample_fig_queue.png (1741b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/docs/sample_scheduler_deck.pptx (33772b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/meeting_notes_intake_example.md (731b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/pkg/scheduler/heartbeat.go (553b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/pkg/scheduler/reorder.go (1404b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/pkg/scheduler/scorer.go (497b), skills/patent-disclosure/examples/example_batch_job_scheduler/knowledge/pkg/scheduler/types.go (866b), skills/patent-disclosure/examples/example_batch_job_scheduler/README.md (578b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/assets/mi_desk_lamp_pro.jpg (172356b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/assets/view_arm_detail.jpg (106834b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/assets/view_joint_detail.jpg (102831b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/assets/view_packaging.jpg (971022b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/assets/view_perspective.jpg (200635b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/assets/views_ortho.jpg (165793b), skills/patent-disclosure/examples/example_design_desk_lamp/knowledge/docs/design_brief.md (785b), skills/patent-disclosure/examples/example_design_desk_lamp/README.md (3352b), skills/patent-disclosure/examples/example_utility_model_ev_powertrain/knowledge/assets/photo_motor_pcu.jpg (126182b), skills/patent-disclosure/examples/example_utility_model_ev_powertrain/knowledge/docs/structure_brief.md (10484b), skills/patent-disclosure/examples/example_utility_model_ev_powertrain/README.md (3813b), skills/patent-disclosure/examples/README.md (668b), skills/patent-disclosure/prompts/correction_handler.md (4585b), skills/patent-disclosure/prompts/design_lineart_assist.md (5587b), skills/patent-disclosure/prompts/design/disclosure_builder.md (4928b), skills/patent-disclosure/prompts/design/patent_points.md (3103b), skills/patent-disclosure/prompts/design/template_reference.md (2083b), skills/patent-disclosure/prompts/disclosure_preview.md (2514b), skills/patent-disclosure/prompts/disclosure_self_check.md (13748b)\n\nFile v4.5.0:SKILL.md\n\n---\nname: patent-disclosure-skill\ndescription: \"中国专利技能：挖掘专利点与编写交底书（发明/实用/外观），把已有交底改写成申请文件四件套，也可按材料交底申请一起做，按著录字段检索公布公告，通俗解读专利，对照审查口径出政策简报，辅助审查答复。| China patents skill: mine patent points and draft disclosures, rewrite an existing disclosure into application documents, or chain disclosure-then-application from inventor materials in one pass (ask when facts are missing; at most three issue-list rounds), search CNIPA bibliographic records, explain patents, brief examination-policy changes, and assist office-action responses.\"\nversion: \"4.5.0\"\nuser-invocable: true\nargument-hint: \"[可选：项目路径 / 交底书 / 申请底稿 / 交底申请一起做 / 专利检索 / 专利号或 PDF / 政策简报 / 审查答复]\"\nallowed-tools: Read, Write, Edit, Grep, Glob, WebSearch, Bash\n---\n\n# 中国专利技能\n\n按用户意图 **`Read`** 对应入口的 `SKILL.md`，再按该流程执行。\n\n| 能力 | 做什么 | 何时进入 | 入口 |\n|------|--------|----------|------|\n| **交底** | 挖专利点 → 查新 → 成稿 → 迭代 | 专利挖掘、交底书、查新、实用新型、外观设计；`/patent-disclosure`、`/交底书` | `skills/patent-disclosure/SKILL.md` |\n| **申请文件** | 已有交底 → 权要 / 说明书 / 摘要 / 附图 | **须显式**且**指定交底目录**：申请文件、申请底稿、申报材料、`/申请底稿`、`/patent-apply`。仅缺材料则终止；内容争议写入问题清单；交付末尾须摘要清单；改已有产出则另存 | `skills/patent-application/SKILL.md` |\n| **案卷** | 按发明人/工程师给的材料一趟写出交底书和申请文件；清单缺口最多来回三轮，缺事实问人、不编 | **须显式**：交底申请一起做、从零出交底和申请、一条龙、帮写交底再出申请、按清单改、会稿、案卷、`/patent-docket`。只写交底或已有交底只出四件套 → 不要进本案。状态 `outputs/docket/` | `skills/patent-docket/SKILL.md` |\n| **检索** | 公布站高级查询（发明人/申请人/分类号/名称/摘要等）；单图或权要可先抽关键字再查 | 按著录字段查公布公告、个人公开清单、以图/权要生成检索式；`/patent-search`。普通多条件**不要**默认翻完全部分页 | `skills/patent-search/SKILL.md` |\n| **解读** | 公开号 / PDF / 全文 → 通俗笔记 + 图谱 | 读专利、公开号或 PDF 且目标为理解；`/patent-read`、`/读专利` | `skills/patent-reader/SKILL.md` |\n| **审查答复** | 审查意见问答与草稿；库薄时引导入库/蒸馏 | **须显式**：审查意见、OA、案例入库、实务书、`/oa` | `skills/patent-oa/SKILL.md` |\n| **政策简报** | 对照国知局口径，说明对交底写法/本稿的影响；改技能仅为旁路 | **须显式**：政策简报、政策雷达、`/政策简报`、`/patent-brief`、`/patent-exam-policy`。「技能进化 / `/patent-evolve`」同一入口，仍先出简报 | `skills/patent-exam-policy/SKILL.md` |\n\n## 路由\n\n- 填表、线稿、CAD、公式、Word 出图在交底包 `prompts/` 与 `tools/`；解读填表用解读包 `prompts/fill_*`；过 WAF 的 `browser.py`、Markdown 转 Word 的 `md_to_docx.py` **各包自带副本**。\n- **禁止跨包调用**其他子技能的 `tools/`。需要同一能力就用本包副本。\n- 专利号或 PDF 且意图为「读懂」→ **优先解读**，不跑交底 Step 1–8。\n- **禁止**因写交底或读专利自动进入政策简报、审查答复、申请文件或案卷。申请文件必须用户点名并给出交底目录；缺 schema / 线稿 / 交底书则停，引导先补交底。内容争议不阻塞主文件。\n- **案卷**必须用户点名（交底申请一起做 / 从零出交底和申请 / 一条龙 / 帮写交底再出申请 / 按清单改 / 会稿 / `/patent-docket`）。点名后 `Read` `skills/patent-docket/SKILL.md`；由案卷再 `Read` 交底或申请入口。调度申请视为已点名申请文件，仍须有交底目录。只写交底、或已有交底只出四件套 → 不要进案卷。\n- 交底 Step 5 查新只用交底包轻量检索（一词一页）；按发明人/申请人等做著录检索时只用检索包，两者不要混用。\n\n## 目录\n\n```\nSKILL.md                         # 本文件：子技能路由入口\nskills/patent-disclosure/        # 交底（含填表/线稿/CAD/公式/docx）\nskills/patent-application/       # 申请文件四件套（须显式；须指定交底目录）\nskills/patent-docket/            # 案卷：交底到申请一趟串起来（须显式）\nskills/patent-search/            # 著录检索\nskills/patent-reader/            # 解读\nskills/patent-oa/                # 审查答复\nskills/patent-exam-policy/        # 政策简报（技能进化为旁路）\n```\n\n## 环境与约定\n\n- **默认语言**：面向用户的检索清单、交底书、申请文件、案卷 TRACKER、解读和审查答复用简体中文；脚本机读前缀与 JSON 字段名保持稳定。\n- **脚本判读（尤其 Windows）**：stderr 有字 **不等于** 失败。以 **退出码 0** 和机读前缀为准：`EPUB_HITS_JSON:` / `EPUB_SEARCH_MD:` / `EPUB_SEARCH_JSON:` / `EPUB_CLASS_HINT:`、`PROBE:` / `BROWSER:`、`MERMAID:` / `DOCX:`、`APPLICATION_GATE:` / `APPLICATION_CLAIMS:` / `APPLICATION_NUMERALS:`、`DOCKET_DIR:` / `DOCKET_YAML:` / `DOCKET_OK:` / `DOCKET_ERROR:`。PowerShell 可能把 stderr 标成 `NativeCommandError`；**禁止**因此重跑安装或把查新降级 WebSearch。\n- **专利类型**：未显式指定时交底**默认发明**。\n- **脚本路径**：相对本技能仓库根（本文件所在目录）。整仓：`python skills/patent-disclosure/tools/…`。当前工作区不是本仓库时，把技能安装目录接到命令前面。单独拷走某一子包时，该包内用 `python tools/…`。不要写厂商环境变量。\n- **用户产出**：写在当前工作区 `outputs/`（解读 `outputs/patent_reader/`，检索 `outputs/patent-search/`，政策 `outputs/exam-policy/`，审查答复 `outputs/oa/`，申请文件 `outputs/patent-application/`，案卷 `outputs/docket/`），不要写到技能安装目录或 `tmp/`。调用脚本时 cwd 用工作区根；`-o` / `-w` 用上述相对路径。\n\n## 执行前核对\n\n```\n□ 已 Read 对应 skills/*/SKILL.md，未把本文件当交底/申请底稿/案卷/检索/解读正文\n□ 交底查新未调用 patent-search\n□ 著录检索未用交底一词一页结果冒充清单\n□ 政策简报 / 审查答复 / 申请文件 / 案卷仅在显式触发时进入\n□ 申请文件已指定交底目录；门禁未过未开写\n□ 案卷未写交底/申请正文；派工只 Read 对方 SKILL.md\n□ 未跨包调用其他子技能的 tools/\n□ 未把政策简报当成改技能；无点名未改交底包以外的目录\n```\n\nFile v4.5.0:skills/patent-application/SKILL.md\n\n---\nname: patent-application\ndescription: \"申请文件：把已有交底写成权利要求书、说明书、摘要与说明书附图。须指定交底目录；仅缺材料才终止。内容争议写入问题清单，不阻塞主文件。交付后对话末尾须给出清单路径并摘要条目。已有产出上改稿则另存新时间戳目录。须显式触发。\"\nuser-invocable: false\n---\n\n# 申请文件\n\n须用户点名（申请文件 / 申请底稿 / 申报材料 / 权利要求书 / `/申请底稿` / `/patent-apply`），并**指定交底材料目录**。案卷会稿（`patent-docket`）调度本包时视为已点名，仍须有交底目录。  \n缺交底书 / schema / 线稿则**终止**，引导先用交底技能补齐。内容歧义**不阻塞**：先出主文件，缺口写入 `问题清单.md`。发明人/申请人未填只记清单，不终止、不挡案卷轮次。交付后对话末尾须给出该文件路径并摘要条目（见 `issues.md`）。\n\n主交付是**四件套**（Markdown + Word + 黑白图）。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. 已有申请产出上改稿（未要求整案重写）：**`Read`** `iteration_context.md` → `iteration.md`（新时间戳目录、出 Word、问题清单），然后结束，不要再走第 3–5 步\n3. 跑 `tools/material_gate.py --case-dir <交底目录>`；退出码 2 则停\n4. 发明 / 实用新型：`claim_strategy.md` → `claims_builder.md` → `figures.md` → `specification_builder.md` → `numeral_register.md` → `consistency.md`\n5. 外观：先 `Read` `references/design_view_cnipa.md`（或交底包同文），只走 `design_application.md`；不跑 `compose_application_figure.py`\n6. 本包 `tools/emit_application_docx.py` 出 Word；**`Read`** `issues.md`，写 `问题清单.md`（不入正式文件），并在**同一条交付回复末尾**给出路径、摘要条目、请用户先看清单\n\n整仓路径：`python skills/patent-application/tools/…`。  \n产出：`outputs/patent-application/{案件标识}_{时间戳}/`。禁止跨包调用其他子技能 `tools/`。不做 TIFF，不做请求书 / 费减 / CPCNS。\n\nFile v4.5.0:skills/patent-disclosure/SKILL.md\n\n---\nname: patent-disclosure\ndescription: \"中国专利交底书：发明/实用新型/外观设计的专利点挖掘、轻量查新与成文。\"\nuser-invocable: false\n---\n\n# 交底书编写\n\n分步指令在 **`prompts/`**（本包内）。发明 / 实用新型 / 外观是**包内三个目录**，不是三个可触发技能。\n\n| 步骤 | 文件 |\n|------|------|\n| Step 1 | `prompts/intake.md` |\n| Step 2 | `prompts/project_scan.md` |\n| Step 3–4 | `prompts/invention/` · `utility_model/` · `design/` 挖点 |\n| 填表 / 线稿 | `prompts/fill_*`、`image_gen.md`、`*_lineart_*.md`；外观视图口径 `references/design_view_cnipa.md` |\n| Step 5 | `prompts/prior_art_search.md`（轻量查新，一词一页） |\n| Step 6 | `prompts/disclosure_preview.md` |\n| Step 7 | 对应类型 `disclosure_builder.md` + `template_reference.md` |\n| Step 8 | `prompts/disclosure_self_check.md` |\n| 迭代 | `iteration_context.md` / `merger.md` / `correction_handler.md` |\n\n查新工具：`tools/crawl/cnipa_epub_search.py`。整仓安装时路径为 `skills/patent-disclosure/tools/crawl/cnipa_epub_search.py`。著录检索不在本包，**禁止**当查新引擎调用。  \n交底交付后**不要**自动进入申请文件；用户点名并给出本目录后，再走 `skills/patent-application/SKILL.md`。  \n`--type` 与 intake 一致；两段式：关键词 → `EPUB_CLASS_HINT` / IPC·LOC → `--class`；不足 4 条则同分类号回补第一轮。\n\n线稿、CAD、公式、Word 出图用本包 `tools/`（`browser.py`、`mermaid_render.py`、`md_to_docx.py` 等）。\n\nFile v4.5.0:skills/patent-docket/SKILL.md\n\n---\nname: patent-docket\ndescription: \"按发明人/工程师给的材料一趟写出交底书和申请文件；申请问题清单上的缺口最多改三轮。缺技术事实就问人，不编。触发：交底申请一起做、从零出交底和申请、一条龙、帮写交底再出申请、按清单改、会稿、案卷、/patent-docket。\"\nuser-invocable: false\n---\n\n# 案卷会稿\n\n单 agent 协调者。**先 `Read` `prompts/guardrails.md`，再 `Read` `prompts/intake.md`。** 禁止跳过 intake 直接派工。\n\n本包只调度与记案卷，不写交底正文、不出四件套。派工时 **`Read`** 对方 `SKILL.md` 并按该包执行；**禁止**调用其他子技能的 `tools/`。\n\n## 加载顺序（每次进入都走）\n\n1. `prompts/guardrails.md`\n2. `prompts/intake.md`（判定 `from_zero` / `from_disclosure` / `from_application` / `resume`）\n3. 按 intake 结果只加载下列之一，不要一次读完所有 prompt：\n   - 新开或从零 → `prompts/bootstrap.md`\n   - 已有 `docket.yaml` → `prompts/resume.md`\n4. 之后按 `docket.yaml` 的 `phase` **只读**对应文件（见下表）。阶段表在 `references/phases.yaml`。\n\n| `phase` | 再读 |\n|---------|------|\n| `bootstrap_disclosure` / `wait_disclosure` / `dispatch_disclosure` | `prompts/dispatch_disclosure.md` |\n| `bootstrap_application` / `wait_application` / `dispatch_application` | `prompts/dispatch_application.md` |\n| `triage` | `prompts/triage.md` → `references/issue_taxonomy.md` |\n| `ask_human` | `prompts/ask_human.md` |\n| `round_close` | `prompts/round_close.md` |\n| `terminal_*` | `prompts/round_close.md`（只做收口陈述，不再派工） |\n\n阶段合法跳转：`references/phases.yaml`。机器校验：`tools/validate_docket.py`。tracker 落盘：`tools/emit_tracker.py`。交接只传路径：`references/handoff_contract.md`。\n\n## 轮次\n\n- 上限 **`config.yaml` 的 `max_rounds`（默认 3）**，细则 `references/max_rounds.md`。\n- 从零：首套交底 + 首套申请记为第 1 轮。\n- 之后每「分诊 → 派工 → 再出申请并核清单」加 1 轮。\n- 第 3 轮结束后必须停。\n\n## 命令\n\n```bash\npython skills/patent-docket/tools/init_docket.py --case-id 案件slug --mode from_zero\npython skills/patent-docket/tools/validate_docket.py --yaml outputs/docket/案件slug/docket.yaml\npython skills/patent-docket/tools/emit_tracker.py --yaml outputs/docket/案件slug/docket.yaml\n```\n\n案卷目录默认 **`outputs/docket/{case_id}/`**（gitignore 的 `outputs/`）。机读前缀：`DOCKET_DIR:` / `DOCKET_YAML:` / `DOCKET_OK:` / `DOCKET_ERROR:`。\n\n**不做**：审查答复、政策简报、著录检索当会稿引擎、多 agent 分发、把聊天摘要当成技术事实。\n\nFile v4.5.0:skills/patent-exam-policy/SKILL.md\n\n---\nname: patent-exam-policy\ndescription: \"给交底用的政策简报：对照国知局近期口径，说明对交底写法/本稿的影响。技能进化仅为旁路，须另点名才改文件。\"\nuser-invocable: false\n---\n\n# 政策简报（交底用）\n\n须用户点名（政策简报 / 政策雷达 / 审查政策更新 / `/政策简报` / `/patent-brief` / `/patent-exam-policy`）。  \n**默认只出简报，不改技能。** 「技能进化 / `/patent-evolve`」走同一套检索，但仍先出简报；只有用户再点名改技能时才 `Read` `apply_after_confirm.md`。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. **`Read`** `prompts/research.md`（A/B 分层种子 + 实用新型/外观/实施细则 + 相对上次增量）\n3. **`Read`** `prompts/emit_backlog.md` → `outputs/exam-policy/`（含施行日历）\n4. **仅当**用户明确要求改交底技能 → **`Read`** `prompts/apply_after_confirm.md`\n\n主题→文件：`references/topic_prompt_map.md`。信源种子：`references/sources.yaml`（A 可支撑交底口径；B 与地方预审不得单独改技能）。\n\nFile v4.5.0:skills/patent-oa/SKILL.md\n\n---\nname: patent-oa\ndescription: \"审查答复辅助：审查意见问答与草稿；库薄时引导案例入库与实务书蒸馏。须显式触发。\"\nuser-invocable: false\n---\n\n# 审查答复辅助\n\n须用户点名（审查意见 / OA / 入库 / 实务书）。草稿须复核后递交。  \n**主场景**是问和答、出意见陈述草稿；用户确认采纳后才出陈述正文 Word（本包 `tools/emit_opinion_docx.py`，禁止调用交底包）。案例入库与实务书蒸馏是让检索变准的配套。每次答复末尾按 `prompts/soft_nudge.md` 看库是否太薄（历史案或手册少于 3），再决定是否加一句引导。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. 向量可选：`prompts/configure_embedding.md` + `tools/config.py`\n3. 答复：`prompts/respond_office_action.md` + `tools/search_cases.py --pdf`\n4. 用户确认采纳：`assets/opinion_statement.md` → `tools/emit_opinion_docx.py`\n5. 入库（用户同意后）：`tools/ingest_case.py`；手册：`tools/ingest_playbook.py`\n\n依赖：`pip install -r tools/requirements-oa.txt`。\n\nFile v4.5.0:skills/patent-reader/SKILL.md\n\n---\nname: patent-reader\ndescription: \"中国专利通俗解读：公开号/PDF 成通俗笔记、图谱与 Obsidian 入库。\"\nuser-invocable: false\n---\n\n# 专利通俗解读\n\n1. **`Read`** `prompts/patent_plain_reader.md`\n2. 实用新型或外观：**`Read`** `prompts/type_hooks.md` + `prompts/fill_*`\n3. 笔记 / 自检：`obsidian_ofm_companion.md`、`patent_reader_self_check.md`\n\n工具在 **`tools/`**（本包 `extract/` · `analyze/` · `vault/`）。  \n中间产物：用户工作区 **`outputs/patent_reader/`**。PDF：`tools/extract/fetch_patent_pdf.py`；入库：`tools/vault/write_patent_obsidian_note.py`。\n\n与交底互斥：解读不跑交底 Step 1–8。\n\nFile v4.5.0:skills/patent-search/SKILL.md\n\n---\nname: patent-search\ndescription: \"中国专利公布公告著录检索：发明人、申请人、分类号、名称、摘要；也可从单图或权利要求生成名称/摘要关键字后查询。\"\nuser-invocable: false\n---\n\n# 著录检索\n\n通用公布站高级查询，不是「个人清单技能」。个人公开清单只是一种用法。\n\n**先 `Read` `prompts/patent_search.md`。** 用户给单图或权要时再 `Read` `prompts/derived_query.md`。\n\n## 默认少翻页\n\n- 阈值在 **`config.yaml`**：`max_pages`（默认 3）；`max_pages_hard`（默认 20）仅在探测不到「共 N 页」时启用。\n- `page_size` 只是探测不到「每页 N 条」时的回退，不要用它估总条数。\n- 对话里用户说「多翻几页 / 翻 5 页」→ 传 `--max-pages N`（普通检索仍受 hard 限制）；或改 `config.yaml`。\n- **不要**一上来爬完全部分页。只有用户明确要求穷举清单时才加 `--complete`。\n- `--complete` 第一页若读到「共 N 页」，按总页数翻完（硬上限随总页数）；读不到才用 `max_pages_hard`。\n- 采到总页数才能说「已翻完全部分页」或「还剩 x 页」；没采到只谈还能不能点「下页」。\n- `complete: false` 时禁止称为「全部」。退出码 `3` 表示分页不完整。\n\n## 命令\n\n```bash\npython skills/patent-search/tools/cnipa_search.py --inventor \"姓名\" --applicant \"单位\"\npython skills/patent-search/tools/cnipa_search.py --title \"数据处理\" --abstract \"吸附 and 再生\" --class B01J20 --max-pages 2\npython skills/patent-search/tools/cnipa_search.py --abstract \"折叠 and 杯盖\" --type design --derived-from image --type-inferred --derived-note \"折叠杯盖\"\npython skills/patent-search/tools/cnipa_search.py --inventor \"姓名\" --complete\n```\n\n单图必须 `--type design|utility_model|invention`，不能 `all`。用户没说类型时看图推断并加 `--type-inferred`。权要按文本选类型，可用 `all`。\n\n单独拷走本包时：`python tools/cnipa_search.py …`。\n\n结果默认落到 **`outputs/patent-search/SEARCH-YYYYMMDD-HHMMSS.md`**（gitignore）。改版式只动 `tools/emit_search_report.py`。\n\n机读前缀：`EPUB_SEARCH_MD:` / `EPUB_SEARCH_JSON:` / `EPUB_SEARCH_NOTE:` / `EPUB_SEARCH_INCOMPLETE:`。对话里告诉用户 Markdown 路径，不要只倒 JSON。\n\n必须走高级查询字段（`#e72` 发明人、`#ti` 名称、`#abs` 摘要/简要说明、`#e51` 分类号等），禁止把发明人姓名填进首页综合框代替。申请号填表前去掉校验点。\n\n**不做**：Google Patents / 学术检索与跨库去重、PSS 登录站、权利要求全文/同族深挖、按附图视觉相似检索、按权利要求语义检索。单图/权要只生成公布站布尔式。  \n**禁止**被交底 Step 5 当查新引擎调用。\n\nFile v4.5.0:README.md\n\n<div align=\"center\">\n\n# 中国专利.skill\n\n> 专利点挖掘与交底书（发明/实用/外观）编写，已有交底改写成申请文件，交底到申请可以一起做，公布公告著录检索，通俗解读专利，对照审查口径出政策简报，辅助审查答复。\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n[![Python 3.9+](https://img.shields.io/badge/Python-3.9%2B-blue.svg)](https://www.python.org/)\n[![Playwright](https://img.shields.io/badge/Playwright-mermaid%20%2B%20CNIPA-2EAD33.svg)](https://playwright.dev/)\n[![AgentSkills](https://img.shields.io/badge/AgentSkills-Standard-green)](https://agentskills.io)\n\n<br>\n\n有设计文档和代码，但**专利点还没梳**？交底书要**框图 + 可改 Word**？<br>\n定稿后还要**多轮补材料、纠错**并留下修改追溯？<br>\n公开专利晦涩难懂，想**快速看懂权要与落地语境**？\n\n[初衷](#初衷) · [运行效果](#运行效果) · [子技能列表](#子技能列表) · [支持作者](#支持作者) · [参考文档](#参考文档) · [安装说明](INSTALL.md) · [技能入口](SKILL.md)\n\n</div>\n\n---\n\n## 初衷\n\n### 专利交底书编写\n\n> **做了多年核心研发，专利发明人那一栏从没写过我的名字。**\n\n代码是自己敲的，方案是自己扛的，轮到交底书却卡在「专利点怎么挖、查新怎么写、框图和 Word 怎么一次交得出去」。本技能把这一环打通：覆盖发明 / 实用新型 / 外观设计，结构图与外观图都能读懂、写进交底；从项目材料梳出可申请的点，查新、脱敏、成文、迭代另存——让真正干活的人，也能把技术贡献写进可交付的交底书里。\n\n### 专利通俗解读\n\n> **不止一篇。**\n\n公开专利常把阅读门槛抬得很高：权要绕、术语密、落地语境散落在说明书与附图里。本技能把单篇读成通俗笔记与图谱，并入库 Obsidian；依托双链、图谱、插件与 Bases 等生态，陆续解读的专利可以沉淀成**只属于自己的私有专利知识库**——权要、术语、线索与附图彼此勾连，越读越厚。再叠上 [Obsidian CLI](https://help.obsidian.md/cli) 与库内外连接能力，检索、批处理、和外部工具接力都更容易：从单篇通俗笔记，走向可检索、可关联、可继续生长的个人专利情报层，把沉睡在 PDF 里的技术细节重新点亮。库厚了之后，还能在这层之上做**专利比对、挖掘与分析**——同族对照、技术路线梳理、差异点扫描，把「读懂」推进到「用起来」。\n\n---\n\n## 运行效果\n\n### 专利交底书编写\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">初版生成<br><sub>首次落盘交付</sub></th>\n<th width=\"50%\" align=\"center\">迭代更新<br><sub>多版本并存 + 对话记录</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-初版生成.jpg\" alt=\"初版生成：outputs 目录下的时间戳交底书、mermaid 图目录等\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-迭代更新.jpg\" alt=\"迭代更新：新时间戳文件与交底书修订对话记录\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 实用新型 / 外观 · 看图与出图\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"33%\" align=\"center\">外观线稿<br><sub>从产品图自动提炼造型轮廓</sub></th>\n<th width=\"33%\" align=\"center\">实用新型线稿<br><sub>从结构图自动生成轮廓与部件序号引出</sub></th>\n<th width=\"34%\" align=\"center\">CAD 三维模型投影<br><sub>从工程模型自动提取等轴测等多视角</sub></th>\n</tr>\n<tr>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-外观专利线稿.png\" alt=\"外观辅助线稿：产品造型黑白线稿示意\" width=\"100%\" />\n</td>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-实用新型专利线稿含部件序号引出线.png\" alt=\"实用新型辅助线稿：结构线稿与部件序号引出线\" width=\"100%\" />\n</td>\n<td width=\"34%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-cad提取等轴测投影图.png\" alt=\"CAD 三维模型等轴测投影：从工程模型自动提取多视角示意\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 专利通俗解读\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">Obsidian 关系图<br><sub>知识图谱与多色节点</sub></th>\n<th width=\"50%\" align=\"center\">解读 Canvas<br><sub>叙事故事线 · 术语 · 公开线索</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-obs图谱.jpg\" alt=\"Obsidian 关系图：解读笔记、术语与 Canvas 知识图谱\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-解读.jpg\" alt=\"专利解读 Canvas：叙事、权要、术语与公开线索图谱\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 子技能列表\n\n<!-- 使用 HTML 表格：技能/名称/触发/详情按内容收紧，剩余给能力 -->\n<table width=\"100%\">\n<colgroup>\n<col width=\"1%\">\n<col width=\"1%\">\n<col>\n<col width=\"1%\">\n<col width=\"1%\">\n</colgroup>\n<thead>\n<tr>\n<th align=\"left\" nowrap width=\"1%\">技能</th>\n<th align=\"left\" nowrap width=\"1%\">名称</th>\n<th align=\"left\">能力</th>\n<th align=\"left\" nowrap width=\"1%\">触发</th>\n<th align=\"left\" nowrap width=\"1%\">详情</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-disclosure/README.md\"><code>patent-disclosure</code></a></td>\n<td nowrap width=\"1%\">交底书编写</td>\n<td>发明 / 实用新型 / 外观设计分模板成文；专利点挖掘、查新、成稿与迭代</td>\n<td nowrap width=\"1%\">「交底书」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-disclosure/README.md\">详情</a></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-application/README.md\"><code>patent-application</code></a></td>\n<td nowrap width=\"1%\">申请文件</td>\n<td>把已有交底改写成权利要求书、说明书、摘要和黑白附图</td>\n<td nowrap width=\"1%\">「申请文件」· 「申请底稿」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-application/README.md\">详情</a></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-docket/README.md\"><code>patent-docket</code></a></td>\n<td nowrap width=\"1%\">案卷会稿</td>\n<td>工程师把材料丢进来，一趟写出交底书和申请文件；清单上的问题最多来回三轮，缺事实就问、不编，少跟代理人来回对稿</td>\n<td nowrap width=\"1%\">「交底申请一起做」· 「从零出交底和申请」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-docket/README.md\">详情</a></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-reader/README.md\"><code>patent-reader</code></a></td>\n<td nowrap width=\"1%\">通俗解读</td>\n<td>公开号或 PDF 成通俗笔记、图谱与 Obsidian 入库</td>\n<td nowrap width=\"1%\">「读专利」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-reader/README.md\">详情</a></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-oa/README.md\"><code>patent-oa</code></a></td>\n<td nowrap width=\"1%\">审查答复辅助</td>\n<td>审查意见问答，输出答复稿；知识蒸馏与可选向量检索</td>\n<td nowrap width=\"1%\">「审查答复」· 「审查意见」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-oa/README.md\">详情</a></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-search/README.md\"><code>patent-search</code></a></td>\n<td nowrap width=\"1%\">著录检索</td>\n<td>按发明人、申请人、分类号、名称或摘要检索公布公告；也可从单图或权要生成检索式</td>\n<td nowrap width=\"1%\">「著录检索」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-search/README.md\">详情</a></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\"><a href=\"skills/patent-exam-policy/README.md\"><code>patent-exam-policy</code></a></td>\n<td nowrap width=\"1%\">政策简报</td>\n<td>对照国知局近期口径，输出政策解读报告，整理对交底写法的影响；可选技能进化</td>\n<td nowrap width=\"1%\">「政策简报」· 「政策雷达」</td>\n<td nowrap width=\"1%\"><a href=\"skills/patent-exam-policy/README.md\">详情</a></td>\n</tr>\n</tbody>\n</table>\n\n---\n\n## 支持作者\n\n如果这个 Skill 对您有帮助，可以请我喝杯咖啡☕随缘支持，感谢感谢🙏🙏\n\n<table width=\"70%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"40%\" align=\"center\">随缘支持</th>\n<th width=\"60%\" align=\"center\">Star History</th>\n</tr>\n<tr>\n<td width=\"40%\" valign=\"middle\" align=\"center\">\n<img src=\"docs/thanks.jpg\" alt=\"随缘支持\" width=\"200\" />\n</td>\n<td width=\"60%\" valign=\"middle\" align=\"center\">\n<img alt=\"Star History Chart\" src=\"https://raw.githubusercontent.com/handsomestWei/patent-disclosure-skill/star-history/star-history.svg\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 参考文档\n\n- [技能入口与 Agent 流程](SKILL.md)（交底 / 申请文件 / 案卷会稿 / 著录检索 / 解读 / 政策简报 / 审查答复）\n- [详细安装说明](INSTALL.md)\n- [Obsidian 安装与可选社区插件（Windows）](skills/patent-reader/docs/obsidian-setup-guide.md)\n\n---\n\n<div align=\"center\">\n\nMIT License © [handsomestWei](https://github.com/handsomestWei/)\n\n</div>\n\nFile v4.5.0:skills/patent-application/README.md\n\n# 专利申请文件\n\n把已有交底改写成申请文件；须**点名**并给出**交底产出目录**。\n<!-- 使用 HTML 表格：避免 GitHub 管道表把左列挤窄 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>专利类型</strong></td><td>发明 / 实用新型出权利要求书、说明书、摘要和黑白附图；外观走外观申请文件</td></tr>\n<tr><td nowrap width=\"1%\"><strong>交底材料</strong></td><td>须指定交底产出目录；缺交底书 / schema / 线稿则终止，引导先补交底</td></tr>\n<tr><td nowrap width=\"1%\"><strong>权利要求</strong></td><td>从属按层展开并与实施例对照</td></tr>\n<tr><td nowrap width=\"1%\"><strong>申请文件成稿</strong></td><td>四件套（Markdown + Word + 黑白图）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>问题清单</strong></td><td>内容争议写入问题清单，不阻塞主文件；交付末尾提醒</td></tr>\n<tr><td nowrap width=\"1%\"><strong>迭代</strong></td><td>已有产出上改稿则另存新时间戳目录</td></tr>\n</tbody>\n</table>\n\n使用示例：「申请文件，交底在 outputs/…」——指向已交付的 `outputs/{案件标识}/`材料目录。\n\nFile v4.5.0:skills/patent-application/references/schemas/README.md\n\n# 申请文件合同\n\n| 文件 | 用途 |\n|------|------|\n| `application_plan.schema.yaml` | 内部策略备忘（含从属树、点名图） |\n| `numeral_register.schema.yaml` | 件号 / 模块标记登记 |\n| `invention_figures.schema.yaml` | 发明框图、流程图、点名 `source_image` |\n| `../design_view_cnipa.md` | 外观视图核查清单（与交底包同文；不改原图） |\n\n词库（非合同）：`../promo_terms.yaml`，权要与摘要宣传语检查共用。\n\n交底侧 schema 仍在交底包，本包只读。\n\nFile v4.5.0:skills/patent-application/tools/README.md\n\n# 申请文件工具\n\n| 脚本 | 前缀 | 退出码 |\n|------|------|--------|\n| `material_gate.py` | `APPLICATION_GATE:` | 0 齐全；2 缺材料；1 用法错误 |\n| `audit_claims.py` | `APPLICATION_CLAIMS:` | 0 无 ERROR；1 有 ERROR |\n| `check_numeral_register.py` | `APPLICATION_NUMERALS:` | 0 无 ERROR；1 有 ERROR |\n| `render_invention_figures.py` | `APPLICATION_FIG:` | 0 已出 SVG；PNG 失败不单独当致命（看 png_fail） |\n| `check_support.py` | `APPLICATION_SUPPORT:` | 0 无 ERROR；1 有 ERROR |\n| `compose_application_figure.py` | `APPLICATION_FIG:` | 0 已出 SVG（PNG 看 png=）；**仅实用新型 / 发明点名图**；外观禁用 |\n| `iteration_dialog_log.py` | `LOG_FILE=` | 0 已追加 |\n| `emit_application_docx.py` | `DOCX:` / `APPLICATION_DOCX:` | 0 全部写出 |\n\n```bash\npython skills/patent-application/tools/material_gate.py --case-dir outputs/{案件}\npython skills/patent-application/tools/render_invention_figures.py \\\n  --plan outputs/patent-application/{案}/figures/invention_figures.yaml \\\n  --out-dir outputs/patent-application/{案}/figures\npython skills/patent-application/tools/audit_claims.py outputs/patent-application/{案}/权利要求书.md\npython skills/patent-application/tools/check_support.py --dir outputs/patent-application/{案}\npython skills/patent-application/tools/compose_application_figure.py \\\n  --source <线稿或场景图> --fig 3 --out-dir outputs/patent-application/{案}/figures\npython skills/patent-application/tools/emit_application_docx.py --dir outputs/patent-application/{案}\n```\n\n宣传语词库：`references/promo_terms.yaml`（`lexicon.py` 加载；权要与摘要共用）。增删词条不必改脚本。\n\nArchive v4.0.0: 187 files, 1339992 bytes\n\nFiles: INSTALL.md (11954b), README.md (17422b), requirements.txt (1138b), skill-card.md (3511b), SKILL.md (4442b), skills/patent-disclosure/prompts/correction_handler.md (4299b), skills/patent-disclosure/prompts/design_lineart_assist.md (4884b), skills/patent-disclosure/prompts/design/disclosure_builder.md (4693b), skills/patent-disclosure/prompts/design/patent_points.md (3003b), skills/patent-disclosure/prompts/design/template_reference.md (1901b), skills/patent-disclosure/prompts/disclosure_preview.md (2514b), skills/patent-disclosure/prompts/disclosure_self_check.md (12851b), skills/patent-disclosure/prompts/fill_appearance_schema.md (3482b), skills/patent-disclosure/prompts/fill_structure_schema.md (4010b), skills/patent-disclosure/prompts/image_gen.md (3862b), skills/patent-disclosure/prompts/intake.md (2817b), skills/patent-disclosure/prompts/invention/disclosure_builder.md (22888b), skills/patent-disclosure/prompts/invention/patent_points_analyzer.md (1343b), skills/patent-disclosure/prompts/invention/template_reference.md (14477b), skills/patent-disclosure/prompts/iteration_context.md (5906b), skills/patent-disclosure/prompts/merger.md (5486b), skills/patent-disclosure/prompts/prior_art_search.md (15508b), skills/patent-disclosure/prompts/project_scan.md (10415b), skills/patent-disclosure/prompts/structure_lineart_assist.md (7687b), skills/patent-disclosure/prompts/structure_lineart_compose.md (5433b), skills/patent-disclosure/prompts/utility_model/disclosure_builder.md (5166b), skills/patent-disclosure/prompts/utility_model/patent_points.md (3834b), skills/patent-disclosure/prompts/utility_model/template_reference.md (1714b), skills/patent-disclosure/references/formulas/paradigms.yaml (10100b), skills/patent-disclosure/references/formulas/README.md (2204b), skills/patent-disclosure/references/patent_type_search.yaml (2913b), skills/patent-disclosure/references/schemas/appearance.schema.yaml (2202b), skills/patent-disclosure/references/schemas/design_lineart_brief.schema.yaml (2747b), skills/patent-disclosure/references/schemas/figure_plan.schema.yaml (7685b), skills/patent-disclosure/references/schemas/formula_plan.schema.yaml (2658b), skills/patent-disclosure/references/schemas/README.md (1636b), skills/patent-disclosure/references/schemas/structure_callout_anchors.schema.yaml (2338b), skills/patent-disclosure/references/schemas/structure_lineart_brief.schema.yaml (3872b), skills/patent-disclosure/references/schemas/structure_lineart_compose.schema.yaml (2952b), skills/patent-disclosure/references/schemas/structure.schema.yaml (1387b), skills/patent-disclosure/SKILL.md (1381b), skills/patent-disclosure/tools/bootstrap_cad_venv.py (6654b), skills/patent-disclosure/tools/browser.py (5099b), skills/patent-disclosure/tools/cad_formats.py (4543b), skills/patent-disclosure/tools/cad_scan.py (3080b), skills/patent-disclosure/tools/cad_venv.py (6428b), skills/patent-disclosure/tools/check_formula_plan.py (8186b), skills/patent-disclosure/tools/crawl/cnipa_epub_crawler.py (18497b), skills/patent-disclosure/tools/crawl/cnipa_epub_parse.py (19620b), skills/patent-disclosure/tools/crawl/cnipa_epub_search.py (7902b), skills/patent-disclosure/tools/crawl/requirements-cnipa.txt (249b), skills/patent-disclosure/tools/design_lineart_gate.py (9544b), skills/patent-disclosure/tools/docx_to_md.py (3834b), skills/patent-disclosure/tools/formula_chem.py (6792b), skills/patent-disclosure/tools/formula_eval.py (8793b), skills/patent-disclosure/tools/formula_paradigms.py (6012b), skills/patent-disclosure/tools/formula_units.py (3706b), skills/patent-disclosure/tools/gen_demo_snap_step.py (5140b), skills/patent-disclosure/tools/image_gen.py (9795b), skills/patent-disclosure/tools/iteration_dialog_log.py (3230b), skills/patent-disclosure/tools/latex_delimiters.py (3970b), skills/patent-disclosure/tools/math_render.py (14502b), skills/patent-disclosure/tools/math_to_omml.py (9538b), skills/patent-disclosure/tools/md_to_docx.py (45983b), skills/patent-disclosure/tools/mermaid_render.py (21569b), skills/patent-disclosure/tools/package-lock.json (86410b), skills/patent-disclosure/tools/package.json (309b), skills/patent-disclosure/tools/patent_type.py (9373b), skills/patent-disclosure/tools/pptx_to_md.py (5039b), skills/patent-disclosure/tools/README.md (20900b), skills/patent-disclosure/tools/requirements-step.txt (325b), skills/patent-disclosure/tools/run_step_to_views.py (4077b), skills/patent-disclosure/tools/stdio_utf8.py (1394b), skills/patent-disclosure/tools/step_to_views.py (18415b), skills/patent-disclosure/tools/structure_callout_overlay.py (16636b), skills/patent-disclosure/tools/structure_lineart_compose.py (24833b), skills/patent-disclosure/tools/structure_lineart_gate.py (14879b), skills/patent-disclosure/tools/svg_screenshot.py (12496b), skills/patent-disclosure/tools/vendor/mermaid.min.js (2571900b), skills/patent-disclosure/tools/vendor/README.md (450b)\n\nFile v4.0.0:SKILL.md\n\n---\nname: patent-disclosure-skill\ndescription: \"中国专利技能：挖掘专利点与编写交底书（发明/实用/外观），按著录字段检索公布公告，通俗解读专利，对照审查口径出政策简报，辅助审查答复。| China patents skill: mine patent points and draft disclosures, search CNIPA bibliographic records, explain patents, brief examination-policy changes for disclosures, and assist office-action responses.\"\nversion: \"4.0.0\"\nuser-invocable: true\nargument-hint: \"[可选：项目路径 / 交底书 / 专利检索 / 专利号或 PDF / 政策简报 / 审查答复]\"\nallowed-tools: Read, Write, Edit, Grep, Glob, WebSearch, Bash\n---\n\n# 中国专利技能\n\n按用户意图 **`Read`** 对应入口的 `SKILL.md`，再按该流程执行。\n\n| 能力 | 做什么 | 何时进入 | 入口 |\n|------|--------|----------|------|\n| **交底** | 挖专利点 → 查新 → 成稿 → 迭代 | 专利挖掘、交底书、查新、实用新型、外观设计；`/patent-disclosure-skill`、`/交底书` | `skills/patent-disclosure/SKILL.md` |\n| **检索** | 公布站高级查询（发明人/申请人/分类号/名称等） | 按著录字段查公布公告、个人公开清单；`/patent-search`。普通多条件**不要**默认翻完全部分页 | `skills/patent-search/SKILL.md` |\n| **解读** | 公开号 / PDF / 全文 → 通俗笔记 + 图谱 | 读专利、公开号或 PDF 且目标为理解；`/patent-read`、`/读专利` | `skills/patent-reader/SKILL.md` |\n| **审查答复** | 审查意见问答与草稿；库薄时引导入库/蒸馏 | **须显式**：审查意见、OA、案例入库、实务书、`/oa` | `skills/patent-oa/SKILL.md` |\n| **政策简报** | 对照国知局口径，说明对交底写法/本稿的影响；改技能仅为旁路 | **须显式**：政策简报、政策雷达、`/政策简报`、`/patent-brief`、`/patent-exam-policy`。「技能进化 / `/patent-evolve`」同一入口，仍先出简报 | `skills/patent-exam-policy/SKILL.md` |\n\n## 路由\n\n- 填表、线稿、CAD、公式、Word 出图在交底包 `prompts/` 与 `tools/`；解读填表用解读包 `prompts/fill_*`；过 WAF 的 `browser.py` 各包自带副本。\n- 专利号或 PDF 且意图为「读懂」→ **优先解读**，不跑交底 Step 1–8。\n- **禁止**因写交底或读专利自动进入政策简报或审查答复。\n- 交底 Step 5 查新只用交底包轻量检索（一词一页）；按发明人/申请人等做著录检索时只用检索包，两者不要混用。\n\n## 目录\n\n```\nSKILL.md                         # 本文件：子技能路由入口\nskills/patent-disclosure/        # 交底（含填表/线稿/CAD/公式/docx）\nskills/patent-search/            # 著录检索\nskills/patent-reader/            # 解读\nskills/patent-oa/                # 审查答复\nskills/patent-exam-policy/        # 政策简报（技能进化为旁路）\n```\n\n## 环境与约定\n\n- **默认语言**：面向用户的检索清单、交底书、解读和审查答复用简体中文；脚本机读前缀与 JSON 字段名保持稳定。\n- **脚本判读（尤其 Windows）**：stderr 有字 **不等于** 失败。以 **退出码 0** 和机读前缀为准：`EPUB_HITS_JSON:` / `EPUB_SEARCH_MD:` / `EPUB_SEARCH_JSON:` / `EPUB_CLASS_HINT:`、`PROBE:` / `BROWSER:`、`MERMAID:` / `DOCX:`。PowerShell 可能把 stderr 标成 `NativeCommandError`；**禁止**因此重跑安装或把查新降级 WebSearch。\n- **专利类型**：未显式指定时交底**默认发明**。\n- **脚本路径**：相对本技能仓库根（本文件所在目录）。整仓：`python skills/patent-disclosure/tools/…`。当前工作区不是本仓库时，把技能安装目录接到命令前面。单独拷走某一子包时，该包内用 `python tools/…`。不要写厂商环境变量。\n- **用户产出**：写在当前工作区 `outputs/`（解读 `outputs/patent_reader/`，检索 `outputs/patent-search/`，政策 `outputs/exam-policy/`），不要写到技能安装目录或 `tmp/`。调用脚本时 cwd 用工作区根；`-o` / `-w` 用上述相对路径。\n\n## 执行前核对\n\n```\n□ 已 Read 对应 skills/*/SKILL.md，未把本文件当交底/检索/解读正文\n□ 交底查新未调用 patent-search\n□ 著录检索未用交底一词一页结果冒充清单\n□ 政策简报 / 审查答复仅在显式触发时进入\n□ 未把政策简报当成改技能；无点名未改交底包以外的目录\n```\n\nFile v4.0.0:skills/patent-disclosure/SKILL.md\n\n---\nname: patent-disclosure\ndescription: \"中国专利交底书：发明/实用新型/外观设计的专利点挖掘、轻量查新与成文。\"\nuser-invocable: false\n---\n\n# 交底书编写\n\n分步指令在 **`prompts/`**（本包内）。发明 / 实用新型 / 外观是**包内三个目录**，不是三个可触发技能。\n\n| 步骤 | 文件 |\n|------|------|\n| Step 1 | `prompts/intake.md` |\n| Step 2 | `prompts/project_scan.md` |\n| Step 3–4 | `prompts/invention/` · `utility_model/` · `design/` 挖点 |\n| 填表 / 线稿 | `prompts/fill_*`、`image_gen.md`、`*_lineart_*.md` |\n| Step 5 | `prompts/prior_art_search.md`（轻量查新，一词一页） |\n| Step 6 | `prompts/disclosure_preview.md` |\n| Step 7 | 对应类型 `disclosure_builder.md` + `template_reference.md` |\n| Step 8 | `prompts/disclosure_self_check.md` |\n| 迭代 | `iteration_context.md` / `merger.md` / `correction_handler.md` |\n\n查新工具：`tools/crawl/cnipa_epub_search.py`。整仓安装时路径为 `skills/patent-disclosure/tools/crawl/cnipa_epub_search.py`。著录检索不在本包，**禁止**当查新引擎调用。  \n`--type` 与 intake 一致；两段式：关键词 → `EPUB_CLASS_HINT` / IPC·LOC → `--class`；不足 4 条则同分类号回补第一轮。\n\n线稿、CAD、公式、Word 出图用本包 `tools/`（`browser.py`、`mermaid_render.py`、`md_to_docx.py` 等）。\n\nFile v4.0.0:skills/patent-exam-policy/SKILL.md\n\n---\nname: patent-exam-policy\ndescription: \"给交底用的政策简报：对照国知局近期口径，说明对交底写法/本稿的影响。技能进化仅为旁路，须另点名才改文件。\"\nuser-invocable: false\n---\n\n# 政策简报（交底用）\n\n须用户点名（政策简报 / 政策雷达 / 审查政策更新 / `/政策简报` / `/patent-brief` / `/patent-exam-policy`）。  \n**默认只出简报，不改技能。** 「技能进化 / `/patent-evolve`」走同一套检索，但仍先出简报；只有用户再点名改技能时才 `Read` `apply_after_confirm.md`。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. **`Read`** `prompts/research.md`（A/B 分层种子 + 实用新型/外观/实施细则 + 相对上次增量）\n3. **`Read`** `prompts/emit_backlog.md` → `outputs/exam-policy/`（含施行日历）\n4. **仅当**用户明确要求改交底技能 → **`Read`** `prompts/apply_after_confirm.md`\n\n主题→文件：`references/topic_prompt_map.md`。信源种子：`references/sources.yaml`（A 可支撑交底口径；B 与地方预审不得单独改技能）。\n\nFile v4.0.0:skills/patent-oa/SKILL.md\n\n---\nname: patent-oa\ndescription: \"审查答复辅助：审查意见问答与草稿；库薄时引导案例入库与实务书蒸馏。须显式触发。\"\nuser-invocable: false\n---\n\n# 审查答复辅助\n\n须用户点名（审查意见 / OA / 入库 / 实务书）。草稿须复核后递交。  \n**主场景**是问和答、出意见陈述草稿。案例入库与实务书蒸馏是让检索变准的配套；用户未必主动想到。每次答复末尾按 `prompts/soft_nudge.md` 看库是否太薄（历史案或手册少于 3），再决定是否加一句引导。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. 向量可选：`prompts/configure_embedding.md` + `tools/config.py`\n3. 答复：`prompts/respond_office_action.md` + `tools/search_cases.py --pdf`\n4. 入库（用户同意后）：`tools/ingest_case.py`；手册：`tools/ingest_playbook.py`\n\n依赖：`pip install -r tools/requirements-oa.txt`。\n\nFile v4.0.0:skills/patent-reader/SKILL.md\n\n---\nname: patent-reader\ndescription: \"中国专利通俗解读：公开号/PDF 成通俗笔记、图谱与 Obsidian 入库。\"\nuser-invocable: false\n---\n\n# 专利通俗解读\n\n1. **`Read`** `prompts/patent_plain_reader.md`\n2. 实用新型或外观：**`Read`** `prompts/type_hooks.md` + `prompts/fill_*`\n3. 笔记 / 自检：`obsidian_ofm_companion.md`、`patent_reader_self_check.md`\n\n工具在 **`tools/`**（本包 `extract/` · `analyze/` · `vault/`）。  \n中间产物：用户工作区 **`outputs/patent_reader/`**。PDF：`tools/extract/fetch_patent_pdf.py`；入库：`tools/vault/write_patent_obsidian_note.py`。\n\n与交底互斥：解读不跑交底 Step 1–8。\n\nFile v4.0.0:skills/patent-search/SKILL.md\n\n---\nname: patent-search\ndescription: \"中国专利公布公告著录检索：发明人、申请人、分类号、名称等高级查询字段。\"\nuser-invocable: false\n---\n\n# 著录检索\n\n通用公布站高级查询，不是「个人清单技能」。个人公开清单只是一种用法。\n\n**先 `Read` `prompts/patent_search.md`。**\n\n## 默认少翻页\n\n- 阈值在 **`config.yaml`**：`max_pages`（默认 3）；`max_pages_hard`（默认 20）仅在探测不到「共 N 页」时启用。\n- `page_size` 只是探测不到「每页 N 条」时的回退，不要用它估总条数。\n- 对话里用户说「多翻几页 / 翻 5 页」→ 传 `--max-pages N`（普通检索仍受 hard 限制）；或改 `config.yaml`。\n- **不要**一上来爬完全部分页。只有用户明确要求穷举清单时才加 `--complete`。\n- `--complete` 第一页若读到「共 N 页」，按总页数翻完（硬上限随总页数）；读不到才用 `max_pages_hard`。\n- 采到总页数才能说「已翻完全部分页」或「还剩 x 页」；没采到只谈还能不能点「下页」。\n- `complete: false` 时禁止称为「全部」。退出码 `3` 表示分页不完整。\n\n## 命令\n\n```bash\npython skills/patent-search/tools/cnipa_search.py --inventor \"姓名\" --applicant \"单位\"\npython skills/patent-search/tools/cnipa_search.py --title \"数据处理\" --class B01J20 --max-pages 2\npython skills/patent-search/tools/cnipa_search.py --inventor \"姓名\" --complete\n```\n\n单独拷走本包时：`python tools/cnipa_search.py …`。\n\n结果默认落到 **`outputs/patent-search/SEARCH-YYYYMMDD-HHMMSS.md`**（gitignore）。改版式只动 `tools/emit_search_report.py`。\n\n机读前缀：`EPUB_SEARCH_MD:` / `EPUB_SEARCH_JSON:` / `EPUB_SEARCH_NOTE:` / `EPUB_SEARCH_INCOMPLETE:`。对话里告诉用户 Markdown 路径，不要只倒 JSON。\n\n必须走高级查询字段（`#e72` 发明人、`#ti` 名称、`#e51` 分类号等），禁止把发明人姓名填进首页综合框代替。申请号填表前去掉校验点。\n\n**不做**：Google Patents / 学术检索与跨库去重、PSS 登录站、权利要求全文/同族深挖。  \n**禁止**被交底 Step 5 当查新引擎调用。\n\nFile v4.0.0:README.md\n\n<div align=\"center\">\n\n# 中国专利.skill\n\n> 专利点挖掘与交底书（发明/实用/外观）编写，公布公告著录检索，通俗解读专利，对照审查口径出政策简报，辅助审查答复。\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n[![Python 3.9+](https://img.shields.io/badge/Python-3.9%2B-blue.svg)](https://www.python.org/)\n[![Playwright](https://img.shields.io/badge/Playwright-mermaid%20%2B%20CNIPA-2EAD33.svg)](https://playwright.dev/)\n[![AgentSkills](https://img.shields.io/badge/AgentSkills-Standard-green)](https://agentskills.io)\n\n<br>\n\n有设计文档和代码，但**专利点还没梳**？交底书要**框图 + 可改 Word**？<br>\n定稿后还要**多轮补材料、纠错**并留下修改追溯？<br>\n公开专利晦涩难懂，想**快速看懂权要与落地语境**？\n\n[初衷](#初衷) · [运行效果](#运行效果) · [功能特性](#功能特性) · [示例](#示例) · [支持作者](#支持作者) · [参考文档](#参考文档) · [安装说明](INSTALL.md) · [技能入口](SKILL.md)\n\n</div>\n\n---\n\n## 初衷\n\n### 专利交底书编写\n\n> **做了多年核心研发，专利发明人那一栏从没写过我的名字。**\n\n代码是自己敲的，方案是自己扛的，轮到交底书却卡在「专利点怎么挖、查新怎么写、框图和 Word 怎么一次交得出去」。本技能把这一环打通：覆盖发明 / 实用新型 / 外观设计，结构图与外观图都能读懂、写进交底；从项目材料梳出可申请的点，查新、脱敏、成文、迭代另存——让真正干活的人，也能把技术贡献写进可交付的交底书里。\n\n### 专利通俗解读\n\n> **不止一篇。**\n\n公开专利常把阅读门槛抬得很高：权要绕、术语密、落地语境散落在说明书与附图里。本技能把单篇读成通俗笔记与图谱，并入库 Obsidian；依托双链、图谱、插件与 Bases 等生态，陆续解读的专利可以沉淀成**只属于自己的私有专利知识库**——权要、术语、线索与附图彼此勾连，越读越厚。再叠上 [Obsidian CLI](https://help.obsidian.md/cli) 与库内外连接能力，检索、批处理、和外部工具接力都更容易：从单篇通俗笔记，走向可检索、可关联、可继续生长的个人专利情报层，把沉睡在 PDF 里的技术细节重新点亮。库厚了之后，还能在这层之上做**专利比对、挖掘与分析**——同族对照、技术路线梳理、差异点扫描，把「读懂」推进到「用起来」。\n\n---\n\n## 运行效果\n\n### 专利交底书编写\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">初版生成<br><sub>首次落盘交付</sub></th>\n<th width=\"50%\" align=\"center\">迭代更新<br><sub>多版本并存 + 对话记录</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-初版生成.jpg\" alt=\"初版生成：outputs 目录下的时间戳交底书、mermaid 图目录等\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-迭代更新.jpg\" alt=\"迭代更新：新时间戳文件与交底书修订对话记录\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 实用新型 / 外观 · 看图与出图\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"33%\" align=\"center\">外观线稿<br><sub>从产品图自动提炼造型轮廓</sub></th>\n<th width=\"33%\" align=\"center\">实用新型线稿<br><sub>从结构图自动生成轮廓与部件序号引出</sub></th>\n<th width=\"34%\" align=\"center\">CAD 三维模型投影<br><sub>从工程模型自动提取等轴测等多视角</sub></th>\n</tr>\n<tr>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-外观专利线稿.png\" alt=\"外观辅助线稿：产品造型黑白线稿示意\" width=\"100%\" />\n</td>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-实用新型专利线稿含部件序号引出线.png\" alt=\"实用新型辅助线稿：结构线稿与部件序号引出线\" width=\"100%\" />\n</td>\n<td width=\"34%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-cad提取等轴测投影图.png\" alt=\"CAD 三维模型等轴测投影：从工程模型自动提取多视角示意\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 专利通俗解读\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">Obsidian 关系图<br><sub>知识图谱与多色节点</sub></th>\n<th width=\"50%\" align=\"center\">解读 Canvas<br><sub>叙事故事线 · 术语 · 公开线索</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-obs图谱.jpg\" alt=\"Obsidian 关系图：解读笔记、术语与 Canvas 知识图谱\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-解读.jpg\" alt=\"专利解读 Canvas：叙事、权要、术语与公开线索图谱\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 功能特性\n\n### 专利交底书编写\n\n支持 **发明**、**实用新型**、**外观设计** 三种专利类型（未指定时默认发明；材料偏结构/外观时可反问切换）。\n面向用户的专利清单、交底书、解读和审查答复默认使用**简体中文**；用户明确要求时可切换其他语言，脚本机读字段保持兼容。\n\n<!-- 使用 HTML 表格：避免 GitHub 管道表把左列挤窄 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>专利类型</strong></td><td>发明 / 实用新型 / 外观设计<strong>分模板成文</strong>；实用与外观先填 Schema，再写 <code>figure_plan.yaml</code> 排序入文图（成文不扫全 assets 临场挑图）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>项目扫描</strong></td><td>按优先级读文档 / 代码；<code>.docx</code> / <code>.pptx</code> 先转 Markdown 再扫；可选扫描 <code>.step</code>/<code>.stp</code> 与原生 CAD（<strong>默认不解析</strong>，遇 STEP 成文不中断，交底落盘后再问）（<code>project_scan.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>外观线稿</strong></td><td>成文前选用或生成产品线稿（已有合格线稿优先，否则图生图 / 文生图）；与干净实拍一并写入 Markdown 和 Word（<code>design_lineart_assist.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>实用结构线稿</strong></td><td>成文前选用或生成结构线稿，按 <code>structure_schema.parts</code> 写出子 SVG、总图相对引用并叠部件序号（<code>structure_lineart_assist.md</code> / <code>structure_lineart_compose.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>专利点</strong></td><td>候选点讨论与融合（按类型：<code>invention|utility_model|design</code> 挖点文件）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>查新</strong></td><td><strong>优先</strong> <a href=\"http://epub.cnipa.gov.cn/\">国知局 · 中国专利公布公告</a>（<code>skills/patent-disclosure/tools/crawl/cnipa_epub_search.py</code>，<code>--type</code> 对齐类型）；异常或无果时降级 WebSearch。著录写入第一章（<code>prior_art_search.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>交底书成稿</strong></td><td>脱敏模版；发明用 <strong>mermaid</strong> 框图；实用/外观按 <code>figure_plan</code> 嵌结构图或视图；定稿可出 <strong>.docx</strong></td></tr>\n<tr><td nowrap width=\"1%\"><strong>交付命名</strong></td><td><code>{案件名}_{YYYYMMDDHHmmss}.md</code> 与同名 <code>.docx</code>（<code>disclosure_builder.md</code> §7.3）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>自检 / 迭代</strong></td><td>逻辑与公式自检（不写入正文）；合并 / 纠正另存新文件 + <code>交底书修订对话记录.md</code></td></tr>\n</tbody>\n</table>\n\n怎么开口：自然语言即可（专利挖掘、交底书、查新等），或 `/交底书`、`/patent-disclosure-skill`；尽量带上**项目路径或技术主题**，并点明类型（未指定默认**发明**）。\n\n| 类型 | 典型场景 | 触发示例 |\n|------|----------|----------|\n| **发明** | 方法 / 系统 / 算法流程 | 「按发明写交底」「项目路径 …」 |\n| **实用新型** | 形状、构造、连接与装配 | 「实用新型」「一种…装置/结构」 |\n| **外观设计** | 外形、图案、色彩或其结合 | 「外观设计」「设计说明 / 视图」 |\n\n已有交底上补材料或纠错时，按 `merger.md` / `correction_handler.md` 另存新稿（实用/外观改图或主题时同步 `figure_plan`）。细则见 [SKILL.md](SKILL.md)、`skills/patent-disclosure/prompts/intake.md`。\n\n### 专利通俗解读\n\n**强烈推荐安装 Obsidian**：索引、Canvas 知识图谱、术语网与 callout 配色依赖库内呈现，才能发挥本流程的完整体验。安装与可选社区插件见 [skills/patent-reader/docs/obsidian-setup-guide.md](skills/patent-reader/docs/obsidian-setup-guide.md)。\n\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>取证解读</strong></td><td>全文 / PDF 抽取 → 权要树、术语表、特征—说明书—附图对照（<code>patent_plain_reader.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>叙述故事线</strong></td><td>一句话总览 + 连贯叙事：把权要与说明书「讲成人话」，降低首次通读成本</td></tr>\n<tr><td nowrap width=\"1%\"><strong>知识图谱</strong></td><td>单篇 <code>*_图谱.canvas</code>、多篇 <code>_专利关联.canvas</code>、术语双链与关系图配色；入库<strong>自动</strong>配置 CSS / Bases</td></tr>\n<tr><td nowrap width=\"1%\"><strong>公开线索辅助</strong></td><td>联网检索公开材料（≤3 条）；Agent 读 URL 写摘要；L1–L4 旁注与 <code>clues/</code> 落地，用行业语境辅助理解（<strong>非</strong>权要 / 说明书证据）</td></tr>\n</tbody>\n</table>\n\n怎么开口：读专利、专利解读、`/读专利`、`/patent-read`，并给出**公开号或 PDF 路径**。配置库环境变量 `PATENT_READER_OBSIDIAN_VAULT` 体验更完整；中间产物在工作区 `outputs/patent_reader/`，无库时笔记也落在该目录。流程见 [skills/patent-reader/tools/README.md](skills/patent-reader/tools/README.md)、[SKILL.md](SKILL.md)。\n\n### 审查答复辅助\n\n审查意见一来，往往要翻旧案、对法条、想策略。需要时可以说「审查答复 / `/审查答复`」：把通知书 PDF 交给技能，**先问清缺陷、再出意见陈述草稿**（须人审后才能递交）。草稿质量依赖自己的**历史案**和可选的**实务书经验手册**——库空时仍能出提纲式草稿，但会对不上旧打法。库里历史案或手册较少时，对话末尾会补一句短提示，引导提示使用「案例入库」或「实务书蒸馏」并给出本地 PDF 路径（先脱敏 / 先预读，不会偷偷改技能）。向量可跳过。细则见 [SKILL.md](SKILL.md) 审查答复入口、[skills/patent-oa/docs/README.md](skills/patent-oa/docs/README.md)、[skills/patent-oa/tools/README.md](skills/patent-oa/tools/README.md)。\n\n### 著录检索\n\n想按发明人、申请人、分类号或名称，把公布公告里已经公开的专利列成清单？需要时可以说「著录检索 / `/patent-search`」：走国知局公布站高级查询，结果落到 `outputs/patent-search/SEARCH-*.md`。默认先翻前面几页，对话里说「多翻几页」或「全部翻完」再加码；没翻完时不会当成完整清单。查某人公开专利时，带上「发明人姓名 + 当前及历史申请主体」，例如「检索某发明人在申请主体一、申请主体二名下的公开专利」——只覆盖已公开/公告记录，不等于单位内部实际提交总数。细则见 [skills/patent-search/SKILL.md](skills/patent-search/SKILL.md)。\n\n### 政策简报\n\n审查指南、智能审查口径一变，交底写法很容易「还按老习惯」。需要时可以说「政策简报 / 政策雷达 / `/政策简报`」：对照国知局等官网**近期口径**，整理观点和原文链接，说明对**交底写法**（若有定稿，也对**这篇稿**）的影响。默认 `outputs/exam-policy/POLICY-*.md`，**不改技能**。也可 `/patent-brief`、`/patent-exam-policy`。只有另说「按简报改交底技能」时，才作为旁路改交底包提示词。细则见 [skills/patent-exam-policy/SKILL.md](skills/patent-exam-policy/SKILL.md) 与 `skills/patent-exam-policy/prompts/`。\n\n接入宿主、Python / Node、可选 STEP 等见 **[INSTALL.md](INSTALL.md)**。\n\n---\n\n## 示例\n\n索引在各包 `examples/`。完整产物落在 **`outputs/`** 或 Obsidian 库。\n\n<!-- 使用 HTML 表格：前两列 nowrap 防挤窄，后两列自动换行 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col width=\"1%\">\n<col>\n<col>\n</colgroup>\n<thead>\n<tr>\n<th align=\"left\" nowrap width=\"1%\">示例</th>\n<th align=\"left\" nowrap width=\"1%\">类型</th>\n<th align=\"left\">材料</th>\n<th align=\"left\">怎么开口</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td nowrap width=\"1%\">批任务调度</td>\n<td nowrap width=\"1%\"><strong>发明</strong>交底</td>\n<td><a href=\"skills/patent-disclosure/examples/example_batch_job_scheduler/\"><code>skills/patent-disclosure/examples/example_batch_job_scheduler/</code></a>（扫 <code>knowledge/</code>）</td>\n<td>「按发明写交底，项目路径 …/knowledge/」或 <code>/交底书</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">汽车集成式电驱桥</td>\n<td nowrap width=\"1%\"><strong>实用新型</strong>交底</td>\n<td><a href=\"skills/patent-disclosure/examples/example_utility_model_ev_powertrain/\"><code>skills/patent-disclosure/examples/example_utility_model_ev_powertrain/</code></a></td>\n<td>「实用新型交底，材料在 …/example_utility_model_ev_powertrain/」</td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">折臂台灯</td>\n<td nowrap width=\"1%\"><strong>外观设计</strong>交底</td>\n<td><a href=\"skills/patent-disclosure/examples/example_design_desk_lamp/\"><code>skills/patent-disclosure/examples/example_design_desk_lamp/</code></a></td>\n<td>「外观设计交底，材料在 …/example_design_desk_lamp/」</td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">公布公告查询</td>\n<td nowrap width=\"1%\"><strong>著录检索</strong></td>\n<td>无需本地样例（联网出清单 → <code>outputs/patent-search/SEARCH-*.md</code>）</td>\n<td>「按发明人/申请人检索公开专利」；<code>/patent-search</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">公开专利 PDF</td>\n<td nowrap width=\"1%\"><strong>通俗解读</strong></td>\n<td><a href=\"skills/patent-reader/examples/example_patent_reader/\"><code>skills/patent-reader/examples/example_patent_reader/</code></a>（PDF 本地自备）</td>\n<td>「读专利」+ 公开号或 PDF；<code>/读专利</code>、<code>/patent-read</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">政策 / 审查动向</td>\n<td nowrap width=\"1%\"><strong>政策简报</strong></td>\n<td>无需本地样例（联网出清单 → <code>outputs/exam-policy/POLICY-*.md</code>）</td>\n<td>「政策简报」：对照国知局口径，看交底写法/本稿；默认不改技能；<code>/政策简报</code>、<code>/patent-brief</code>、<code>/patent-exam-policy</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">审查答复样例</td>\n<td nowrap width=\"1%\"><strong>审查答复</strong></td>\n<td><a href=\"skills/patent-oa/examples/example_oa_response/\"><code>skills/patent-oa/examples/example_oa_response/</code></a>（2 历史案 + 1 待答复通知书）</td>\n<td>「审查答复」+ 通知书路径；库空也可出草稿。想对照旧案可说「案例入库」；<code>/审查答复</code>、<code>/oa</code></td>\n</tr>\n</tbody>\n</table>\n\n---\n\n## 支持作者\n\n如果这个 Skill 对您有帮助，可以请我喝杯咖啡☕随缘支持，感谢感谢🙏🙏\n\n<table width=\"70%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"40%\" align=\"center\">随缘支持</th>\n<th width=\"60%\" align=\"center\">Star History</th>\n</tr>\n<tr>\n<td width=\"40%\" valign=\"middle\" align=\"center\">\n<img src=\"docs/thanks.jpg\" alt=\"随缘支持\" width=\"200\" />\n</td>\n<td width=\"60%\" valign=\"middle\" align=\"center\">\n<img alt=\"Star History Chart\" src=\"https://raw.githubusercontent.com/handsomestWei/patent-disclosure-skill/star-history/star-history.svg\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 参考文档\n\n- [技能入口与 Agent 流程](SKILL.md)（交底 / 著录检索 / 解读 / 政策简报 / 审查答复）\n- [详细安装说明](INSTALL.md)\n- [交底书：图示与转换 / 国知局工具](skills/patent-disclosure/tools/README.md)\n- [著录检索](skills/patent-search/SKILL.md)\n- [专利解读工具](skills/patent-reader/tools/README.md)\n- [审查答复 · 案例 RAG](skills/patent-oa/tools/README.md)\n- [Obsidian 安装与可选社区插件（Windows）](skills/patent-reader/docs/obsidian-setup-guide.md)\n- [交底书模版细则](skills/patent-disclosure/prompts/invention/template_reference.md)\n\n---\n\n<div align=\"center\">\n\nMIT License © [handsomestWei](https://github.com/handsomestWei/)\n\n</div>\n\nFile v4.0.0:skills/patent-disclosure/references/formulas/README.md\n\n# 公式推荐范式（外挂配置）\n\n发明交底在写 **3.4.1** 前，须依据本目录配置**选题**，再填入案件符号与数值，避免临时发明抽象式子。\n\n| 文件 | 作用 |\n|------|------|\n| [`paradigms.yaml`](paradigms.yaml) | 默认范式库 + 全局规则（禁装饰音、符号上限等） |\n| [`../schemas/formula_plan.schema.yaml`](../schemas/formula_plan.schema.yaml) | 案件级 `formula_plan.yaml` 合同 |\n\n## 加载顺序（后者覆盖同 `id`）\n\n1. 仓库 `references/formulas/paradigms.yaml`\n2. 环境变量 `PATENT_FORMULA_PARADIGMS` 指向的 YAML/JSON\n3. 案件目录 `formula_paradigms.yaml` 或 `formula_paradigms.json`（与交底输出同级）\n\n查看合并结果：\n\n```bash\npython tools/formula_paradigms.py list\npython tools/formula_paradigms.py list --case-dir outputs/某案\npython tools/formula_paradigms.py show weighted_sum\n```\n\n校验案件公式计划：\n\n```bash\npython tools/check_formula_plan.py -i outputs/某案/formula_plan.yaml\npython tools/check_formula_plan.py -i outputs/某案/formula_plan.yaml --eval\n```\n\n`--eval`：对可解析的简单式（`+ - * / min max`）代入 `numeric_example` 核对 `result`；求和/范数/分位等跳过并警告。  \n`chemistry` 标签或 `\\ce{` / 反应箭头：检查简单反应式原子守恒。`physics`/`si`：符号表单位族粗检（警告）。\n\n## 如何扩展一条范式\n\n在覆盖文件中追加（保留 `version` / 可选 `rules`）：\n\n```yaml\nversion: 1\nparadigms:\n  - id: my_shop_floor_oee\n    name_zh: 产线 OEE 合成\n    tags: [score, manufacturing]\n    when_zh: 可用率×表现×质量\n    latex: 'OEE = A \\\\cdot P \\\\cdot Q'\n    notes_zh: A,P,Q ∈ (0,1]\n```\n\n`id` 用小写+下划线；写清 `when_zh` / `notes_zh`，否则易被误选。  \n`combos` 可同样追加，供 Agent 在调度/检索等场景一次选多式。\n\n## 成文纪律（摘要）\n\n- `formula_plan.paradigm_ids`（及可选 `combo_id`）必须∈合并后的库。  \n- 默认 `rules.forbid_accents: true`：正文不要用 `\\tilde`/`\\hat`/`\\bar` 等；平滑用 `ema_smooth` + 符号 `A`。  \n- 须含可代入数值例；打分与限频触发尽量分式，参见 combo `match_then_rate_limit`。\n\nFile v4.0.0:skills/patent-disclosure/references/schemas/README.md\n\n# Schema 合同说明\n\n| 文件 | 用途 | 交底怎么用 |\n|------|------|------------|\n| `structure.schema.yaml` | 形状/构造 | `prompts/utility_model/`；填表见 `fill_structure_schema.md` |\n| `appearance.schema.yaml` | 外观造型 | `prompts/design/`；填表见 `fill_appearance_schema.md` |\n| `figure_plan.schema.yaml` | 附图选用、排序与图际关联（`relates_to`） | 实用/外观成文只嵌 `use_in_disclosure: true` |\n| `formula_plan.schema.yaml` | 发明公式选题 + 可算提纲 | 含公式时先写 `formula_plan.yaml`；范式见 `references/formulas/` |\n| `design_lineart_brief.schema.yaml` | 外观线稿描述（成文前必做） | 不问用户；已有合格线稿或大模型生成；CAD 不得当线稿 |\n| `structure_lineart_brief.schema.yaml` | 实用结构线稿描述（成文前必做） | 不问用户；轮廓与序号分层；禁止自创件号；CAD 不入文 |\n| `structure_lineart_compose.schema.yaml` | 实用结构线稿按件拼装 | 每件一个子 SVG，总图相对引用；粒度止于件号；crop / 单件图 / 占位框 |\n\n填写指令：`prompts/fill_structure_schema.md`、`fill_appearance_schema.md`（填表末步写出 **`figure_plan.yaml`**，含跨图核对与 `relates_to`）；线稿合同 **`prompts/image_gen.md`**；外观见 **`prompts/design_lineart_assist.md`**；实用新型见 **`prompts/structure_lineart_assist.md`** + **`structure_lineart_compose.md`**。  \n多轮改材料或主题时须同步重评 `figure_plan`（含 `relates_to`；见该合同「多轮同步」）。StructureSchema 可选 `relations[].seen_in` 标注连接可见于哪些 `fig`。\n\nFile v4.0.0:skills/patent-disclosure/tools/README.md\n\n# 交底包 tools\n\n本目录是 **patent-disclosure** 的脚本根：浏览器、docx、mermaid、公式、CAD、线稿，以及 `crawl/` 轻量查新。\n\n整仓安装时从仓库根调用：`python skills/patent-disclosure/tools/…`。单独拷走本包时，本目录即为 `tools/`。\n\n## 国知局公布公告检索（交底 Step 5 轻量查新）\n\n| 脚本 | 作用 |\n|------|------|\n| **`crawl/cnipa_epub_search.py`** | **（Step 5 优先）** 一步拉取+解析，不落盘；**一词一页**；**`--type invention\\|utility_model\\|design\\|all`** |\n| **`crawl/cnipa_epub_crawler.py`** | 拉取并默认保存结果页 HTML |\n| **`crawl/cnipa_epub_parse.py`** | 仅解析已保存 HTML |\n| **`patent_type.py`** | 类型别名、国知局 checkbox、Google Patents 查询提示 |\n\n依赖：`pip install playwright`（或根目录 `requirements.txt`）。浏览器见 **`tools/browser.py`**。查新说明见 **`prompts/prior_art_search.md`**。\n\n著录检索（发明人/申请人/分类号等高级查询）是另一个技能包，**不是**本目录脚本。本包查新只用上面的 `crawl/`，不要 import、不要调用检索爬虫。整仓时入口在仓库根 `SKILL.md`。\n\n抓取失败时降级 **WebSearch**（Google 学术**无**专利类型过滤；Google Patents 支持 PATENT/DESIGN，实用新型靠关键词+国知局）。\n\n---\n\n## CAD / STEP（可选，默认关闭）\n\n| 脚本 | 作用 |\n|------|------|\n| **`cad_scan.py`** | 扫描 `.step`/`.stp` 与原生 CAD 后缀；输出 JSON（`ask_enable_step_parse` / `hint_export_step`）。**无重依赖**。 |\n| **`cad_formats.py`** | 后缀表与提示文案。 |\n| **`cad_venv.py`** | 探测 `tools/cad-env`；已能 `import cadquery` 则 `skip_install=true`。 |\n| **`bootstrap_cad_venv.py`** | 仅在未就绪时建 venv + `--isolated` pip（国内源 → pypi.org）。 |\n| **`step_to_views.py`** | STEP → SVG（有 Cairo 再 PNG）。须 **`--enable-step-parse`**；请用 cad-env 的 Python。 |\n| **`svg_screenshot.py`** | 短时 HTTP + 无头浏览器把 SVG 截成 PNG（端口先探测，用完关闭）。 |\n| **`run_step_to_views.py`** | 探测 cad-env → 必要时 bootstrap → 出图 → 补 PNG。 |\n| **`gen_demo_snap_step.py`** | 生成教学用 `tests/fixtures/cad/demo_snap_plate.step`（无 CadQuery）。 |\n| **`requirements-step.txt`** | ASCII only；CadQuery + cairosvg；**只装进 cad-env**。 |\n\n流程纪律见 **`skills/patent-disclosure/prompts/project_scan.md`**「CAD / STEP」：有 STEP 成文不中断，交底落盘后再反问；仅有原生 CAD 则交付回复末尾提示导出 STEP。投影图是普通材料（`kind: cad`），**不得当线稿、不得入文**；打分后可能作图生图参考。\n\nCadQuery 官方轮子支持 **Python 3.10–3.12**（**不是** 3.13）。本机已是 3.11/3.12 就用当前解释器建 `cad-env`，不要强行找 3.10。无系统 Cairo 时 **保留 SVG**，用本技能已有的 Playwright 截 PNG。CAD 出图**不用** matplotlib（matplotlib 仅发明公式 PNG 可选）。\n\n```bash\npython tools/cad_scan.py -r knowledge --json\npython tools/cad_venv.py\npython tools/run_step_to_views.py --enable-step-parse -i a.step -o outputs/case/cad_views\n```\n\n---\n\n## 发明公式范式（`references/formulas/`）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`references/formulas/paradigms.yaml`** | 默认可扩展范式库 |\n| **`references/schemas/formula_plan.schema.yaml`** | 案件 `formula_plan.yaml` 合同 |\n| **`formula_paradigms.py`** | `list` / `show` / `combos`（支持案件目录覆盖） |\n| **`check_formula_plan.py`** | 校验选题 id、禁装饰音、数值例；`--eval` 简单式代算；化学守恒 / 量纲粗检（按 tag） |\n\n```bash\npython tools/formula_paradigms.py list\npython tools/check_formula_plan.py -i outputs/case/formula_plan.yaml --eval\n```\n\n成文纪律见 **`skills/patent-disclosure/prompts/invention/disclosure_builder.md` §7.7**。\n\n## 线稿规划（成文前必做）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`prompts/image_gen.md`** | Agent 合同：合格已有线稿 / 图生图 / 文生图；CAD 不得当线稿入文 |\n| **`image_gen.py`** | 读 figure_plan，打印 `mode` / `fallback` |\n\n```bash\npython tools/image_gen.py --case-dir outputs/case\n```\n\n## 外观线稿（必做）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`prompts/design_lineart_assist.md`** | 不问用户；写 brief → 门禁 → 图生图或文生图 |\n| **`design_lineart_gate.py`** | 默认开；无源图则允许文生图；`--prepare-jobs` 写出 `lineart_assist/design_lineart_jobs.json` |\n| **`references/schemas/design_lineart_brief.schema.yaml`** | 描述合同 |\n\n```bash\npython tools/design_lineart_gate.py --case-dir outputs/case --prepare-jobs\n```\n\n生成的线稿默认入文。外观另将干净实拍一并写入 md 与 Word。CAD 不得 `use_in_disclosure: true`。\n\n## 实用新型结构线稿（必做）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`prompts/structure_lineart_assist.md`** | 不问用户；轮廓 → 按件拼装 → 按 Structure 叠件号 |\n| **`prompts/structure_lineart_compose.md`** | 独立拼装指令：每件一个子 SVG；总图相对引用；粒度止于件号 |\n| **`structure_lineart_gate.py`** | 默认开；无 Structure 拒绝；无源图则允许文生图 |\n| **`structure_lineart_compose.py`** | 读 compose YAML，写出 `parts/{视}_{id}.svg` 与相对引用的总 SVG |\n| **`structure_callout_overlay.py`** | 读取锚点后以 SVG 叠标；有 `base_svg_path` 时注入拼装图，不压扁零件层；叠标后扩大画布留白，避免贴边序号被截掉 |\n| **`references/schemas/structure_lineart_brief.schema.yaml`** | 描述合同（与外观分文件） |\n| **`references/schemas/structure_lineart_compose.schema.yaml`** | 按件槽位 / crop / 单件图合同 |\n| **`references/schemas/structure_callout_anchors.schema.yaml`** | 锚点持久化合同（`anchor` + `label` + 置信度；可选 `base_svg_path`） |\n\n```bash\npython tools/structure_lineart_gate.py --case-dir outputs/case --prepare-jobs\npython tools/structure_lineart_compose.py --case-dir outputs/case\npython tools/structure_callout_overlay.py --case-dir outputs/case --anchors outputs/case/structure_callout_anchors.yaml\n```\n\n推荐：轮廓之后按件写出子 SVG 再拼总图，再 `callout_mode: overlay` 注入件号。大模型只定位，Python/SVG 叠标，不做含件号的二次生图。叠标后须读图按 `parts` 名称核对引出线（改 YAML 重叠标，最多 2 轮）；脚本合法 ≠ 图面对。禁止自创件号；CAD 投影不是线稿。可编辑源是 `parts/*.svg` + 总图引用，入文 PNG 只是预览。\n\n## Office / mermaid\n\n用 **`docx_to_md.py`**、**`pptx_to_md.py`**、**`mermaid_render.py`** 等。\n\n## mermaid_render.py — mermaid：图示 → PNG + 定稿 Markdown + **默认生成 Word**\n\n将 fenced **mermaid**（`` ```mermaid`` ``）逐块经 **Playwright + 内置 `vendor/mermaid.min.js`** 渲染为 PNG；输出 `.md` 中**保留** mermaid 围栏源码，并追加 ``<!-- ![图示 n](mermaid_figures/…) -->`` 供 **`md_to_docx.py`** 嵌入 Word（Word **仅**嵌 PNG，不写 mermaid 代码块）。**3.2 系统框图**与 **3.4 流程图**均用 mermaid（`flowchart` / `subgraph` 等），交底书正文**不再**要求单独的文字框图或 PlantUML。流程图步骤号（`S1` 等）须写在**可见标签**里；脚本会把 `S1[文案]` 补成 `S1[\"S1 文案\"]` 再出图，否则 PNG 上看不到序号。\n\n**生图失败降级**：某一围栏失败时**不中断**——该处**保留**原 `` ```mermaid`` … `` ``` `` 源码；其余块照常出图。仍写出定稿 `.md`，并**照常尝试**生成 Word（未出图块在 Word 中为 **Consolas 代码块**）。无可用浏览器时同样保留围栏，不阻塞 Markdown。\n\n### 依赖：mermaid（Playwright，无需 Node）\n\n与国知局查新**共用** `tools/browser.py`：系统 **Chrome → Edge → Playwright 自带 Chromium**。仓库已内置 `tools/vendor/mermaid.min.js`。\n\n| 需要 | 说明 |\n|------|------|\n| `pip install playwright` | 已写入根目录 `requirements.txt` |\n| 本机 Chrome 或 Edge | **推荐**；有则不必再下 Chromium |\n| `python -m playwright install chromium` | **仅当**本机无 Chrome/Edge 时 |\n\n探测：`python tools/browser.py --probe`。**禁止**为出图执行 `npm install` / `npx -y @mermaid-js/mermaid-cli`。`tools/package.json` 仅为旧 mmdc 可选遗留，主路径不使用。\n\n生成 Word 仍需：`pip install -r requirements.txt`（python-docx 等）。\n\n默认视口 **1400×1050**、`device_scale_factor=2`（历史参数名 `--mmdc-scale` / `--mmdc-width` / `--mmdc-height` 仍可用）。再锐化可 `--mmdc-scale 3`。\n\n### 用法\n\n```bash\n# 写出定稿 .md，并在同目录生成同名 .docx（默认）；-o 须为「案件名_YYYYMMDDHHmmss.md」（见 skills/patent-disclosure/prompts/invention/disclosure_builder.md §7.3 第 5 点）\npython tools/mermaid_render.py -i draft.md -o \"一种XXX方法及系统_20260408143025.md\"\n\n# 指定 .docx 路径（.md 主名仍须含时间戳）\npython tools/mermaid_render.py -i draft.md -o out/一种XXX方法及系统_20260408143025.md --docx out/一种XXX方法及系统_20260408143025.docx\n\n# 仅 Markdown，不要 Word\npython tools/mermaid_render.py -i draft.md -o \"一种XXX方法及系统_20260408143025.md\" --no-docx\n\n# 更高清晰度（可选）\npython tools/mermaid_render.py -i draft.md -o \"…定稿.md\" --mmdc-scale 3 --mmdc-width 1600 --mmdc-height 1200\n\n# 指定 mermaid 图片子目录（相对输出 .md）\npython tools/mermaid_render.py -i draft.md -o out/一种XXX方法及系统_20260408143025.md --assets-dir figures/mermaid\n```\n\n**Word 生成失败**（缺依赖、版式报错等）时：脚本仍以退出码 **0** 结束（Markdown 已成功）；stderr 会打印 **`md_to_docx.py` 的手动命令**，请复制执行。\n\n无可用浏览器时仍写出 Markdown（保留 mermaid 围栏）；补齐 Chrome/Edge 或 Chromium 后可重跑本脚本出 PNG。\n\n### 与交底书约定\n\n- 技能要求定稿**同时**交付 **Markdown + Word**，且 **`-o` 主文件名须含 `_{YYYYMMDDHHmmss}`**（`skills/patent-disclosure/prompts/invention/disclosure_builder.md` §7.3 第 5 点，含首次定稿）；**3.2 系统框图**与 **3.4 流程图**均用 fenced mermaid，**不要** ASCII 文字流程图或框图。\n- 交付代理人前：运行 `mermaid_render.py` 一步即可（默认再调 `md_to_docx.py`）；若 Word 失败，按 stderr 提示手动执行 `md_to_docx.py`。\n- **判读**：`MERMAID:` / `DOCX: ok=1` 且退出码 0 即为成功；stderr 中文或 PowerShell 红字不是失败。`DOCX: ok=0` 才算 Word 失败。\n- 默认**不**预渲染公式 PNG。Word 公式走 OMML；stderr 若有 `omml_text_fallback` / `OMML_FAIL:`，须用户确认后再 `pip install matplotlib` 并以 `--math` / `--math-render` 重出 Word。\n\n---\n\n## math_to_omml.py — LaTeX → 可编辑 Office Math\n\n``latex2mathml`` → MathML → Word ``m:oMath`` / ``m:oMathPara``。不依赖本机 TeX。由 **`md_to_docx.py`** 默认调用。失败则留 LaTeX 原文；stderr 会列出 `omml_text_fallback`。\n\n兼容：单行 ``\\[ ... \\]`` 与多行块公式同样写入 OMML；``\\tag{1}`` 改为式末 ``(1)``。\n上标写入 ``m:sup``（不再误塞进 ``m:sub``）。单位与缺字符号在转换前归一：``^{\\circ}C/F``、``\\degree``、``\\AA``、``\\ohm``、``\\micro``、``\\permil``、``\\sim`` 等；非汉字公式 run 指定 Cambria Math，避免中文 Word 落到宋体后显示方框。\n\n```bash\npip install latex2mathml   # 已写入根目录 requirements.txt\n```\n\n---\n\n## math_render.py — LaTeX 公式 → PNG（可选回退）\n\n将 Markdown 中的 **LaTeX 公式**用 **matplotlib mathtext** 渲染为 PNG；**保留 LaTeX 原文**，图片引用写入 HTML 注释，供 **`md_to_docx.py`** 在 **OMML 失败时**嵌入。\n\n**默认不定稿出公式 PNG**，也不把 matplotlib 写入主 `requirements.txt`。仅当用户确认后：`pip install matplotlib`，再 `md_to_docx.py --math-render` 或 `mermaid_render.py --math`。\n\n**Mermaid 框图**：``mermaid_render.py`` **保留** `` ```mermaid`` 源码，并追加 ``<!-- ![图示 n](mermaid_figures/...) -->``。\n\n**mathtext 兼容**：``\\ge``→``\\geq`` 等；``\\tag{1}`` 转式末 ``(1)``。\n\n**Word 主路径**：默认 **OMML 优先**；无 PNG 时失败留原文。``--no-omml`` 可强制旧行为。\n\n### 依赖（可选）\n\n```bash\npip install matplotlib\n```\n\n### 用法\n\n```bash\npython tools/math_render.py -i draft.md -o draft_with_math.md\npython tools/math_render.py -i draft.md -o out.md --assets-dir math_figures\npython tools/md_to_docx.py -i a.md -o a.docx --math-render\npython tools/mermaid_render.py -i a.md -o a.md --math\n```\n\n---\n\n## md_to_docx.py — Markdown → Word\n\n将交底书 Markdown 转为 `.docx`，**`#`–`######` 映射为 Word 内置「标题 1」–「标题 9」**，正文为宋体 10.5pt，代码块为 Consolas，便于交给代理人或所内用 Word 修订。\n\n**图示**：定稿应用 **`mermaid_render.py`** 将 mermaid 转为 PNG；若个别块生图失败被降级保留围栏，本脚本会将**仍存在的** `` ```mermaid`` 块按**代码块**写入 Word。本脚本不启动浏览器。\n\n### 依赖\n\n```bash\npip install -r requirements.txt\n```\n\n依赖为 `python-docx` + `latex2mathml`（见仓库根目录 `requirements.txt`）。缺 `latex2mathml` 时留原文；公式 PNG 须 ``--math-render`` 且已装 matplotlib。\n\n### 用法\n\n```bash\npython tools/md_to_docx.py --input path/to/交底书.md --output path/to/交底书.docx\npython tools/md_to_docx.py -i a.md -o a.docx --no-omml         # 仅 PNG/原文\npython tools/md_to_docx.py -i a.md -o a.docx --math-render    # OMML 失败用 PNG（须 matplotlib）\n```\n\n图片 `![](相对路径.png)`：默认相对 **Markdown 文件所在目录**；也可指定根目录：\n\n```bash\npython tools/md_to_docx.py -i ./outputs/case/disclosure.md -o ./outputs/case/disclosure.docx --base-dir ./outputs/case\n```\n\n**插图**：对 PNG/GIF/JPEG 会读取像素尺寸，在默认 **最大宽 5.5\" × 最大高 8.2\"** 内**等比缩放**并同时指定 `width`/`height`，避免竖长流程图仅按宽度放大后**高度超出版心**、打印或阅读时像被裁切。可按纸张边距调整，例如：\n\n```bash\npython tools/md_to_docx.py -i a.md -o a.docx --image-max-width-inches 6 --image-max-height-inches 9\n```\n\n整仓从仓库根调用：`python skills/patent-disclosure/tools/…`。单独拷走本包时本目录即为 `tools/`。\n\n### 支持的 Markdown 子集\n\n| 元素 | 行为 |\n|------|------|\n| `#`–`######` | Word 标题 1–9 |\n| 段落 | 宋体正文，支持 `**粗体**`、`` `行内代码` ``；**相邻非空行（中间无空行）各自成段**，「（1）…（2）…」会分行显示 |\n| `-` / `*` 列表 | 项目符号列表 |\n| `1.` 列表 | 编号列表；被标题 / 段落 / 表格 / 分隔线等隔开的新一组从 1 重计（避免跨章串号） |\n| ` ``` ` 围栏 | 等宽代码块 |\n| `\\| 表格 \\|` | 简单表格（Table Grid）；单元格内 ``\\\\(...\\\\)``、``$...$``、``<!-- -->`` 及 ``\\\\|`` 中的 ``|`` **不会**被当作列分隔符 |\n| `> ` | 左缩进引用 |\n| `---` 等 | 浅色分隔线 |\n| `![](path)` | 嵌入图片（路径需存在；默认宽/高上限内等比缩放；公式图与正文混排） |\n| `$` / `\\\\(...\\\\)` / `$$` / `\\\\[...\\\\]` LaTeX | **优先 OMML（可编辑公式）** → 已有公式 PNG 则嵌图 → 否则 **原文**；``--math-render`` 才预渲染 PNG；``--no-omml`` 跳过 OMML |\n\n**未完整支持**：复杂嵌套列表、HTML 块、**未预渲染的** mermaid 围栏（仍为代码块）、脚注、任务列表等。定稿前请运行 **`mermaid_render.py`**；若仅用外部工具导出 PNG，可直接写 `![](...)`。\n\n### 版式说明（md_to_docx）\n\n- 不同语言 Word 中「标题 1」显示名可能为「Heading 1」或「标题 1」，样式仍为大纲级别标题，可用导航窗格与目录域。\n- Markdown 里每组 `1.` 列表（被标题、正文、表格、分隔线等隔开）在 Word 中从 1 重计，避免第一章 1–4 之后第二章变成 5–8。\n- 若需所内固定模版（页眉、首页不同），可在本脚本生成后套用单位 `.dotx`，或后续扩展 `python-docx` 打开模版再写入。\n\n---\n\n## iteration_dialog_log.py — 修订对话记录（迭代用）\n\n每轮 **`skills/patent-disclosure/prompts/merger.md` / `correction_handler.md`** 交付后，在**案件目录**追加一条 **`交底书修订对话记录.md`**：含**本地时间与 UTC**、用户说明摘要、本轮交付文件名、合并/纠正摘要摘录。规则见 **`skills/patent-disclosure/prompts/iteration_context.md`**。\n\n**依赖**：仅标准库。\n\n```bash\npython tools/iteration_dialog_log.py --case-dir outputs/某案件 --kind merge \\\n  --user \"补充了调度装置资料，合并进第三章\" \\\n  --summary \"已扩写 3.4，并更新实施例；未改保护点表述。\" \\\n  --artifacts \"一种XXX方法及系统_20260408143025.md,一种XXX方法及系统_20260408143025.docx\"\n```\n\n- `--kind`：`merge` 或 `correct`。  \n- `--log-name`：可选，默认 `交底书修订对话记录.md`；英文环境可改用 `disclosure_revision_log.md`。  \n- 无法执行脚本时，由 Agent 按同结构手工追加。\n\n---\n\n## docx_to_md.py — Word → Markdown + 抽取图片\n\n将 **.docx**（Word / WPS 等另存为 docx）转为 **Markdown**，并把文档内嵌图片落到磁盘，便于 **`Read` 与 Step 2 扫描**（与直接读二进制 .docx 相比更稳）。**Step 2** 对扫描树内**每一个** `.docx` 都应先转换再读产出 `.md`，见 `skills/patent-disclosure/prompts/project_scan.md`。\n\n### 依赖\n\n与 `md_to_docx` 共用根目录 `requirements.txt`（`python-docx` + **`mammoth`**）。\n\n```bash\npip install -r requirements.txt\n```\n\n### 用法\n\n```bash\npython tools/docx_to_md.py --input path/to/设计说明.docx --output outputs/case/design.md\n```\n\n- 默认图片目录：`outputs/case/design_media/`，Markdown 内为相对路径 `![](design_media/img_0001.png)`。\n- 自定义图片目录：\n\n```bash\npython tools/docx_to_md.py -i ./raw/spec.docx -o ./knowledge/spec.md --media-dir ./knowledge/spec_assets\n```\n\n转换警告（如部分样式、WMF 图）会输出到 **stderr**，仍可能生成可用 `.md`。\n\n### 局限（mammoth）\n\n- 仅 **`.docx`**（OOXML）；老版 **`.doc`** 不支持。\n- **Markdown 输出在 mammoth 侧标记为 deprecated**，复杂排版可能弱于「先导出 HTML 再转 MD」；专利扫描一般足够。若版式崩坏，建议所内 **另存为 PDF 或纯文本** 再扫。\n- **WMF/EMF** 等 Windows 图元可能需单独处理（见 [mammoth WMF 配方](https://github.com/mwilliamson/python-mammoth)）。\n\n整仓从仓库根调用：`python skills/patent-disclosure/tools/…`。单独拷走本包时本目录即为 `tools/`。\n\n---\n\n## pptx_to_md.py — PowerPoint → Markdown + 抽取图片\n\n将 **.pptx** / **.ppsx** 按**幻灯片页**导出为 Markdown，并抽取幻灯片中的**嵌入位图**（`PICTURE` 形状），便于 **`Read` 与 Step 2 扫描**。**Step 2** 对扫描树内**每一个** `.pptx` 均应先转换再读 `.md`，见 `skills/patent-disclosure/prompts/project_scan.md`。\n\n### 依赖\n\n根目录 `requirements.txt` 中的 **`python-pptx`**。\n\n```bash\npip install -r requirements.txt\n```\n\n### 用法\n\n```bash\npython tools/pptx_to_md.py --input path/to/评审材料.pptx --output outputs/case/review.md\n```\n\n- 默认图片目录：`outputs/case/review_media/`，文件名形如 `slide03_img0001.png`。\n- 自定义图片目录：\n\n```bash\npython tools/pptx_to_md.py -i ./raw/deck.pptx -o ./knowledge/deck.md --media-dir ./knowledge/deck_media\n```\n\n每页输出二级标题 `## 第 N 页`，其后为该页形状中的**文本与表格**（简化为管道表）及图片引用；若存在**演讲者备注**，以「**备注**」小节附于该页末尾。\n\n### 局限（python-pptx）\n\n- 仅 **`.pptx` / `.ppsx`**（OOXML）；**`.ppt`** 不支持，请先另存。\n- **图表、SmartArt、嵌入 OLE** 等若未以普通图片形状存在，**不会**自动栅格化为 PNG；可先在 PowerPoint 中另存为图片或导出 PDF 作补充材料。\n- 文本按形状遍历顺序输出，与视觉阅读顺序可能略有差异。\n\n整仓从仓库根调用：`python skills/patent-disclosure/tools/…`。单独拷走本包时本目录即为 `tools/`。\n\n通俗解读、著录检索、审查答复的脚本在各自技能包，不在本目录。\n\n---\n\n## 扩展其它脚本时\n\n- Word / PPT 转换依赖写在 `requirements.txt`。\n- 在 `SKILL.md`「工具与数据来源」表中增加一行调用说明。\n- 勿将密钥写入仓库；配置使用环境变量或用户主目录。\n\nFile v4.0.0:skills/patent-disclosure/tools/vendor/README.md\n\n# 内置 mermaid（供 Playwright 出图，无需 Node / mmdc）\n\n| 文件 | 版本 | 来源 |\n|------|------|------|\n| `mermaid.min.js` | **11.4.1** | https://cdn.jsdelivr.net/npm/mermaid@11.4.1/dist/mermaid.min.js |\n\n与历史 `@mermaid-js/mermaid-cli` 11.4.x 同系列。出图由 `tools/mermaid_render.py` 经 Playwright 加载本文件，**禁止**运行时从 CDN 再拉。\n\n升级时请同步改本表版本号，并替换 `mermaid.min.js`。\n\nFile v4.0.0:skills/patent-exam-policy/docs/README.md\n\n# docs — 已确认沉淀的政策简报（可选提交）\n\n日常简报默认在 **`outputs/exam-policy/`**（gitignore，不进仓）。\n\n仅当用户确认「沉淀到 docs/」时，将对应 `POLICY-*.md` **复制**到本目录。  \n内容以政策简报为主；技能进化附录即使存在，复制过来也不等于已改 prompts。\n\n不要把未确认的草案直接提交到这里。\n\nArchive v3.9.0: 167 files, 1288196 bytes\n\nFiles: assets/obsidian/_专利解读索引.template.md (1806b), assets/obsidian/glossary.base.yaml (542b), assets/obsidian/graph_color_groups.json (790b), assets/obsidian/oa.base.yaml (1260b), assets/obsidian/patent-reader.css (1561b), assets/obsidian/patents.base.yaml (1988b), assets/obsidian/README.md (578b), assets/patent_note_template.md (3535b), docs/evolution/EVOL-20260811-1051.md (6735b), docs/evolution/README.md (365b), docs/oa/embedding.config.yaml (902b), docs/oa/README.md (1206b), docs/obsidian-setup-guide.md (4762b), INSTALL.md (10342b), prompts/disclosure/correction_handler.md (4292b), prompts/disclosure/design/disclosure_builder.md (4671b), prompts/disclosure/design/patent_points.md (3008b), prompts/disclosure/design/template_reference.md (1901b), prompts/disclosure/disclosure_preview.md (2514b), prompts/disclosure/disclosure_self_check.md (12849b), prompts/disclosure/intake.md (2789b), prompts/disclosure/invention/disclosure_builder.md (22924b), prompts/disclosure/invention/patent_points_analyzer.md (1343b), prompts/disclosure/invention/template_reference.md (14498b), prompts/disclosure/iteration_context.md (5915b), prompts/disclosure/merger.md (5479b), prompts/disclosure/prior_art_search.md (15229b), prompts/disclosure/project_scan.md (10416b), prompts/disclosure/utility_model/disclosure_builder.md (5161b), prompts/disclosure/utility_model/patent_points.md (3841b), prompts/disclosure/utility_model/template_reference.md (1714b), prompts/evolution/apply_after_confirm.md (1069b), prompts/evolution/emit_backlog.md (2321b), prompts/evolution/guardrails.md (1821b), prompts/evolution/intake.md (1197b), prompts/evolution/research.md (2611b), prompts/evolution/soft_nudge.md (1697b), prompts/oa/case_note_template.md (1568b), prompts/oa/configure_embedding.md (2340b), prompts/oa/guardrails.md (2430b), prompts/oa/ingest_case.md (1958b), prompts/oa/ingest_playbook.md (3046b), prompts/oa/intake.md (1151b), prompts/oa/respond_office_action.md (6110b), prompts/reader/obsidian_ofm_companion.md (2332b), prompts/reader/obsidian_plugin_guide.md (1656b), prompts/reader/patent_plain_reader.md (20353b), prompts/reader/patent_reader_self_check.md (1479b), prompts/reader/type_hooks.md (1990b), prompts/shared/design_lineart_assist.md (4902b), prompts/shared/fill_appearance_schema.md (3795b), prompts/shared/fill_structure_schema.md (4437b), prompts/shared/image_gen.md (3871b), prompts/shared/structure_lineart_assist.md (7378b), prompts/shared/structure_lineart_compose.md (5066b), README.md (15942b), references/formulas/paradigms.yaml (10100b), references/formulas/README.md (2239b), references/ipc_application_hints.yaml (3603b), references/patent_domain_rules.yaml (1030b), references/patent_obsidian_format.md (8048b), references/patent_pdf_sources.yaml (3513b), references/patent_type_search.yaml (3393b), references/schemas/appearance.schema.yaml (2266b), references/schemas/design_lineart_brief.schema.yaml (2754b), references/schemas/evolution_backlog.schema.yaml (1476b), references/schemas/figure_plan.schema.yaml (7699b), references/schemas/formula_plan.schema.yaml (2665b), references/schemas/oa_case.schema.yaml (3019b), references/schemas/oa_playbook.schema.yaml (907b), references/schemas/README.md (2421b), references/schemas/structure_callout_anchors.schema.yaml (2338b), references/schemas/structure_lineart_brief.schema.yaml (3667b), references/schemas/structure_lineart_compose.schema.yaml (2870b), references/schemas/structure.schema.yaml (1405b), requirements.txt (1012b), scripts/generate-star-history.py (17189b), skill-card.md (3595b), SKILL.md (21808b), tools/__init__.py (0b)\n\nFile v3.9.0:SKILL.md\n\n---\nname: patent-disclosure-skill\ndescription: \"中国专利技能：专利点挖掘与交底书（发明/实用/外观）编写，通俗解读专利，嗅探政策动向，辅助审查答复。| China patents skill: mine patent points and draft disclosures (invention / utility model / design), plain-language reading, policy sniffing, assisted office-action response.\"\nversion: \"3.9.0\"\nuser-invocable: true\nargument-hint: \"[可选：项目路径 / 专利号或 PDF / 政策动向嗅探或技能进化 / 审查答复、案例入库或实务书蒸馏]\"\nallowed-tools: Read, Write, Edit, Grep, Glob, WebSearch, Bash\n---\n\n# 中国专利技能 · 交底编写 · 通俗解读 · 政策/审查动向嗅探 · 审查答复\n\n本技能**单包模块化**：分步指令在 **`prompts/`**，执行前须 **`Read`** 对应文件。`SKILL.md` 只做路由。\n\n| 模式 | 何时用 | 主入口 |\n|------|--------|--------|\n| **A · 交底书编写** | 挖专利点 → 查新 → 成稿 → 迭代 | `prompts/disclosure/`（类型子目录见下） |\n| **B · 专利通俗解读** | 公开号 / PDF / 全文 → 通俗笔记 + 图谱 | `prompts/reader/patent_plain_reader.md` |\n| **C · 技能进化旁路** | 政策/审查动向嗅探 → 带时间戳清单 → **人审后**才改技能 | `prompts/evolution/`（须显式触发） |\n| **D · 审查答复辅助** | 案例脱敏入库；实务书→经验手册；通知书 → 检索+手册 → 自动出草稿（可换策略迭代） | `prompts/oa/`（须显式触发；草稿须复核后递交） |\n\n提供**专利号或专利全文/PDF**且意图为「读懂」时 → **优先模式 B**，**不**默认跑交底书 Step 1–8。  \n**禁止**因写交底/读专利自动进入模式 C/D。\n\n## 目录约定（薄路由）\n\n```\nprompts/disclosure/          # 交底公共流程\n  invention/                 # 发明：挖点 / builder / template\n  utility_model/             # 实用新型：挖点 / builder / template（单独 md，勿套用发明 mermaid 主线）\n  design/                    # 外观设计：挖点 / builder / template（单独 md）\nprompts/reader/              # 通俗解读 + type_hooks\nprompts/shared/              # 写读共用：Structure / Appearance 填表 + figure_plan + 线稿（image_gen）\nprompts/evolution/           # 模式 C：政策/审查动向嗅探 · 进化清单（旁路，须显式触发）\nprompts/oa/                  # 模式 D：审查答复 / 案例入库（旁路，须显式触发）\nreferences/schemas/          # structure / appearance / figure_plan / formula_plan / lineart / evolution / oa_case\nreferences/formulas/         # 发明公式推荐范式（paradigms.yaml，可外挂扩展）\ntools/crawl/                 # 国知局等爬取\ntools/shared/                # docx/mermaid/专利类型/可选 STEP（cad-env）/ 线稿门禁与按件拼装；browser.py + svg_screenshot.py\ntools/patent_reader/         # 解读工具：shared/ | extract/ | analyze/ | vault/\ntools/oa/                    # 模式 D：config / embed / sqlite-vec / ingest / search\noutputs/evolution/           # 模式 C 清单默认落盘（gitignore）\ndocs/evolution/              # 仅用户确认「沉淀」后可复制提交\ndocs/oa/                     # 模式 D：embedding 配置模板种子（运行时在系统文档目录）\n```\n\n## 环境与约定\n\n- **脚本判读（尤其 Windows）**：stderr 有字 **不等于** 失败。以 **退出码 0** 和机读前缀为准：`EPUB_HITS_JSON:` / `EPUB_MERGE:` / `EPUB_CLASS_HINT:`、`PROBE:` / `BROWSER:`、`MERMAID:` / `DOCX:` / `MATH:` / `omml_text_fallback=`、`CAD_VENV:` / `SVG_HTTP:` / `PIP_INDEX` / `PLAYBOOK:`。PowerShell 可能把 stderr 标成 `NativeCommandError` 或乱码；**禁止**因此重跑安装、或把查新降级 WebSearch。勿用 `2>&1` 把 JSON 混进错误流。\n- **专利类型**：未显式指定时交底**默认发明**；材料更偏实用/外观时在汇总或预览阶段**反问**（见 `disclosure/intake.md`）。\n- **交底书图示**：\n  - **发明**：3.2 / 3.4 用 fenced **mermaid** → `tools/shared/mermaid_render.py`（Playwright + 内置 mermaid.js，见 `tools/shared/browser.py`）。流程图步骤号须写入可见标签：`S1[\"S1 …\"]`（id 本身不出图）。成文须让**标题领域对象**贯穿 3.1 / 框图 / 流程 / 实施例；用词贴合话题背景，话题错位的抽象行话换成领域表述（发明 `disclosure_builder.md` §7.9）。\n  - **实用新型**：先 `figure_plan.yaml` 排序入文图（**只入合格线稿**；CAD 投影不入文）+ 部件/关系表（见 `utility_model/disclosure_builder.md`）。\n  - **外观**：先判立体/平面与要点落面，再写 `figure_plan.yaml` 选正投影（**非默认六视**；**干净实拍 + 线稿都入文**，写入 md 与 Word；CAD 不入文）（见 `design/disclosure_builder.md`）。\n- **STEP / CAD（可选，默认关）**：Step 2 用 `cad_scan.py` 分类；**不中断**挖点/成文。遇 `.step`/`.stp` 记下路径，交底 **落盘后再反问**是否开启解析；用户 **是** 才 `cad_venv.py`（已就绪则跳过安装）/`bootstrap_cad_venv.py` + `run_step_to_views.py --enable-step-parse`。CadQuery 只进 `tools/shared/cad-env`（Python 3.10–3.12，不强制 3.10）。PNG：有 Cairo 用 cairosvg，否则 `svg_screenshot.py` 无头浏览器截 SVG；**禁止为 CAD 安装 matplotlib**（matplotlib 只用于发明公式 PNG）。投影图是**普通材料**（`kind: cad`），**不得**当线稿、**不得**入文；打分后可能作图生图参考。仅有原生 CAD 则交付回复末尾提示导出 STEP。见 `project_scan.md`「CAD / STEP」。\n- **外观线稿（必做）**：填表后 **`Read`** `shared/image_gen.md` + `shared/design_lineart_assist.md`。不问用户。已有合格线稿则入文；否则大模型生成。干净实拍**同时入文**（md + Word），但不得标成线稿。CAD 不入文。仅用户明确不要或 `PATENT_SKILL_SKIP_LINEART=1` 才跳过。\n- **实用结构线稿（必做）**：填表后 **`Read`** `shared/image_gen.md` + `shared/structure_lineart_assist.md`（轮廓后 **`Read`** `shared/structure_lineart_compose.md`）。不问用户。对齐 `structure_schema.parts`；轮廓按件拼装为子 SVG + 总图相对引用，再叠序号。推荐：`structure_lineart_compose.py` 每件落 `parts/{视}_{id}.svg`，总图 `<g id=\"part-N\">` 引用子文件（不要整图 base64+clip），大模型只定位并把归一化锚点持久化到 `structure_callout_anchors.yaml`（含 `base_svg_path`），再由 `structure_callout_overlay.py` **注入**件号组；**叠标后须读图按部件名称核对引出线**（改 YAML 重叠标，最多 2 轮；禁止含件号二次生图或自创件号）。CAD 不得当线稿入文。**勿**与外观 `design_lineart_*` 混用。\n- **解读 + Obsidian**：强烈推荐配置库；见 **`docs/obsidian-setup-guide.md`**。\n- **技能进化 / 动向嗅探（须显式触发）**：用户点名后走模式 C（政策/审查动向嗅探 → 清单）；清单含 **观点↔信源 URL 表**；未人审确认前**不**改技能正文。\n- **审查答复（须显式触发）**：用户点名后走模式 D；向量模型**可选**（可 `skip-vector`，中途再 enable + 重建）；推荐智谱 `embedding-3`；标签检索始终可用，向量超时则回退。实务书蒸馏：只要**本地路径**，先预读再外挂 book-to-skill，手册进 `oa/playbooks/`、不进案例检索。\n\n---\n\n## 触发条件\n\n- **交底书**：专利挖掘、交底书、查新、实用新型、外观设计等；`/patent-disclosure-skill`、`/交底书`。\n- **通俗解读**：读专利、公开号 / PDF 且目标为理解；`/patent-read`、`/读专利`。\n- **交底书迭代**：已有交底上补材料/纠错 → `disclosure/iteration_context.md` → `merger` / `correction_handler`；另存时间戳稿。\n- **技能进化旁路**：技能进化、政策/审查动向嗅探、政策雷达、审查政策更新、自进化、`/patent-evolve`、`/技能进化` → **仅此时**进入模式 C。\n- **审查答复 / 案例入库 / 经验手册**：审查意见、意见陈述、OA、补正通知书、案例入库、书籍蒸馏、实务书、`/oa`、`/审查答复` → **仅此时**进入模式 D。\n\n---\n\n## 工具与数据来源\n\n| 任务 | 建议方式 |\n|------|----------|\n| 加载分步指令 | **`Read`** → `prompts/disclosure|reader|shared|evolution/…`（完整子路径） |\n| Word / PPT → Markdown | `tools/shared/docx_to_md.py` / `pptx_to_md.py` |\n| CAD 扫描 / STEP→多视图（可选，默认关） | `tools/shared/cad_scan.py`；**交付后**用户确认才 `cad_venv.py`（就绪则跳过安装）+ `run_step_to_views.py --enable-step-parse`；投影只当材料 |\n| 线稿规划（必做） | `prompts/shared/image_gen.md`；`tools/shared/image_gen.py`（existing / img2img / txt2img） |\n| 外观线稿（必做） | `prompts/shared/design_lineart_assist.md`；门禁 `design_lineart_gate.py` |\n| 实用结构线稿（必做） | `prompts/shared/structure_lineart_assist.md` + `structure_lineart_compose.md`；门禁 `structure_lineart_gate.py`；拼装 `structure_lineart_compose.py`；锚点 `structure_callout_anchors.yaml`；叠标 `structure_callout_overlay.py` |\n| 联网查新 | **`Read`** `disclosure/prior_art_search.md`。优先 **`cnipa_epub_search.py --type …`**（与 intake 一致）；**两段式**：关键词 → `EPUB_CLASS_HINT` / `ipc_codes`·`loc_codes` → `--class` 第二轮（发明/实用 IPC，外观 **LOC**）；1.1 优先第二轮；不足 4 条则同分类号回补第一轮，仍少可仅分类号/相邻号再查，禁止编造凑数。Google Patents `CPC=` 仅可选补充，被墙即跳过。`abstract` 必用；公布站失败再 WebSearch。见 `patent_type_search.yaml` |\n| 交底定稿 | 发明：`tools/shared/mermaid_render.py` → md+docx；实用/外观：按各类型 builder（外观 md+docx 须同时嵌实拍与线稿） |\n| 专利通俗解读 | **`Read`** `reader/patent_plain_reader.md`；实用/外观另 Read `reader/type_hooks.md` + `shared/fill_*` |\n| 解读取 PDF / 入库 | `tools/patent_reader/extract/fetch_patent_pdf.py`；`…/vault/write_patent_obsidian_note.py` 等（见 `tools/patent_reader/README.md`） |\n| 政策/审查动向嗅探 | **`Read`** `evolution/intake.md` → `research.md`（WebSearch + 官网抓取）→ `emit_backlog.md`；确认后 `apply_after_confirm.md` |\n| 审查答复 / 案例库 | **`Read`** `oa/intake.md`；PDF 用 `oa/pdf_text.py` / `search_cases.py --pdf` / `ingest_case.py --pdf`；入库 `oa/ingest_case.md`；手册 `oa/ingest_playbook.md` + `ingest_playbook.py`；答复 `oa/respond_office_action.md`；配置 `oa/config.py` |\n\n---\n\n## Prompt 文件映射\n\n### 交底书（公共 + 类型特化）\n\n| 步骤 | 文件 | 用途 |\n|------|------|------|\n| Step 1 | `prompts/disclosure/intake.md` | 边界；**默认发明**；可反问实用/外观 |\n| Step 2 | `prompts/disclosure/project_scan.md` | 项目扫描（Office + **可选 CAD/STEP**；三类示例加扫） |\n| Step 3–4 | **发明** `disclosure/invention/patent_points_analyzer.md`；**实用** `utility_model/patent_points.md`；**外观** `design/patent_points.md` | 挖点（**分文件，勿混用**） |\n| 填表（实用/外观） | `prompts/shared/fill_structure_schema.md` / `fill_appearance_schema.md` | 图→schema + **`figure_plan.yaml`**（打分；CAD 不入文） |\n| 线稿规划 | `prompts/shared/image_gen.md` | 必做；existing / img2img / txt2img |\n| 外观线稿 | `prompts/shared/design_lineart_assist.md` | 必做；不问用户；实拍+线稿都入 md/Word；CAD 不是线稿 |\n| 实用结构线稿 | `prompts/shared/structure_lineart_assist.md` | 必做；不问用户；轮廓→子 SVG+总图引用→按 parts 叠序号 |\n| 实用线稿拼装 | `prompts/shared/structure_lineart_compose.md` | 独立模块；每件一个子 SVG，总图相对引用，再注入件号 |\n| Step 5 | `prompts/disclosure/prior_art_search.md` | 查新（`--type`） |\n| Step 6 | `prompts/disclosure/disclosure_preview.md` | 摘要预览（按类型裁剪） |\n| Step 7 | 对应类型目录 `disclosure_builder.md` + `template_reference.md` | 成文（**分文件**；发明含公式时先 `formula_plan.yaml`） |\n| Step 8 | `prompts/disclosure/disclosure_self_check.md` | 内部自检（含 §8.4 / §8.5） |\n| 迭代 | `disclosure/iteration_context.md` / `merger.md` / `correction_handler.md` | 另存 |\n\n### 专利通俗解读\n\n| 步骤 | 文件 |\n|------|------|\n| 主流程 | `prompts/reader/patent_plain_reader.md` |\n| 类型挂钩 | `prompts/reader/type_hooks.md` |\n| 写笔记 | `reader/obsidian_ofm_companion.md` + `references/patent_obsidian_format.md` |\n| 自检 / 插件引导 | `reader/patent_reader_self_check.md` / `obsidian_plugin_guide.md` |\n| 取 PDF | `tools/patent_reader/extract/fetch_patent_pdf.py` |\n| 入库 | `tools/patent_reader/vault/write_patent_obsidian_note.py` |\n\n### 技能进化旁路 · 政策/审查动向嗅探（模式 C）\n\n| 步骤 | 文件 |\n|------|------|\n| 总则 | `prompts/evolution/guardrails.md` |\n| 录入 | `prompts/evolution/intake.md` |\n| 检索/抓取 | `prompts/evolution/research.md` |\n| 出清单 | `prompts/evolution/emit_backlog.md` |\n| 确认后改技能 | `prompts/evolution/apply_after_confirm.md`（须人审） |\n| 交底交付低频提示 | `prompts/evolution/soft_nudge.md`（可选一句，不入正文） |\n| 合同 | `references/schemas/evolution_backlog.schema.yaml` |\n\n### 审查答复（模式 D）\n\n| 步骤 | 文件 |\n|------|------|\n| 总则 | `prompts/oa/guardrails.md` |\n| 录入 | `prompts/oa/intake.md` |\n| 向量对话配置 | `prompts/oa/configure_embedding.md`（问答 → set/secrets → selftest） |\n| 脱敏入库 | `prompts/oa/ingest_case.md` + `tools/oa/ingest_case.py`（支持 `--pdf`） |\n| 经验手册 | `prompts/oa/ingest_playbook.md` + `tools/oa/ingest_playbook.py`（先 peek；本地路径；`oa/playbooks/`） |\n| 答复草稿 | `prompts/oa/respond_office_action.md` + `tools/oa/search_cases.py --pdf`（可 Read 手册 cheatsheet） |\n| PDF 抽取 | `tools/oa/pdf_text.py`（pymupdf；优先路径，禁止让用户手贴） |\n| 案例模板 | `prompts/oa/case_note_template.md` |\n| 合同 / 配置 | `references/schemas/oa_case.schema.yaml`、`oa_playbook.schema.yaml`；运行时 `{Documents}/…/oa/embedding.config.yaml`（仓库模板 `docs/oa/`） |\n\n---\n\n## 模式 A · 交底书主流程\n\n1. **`Read`** `disclosure/intake.md` → Step 1（默认发明）  \n2. **`Read`** `disclosure/project_scan.md` → Step 2  \n3. 按类型 **`Read`** `invention|utility_model|design` 挖点；实用/外观先/并行 **`Read`** `shared/fill_*`  \n   - 填表写出 `figure_plan` 后：**`Read`** `shared/image_gen.md` + 对应 `shared/*_lineart_assist.md`（必做，不问用户）  \n4. **`Read`** `disclosure/prior_art_search.md` → Step 5（`--type` 对齐）  \n5. **`Read`** `disclosure/disclosure_preview.md` → Step 6（可跳过；此处可类型反问）  \n6. **`Read`** **同类型** `disclosure_builder` + `template_reference` → Step 7（**禁止**用发明 builder 写实用/外观）  \n7. **`Read`** `disclosure/disclosure_self_check.md` → Step 8  \n8. **交付回复末尾**：若 cad_scan 为 `ask_enable_step_parse`，交底落盘后再反问是否开启 STEP 解析；`hint_export_step` 则提示导出。未得 **是** 禁止装依赖。用户成文前已主动说「是」的除外。\n\n**禁止**：交底书正文出现「自检清单」章节。\n\n---\n\n## 模式 B · 专利通俗解读\n\n1. **`Read`** `reader/patent_plain_reader.md`（门禁 / fetch / extract / 线索 / 入库）  \n2. 若实用新型或外观：**`Read`** `reader/type_hooks.md` + 对应 `shared/fill_*`  \n3. **`Read`** ofm + 自检；入库后可选插件引导；≥2 篇反问关联  \n\n**与模式 A 互斥**：解读不跑交底 Step 1–8。\n\n---\n\n## 模式 C · 技能进化旁路 · 政策/审查动向嗅探\n\n1. **`Read`** `evolution/guardrails.md` → `intake.md`  \n2. **`Read`** `evolution/research.md`：WebSearch + 打开国知局等官网正文；默认近 12 个月  \n3. **`Read`** `evolution/emit_backlog.md`：写入 `outputs/evolution/EVOL-YYYYMMDD-HHMM.md`  \n   - **主表必为「观点 ↔ 信源 URL」**（一行一观点，附准确 `https://` 链接）  \n   - 证据 C（自媒体等）不得单独支撑「改技能」建议  \n4. 展示人审闸门；**等待**「全部采纳 / 采纳 E… / 全部搁置 / 沉淀到 docs/evolution/」  \n5. 仅确认采纳后 → **`Read`** `apply_after_confirm.md` → 最小改动 prompts，并写 `.status.md`  \n\n交底定稿交付后的**可选一句**提示见 `evolution/soft_nudge.md`（低频；**不**等于自动进入本模式）。\n\n**与 A/B 互斥**：进化旁路不写交底书、不做专利解读成稿。\n\n---\n\n## 模式 D · 审查答复辅助\n\n1. **`Read`** `oa/guardrails.md` → `intake.md`  \n2. **首次 / 改向量**：`Read` `oa/configure_embedding.md` → 对话问清（可跳过 / 预设 / 自定义 URL+模型+Key）→ `config.py set … --api-key …`（默认 **selftest**）→ 需重建则人确认后 `rebuild_vectors.py --confirm`  \n3. **入库**：`ingest_case.py`（支持 `--pdf`）；笔记进 `oa/cases/history/`（或 pending/drafts）；自动刷新 `_OA索引` / Canvas / Bases；无向量时仍写笔记 + 元数据  \n4. **经验手册**：`ingest_playbook.py peek` → 判断审查答复相关且值得蒸馏（不合适则拒绝，除非用户强烈要求）→ `ensure-skill` 自动安装 [book-to-skill](https://github.com/virgiliojr94/book-to-skill) → 按该 skill 蒸馏本地书 → `ingest` 到 `oa/playbooks/`（**不进**案例向量）  \n5. **答复**：`search_cases.py --pdf …` → `ingest_playbook.py list` 并按缺陷 Read cheatsheet → **同点多策略相对分（分差≥15 且过保范围门槛才改缩权；禁止授权率、禁止裸 argmax）** → 出一份草稿 → 事后短摘要；用户可换策略另存新稿  \n6. **仅刷新 Obs**：`python tools/oa/refresh_vault.py` \n\n依赖：`pip install -r tools/oa/requirements-oa.txt`。  \n**与 A/B/C 互斥**：不写交底书主流程；草稿须复核后递交（写稿前不中断勾选；换策略则另存新稿）。\n\n---\n\n## 迭代模式（交底书 · 摘要）\n\n- 补材料 / 扩展：`iteration_context` → `merger` → 新时间戳稿（实用/外观若改图或主题须同步 **`figure_plan`**；术语改叫法则整族替换）  \n- 纠错：`iteration_context` → `correction_handler` → 新时间戳稿（同上；含术语太抽象、标题对象未落地）  \n\n---\n\n## Agent 自用工作流检查清单\n\n```\n□ 已区分模式 A / B / C / D / 迭代，未混跑\n□ 交底未指定类型时已默认发明；材料偏实用/外观已按需反问\n□ Step 3–4 / Step 7 已 Read 对应类型子目录 md（非发明套用实用/外观）\n□ 查新 cnipa 已带与案件一致的 --type；两段式（关键词 → IPC/LOC → --class）；外观用 LOC；1.1 优先第二轮，不足 4 条已同分类号回补（仍少可仅分类号/相邻号，未编造凑数）；未粘贴合并大杂烩；GP 被墙已跳过；abstract 必用\n□ 发明成文：3.1 已铺标题对象与领域术语；框图/流程/实施例贯穿标题实词；用词贴合话题背景（错位行话已换成领域表述，非靠定义保留）；3.3 独立模块、3.4 逐项对应 S 步；第五章为可实施机制\n□ 发明含公式：已写 formula_plan（范式∈references/formulas）且可算数值例；禁装饰音；已 check_formula_plan 或等价自检；行内为 \\(...\\)/$...$ 而非 (M_{\\mathrm{…}})；latex_delimiters 无 hits；改正后已用时间戳 md 重出 Word\n□ 实用/外观已走 schema 填表（shared）并写出 figure_plan（含 relevance/quality 与必要 relates_to），未看图直接长文；实用只嵌入文线稿；外观 md+docx 同时嵌实拍与线稿；CAD 未入文\n□ Step 2/补材料已 cad_scan：遇 STEP **未**中断成文、**未**装依赖；交底落盘后才反问；仅原生 CAD 则交付回复末尾提示导出 STEP；未确认不开 step_to_views；确认后先 cad_venv 探测，已就绪则跳过 bootstrap；CAD 投影只当材料\n□ 外观线稿：已 Read image_gen.md + design_lineart_assist；已有合格线稿则未再生成，否则图生图或先描述再文生图；实拍与线稿均已入 md 与 Word；CAD 未当线稿入文\n□ 实用结构线稿：已 Read image_gen.md + structure_lineart_assist + structure_lineart_compose；件号对齐 parts；已按件写出 parts/{视}_{id}.svg 且总图相对引用（一层一件号，未拆筋/齿/螺栓，未整图 clip）；优先 overlay 注入；已叠标后读图核对（非仅 Python 合法）；未自创件号；CAD 未入文\n□ 迭代改材料/主题时已重评 figure_plan（含图际关联）\n□ 解读实用/外观：公开号种类码或 patent_type.py / fetch 状态已判别类型，并 Read type_hooks + 共用 schema（用户未口头声明也可）\n□ 模式 C：已显式触发；清单含观点↔URL 主表；未确认前未改技能；确认后才 apply\n□ 交底定稿交付：已按 evolution/soft_nudge 判断是否加低频一句（未每次必出、未写入正文）\n□ 模式 D：已显式触发；向量可选已反问（可跳过）；PDF 已自动抽取；入库已脱敏；检索展示 retrieval_mode；向量失败已回退标签；需重建时已人确认；手册先预读再蒸馏且未进案例向量；答复同点多策略用相对分+保范围门槛（非授权率、非裸 argmax），事后摘要且可换策略另存新稿\n□ 路径使用 prompts/disclosure|reader|shared|evolution|oa 与 tools/crawl|shared|oa|patent_reader/{extract,analyze,vault,shared}\n```\n\nFile v3.9.0:assets/obsidian/README.md\n\n# Obsidian 库模板\n\n本目录是仓库源稿。入库脚本会把文件拷进用户的 Obsidian 库。\n\n## Bases 扩展名\n\n部分技能市场不允许提交 `.base`。因此仓库里只保留 `*.base.yaml`：\n\n| 仓库源稿 | 拷进库后 |\n|----------|----------|\n| `patents.base.yaml` | `{papers_dir}/patents.base` |\n| `glossary.base.yaml` | `{glossary_dir}/glossary.base` |\n| `oa.base.yaml` | `oa/_OA看板.base` |\n\nObsidian Bases 仍只认 `.base`。不要在库内用 `.base.yaml`，也不要把库内 wikilink（如 `![[…/patents.base#…]]`）改成 yaml 后缀。\n\nFile v3.9.0:docs/evolution/README.md\n\n# docs/evolution — 已确认沉淀的进化清单（可选提交）\n\n日常雷达产出默认在 **`outputs/evolution/`**（gitignore，不进仓）。\n\n仅当用户在模式 C 中确认「沉淀到 docs/evolution/」时，将对应 `EVOL-*.md` **复制**到本目录，作为可版本管理的知识备忘。\n\n不要把未确认的草案直接提交到这里。\n\nFile v3.9.0:docs/oa/README.md\n\n# 模式 D · 审查答复案例库\n\n运行时数据优先落在操作系统**默认文档目录**（可用 `PATENT_OA_HOME` 覆盖）：\n\n| 路径 | 用途 |\n|------|------|\n| `{Documents}/patent-disclosure-skill/oa/embedding.config.yaml` | 嵌入模型与 sqlite 路径（首次须用户确认） |\n| `{Documents}/patent-disclosure-skill/oa/data/oa_vectors.sqlite` | sqlite-vec 向量库 |\n| `{Documents}/patent-disclosure-skill/oa/` | 无 Obsidian 库时的 oa 回退根 |\n| 本目录 `embedding.config.yaml` | **仓库模板种子**（`config.py seed` 复制到文档目录） |\n\n正式案例优先写入 **Obsidian**（方案 C）：\n\n```\n{vault}/oa/\n  _OA索引.md\n  _OA看板.base\n  _OA关联.canvas\n  cases/history/   # status=history，可检索\n  pending/         # 待答复\n  drafts/          # 人审草稿\n  playbooks/       # 实务书蒸馏手册（不进案例检索）\n```\n\n刷新：`python tools/oa/refresh_vault.py`  \n查看实际路径：`python tools/oa/config.py recommend`。  \n仓库源稿是 `assets/obsidian/oa.base.yaml`（部分技能市场不允许提交 `.base`）；写入库时仍为 `_OA看板.base`。  \n流程见 `prompts/oa/` 与 [SKILL.md](../../SKILL.md) 模式 D。\n\nFile v3.9.0:README.md\n\n<div align=\"center\">\n\n# 中国专利.skill\n\n> 专利点挖掘与交底书（发明/实用/外观）编写，通俗解读专利，嗅探政策动向，辅助审查答复。\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n[![Python 3.9+](https://img.shields.io/badge/Python-3.9%2B-blue.svg)](https://www.python.org/)\n[![Playwright](https://img.shields.io/badge/Playwright-mermaid%20%2B%20CNIPA-2EAD33.svg)](https://playwright.dev/)\n[![AgentSkills](https://img.shields.io/badge/AgentSkills-Standard-green)](https://agentskills.io)\n\n<br>\n\n有设计文档和代码，但**专利点还没梳**？交底书要**框图 + 可改 Word**？<br>\n定稿后还要**多轮补材料、纠错**并留下修改追溯？<br>\n公开专利晦涩难懂，想**快速看懂权要与落地语境**？\n\n[初衷](#初衷) · [运行效果](#运行效果) · [功能特性](#功能特性) · [示例](#示例) · [支持作者](#支持作者) · [参考文档](#参考文档) · [安装说明](INSTALL.md) · [技能入口](SKILL.md)\n\n</div>\n\n---\n\n## 初衷\n\n### 专利交底书编写\n\n> **做了多年核心研发，专利发明人那一栏从没写过我的名字。**\n\n代码是自己敲的，方案是自己扛的，轮到交底书却卡在「专利点怎么挖、查新怎么写、框图和 Word 怎么一次交得出去」。本技能把这一环打通：覆盖发明 / 实用新型 / 外观设计，结构图与外观图都能读懂、写进交底；从项目材料梳出可申请的点，查新、脱敏、成文、迭代另存——让真正干活的人，也能把技术贡献写进可交付的交底书里。\n\n### 专利通俗解读\n\n> **不止一篇。**\n\n公开专利常把阅读门槛抬得很高：权要绕、术语密、落地语境散落在说明书与附图里。本技能把单篇读成通俗笔记与图谱，并入库 Obsidian；依托双链、图谱、插件与 Bases 等生态，陆续解读的专利可以沉淀成**只属于自己的私有专利知识库**——权要、术语、线索与附图彼此勾连，越读越厚。再叠上 [Obsidian CLI](https://help.obsidian.md/cli) 与库内外连接能力，检索、批处理、和外部工具接力都更容易：从单篇通俗笔记，走向可检索、可关联、可继续生长的个人专利情报层，把沉睡在 PDF 里的技术细节重新点亮。库厚了之后，还能在这层之上做**专利比对、挖掘与分析**——同族对照、技术路线梳理、差异点扫描，把「读懂」推进到「用起来」。\n\n---\n\n## 运行效果\n\n### 专利交底书编写\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">初版生成<br><sub>首次落盘交付</sub></th>\n<th width=\"50%\" align=\"center\">迭代更新<br><sub>多版本并存 + 对话记录</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-初版生成.jpg\" alt=\"初版生成：outputs 目录下的时间戳交底书、mermaid 图目录等\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-迭代更新.jpg\" alt=\"迭代更新：新时间戳文件与交底书修订对话记录\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 实用新型 / 外观 · 看图与出图\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"33%\" align=\"center\">外观线稿<br><sub>从产品图自动提炼造型轮廓</sub></th>\n<th width=\"33%\" align=\"center\">实用新型线稿<br><sub>从结构图自动生成轮廓与部件序号引出</sub></th>\n<th width=\"34%\" align=\"center\">CAD 三维模型投影<br><sub>从工程模型自动提取等轴测等多视角</sub></th>\n</tr>\n<tr>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-外观专利线稿.png\" alt=\"外观辅助线稿：产品造型黑白线稿示意\" width=\"100%\" />\n</td>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-实用新型专利线稿含部件序号引出线.png\" alt=\"实用新型辅助线稿：结构线稿与部件序号引出线\" width=\"100%\" />\n</td>\n<td width=\"34%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-cad提取等轴测投影图.png\" alt=\"CAD 三维模型等轴测投影：从工程模型自动提取多视角示意\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 专利通俗解读\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">Obsidian 关系图<br><sub>知识图谱与多色节点</sub></th>\n<th width=\"50%\" align=\"center\">解读 Canvas<br><sub>叙事故事线 · 术语 · 公开线索</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-obs图谱.jpg\" alt=\"Obsidian 关系图：解读笔记、术语与 Canvas 知识图谱\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-解读.jpg\" alt=\"专利解读 Canvas：叙事、权要、术语与公开线索图谱\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 功能特性\n\n### 专利交底书编写\n\n支持 **发明**、**实用新型**、**外观设计** 三种专利类型（未指定时默认发明；材料偏结构/外观时可反问切换）。\n\n<!-- 使用 HTML 表格：避免 GitHub 管道表把左列挤窄 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>专利类型</strong></td><td>发明 / 实用新型 / 外观设计<strong>分模板成文</strong>；实用与外观先填 Schema，再写 <code>figure_plan.yaml</code> 排序入文图（成文不扫全 assets 临场挑图）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>项目扫描</strong></td><td>按优先级读文档 / 代码；<code>.docx</code> / <code>.pptx</code> 先转 Markdown 再扫；可选扫描 <code>.step</code>/<code>.stp</code> 与原生 CAD（<strong>默认不解析</strong>，遇 STEP 成文不中断，交底落盘后再问）（<code>project_scan.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>外观线稿</strong></td><td>成文前选用或生成产品线稿（已有合格线稿优先，否则图生图 / 文生图）；与干净实拍一并写入 Markdown 和 Word（<code>design_lineart_assist.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>实用结构线稿</strong></td><td>成文前选用或生成结构线稿，按 <code>structure_schema.parts</code> 写出子 SVG、总图相对引用并叠部件序号（<code>structure_lineart_assist.md</code> / <code>structure_lineart_compose.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>专利点</strong></td><td>候选点讨论与融合（按类型：<code>invention|utility_model|design</code> 挖点文件）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>查新</strong></td><td><strong>优先</strong> <a href=\"http://epub.cnipa.gov.cn/\">国知局 · 中国专利公布公告</a>（<code>tools/crawl/cnipa_epub_search.py</code>，<code>--type</code> 对齐类型）；异常或无果时降级 WebSearch。著录写入第一章（<code>prior_art_search.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>交底书成稿</strong></td><td>脱敏模版；发明用 <strong>mermaid</strong> 框图；实用/外观按 <code>figure_plan</code> 嵌结构图或视图；定稿可出 <strong>.docx</strong></td></tr>\n<tr><td nowrap width=\"1%\"><strong>交付命名</strong></td><td><code>{案件名}_{YYYYMMDDHHmmss}.md</code> 与同名 <code>.docx</code>（<code>disclosure_builder.md</code> §7.3）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>自检 / 迭代</strong></td><td>逻辑与公式自检（不写入正文）；合并 / 纠正另存新文件 + <code>交底书修订对话记录.md</code></td></tr>\n</tbody>\n</table>\n\n怎么开口：自然语言即可（专利挖掘、交底书、查新等），或 `/交底书`、`/patent-disclosure-skill`；尽量带上**项目路径或技术主题**，并点明类型（未指定默认**发明**）。\n\n| 类型 | 典型场景 | 触发示例 |\n|------|----------|----------|\n| **发明** | 方法 / 系统 / 算法流程 | 「按发明写交底」「项目路径 …」 |\n| **实用新型** | 形状、构造、连接与装配 | 「实用新型」「一种…装置/结构」 |\n| **外观设计** | 外形、图案、色彩或其结合 | 「外观设计」「设计说明 / 视图」 |\n\n已有交底上补材料或纠错时，按 `merger.md` / `correction_handler.md` 另存新稿（实用/外观改图或主题时同步 `figure_plan`）。细则见 [SKILL.md](SKILL.md)、`prompts/disclosure/intake.md`。\n\n### 专利通俗解读\n\n**强烈推荐安装 Obsidian**：索引、Canvas 知识图谱、术语网与 callout 配色依赖库内呈现，才能发挥本模式的完整体验。安装与可选社区插件见 [docs/obsidian-setup-guide.md](docs/obsidian-setup-guide.md)。\n\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>取证解读</strong></td><td>全文 / PDF 抽取 → 权要树、术语表、特征—说明书—附图对照（<code>patent_plain_reader.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>叙述故事线</strong></td><td>一句话总览 + 连贯叙事：把权要与说明书「讲成人话」，降低首次通读成本</td></tr>\n<tr><td nowrap width=\"1%\"><strong>知识图谱</strong></td><td>单篇 <code>*_图谱.canvas</code>、多篇 <code>_专利关联.canvas</code>、术语双链与关系图配色；入库<strong>自动</strong>配置 CSS / Bases</td></tr>\n<tr><td nowrap width=\"1%\"><strong>公开线索辅助</strong></td><td>联网检索公开材料（≤3 条）；Agent 读 URL 写摘要；L1–L4 旁注与 <code>clues/</code> 落地，用行业语境辅助理解（<strong>非</strong>权要 / 说明书证据）</td></tr>\n</tbody>\n</table>\n\n怎么开口：读专利、专利解读、`/读专利`、`/patent-read`，并给出**公开号或 PDF 路径**。配置库环境变量 `PATENT_READER_OBSIDIAN_VAULT` 体验更完整；无库时可降级到 `outputs/patent_reader/`。流程见 [tools/patent_reader/README.md](tools/patent_reader/README.md)、[SKILL.md](SKILL.md)。\n\n### 政策感知与技能自进化\n\n审查指南、智能审查口径一变，交底写法很容易「还按老习惯」。需要时可以说一声「技能进化 / 政策雷达 / 政策审查动向嗅探」：联网看看国知局等官网**近期政策与审查动向**，把观点和原文链接整理成**参考清单**（默认 `outputs/evolution/EVOL-*.md`；确认沉淀后再拷到 `docs/evolution/`），帮你判断技能该不该跟、怎么跟。也可 `/patent-evolve`、`/技能进化`。默认不开；你点头确认前，**不会**擅自改交底/解读流程。细则见 [SKILL.md](SKILL.md)「模式 C」与 `prompts/evolution/`。\n\n### 审查答复辅助\n\n审查意见一来，往往要翻旧案、对法条、想策略——经验散落在 PDF 和聊天记录里，很难复用。需要时可以说「审查答复 / 案例入库 / `/审查答复`」：**自动**完成「历史通知书与答复脱敏写入 Obsidian、打上法条/缺陷等标签以固化经验 → 对新通知书做标签过滤（向量模型可选；启用后叠加本地轻量向量相似度检索，相当于外挂一套属于自己的 RAG 知识库）→ 交大模型起草意见陈述」整条链路。也可把**本地**审查答复实务书先预读、再蒸馏成 `oa/playbooks/` 经验手册（不进案例检索），写答复时按缺陷查阅。向量可跳过，也可中途开启并重建索引；向量不可用时仍靠标签检索继续出草稿。默认不开；产出为草稿，须人审后再递交。细则见 [SKILL.md](SKILL.md)「模式 D」、[docs/oa/README.md](docs/oa/README.md)、[tools/oa/README.md](tools/oa/README.md)。\n\n接入宿主、Python / Node、可选 STEP 等见 **[INSTALL.md](INSTALL.md)**。\n\n---\n\n## 示例\n\n索引见 [examples/README.md](examples/README.md)。完整产物落在 **`outputs/`** 或 Obsidian 库。\n\n<!-- 使用 HTML 表格：前两列 nowrap 防挤窄，后两列自动换行 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col width=\"1%\">\n<col>\n<col>\n</colgroup>\n<thead>\n<tr>\n<th align=\"left\" nowrap width=\"1%\">示例</th>\n<th align=\"left\" nowrap width=\"1%\">类型</th>\n<th align=\"left\">材料</th>\n<th align=\"left\">怎么开口</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td nowrap width=\"1%\">批任务调度</td>\n<td nowrap width=\"1%\"><strong>发明</strong>交底</td>\n<td><a href=\"examples/example_batch_job_scheduler/\"><code>examples/example_batch_job_scheduler/</code></a>（扫 <code>knowledge/</code>）</td>\n<td>「按发明写交底，项目路径 …/knowledge/」或 <code>/交底书</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">汽车集成式电驱桥</td>\n<td nowrap width=\"1%\"><strong>实用新型</strong>交底</td>\n<td><a href=\"examples/example_utility_model_ev_powertrain/\"><code>examples/example_utility_model_ev_powertrain/</code></a></td>\n<td>「实用新型交底，材料在 …/example_utility_model_ev_powertrain/」</td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">折臂台灯</td>\n<td nowrap width=\"1%\"><strong>外观设计</strong>交底</td>\n<td><a href=\"examples/example_design_desk_lamp/\"><code>examples/example_design_desk_lamp/</code></a></td>\n<td>「外观设计交底，材料在 …/example_design_desk_lamp/」</td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">公开专利 PDF</td>\n<td nowrap width=\"1%\"><strong>通俗解读</strong></td>\n<td><a href=\"examples/example_patent_reader/\"><code>examples/example_patent_reader/</code></a>（PDF 本地自备）</td>\n<td>「读专利」+ 公开号或 PDF；<code>/读专利</code>、<code>/patent-read</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">政策 / 审查动向</td>\n<td nowrap width=\"1%\"><strong>技能自进化</strong></td>\n<td>无需本地样例（联网出清单 → <code>outputs/evolution/EVOL-*.md</code>）</td>\n<td>「技能进化 / 政策雷达 / 政策审查动向嗅探：近 12 个月国知局动向，整理观点↔链接，先别改技能」；<code>/patent-evolve</code>、<code>/技能进化</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">审查答复样例</td>\n<td nowrap width=\"1%\"><strong>审查答复</strong></td>\n<td><a href=\"examples/example_oa_response/\"><code>examples/example_oa_response/</code></a>（2 历史案 + 1 待答复通知书）</td>\n<td>「审查答复：先入库 <code>cases/</code>，再用 <code>pending/oa_notice_pending.md</code> 出草稿；向量可跳过」；<code>/审查答复</code>、<code>/oa</code></td>\n</tr>\n</tbody>\n</table>\n\n---\n\n## 支持作者\n\n如果这个 Skill 对您有帮助，可以请我喝杯咖啡☕随缘支持，感谢感谢🙏🙏\n\n<table width=\"70%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"40%\" align=\"center\">随缘支持</th>\n<th width=\"60%\" align=\"center\">Star History</th>\n</tr>\n<tr>\n<td width=\"40%\" valign=\"middle\" align=\"center\">\n<img src=\"docs/thanks.jpg\" alt=\"随缘支持\" width=\"200\" />\n</td>\n<td width=\"60%\" valign=\"middle\" align=\"center\">\n<img alt=\"Star History Chart\" src=\"https://raw.githubusercontent.com/handsomestWei/patent-disclosure-skill/star-history/star-history.svg\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 参考文档\n\n- [技能入口与 Agent 流程](SKILL.md)（交底 / 解读 / 进化 / 审查答复）\n- [详细安装说明](INSTALL.md)\n- [交底书：图示与转换 / 国知局工具](tools/README.md)\n- [专利解读工具](tools/patent_reader/README.md)\n- [审查答复 · 案例 RAG](tools/oa/README.md)\n- [Obsidian 安装与可选社区插件（Windows）](docs/obsidian-setup-guide.md)\n- [示例案件与原材料](examples/README.md)\n- [交底书模版细则](prompts/disclosure/invention/template_reference.md)\n\n---\n\n<div align=\"center\">\n\nMIT License © [handsomestWei](https://github.com/handsomestWei/)\n\n</div>\n\nFile v3.9.0:references/formulas/README.md\n\n# 公式推荐范式（外挂配置）\n\n发明交底在写 **3.4.1** 前，须依据本目录配置**选题**，再填入案件符号与数值，避免临时发明抽象式子。\n\n| 文件 | 作用 |\n|------|------|\n| [`paradigms.yaml`](paradigms.yaml) | 默认范式库 + 全局规则（禁装饰音、符号上限等） |\n| [`../schemas/formula_plan.schema.yaml`](../schemas/formula_plan.schema.yaml) | 案件级 `formula_plan.yaml` 合同 |\n\n## 加载顺序（后者覆盖同 `id`）\n\n1. 仓库 `references/formulas/paradigms.yaml`\n2. 环境变量 `PATENT_FORMULA_PARADIGMS` 指向的 YAML/JSON\n3. 案件目录 `formula_paradigms.yaml` 或 `formula_paradigms.json`（与交底输出同级）\n\n查看合并结果：\n\n```bash\npython tools/shared/formula_paradigms.py list\npython tools/shared/formula_paradigms.py list --case-dir outputs/某案\npython tools/shared/formula_paradigms.py show weighted_sum\n```\n\n校验案件公式计划：\n\n```bash\npython tools/shared/check_formula_plan.py -i outputs/某案/formula_plan.yaml\npython tools/shared/check_formula_plan.py -i outputs/某案/formula_plan.yaml --eval\n```\n\n`--eval`：对可解析的简单式（`+ - * / min max`）代入 `numeric_example` 核对 `result`；求和/范数/分位等跳过并警告。  \n`chemistry` 标签或 `\\ce{` / 反应箭头：检查简单反应式原子守恒。`physics`/`si`：符号表单位族粗检（警告）。\n\n## 如何扩展一条范式\n\n在覆盖文件中追加（保留 `version` / 可选 `rules`）：\n\n```yaml\nversion: 1\nparadigms:\n  - id: my_shop_floor_oee\n    name_zh: 产线 OEE 合成\n    tags: [score, manufacturing]\n    when_zh: 可用率×表现×质量\n    latex: 'OEE = A \\\\cdot P \\\\cdot Q'\n    notes_zh: A,P,Q ∈ (0,1]\n```\n\n`id` 用小写+下划线；写清 `when_zh` / `notes_zh`，否则易被误选。  \n`combos` 可同样追加，供 Agent 在调度/检索等场景一次选多式。\n\n## 成文纪律（摘要）\n\n- `formula_plan.paradigm_ids`（及可选 `combo_id`）必须∈合并后的库。  \n- 默认 `rules.forbid_accents: true`：正文不要用 `\\tilde`/`\\hat`/`\\bar` 等；平滑用 `ema_smooth` + 符号 `A`。  \n- 须含可代入数值例；打分与限频触发尽量分式，参见 combo `match_then_rate_limit`。\n\nFile v3.9.0:references/schemas/README.md\n\n# Schema 合同说明\n\n| 文件 | 用途 | 交底 | 解读 |\n|------|------|------|------|\n| `structure.schema.yaml` | 形状/构造 | `disclosure/utility_model/` | 实用新型 / 装置附图 → `structure_schema.json` → 笔记「结构说明」+ Canvas |\n| `appearance.schema.yaml` | 外观造型 | `disclosure/design/` | 外观设计 → `appearance_schema.json` → 笔记「外观要点」+ Canvas |\n| `figure_plan.schema.yaml` | 附图选用、排序与图际关联（`relates_to`） | 实用/外观成文只嵌 `use_in_disclosure: true` | 可选；解读不强依赖 |\n| `formula_plan.schema.yaml` | 发明公式选题 + 可算提纲 | 含公式时先写 `formula_plan.yaml`；范式见 `references/formulas/` | 一般不用 |\n| `design_lineart_brief.schema.yaml` | 外观线稿描述（成文前必做） | 不问用户；已有合格线稿或大模型生成；CAD 不得当线稿 | 一般不用 |\n| `structure_lineart_brief.schema.yaml` | 实用结构线稿描述（成文前必做） | 不问用户；轮廓与序号分层；禁止自创件号；CAD 不入文 | 一般不用 |\n| `structure_lineart_compose.schema.yaml` | 实用结构线稿按件拼装 | 每件一个子 SVG，总图相对引用；粒度止于件号；crop / 单件图 / 占位框 | 一般不用 |\n| `evolution_backlog.schema.yaml` | 技能进化清单（模式 C） | 旁路产出 `outputs/evolution/EVOL-*.md`；人审前不改 prompts | 不用 |\n| `oa_case.schema.yaml` | 审查答复案例（模式 D） | 旁路：脱敏入库 Obs / 系统文档目录 `…/oa/cases` + sqlite-vec；答复先检索 | 可同库 `oa/cases/` |\n| `oa_playbook.schema.yaml` | 审查答复经验手册（模式 D） | 实务书蒸馏到 `oa/playbooks/`；不进案例向量 | 可同库 `oa/playbooks/` |\n\n填写指令：`prompts/shared/fill_structure_schema.md`、`fill_appearance_schema.md`（填表末步写出 **`figure_plan.yaml`**，含跨图核对与 `relates_to`）；线稿公共合同 **`prompts/shared/image_gen.md`**；外观见 **`prompts/shared/design_lineart_assist.md`**；实用新型见 **`prompts/shared/structure_lineart_assist.md`** + **`structure_lineart_compose.md`**。  \n**禁止**在 disclosure 与 reader 各维护一份字段定义。  \n多轮改材料或主题时须同步重评 `figure_plan`（含 `relates_to`；见该合同「多轮同步」）。StructureSchema 可选 `relations[].seen_in` 标注连接可见于哪些 `fig`。\n\nFile v3.9.0:tools/oa/README.md\n\n# 模式 D · 审查答复工具\n\n案例笔记（Obsidian）+ 可选向量检索。**向量不是必须的**。\n\n## 对话配置（推荐）\n\nAgent 按 `prompts/oa/configure_embedding.md` 问答；写文件命令示例：\n\n```bash\npython tools/oa/config.py recommend\npython tools/oa/config.py skip-vector\n# 或：预设 + Key（Key → 文档目录 embedding.secrets.yaml）\npython tools/oa/config.py set --preset zhipu --api-key \"sk-...\"\n# 或：自定义\npython tools/oa/config.py set --provider openai_compatible \\\n  --model embedding-3 --dimensions 1024 \\\n  --base-url https://open.bigmodel.cn/api/paas/v4 \\\n  --api-key \"sk-...\"\n# set 默认自检；也可单独：\npython tools/oa/config.py selftest\npython tools/oa/config.py status\npython tools/oa/rebuild_vectors.py --confirm\n```\n\n- 配置：`{Documents}/patent-disclosure-skill/oa/embedding.config.yaml`  \n- 密钥：同目录 `embedding.secrets.yaml`（勿提交）  \n- 自检失败仍可用标签检索。\n\n## Provider\n\n| provider | 典型 preset |\n|----------|-------------|\n| `openai_compatible` | `zhipu` / `dashscope` / `openai` |\n| `minimax` | `minimax` |\n| `local` | `local` |\n\n## 入库 / 检索（优先 PDF）\n\n```bash\npython tools/oa/search_cases.py --pdf notice.pdf --defect inventiveness --top-k 5\npython tools/oa/ingest_case.py -i path/to/case.md\npython tools/oa/refresh_vault.py   # 索引 + Bases + 关联 Canvas\n```\n\nObsidian 结构：`oa/cases/history/` · `oa/pending/` · `oa/drafts/` · `oa/playbooks/` + `_OA索引` / `_OA看板.base` / `_OA关联.canvas`。\n\n实务书蒸馏（先预读，只要本地路径）：\n\n```bash\npython tools/oa/ingest_playbook.py peek --path book.pdf\npython tools/oa/ingest_playbook.py ensure-skill\npython tools/oa/ingest_playbook.py ingest --from-skill-dir DISTILLED --source-path book.pdf --slug slug\npython tools/oa/ingest_playbook.py list\n```\n\n见 `prompts/oa/` 与 [SKILL.md](../../SKILL.md) 模式 D。\n\nFile v3.9.0:tools/patent_reader/README.md\n\n# 专利通俗解读工具（`tools/patent_reader/`）\n\n阅读模式专用脚本，与交底书主流程工具（`tools/shared/`、`tools/crawl/` 等）分离。\n\n## 目录结构\n\n```\ntools/patent_reader/\n├── shared/     # 共享配置与路径\n├── extract/    # PDF / 全文 / 附图取证\n├── analyze/    # 权要树、线索包、校验与 lint\n└── vault/      # Obsidian 入库、Canvas、关联与库环境\n```\n\n| 子目录 | 文件 | 作用 |\n|--------|------|------|\n| `shared/` | `common.py` | 领域路由、IPC 提示、路径与环境变量 |\n| `extract/` | `fetch_patent_pdf.py` | **按公开号下载全文 PDF**（源表 `references/patent_pdf_sources.yaml`；状态含自动判别的 `patent_type`） |\n| | `fetch_design_views.py` | **外观设计视图取证**（国知局会话 + 详情页 `/imgs` 序号探测；无 PDF CDN 时用） |\n| | `extract_patent_text.py` | 全文/PDF 取证 |\n| | `figure_extract.py` | caption+bbox 裁切 + 质量门 |\n| | `extract_patent_figures.py` | PDF 附图 CLI → manifest |\n| `analyze/` | `build_context_anchor.py` | 技术落地线索包 |\n| | `build_claim_mermaid.py` | 权利要求 mermaid |\n| | `validate_claim_tree.py` | 权项树校验/规范化 |\n| | `validate_public_clues.py` | 附录 B 线索校验 + 置信度筛选 |\n| | `lint_patent_note.py` | 笔记结构校验 |\n| `vault/` | `obsidian.py` | Frontmatter、Canvas、库 bootstrap、Mermaid |\n| | `schema_vault.py` | Structure/Appearance Schema 写入笔记/Canvas |\n| | `clue_vault.py` | `clues/` 落地、附录/旁注/Canvas |\n| | `desc_paragraphs.py` | 说明书 `[000N]` 解析与悬停 wikilink |\n| | `note_cites.py` | 笔记引用增强 |\n| | `patent_link.py` | 库内专利关联规则 |\n| | `write_patent_obsidian_note.py` | 入库主入口 |\n| | `build_patent_canvas.py` | JSON Canvas 图谱 |\n| | `link_patent_notes.py` | 交付后库内关联与全局 Canvas |\n| | `materialize_public_clues.py` | 对已有解读补跑线索落地 |\n| | `check_obsidian_env.py` | 探测/持久化库路径 |\n| | `setup_obsidian_vault.py` | 库初始化（开发/排障） |\n| 根 | `requirements.txt` | 可选依赖（`pymupdf`） |\n\n库内模板：`assets/obsidian/`（CSS、`*.base.yaml` 源稿、索引页；拷库时写成 `.base`）。\n\n流程见 **`prompts/reader/patent_plain_reader.md`**。\n\n## 快速开始\n\n```bash\npip install -r tools/patent_reader/requirements.txt\n\n# 先探测库路径（强烈推荐已装 Obsidian 并开库）\npython tools/patent_reader/vault/check_obsidian_env.py --auto-accept\n\n# 仅公开号：先下载 PDF（Google Patents 页 → CDN；见 patent_pdf_sources.yaml）\npython tools/patent_reader/extract/fetch_patent_pdf.py \\\n  --pub CN119961390A -o tmp/patent_reader/demo\n\npython tools/patent_reader/extract/extract_patent_text.py \\\n  -i tmp/patent_reader/demo/source/CN119961390A.pdf \\\n  -o tmp/patent_reader/demo --pub-number CN119961390A\n\n# 外观设计（CN…S）：常无 PDF CDN → 用国知局视图取证\npip install -r tools/crawl/requirements-cnipa.txt\npython tools/shared/browser.py --probe\n# 无 Chrome/Edge 时才：python -m playwright install chromium\npython tools/patent_reader/extract/fetch_design_views.py \\\n  --pub CN309939145S -o tmp/patent_reader/demo_design\n# → figures/images/view_001.jpg … + figures/manifest.json + source/*_design_brief.json\n```\n\n入库用 `vault/write_patent_obsidian_note.py`（内含 bootstrap）；勿再单独要求用户跑 `setup_obsidian_vault.py`。\n\n## 环境变量\n\n| 变量 | 说明 |\n|------|------|\n| `PATENT_READER_OBSIDIAN_VAULT` | Obsidian 库根（兼容 `PATENT_DISCLOSURE_OBSIDIAN_VAULT`）；也可用 `check_obsidian_env.py --set` 持久化到 `~/.patent-disclosure-skill/obsidian_vault.txt` |\n| `PATENT_READER_PAPERS_DIR` | 库内目录，默认 `Research/Patents` |\n| `PATENT_READER_OUTPUT_DIR` | 未配置库时输出目录 |\n| `PATENT_READER_GLOSSARY_DIR` | 术语目录，默认 `Research/术语` |\n\n交付后可选社区插件引导：`prompts/reader/obsidian_plugin_guide.md`。  \n关系图配色与插件说明：`docs/obsidian-setup-guide.md`（原生 Groups，无需插件）。\n\nFile v3.9.0:tools/README.md\n\n# tools / 可选脚本\n\n本目录按职责分子目录：\n\n| 目录 | 内容 |\n|------|------|\n| **`crawl/`** | 国知局公布公告检索：`cnipa_epub_*.py`、`requirements-cnipa.txt` |\n| **`shared/`** | 公用：`browser.py`（Chrome→Edge→Chromium）、`docx/pptx/md` 转换、`mermaid`/`math`/`math_to_omml`（OMML）、`formula_paradigms` / `check_formula_plan`、`iteration_dialog_log`、`patent_type.py`、**可选** STEP / 线稿门禁 |\n| **`patent_reader/`** | 专利通俗解读：`shared/` · `extract/` · `analyze/` · `vault/`（见该目录 README） |\n| **`oa/`** | 模式 D 审查答复：嵌入配置、sqlite-vec 入库/检索、实务书→`oa/playbooks/`（见该目录 README） |\n\n技能主流程以 `SKILL.md` 与 `prompts/` 为准。调用时请使用子目录完整路径（如 `tools/crawl/cnipa_epub_search.py`、`tools/shared/mermaid_render.py`）。\n\n## 国知局公布公告检索（`crawl/`，Step 5 查新优先）\n\n| 脚本 | 作用 |\n|------|------|\n| **`crawl/cnipa_epub_search.py`** | **（Step 5 优先）** 一步拉取+解析，不落盘；**`--type invention\\|utility_model\\|design\\|all`** 对应首页四类勾选；一次进程传入多词、同一浏览器内逐词检索并合并 JSON。 |\n| **`crawl/cnipa_epub_crawler.py`** | 拉取并默认保存结果页 HTML；同样支持 `--type`。 |\n| **`crawl/cnipa_epub_parse.py`** | 仅解析已保存 HTML。 |\n| **`shared/patent_type.py`** | 类型别名、国知局 checkbox、Google Patents 查询提示；**`--pub` 按文献种类码推断类型**（解读 Schema 挂钩）。 |\n\n依赖：`pip install playwright`（或根目录 `requirements.txt`）。浏览器见 **`tools/shared/browser.py`**（系统 Chrome → Edge → 自带 Chromium）。类型检索说明见 **`references/patent_type_search.yaml`**、**`prompts/disclosure/prior_art_search.md`**。\n\n抓取失败时降级 **WebSearch**（Google 学术**无**专利类型过滤；Google Patents 支持 PATENT/DESIGN，实用新型靠关键词+国知局）。\n\n---\n\n## CAD / STEP（`shared/`，可选，默认关闭）\n\n| 脚本 | 作用 |\n|------|------|\n| **`shared/cad_scan.py`** | 扫描 `.step`/`.stp` 与原生 CAD 后缀；输出 JSON（`ask_enable_step_parse` / `hint_export_step`）。**无重依赖**。 |\n| **`shared/cad_formats.py`** | 后缀表与提示文案。 |\n| **`shared/cad_venv.py`** | 探测 `tools/shared/cad-env`；已能 `import cadquery` 则 `skip_install=true`。 |\n| **`shared/bootstrap_cad_venv.py`** | 仅在未就绪时建 venv + `--isolated` pip（国内源 → pypi.org）。 |\n| **`shared/step_to_views.py`** | STEP → SVG（有 Cairo 再 PNG）。须 **`--enable-step-parse`**；请用 cad-env 的 Python。 |\n| **`shared/svg_screenshot.py`** | 短时 HTTP + 无头浏览器把 SVG 截成 PNG（端口先探测，用完关闭）。 |\n| **`shared/run_step_to_views.py`** | 探测 cad-env → 必要时 bootstrap → 出图 → 补 PNG。 |\n| **`shared/gen_demo_snap_step.py`** | 生成教学用 `tests/fixtures/cad/demo_snap_plate.step`（无 CadQuery）。 |\n| **`shared/requirements-step.txt`** | ASCII only；CadQuery + cairosvg；**只装进 cad-env**。 |\n\n流程纪律见 **`prompts/disclosure/project_scan.md`**「CAD / STEP」：有 STEP 成文不中断，交底落盘后再反问；仅有原生 CAD 则交付回复末尾提示导出 STEP。投影图是普通材料（`kind: cad`），**不得当线稿、不得入文**；打分后可能作图生图参考。\n\nCadQuery 官方轮子支持 **Python 3.10–3.12**（**不是** 3.13）。本机已是 3.11/3.12 就用当前解释器建 `cad-env`，不要强行找 3.10。无系统 Cairo 时 **保留 SVG**，用本技能已有的 Playwright 截 PNG。CAD 出图**不用** matplotlib（matplotlib 仅发明公式 PNG 可选）。\n\n```bash\npython tools/shared/cad_scan.py -r knowledge --json\npython tools/shared/cad_venv.py\npython tools/shared/run_step_to_views.py --enable-step-parse -i a.step -o outputs/case/cad_views\n```\n\n---\n\n## 发明公式范式（`shared/` + `references/formulas/`）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`references/formulas/paradigms.yaml`** | 默认可扩展范式库 |\n| **`references/schemas/formula_plan.schema.yaml`** | 案件 `formula_plan.yaml` 合同 |\n| **`shared/formula_paradigms.py`** | `list` / `show` / `combos`（支持案件目录覆盖） |\n| **`shared/check_formula_plan.py`** | 校验选题 id、禁装饰音、数值例；`--eval` 简单式代算；化学守恒 / 量纲粗检（按 tag） |\n\n```bash\npython tools/shared/formula_paradigms.py list\npython tools/shared/check_formula_plan.py -i outputs/case/formula_plan.yaml --eval\n```\n\n成文纪律见 **`prompts/disclosure/invention/disclosure_builder.md` §7.7**。\n\n## 线稿规划（`shared/`，成文前必做）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`prompts/shared/image_gen.md`** | Agent 合同：合格已有线稿 / 图生图 / 文生图；CAD 不得当线稿入文 |\n| **`shared/image_gen.py`** | 读 figure_plan，打印 `mode` / `fallback` |\n\n```bash\npython tools/shared/image_gen.py --case-dir outputs/case\n```\n\n## 外观线稿（`shared/`，必做）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`prompts/shared/design_lineart_assist.md`** | 不问用户；写 brief → 门禁 → 图生图或文生图 |\n| **`shared/design_lineart_gate.py`** | 默认开；无源图则允许文生图；`--prepare-jobs` 写出 `lineart_assist/design_lineart_jobs.json` |\n| **`references/schemas/design_lineart_brief.schema.yaml`** | 描述合同 |\n\n```bash\npython tools/shared/design_lineart_gate.py --case-dir outputs/case --prepare-jobs\n```\n\n生成的线稿默认入文。外观另将干净实拍一并写入 md 与 Word。CAD 不得 `use_in_disclosure: true`。\n\n## 实用新型结构线稿（`shared/`，必做）\n\n| 脚本 / 文档 | 作用 |\n|-------------|------|\n| **`prompts/shared/structure_lineart_assist.md`** | 不问用户；轮廓 → 按件拼装 → 按 Structure 叠件号 |\n| **`prompts/shared/structure_lineart_compose.md`** | 独立拼装指令：每件一个子 SVG；总图相对引用；粒度止于件号 |\n| **`shared/structure_lineart_gate.py`** | 默认开；无 Structure 拒绝；无源图则允许文生图 |\n| **`shared/structure_lineart_compose.py`** | 读 compose YAML，写出 `parts/{视}_{id}.svg` 与相对引用的总 SVG |\n| **`shared/structure_callout_overlay.py`** | 读取锚点后以 SVG 叠标；有 `base_svg_path` 时注入拼装图，不压扁零件层 |\n| **`references/schemas/structure_lineart_brief.schema.yaml`** | 描述合同（与外观分文件） |\n| **`references/schemas/structure_lineart_compose.schema.yaml`** | 按件槽位 / crop / 单件图合同 |\n| **`references/schemas/structure_callout_anchors.schema.yaml`** | 锚点持久化合同（`anchor` + `label` + 置信度；可选 `base_svg_path`） |\n\n```bash\npython tools/shared/structure_lineart_gate.py --case-dir outputs/case --prepare-jobs\npython tools/shared/structure_lineart_compose.py --case-dir outputs/case\npython tools/shared/structure_callout_overlay.py --case-dir outputs/case --anchors outputs/case/structure_callout_anchors.yaml\n```\n\n推荐：轮廓之后按件写出子 SVG 再拼总图，再 `callout_mode: overlay` 注入件号。大模型只定位，Python/SVG 叠标，不做含件号的二次生图。叠标后须读图按 `parts` 名称核对引出线（改 YAML 重叠标，最多 2 轮）；脚本合法 ≠ 图面对。禁止自创件号；CAD 投影不是线稿。可编辑源是 `parts/*.svg` + 总图引用，入文 PNG 只是预览。\n\n## Office / mermaid（`shared/`）\n\n用 **`shared/docx_to_md.py`**、**`shared/pptx_to_md.py`**、**`shared/mermaid_render.py`** 等。\n\n## mermaid_render.py — mermaid：图示 → PNG + 定稿 Markdown + **默认生成 Word**\n\n将 fenced **mermaid**（`` ```mermaid`` ``）逐块经 **Playwright + 内置 `vendor/mermaid.min.js`** 渲染为 PNG；输出 `.md` 中**保留** mermaid 围栏源码，并追加 ``<!-- ![图示 n](mermaid_figures/…) -->`` 供 **`md_to_docx.py`** 嵌入 Word（Word **仅**嵌 PNG，不写 mermaid 代码块）。**3.2 系统框图**与 **3.4 流程图**均用 mermaid（`flowchart` / `subgraph` 等），交底书正文**不再**要求单独的文字框图或 PlantUML。流程图步骤号（`S1` 等）须写在**可见标签**里；脚本会把 `S1[文案]` 补成 `S1[\"S1 文案\"]` 再出图，否则 PNG 上看不到序号。\n\n**生图失败降级**：某一围栏失败时**不中断**——该处**保留**原 `` ```mermaid`` … `` ``` `` 源码；其余块照常出图。仍写出定稿 `.md`，并**照常尝试**生成 Word（未出图块在 Word 中为 **Consolas 代码块**）。无可用浏览器时同样保留围栏，不阻塞 Markdown。\n\n### 依赖：mermaid（Playwright，无需 Node）\n\n与国知局查新**共用** `tools/shared/browser.py`：系统 **Chrome → Edge → Playwright 自带 Chromium**。仓库已内置 `tools/shared/vendor/mermaid.min.js`。\n\n| 需要 | 说明 |\n|------|------|\n| `pip install playwright` | 已写入根目录 `requirements.txt` |\n| 本机 Chrome 或 Edge | **推荐**；有则不必再下 Chromium |\n| `python -m playwright install chromium` | **仅当**本机无 Chrome/Edge 时 |\n\n探测：`python tools/shared/browser.py --probe`。**禁止**为出图执行 `npm install` / `npx -y @mermaid-js/mermaid-cli`。`tools/package.json` 仅为旧 mmdc 可选遗留，主路径不使用。\n\n生成 Word 仍需：`pip install -r requirements.txt`（python-docx 等）。\n\n默认视口 **1400×1050**、`device_scale_factor=2`（历史参数名 `--mmdc-scale` / `--mmdc-width` / `--mmdc-height` 仍可用）。再锐化可 `--mmdc-scale 3`。\n\n### 用法\n\n```bash\n# 写出定稿 .md，并在同目录生成同名 .docx（默认）；-o 须为「案件名_YYYYMMDDHHmmss.md」（见 prompts/disclosure/invention/disclosure_builder.md §7.3 第 5 点）\npython tools/shared/mermaid_render.py -i draft.md -o \"一种XXX方法及系统_20260408143025.md\"\n\n# 指定 .docx 路径（.md 主名仍须含时间戳）\npython tools/shared/mermaid_render.py -i draft.md -o out/一种XXX方法及系统_20260408143025.md --docx out/一种XXX方法及系统_20260408143025.docx\n\n# 仅 Markdown，不要 Word\npython tools/shared/mermaid_render.py -i draft.md -o \"一种XXX方法及系统_20260408143025.md\" --no-docx\n\n# 更高清晰度（可选）\npython tools/shared/mermaid_render.py -i draft.md -o \"…定稿.md\" --mmdc-scale 3 --mmdc-width 1600 --mmdc-height 1200\n\n# 指定 mermaid 图片子目录（相对输出 .md）\npython tools/shared/mermaid_render.py -i draft.md -o out/一种XXX方法及系统_20260408143025.md --assets-dir figures/mermaid\n```\n\n**Word 生成失败**（缺依赖、版式报错等）时：脚本仍以退出码 **0** 结束（Markdown 已成功）；stderr 会打印 **`md_to_docx.py` 的手动命令**，请复制执行。\n\n无可用浏览器时仍写出 Markdown（保留 mermaid 围栏）；补齐 Chrome/Edge 或 Chromium 后可重跑本脚本出 PNG。\n\n### 与交底书约定\n\n- 技能要求定稿**同时**交付 **Markdown + Word**，且 **`-o` 主文件名须含 `_{YYYYMMDDHHmmss}`**（`prompts/disclosure/invention/disclosure_builder.md` §7.3 第 5 点，含首次定稿）；**3.2 系统框图**与 **3.4 流程图**均用 fenced mermaid，**不要** ASCII 文字流程图或框图。\n- 交付代理人前：运行 `mermaid_render.py` 一步即可（默认再调 `md_to_docx.py`）；若 Word 失败，按 stderr 提示手动执行 `md_to_docx.py`。\n- **判读**：`MERMAID:` / `DOCX: ok=1` 且退出码 0 即为成功；stderr 中文或 PowerShell 红字不是失败。`DOCX: ok=0` 才算 Word 失败。\n- 默认**不**预渲染公式 PNG。Word 公式走 OMML；stderr 若有 `omml_text_fallback` / `OMML_FAIL:`，须用户确认后再 `pip install matplotlib` 并以 `--math` / `--math-render` 重出 Word。\n\n---\n\n## math_to_omml.py — LaTeX → 可编辑 Office Math\n\n``latex2mathml`` → MathML → Word ``m:oMath`` / ``m:oMathPara``。不依赖本机 TeX。由 **`md_to_docx.py`** 默认调用。失败则留 LaTeX 原文；stderr 会列出 `omml_text_fallback`。\n\n```bash\npip install latex2mathml   # 已写入根目录 requirements.txt\n```\n\n---\n\n## math_render.py — LaTeX 公式 → PNG（可选回退）\n\n将 Markdown 中的 **LaTeX 公式**用 **matplotlib mathtext** 渲染为 PNG；**保留 LaTeX 原文**，图片引用写入 HTML 注释，供 **`md_to_docx.py`** 在 **OMML 失败时**嵌入。\n\n**默认不定稿出公式 PNG**，也不把 matplotlib 写入主 `requirements.txt`。仅当用户确认后：`pip install matplotlib`，再 `md_to_docx.py --math-render` 或 `mermaid_render.py --math`。\n\n**Mermaid 框图**：``mermaid_render.py`` **保留** `` ```mermaid`` 源码，并追加 ``<!-- ![图示 n](mermaid_figures/...) -->``。\n\n**mathtext 兼容**：``\\ge``→``\\geq`` 等；``\\tag{1}`` 转式末 ``(1)``。\n\n**Word 主路径**：默认 **OMML 优先**；无 PNG 时失败留原文。``--no-omml`` 可强制旧行为。\n\n### 依赖（可选）\n\n```bash\npip install matplotlib\n```\n\n### 用法\n\n```bash\npython tools/shared/math_render.py -i draft.md -o draft_with_math.md\npython tools/shared/math_render.py -i draft.md -o out.md --assets-dir math_figures\npython tools/shared/md_to_docx.py -i a.md -o a.docx --math-render\npython tools/shared/mermaid_render.py -i a.md -o a.md --math\n```\n\n---\n\n## md_to_docx.py — Markdown → Word\n\n将交底书 Markdown 转为 `.docx`，**`#`–`######` 映射为 Word 内置「标题 1」–「标题 9」**，正文为宋体 10.5pt，代码块为 Consolas，便于交给代理人或所内用 Word 修订。\n\n**图示**：定稿应用 **`mermaid_render.py`** 将 mermaid 转为 PNG；若个别块生图失败被降级保留围栏，本脚本会将**仍存在的** `` ```mermaid`` 块按**代码块**写入 Word。本脚本不启动浏览器。\n\n### 依赖\n\n```bash\npip install -r requirements.txt\n```\n\n依赖为 `python-docx` + `latex2mathml`（见仓库根目录 `requirements.txt`）。缺 `latex2mathml` 时留原文；公式 PNG 须 ``--math-render`` 且已装 matplotlib。\n\n### 用法\n\n```bash\npython tools/shared/md_to_docx.py --input path/to/交底书.md --output path/to/交底书.docx\npython tools/shared/md_to_docx.py -i a.md -o a.docx --no-omml         # 仅 PNG/原文\npython tools/shared/md_to_docx.py -i a.md -o a.docx --math-render    # OMML 失败用 PNG（须 matplotlib）\n```\n\n图片 `![](相对路径.png)`：默认相对 **Markdown 文件所在目录**；也可指定根目录：\n\n```bash\npython tools/shared/md_to_docx.py -i ./outputs/case/disclosure.md -o ./outputs/case/disclosure.docx --base-dir ./outputs/case\n```\n\n**插图**：对 PNG/GIF/JPEG 会读取像素尺寸，在默认 **最大宽 5.5\" × 最大高 8.2\"** 内**等比缩放**并同时指定 `width`/`height`，避免竖长流程图仅按宽度放大后**高度超出版心**、打印或阅读时像被裁切。可按纸张边距调整，例如：\n\n```bash\npython tools/shared/md_to_docx.py -i a.md -o a.docx --image-max-width-inches 6 --image-max-height-inches 9\n```\n\n在 Claude Code 中可将 `tools` 换为 `${CLAUDE_SKILL_DIR}/tools`。\n\n### 支持的 Markdown 子集\n\n| 元素 | 行为 |\n|------|------|\n| `#`–`######` | Word 标题 1–9 |\n| 段落 | 宋体正文，支持 `**粗体**`、`` `行内代码` ``；**相邻非空行（中间无空行）各自成段**，「（1）…（2）…」会分行显示 |\n| `-` / `*` 列表 | 项目符号列表 |\n| `1.` 列表 | 编号列表；被标题 / 段落 / 表格 / 分隔线等隔开的新一组从 1 重计（避免跨章串号） |\n| ` ``` ` 围栏 | 等宽代码块 |\n| `\\| 表格 \\|` | 简单表格（Table Grid）；单元格内 ``\\\\(...\\\\)``、``$...$``、``<!-- -->`` 及 ``\\\\|`` 中的 ``|`` **不会**被当作列分隔符 |\n| `> ` | 左缩进引用 |\n| `---` 等 | 浅色分隔线 |\n| `![](path)` | 嵌入图片（路径需存在；默认宽/高上限内等比缩放；公式图与正文混排） |\n| `$` / `\\\\(...\\\\)` / `$$` / `\\\\[...\\\\]` LaTeX | **优先 OMML（可编辑公式）** → 已有公式 PNG 则嵌图 → 否则 **原文**；``--math-render`` 才预渲染 PNG；``--no-omml`` 跳过 OMML |\n\n**未完整支持**：复杂嵌套列表、HTML 块、**未预渲染的** mermaid 围栏（仍为代码块）、脚注、任务列表等。定稿前请运行 **`mermaid_render.py`**；若仅用外部工具导出 PNG，可直接写 `![](...)`。\n\n### 版式说明（md_to_docx）\n\n- 不同语言 Word 中「标题 1」显示名可能为「Heading 1」或「标题 1」，样式仍为大纲级别标题，可用导航窗格与目录域。\n- Markdown 里每组 `1.` 列表（被标题、正文、表格、分隔线等隔开）在 Word 中从 1 重计，避免第一章 1–4 之后第二章变成 5–8。\n- 若需所内固定模版（页眉、首页不同），可在本脚本生成后套用单位 `.dotx`，或后续扩展 `python-docx` 打开模版再写入。\n\n---\n\n## iteration_dialog_log.py — 修订对话记录（迭代用）\n\n每轮 **`prompts/disclosure/merger.md` / `correction_handler.md`** 交付后，在**案件目录**追加一条 **`交底书修订对话记录.md`**：含**本地时间与 UTC**、用户说明摘要、本轮交付文件名、合并/纠正摘要摘录。规则见 **`prompts/disclosure/iteration_context.md`**。\n\n**依赖**：仅标准库。\n\n```bash\npython tools/shared/iteration_dialog_log.py --case-dir outputs/某案件 --kind merge \\\n  --user \"补充了调度装置资料，合并进第三章\" \\\n  --summary \"已扩写 3.4，并更新实施例；未改保护点表述。\" \\\n  --artifacts \"一种XXX方法及系统_20260408143025.md,一种XXX方法及系统_20260408143025.docx\"\n```\n\n- `--kind`：`merge` 或 `correct`。  \n- `--log-name`：可选，默认 `交底书修订对话记录.md`；英文环境可改用 `disclosure_revision_log.md`。  \n- 无法执行脚本时，由 Agent 按同结构手工追加。\n\n---\n\n## docx_to_md.py — Word → Markdown + 抽取图片\n\n将 **.docx**（Word / WPS 等另存为 docx）转为 **Markdown**，并把文档内嵌图片落到磁盘，便于 **`Read` 与 Step 2 扫描**（与直接读二进制 .docx 相比更稳）。**Step 2** 对扫描树内**每一个** `.docx` 都应先转换再读产出 `.md`，见 `prompts/disclosure/project_scan.md`。\n\n### 依赖\n\n与 `md_to_docx` 共用根目录 `requirements.txt`（`python-docx` + **`mammoth`**）。\n\n```bash\npip install -r requirements.txt\n```\n\n### 用法\n\n```bash\npython tools/shared/docx_to_md.py --input path/to/设计说明.docx --output outputs/case/design.md\n```\n\n- 默认图片目录：`outputs/case/design_media/`，Markdown 内为相对路径 `![](design_media/img_0001.png)`。\n- 自定义图片目录：\n\n```bash\npython tools/shared/docx_to_md.py -i ./raw/spec.docx -o ./knowledge/spec.md --media-dir ./knowledge/spec_assets\n```\n\n转换警告（如部分样式、WMF 图）会输出到 **stderr**，仍可能生成可用 `.md`。\n\n### 局限（mammoth）\n\n- 仅 **`.docx`**（OOXML）；老版 **`.doc`** 不支持。\n- **Markdown 输出在 mammoth 侧标记为 deprecated**，复杂排版可能弱于「先导出 HTML 再转 MD」；专利扫描一般足够。若版式崩坏，建议所内 **另存为 PDF 或纯文本** 再扫。\n- **WMF/EMF** 等 Windows 图元可能需单独处理（见 [mammoth WMF 配方](https://github.com/mwilliamson/python-mammoth)）。\n\n在 Claude Code 中可将 `tools` 换为 `${CLAUDE_SKILL_DIR}/tools`。\n\n---\n\n## pptx_to_md.py — PowerPoint → Markdown + 抽取图片\n\n将 **.pptx** / **.ppsx** 按**幻灯片页**导出为 Markdown，并抽取幻灯片中的**嵌入位图**（`PICTURE` 形状），便于 **`Read` 与 Step 2 扫描**。**Step 2** 对扫描树内**每一个** `.pptx` 均应先转换再读 `.md`，见 `prompts/disclosure/project_scan.md`。\n\n### 依赖\n\n根目录 `requirements.txt` 中的 **`python-pptx`**。\n\n```bash\npip install -r requirements.txt\n```\n\n### 用法\n\n```bash\npython tools/shared/pptx_to_md.py --input path/to/评审材料.pptx --output outputs/case/review.md\n```\n\n- 默认图片目录：`outputs/case/review_media/`，文件名形如 `slide03_img0001.png`。\n- 自定义图片目录：\n\n```bash\npython tools/shared/pptx_to_md.py -i ./raw/deck.pptx -o ./knowledge/deck.md --media-dir ./knowledge/deck_media\n```\n\n每页输出二级标题 `## 第 N 页`，其后为该页形状中的**文本与表格**（简化为管道表）及图片引用；若存在**演讲者备注**，以「**备注**」小节附于该页末尾。\n\n### 局限（python-pptx）\n\n- 仅 **`.pptx` / `.ppsx`**（OOXML）；**`.ppt`** 不支持，请先另存。\n- **图表、SmartArt、嵌入 OLE** 等若未以普通图片形状存在，**不会**自动栅格化为 PNG；可先在 PowerPoint 中另存为图片或导出 PDF 作补充材料。\n- 文本按形状遍历顺序输出，与视觉阅读顺序可能略有差异。\n\n在 Claude Code 中可将 `tools` 换为 `${CLAUDE_SKILL_DIR}/tools`。\n\n---\n\n## 专利通俗解读（阅读模式）\n\n脚本与说明见 **[`patent_reader/README.md`](patent_reader/README.md)**。\n\n```bash\npip install -r tools/patent_reader/requirements.txt\n\n# 发明/实用新型全文 PDF\npython tools/patent_reader/extract/fetch_patent_pdf.py --pub CN… -o RUN\n\n# 外观设计视图（常无 PDF CDN；需 Playwright，同国知局爬虫依赖）\npip install -r tools/crawl/requirements-cnipa.txt\npython tools/shared/browser.py --probe\n# 无 Chrome/Edge 时才：python -m playwright install chromium\npython tools/patent_reader/extract/fetch_design_views.py --pub CN…S -o RUN\n```\n\n---\n\n## 审查答复案例库（`oa/`，可选，默认关闭）\n\n| 脚本 | 作用 |\n|------|------|\n| **`oa/config.py`** | `recommend` / `skip-vector` / `enable-vector` / `status` / `set` |\n| **`oa/pdf_text.py`** | 审查通知书/答复 PDF→文本（pymupdf） |\n| **`oa/ingest_case.py`** | 脱敏入库；无向量亦可；支持 `--pdf` |\n| **`oa/ingest_playbook.py`** | 预读 / 安装 book-to-skill / 手册转写 `oa/playbooks/`（不进案例向量） |\n| **`oa/search_cases.py`** | 标签检索 + 可选向量；失败回退；支持 `--pdf` |\n| **`oa/rebuild_vectors.py`** | 用户确认后扫描 oa/cases 重建向量 |\n\n依赖：`pip install -r tools/oa/requirements-oa.txt`。说明见 **`tools/oa/README.md`**、**`docs/oa/README.md`**。\n\n---\n\n## 扩展其它脚本时\n\n- Word / PPT 转换依赖写在 `requirements.txt`。\n- 在 `SKILL.md`「工具与数据来源」表中增加一行调用说明。\n- 勿将密钥写入仓库；配置使用环境变量或用户主目录。\n\nFile v3.9.0:tools/shared/vendor/README.md\n\n# 内置 mermaid（供 Playwright 出图，无需 Node / mmdc）\n\n| 文件 | 版本 | 来源 |\n|------|------|------|\n| `mermaid.min.js` | **11.4.1** | https://cdn.jsdelivr.net/npm/mermaid@11.4.1/dist/mermaid.min.js |\n\n与历史 `@mermaid-js/mermaid-cli` 11.4.x 同系列。出图由 `tools/shared/mermaid_render.py` 经 Playwright 加载本文件，**禁止**运行时从 CDN 再拉。\n\n升级时请同步改本表版本号，并替换 `mermaid.min.js`。\n\nFile v3.9.0:_meta.json\n\n{\n  \"ownerId\": \"kn71nkfhpcw7dp6pkyqrj43dgd84eg1k\",\n  \"slug\": \"patent-disclosure-skill\",\n  \"version\": \"3.9.0\",\n  \"publishedAt\": 1787880372447\n}\n\nArchive v3.7.0: 162 files, 1264787 bytes\n\nFiles: assets/obsidian/_专利解读索引.template.md (1806b), assets/obsidian/glossary.base.yaml (542b), assets/obsidian/graph_color_groups.json (790b), assets/obsidian/oa.base.yaml (1260b), assets/obsidian/patent-reader.css (1561b), assets/obsidian/patents.base.yaml (1988b), assets/obsidian/README.md (578b), assets/patent_note_template.md (3535b), docs/evolution/EVOL-20260811-1051.md (6735b), docs/evolution/README.md (365b), docs/oa/.gitignore (49b), docs/oa/embedding.config.yaml (902b), docs/oa/README.md (1139b), docs/obsidian-setup-guide.md (4762b), INSTALL.md (10327b), prompts/disclosure/correction_handler.md (4107b), prompts/disclosure/design/disclosure_builder.md (4330b), prompts/disclosure/design/patent_points.md (3008b), prompts/disclosure/design/template_reference.md (1901b), prompts/disclosure/disclosure_preview.md (2514b), prompts/disclosure/disclosure_self_check.md (11776b), prompts/disclosure/intake.md (2789b), prompts/disclosure/invention/disclosure_builder.md (21880b), prompts/disclosure/invention/patent_points_analyzer.md (1343b), prompts/disclosure/invention/template_reference.md (14130b), prompts/disclosure/iteration_context.md (5915b), prompts/disclosure/merger.md (5479b), prompts/disclosure/prior_art_search.md (12119b), prompts/disclosure/project_scan.md (10416b), prompts/disclosure/utility_model/disclosure_builder.md (5102b), prompts/disclosure/utility_model/patent_points.md (3841b), prompts/disclosure/utility_model/template_reference.md (1714b), prompts/evolution/apply_after_confirm.md (1069b), prompts/evolution/emit_backlog.md (2321b), prompts/evolution/guardrails.md (1821b), prompts/evolution/intake.md (1197b), prompts/evolution/research.md (2611b), prompts/evolution/soft_nudge.md (1697b), prompts/oa/case_note_template.md (1568b), prompts/oa/configure_embedding.md (2340b), prompts/oa/guardrails.md (1703b), prompts/oa/ingest_case.md (1931b), prompts/oa/intake.md (959b), prompts/oa/respond_office_action.md (2636b), prompts/reader/obsidian_ofm_companion.md (2332b), prompts/reader/obsidian_plugin_guide.md (1656b), prompts/reader/patent_plain_reader.md (20353b), prompts/reader/patent_reader_self_check.md (1479b), prompts/reader/type_hooks.md (1990b), prompts/shared/design_lineart_assist.md (4902b), prompts/shared/fill_appearance_schema.md (3795b), prompts/shared/fill_structure_schema.md (4437b), prompts/shared/image_gen.md (3871b), prompts/shared/structure_lineart_assist.md (7378b), prompts/shared/structure_lineart_compose.md (5066b), README.md (15876b), references/formulas/paradigms.yaml (10100b), references/formulas/README.md (2239b), references/ipc_application_hints.yaml (3603b), references/patent_domain_rules.yaml (1030b), references/patent_obsidian_format.md (8048b), references/patent_pdf_sources.yaml (3513b), references/patent_type_search.yaml (2647b), references/schemas/appearance.schema.yaml (2266b), references/schemas/design_lineart_brief.schema.yaml (2754b), references/schemas/evolution_backlog.schema.yaml (1476b), references/schemas/figure_plan.schema.yaml (7699b), references/schemas/formula_plan.schema.yaml (2665b), references/schemas/oa_case.schema.yaml (2911b), references/schemas/README.md (2264b), references/schemas/structure_callout_anchors.schema.yaml (2338b), references/schemas/structure_lineart_brief.schema.yaml (3667b), references/schemas/structure_lineart_compose.schema.yaml (2870b), references/schemas/structure.schema.yaml (1405b), requirements.txt (1012b), scripts/generate-star-history.py (17189b), skill-card.md (3019b), SKILL.md (19984b), tools/__init__.py (0b), tools/crawl/cnipa_epub_crawler.py (14290b)\n\nFile v3.7.0:SKILL.md\n\n---\nname: patent-disclosure-skill\ndescription: \"中国专利技能：专利点挖掘与交底书（发明/实用/外观）编写，通俗解读专利，嗅探政策动向，辅助审查答复。| China patents skill: mine patent points and draft disclosures (invention / utility model / design), plain-language reading, policy sniffing, assisted office-action response.\"\nversion: \"3.7.0\"\nuser-invocable: true\nargument-hint: \"[可选：项目路径 / 专利号或 PDF / 政策动向嗅探或技能进化 / 审查答复或案例入库]\"\nallowed-tools: Read, Write, Edit, Grep, Glob, WebSearch, Bash\n---\n\n# 中国专利技能 · 交底编写 · 通俗解读 · 政策/审查动向嗅探 · 审查答复\n\n本技能**单包模块化**：分步指令在 **`prompts/`**，执行前须 **`Read`** 对应文件。`SKILL.md` 只做路由。\n\n| 模式 | 何时用 | 主入口 |\n|------|--------|--------|\n| **A · 交底书编写** | 挖专利点 → 查新 → 成稿 → 迭代 | `prompts/disclosure/`（类型子目录见下） |\n| **B · 专利通俗解读** | 公开号 / PDF / 全文 → 通俗笔记 + 图谱 | `prompts/reader/patent_plain_reader.md` |\n| **C · 技能进化旁路** | 政策/审查动向嗅探 → 带时间戳清单 → **人审后**才改技能 | `prompts/evolution/`（须显式触发） |\n| **D · 审查答复辅助** | 案例脱敏入库；通知书 → 标签+向量检索 → 答复草稿 | `prompts/oa/`（须显式触发；须人审） |\n\n提供**专利号或专利全文/PDF**且意图为「读懂」时 → **优先模式 B**，**不**默认跑交底书 Step 1–8。  \n**禁止**因写交底/读专利自动进入模式 C/D。\n\n## 目录约定（薄路由）\n\n```\nprompts/disclosure/          # 交底公共流程\n  invention/                 # 发明：挖点 / builder / template\n  utility_model/             # 实用新型：挖点 / builder / template（单独 md，勿套用发明 mermaid 主线）\n  design/                    # 外观设计：挖点 / builder / template（单独 md）\nprompts/reader/              # 通俗解读 + type_hooks\nprompts/shared/              # 写读共用：Structure / Appearance 填表 + figure_plan + 线稿（image_gen）\nprompts/evolution/           # 模式 C：政策/审查动向嗅探 · 进化清单（旁路，须显式触发）\nprompts/oa/                  # 模式 D：审查答复 / 案例入库（旁路，须显式触发）\nreferences/schemas/          # structure / appearance / figure_plan / formula_plan / lineart / evolution / oa_case\nreferences/formulas/         # 发明公式推荐范式（paradigms.yaml，可外挂扩展）\ntools/crawl/                 # 国知局等爬取\ntools/shared/                # docx/mermaid/专利类型/可选 STEP（cad-env）/ 线稿门禁与按件拼装；browser.py + svg_screenshot.py\ntools/patent_reader/         # 解读工具：shared/ | extract/ | analyze/ | vault/\ntools/oa/                    # 模式 D：config / embed / sqlite-vec / ingest / search\noutputs/evolution/           # 模式 C 清单默认落盘（gitignore）\ndocs/evolution/              # 仅用户确认「沉淀」后可复制提交\ndocs/oa/                     # 模式 D：embedding 配置模板种子（运行时在系统文档目录）\n```\n\n## 环境与约定\n\n- **脚本判读（尤其 Windows）**：stderr 有字 **不等于** 失败。以 **退出码 0** 和机读前缀为准：`EPUB_HITS_JSON:` / `EPUB_MERGE:`、`PROBE:` / `BROWSER:`、`MERMAID:` / `DOCX:` / `MATH:` / `omml_text_fallback=`、`CAD_VENV:` / `SVG_HTTP:` / `PIP_INDEX`。PowerShell 可能把 stderr 标成 `NativeCommandError` 或乱码；**禁止**因此重跑安装、或把查新降级 WebSearch。勿用 `2>&1` 把 JSON 混进错误流。\n- **专利类型**：未显式指定时交底**默认发明**；材料更偏实用/外观时在汇总或预览阶段**反问**（见 `disclosure/intake.md`）。\n- **交底书图示**：\n  - **发明**：3.2 / 3.4 用 fenced **mermaid** → `tools/shared/mermaid_render.py`（Playwright + 内置 mermaid.js，见 `tools/shared/browser.py`）。流程图步骤号须写入可见标签：`S1[\"S1 …\"]`（id 本身不出图）。成文须让**标题领域对象**贯穿 3.1 / 框图 / 流程 / 实施例；用词贴合话题背景，话题错位的抽象行话换成领域表述（发明 `disclosure_builder.md` §7.9）。\n  - **实用新型**：先 `figure_plan.yaml` 排序入文图（**只入合格线稿**；CAD 投影不入文）+ 部件/关系表（见 `utility_model/disclosure_builder.md`）。\n  - **外观**：先判立体/平面与要点落面，再写 `figure_plan.yaml` 选正投影（**非默认六视**；**干净实拍 + 线稿都入文**，写入 md 与 Word；CAD 不入文）（见 `design/disclosure_builder.md`）。\n- **STEP / CAD（可选，默认关）**：Step 2 用 `cad_scan.py` 分类；**不中断**挖点/成文。遇 `.step`/`.stp` 记下路径，交底 **落盘后再反问**是否开启解析；用户 **是** 才 `cad_venv.py`（已就绪则跳过安装）/`bootstrap_cad_venv.py` + `run_step_to_views.py --enable-step-parse`。CadQuery 只进 `tools/shared/cad-env`（Python 3.10–3.12，不强制 3.10）。PNG：有 Cairo 用 cairosvg，否则 `svg_screenshot.py` 无头浏览器截 SVG；**禁止为 CAD 安装 matplotlib**（matplotlib 只用于发明公式 PNG）。投影图是**普通材料**（`kind: cad`），**不得**当线稿、**不得**入文；打分后可能作图生图参考。仅有原生 CAD 则交付回复末尾提示导出 STEP。见 `project_scan.md`「CAD / STEP」。\n- **外观线稿（必做）**：填表后 **`Read`** `shared/image_gen.md` + `shared/design_lineart_assist.md`。不问用户。已有合格线稿则入文；否则大模型生成。干净实拍**同时入文**（md + Word），但不得标成线稿。CAD 不入文。仅用户明确不要或 `PATENT_SKILL_SKIP_LINEART=1` 才跳过。\n- **实用结构线稿（必做）**：填表后 **`Read`** `shared/image_gen.md` + `shared/structure_lineart_assist.md`（轮廓后 **`Read`** `shared/structure_lineart_compose.md`）。不问用户。对齐 `structure_schema.parts`；轮廓按件拼装为子 SVG + 总图相对引用，再叠序号。推荐：`structure_lineart_compose.py` 每件落 `parts/{视}_{id}.svg`，总图 `<g id=\"part-N\">` 引用子文件（不要整图 base64+clip），大模型只定位并把归一化锚点持久化到 `structure_callout_anchors.yaml`（含 `base_svg_path`），再由 `structure_callout_overlay.py` **注入**件号组；**叠标后须读图按部件名称核对引出线**（改 YAML 重叠标，最多 2 轮；禁止含件号二次生图或自创件号）。CAD 不得当线稿入文。**勿**与外观 `design_lineart_*` 混用。\n- **解读 + Obsidian**：强烈推荐配置库；见 **`docs/obsidian-setup-guide.md`**。\n- **技能进化 / 动向嗅探（须显式触发）**：用户点名后走模式 C（政策/审查动向嗅探 → 清单）；清单含 **观点↔信源 URL 表**；未人审确认前**不**改技能正文。\n- **审查答复（须显式触发）**：用户点名后走模式 D；向量模型**可选**（可 `skip-vector`，中途再 enable + 重建）；推荐智谱 `embedding-3`；标签检索始终可用，向量超时则回退。\n\n---\n\n## 触发条件\n\n- **交底书**：专利挖掘、交底书、查新、实用新型、外观设计等；`/patent-disclosure-skill`、`/交底书`。\n- **通俗解读**：读专利、公开号 / PDF 且目标为理解；`/patent-read`、`/读专利`。\n- **交底书迭代**：已有交底上补材料/纠错 → `disclosure/iteration_context.md` → `merger` / `correction_handler`；另存时间戳稿。\n- **技能进化旁路**：技能进化、政策/审查动向嗅探、政策雷达、审查政策更新、自进化、`/patent-evolve`、`/技能进化` → **仅此时**进入模式 C。\n- **审查答复 / 案例入库**：审查意见、意见陈述、OA、补正通知书、案例入库、`/oa`、`/审查答复` → **仅此时**进入模式 D。\n\n---\n\n## 工具与数据来源\n\n| 任务 | 建议方式 |\n|------|----------|\n| 加载分步指令 | **`Read`** → `prompts/disclosure|reader|shared|evolution/…`（完整子路径） |\n| Word / PPT → Markdown | `tools/shared/docx_to_md.py` / `pptx_to_md.py` |\n| CAD 扫描 / STEP→多视图（可选，默认关） | `tools/shared/cad_scan.py`；**交付后**用户确认才 `cad_venv.py`（就绪则跳过安装）+ `run_step_to_views.py --enable-step-parse`；投影只当材料 |\n| 线稿规划（必做） | `prompts/shared/image_gen.md`；`tools/shared/image_gen.py`（existing / img2img / txt2img） |\n| 外观线稿（必做） | `prompts/shared/design_lineart_assist.md`；门禁 `design_lineart_gate.py` |\n| 实用结构线稿（必做） | `prompts/shared/structure_lineart_assist.md` + `structure_lineart_compose.md`；门禁 `structure_lineart_gate.py`；拼装 `structure_lineart_compose.py`；锚点 `structure_callout_anchors.yaml`；叠标 `structure_callout_overlay.py` |\n| 联网查新 | **`Read`** `disclosure/prior_art_search.md`。优先 **`tools/crawl/cnipa_epub_search.py --type …`**（与 intake 类型一致）；`abstract` 必用；异常再 WebSearch。类型映射见 `references/patent_type_search.yaml` |\n| 交底定稿 | 发明：`tools/shared/mermaid_render.py` → md+docx；实用/外观：按各类型 builder（外观 md+docx 须同时嵌实拍与线稿） |\n| 专利通俗解读 | **`Read`** `reader/patent_plain_reader.md`；实用/外观另 Read `reader/type_hooks.md` + `shared/fill_*` |\n| 解读取 PDF / 入库 | `tools/patent_reader/extract/fetch_patent_pdf.py`；`…/vault/write_patent_obsidian_note.py` 等（见 `tools/patent_reader/README.md`） |\n| 政策/审查动向嗅探 | **`Read`** `evolution/intake.md` → `research.md`（WebSearch + 官网抓取）→ `emit_backlog.md`；确认后 `apply_after_confirm.md` |\n| 审查答复 / 案例库 | **`Read`** `oa/intake.md`；PDF 用 `oa/pdf_text.py` / `search_cases.py --pdf` / `ingest_case.py --pdf`；入库 `oa/ingest_case.md`；答复 `oa/respond_office_action.md`；配置 `oa/config.py` |\n\n---\n\n## Prompt 文件映射\n\n### 交底书（公共 + 类型特化）\n\n| 步骤 | 文件 | 用途 |\n|------|------|------|\n| Step 1 | `prompts/disclosure/intake.md` | 边界；**默认发明**；可反问实用/外观 |\n| Step 2 | `prompts/disclosure/project_scan.md` | 项目扫描（Office + **可选 CAD/STEP**；三类示例加扫） |\n| Step 3–4 | **发明** `disclosure/invention/patent_points_analyzer.md`；**实用** `utility_model/patent_points.md`；**外观** `design/patent_points.md` | 挖点（**分文件，勿混用**） |\n| 填表（实用/外观） | `prompts/shared/fill_structure_schema.md` / `fill_appearance_schema.md` | 图→schema + **`figure_plan.yaml`**（打分；CAD 不入文） |\n| 线稿规划 | `prompts/shared/image_gen.md` | 必做；existing / img2img / txt2img |\n| 外观线稿 | `prompts/shared/design_lineart_assist.md` | 必做；不问用户；实拍+线稿都入 md/Word；CAD 不是线稿 |\n| 实用结构线稿 | `prompts/shared/structure_lineart_assist.md` | 必做；不问用户；轮廓→子 SVG+总图引用→按 parts 叠序号 |\n| 实用线稿拼装 | `prompts/shared/structure_lineart_compose.md` | 独立模块；每件一个子 SVG，总图相对引用，再注入件号 |\n| Step 5 | `prompts/disclosure/prior_art_search.md` | 查新（`--type`） |\n| Step 6 | `prompts/disclosure/disclosure_preview.md` | 摘要预览（按类型裁剪） |\n| Step 7 | 对应类型目录 `disclosure_builder.md` + `template_reference.md` | 成文（**分文件**；发明含公式时先 `formula_plan.yaml`） |\n| Step 8 | `prompts/disclosure/disclosure_self_check.md` | 内部自检（含 §8.4 / §8.5） |\n| 迭代 | `disclosure/iteration_context.md` / `merger.md` / `correction_handler.md` | 另存 |\n\n### 专利通俗解读\n\n| 步骤 | 文件 |\n|------|------|\n| 主流程 | `prompts/reader/patent_plain_reader.md` |\n| 类型挂钩 | `prompts/reader/type_hooks.md` |\n| 写笔记 | `reader/obsidian_ofm_companion.md` + `references/patent_obsidian_format.md` |\n| 自检 / 插件引导 | `reader/patent_reader_self_check.md` / `obsidian_plugin_guide.md` |\n| 取 PDF | `tools/patent_reader/extract/fetch_patent_pdf.py` |\n| 入库 | `tools/patent_reader/vault/write_patent_obsidian_note.py` |\n\n### 技能进化旁路 · 政策/审查动向嗅探（模式 C）\n\n| 步骤 | 文件 |\n|------|------|\n| 总则 | `prompts/evolution/guardrails.md` |\n| 录入 | `prompts/evolution/intake.md` |\n| 检索/抓取 | `prompts/evolution/research.md` |\n| 出清单 | `prompts/evolution/emit_backlog.md` |\n| 确认后改技能 | `prompts/evolution/apply_after_confirm.md`（须人审） |\n| 交底交付低频提示 | `prompts/evolution/soft_nudge.md`（可选一句，不入正文） |\n| 合同 | `references/schemas/evolution_backlog.schema.yaml` |\n\n### 审查答复（模式 D）\n\n| 步骤 | 文件 |\n|------|------|\n| 总则 | `prompts/oa/guardrails.md` |\n| 录入 | `prompts/oa/intake.md` |\n| 向量对话配置 | `prompts/oa/configure_embedding.md`（问答 → set/secrets → selftest） |\n| 脱敏入库 | `prompts/oa/ingest_case.md` + `tools/oa/ingest_case.py`（支持 `--pdf`） |\n| 答复草稿 | `prompts/oa/respond_office_action.md` + `tools/oa/search_cases.py --pdf` |\n| PDF 抽取 | `tools/oa/pdf_text.py`（pymupdf；优先路径，禁止让用户手贴） |\n| 案例模板 | `prompts/oa/case_note_template.md` |\n| 合同 / 配置 | `references/schemas/oa_case.schema.yaml`；运行时 `{Documents}/…/oa/embedding.config.yaml`（仓库模板 `docs/oa/`） |\n\n---\n\n## 模式 A · 交底书主流程\n\n1. **`Read`** `disclosure/intake.md` → Step 1（默认发明）  \n2. **`Read`** `disclosure/project_scan.md` → Step 2  \n3. 按类型 **`Read`** `invention|utility_model|design` 挖点；实用/外观先/并行 **`Read`** `shared/fill_*`  \n   - 填表写出 `figure_plan` 后：**`Read`** `shared/image_gen.md` + 对应 `shared/*_lineart_assist.md`（必做，不问用户）  \n4. **`Read`** `disclosure/prior_art_search.md` → Step 5（`--type` 对齐）  \n5. **`Read`** `disclosure/disclosure_preview.md` → Step 6（可跳过；此处可类型反问）  \n6. **`Read`** **同类型** `disclosure_builder` + `template_reference` → Step 7（**禁止**用发明 builder 写实用/外观）  \n7. **`Read`** `disclosure/disclosure_self_check.md` → Step 8  \n8. **交付回复末尾**：若 cad_scan 为 `ask_enable_step_parse`，交底落盘后再反问是否开启 STEP 解析；`hint_export_step` 则提示导出。未得 **是** 禁止装依赖。用户成文前已主动说「是」的除外。\n\n**禁止**：交底书正文出现「自检清单」章节。\n\n---\n\n## 模式 B · 专利通俗解读\n\n1. **`Read`** `reader/patent_plain_reader.md`（门禁 / fetch / extract / 线索 / 入库）  \n2. 若实用新型或外观：**`Read`** `reader/type_hooks.md` + 对应 `shared/fill_*`  \n3. **`Read`** ofm + 自检；入库后可选插件引导；≥2 篇反问关联  \n\n**与模式 A 互斥**：解读不跑交底 Step 1–8。\n\n---\n\n## 模式 C · 技能进化旁路 · 政策/审查动向嗅探\n\n1. **`Read`** `evolution/guardrails.md` → `intake.md`  \n2. **`Read`** `evolution/research.md`：WebSearch + 打开国知局等官网正文；默认近 12 个月  \n3. **`Read`** `evolution/emit_backlog.md`：写入 `outputs/evolution/EVOL-YYYYMMDD-HHMM.md`  \n   - **主表必为「观点 ↔ 信源 URL」**（一行一观点，附准确 `https://` 链接）  \n   - 证据 C（自媒体等）不得单独支撑「改技能」建议  \n4. 展示人审闸门；**等待**「全部采纳 / 采纳 E… / 全部搁置 / 沉淀到 docs/evolution/」  \n5. 仅确认采纳后 → **`Read`** `apply_after_confirm.md` → 最小改动 prompts，并写 `.status.md`  \n\n交底定稿交付后的**可选一句**提示见 `evolution/soft_nudge.md`（低频；**不**等于自动进入本模式）。\n\n**与 A/B 互斥**：进化旁路不写交底书、不做专利解读成稿。\n\n---\n\n## 模式 D · 审查答复辅助\n\n1. **`Read`** `oa/guardrails.md` → `intake.md`  \n2. **首次 / 改向量**：`Read` `oa/configure_embedding.md` → 对话问清（可跳过 / 预设 / 自定义 URL+模型+Key）→ `config.py set … --api-key …`（默认 **selftest**）→ 需重建则人确认后 `rebuild_vectors.py --confirm`  \n3. **入库**：`ingest_case.py`（支持 `--pdf`）；笔记进 `oa/cases/history/`（或 pending/drafts）；自动刷新 `_OA索引` / Canvas / Bases；无向量时仍写笔记 + 元数据  \n4. **答复**：`search_cases.py --pdf …`（标签优先过滤；向量可用则 Top-K，失败/超时回退标签，展示 `retrieval_mode` + diff）→ 策略勾选 → 草稿 → 人审  \n5. **仅刷新 Obs**：`python tools/oa/refresh_vault.py` \n\n依赖：`pip install -r tools/oa/requirements-oa.txt`。  \n**与 A/B/C 互斥**：不写交底书主流程；草稿须复核后递交。\n\n---\n\n## 迭代模式（交底书 · 摘要）\n\n- 补材料 / 扩展：`iteration_context` → `merger` → 新时间戳稿（实用/外观若改图或主题须同步 **`figure_plan`**；术语改叫法则整族替换）  \n- 纠错：`iteration_context` → `correction_handler` → 新时间戳稿（同上；含术语太抽象、标题对象未落地）  \n\n---\n\n## Agent 自用工作流检查清单\n\n```\n□ 已区分模式 A / B / C / D / 迭代，未混跑\n□ 交底未指定类型时已默认发明；材料偏实用/外观已按需反问\n□ Step 3–4 / Step 7 已 Read 对应类型子目录 md（非发明套用实用/外观）\n□ 查新 cnipa 已带与案件一致的 --type；abstract 必用\n□ 发明成文：3.1 已铺标题对象与领域术语；框图/流程/实施例贯穿标题实词；用词贴合话题背景（错位行话已换成领域表述，非靠定义保留）；3.3 独立模块、3.4 逐项对应 S 步；第五章为可实施机制\n□ 发明含公式：已写 formula_plan（范式∈references/formulas）且可算数值例；禁装饰音；已 check_formula_plan 或等价自检\n□ 实用/外观已走 schema 填表（shared）并写出 figure_plan（含 relevance/quality 与必要 relates_to），未看图直接长文；实用只嵌入文线稿；外观 md+docx 同时嵌实拍与线稿；CAD 未入文\n□ Step 2/补材料已 cad_scan：遇 STEP **未**中断成文、**未**装依赖；交底落盘后才反问；仅原生 CAD 则交付回复末尾提示导出 STEP；未确认不开 step_to_views；确认后先 cad_venv 探测，已就绪则跳过 bootstrap；CAD 投影只当材料\n□ 外观线稿：已 Read image_gen.md + design_lineart_assist；已有合格线稿则未再生成，否则图生图或先描述再文生图；实拍与线稿均已入 md 与 Word；CAD 未当线稿入文\n□ 实用结构线稿：已 Read image_gen.md + structure_lineart_assist + structure_lineart_compose；件号对齐 parts；已按件写出 parts/{视}_{id}.svg 且总图相对引用（一层一件号，未拆筋/齿/螺栓，未整图 clip）；优先 overlay 注入；已叠标后读图核对（非仅 Python 合法）；未自创件号；CAD 未入文\n□ 迭代改材料/主题时已重评 figure_plan（含图际关联）\n□ 解读实用/外观：公开号种类码或 patent_type.py / fetch 状态已判别类型，并 Read type_hooks + 共用 schema（用户未口头声明也可）\n□ 模式 C：已显式触发；清单含观点↔URL 主表；未确认前未改技能；确认后才 apply\n□ 交底定稿交付：已按 evolution/soft_nudge 判断是否加低频一句（未每次必出、未写入正文）\n□ 模式 D：已显式触发；向量可选已反问（可跳过）；PDF 已自动抽取；入库已脱敏；检索展示 retrieval_mode；向量失败已回退标签；需重建时已人确认；草稿已人审提示\n□ 路径使用 prompts/disclosure|reader|shared|evolution|oa 与 tools/crawl|shared|oa|patent_reader/{extract,analyze,vault,shared}\n```\n\nFile v3.7.0:assets/obsidian/README.md\n\n# Obsidian 库模板\n\n本目录是仓库源稿。入库脚本会把文件拷进用户的 Obsidian 库。\n\n## Bases 扩展名\n\n部分技能市场不允许提交 `.base`。因此仓库里只保留 `*.base.yaml`：\n\n| 仓库源稿 | 拷进库后 |\n|----------|----------|\n| `patents.base.yaml` | `{papers_dir}/patents.base` |\n| `glossary.base.yaml` | `{glossary_dir}/glossary.base` |\n| `oa.base.yaml` | `oa/_OA看板.base` |\n\nObsidian Bases 仍只认 `.base`。不要在库内用 `.base.yaml`，也不要把库内 wikilink（如 `![[…/patents.base#…]]`）改成 yaml 后缀。\n\nFile v3.7.0:docs/evolution/README.md\n\n# docs/evolution — 已确认沉淀的进化清单（可选提交）\n\n日常雷达产出默认在 **`outputs/evolution/`**（gitignore，不进仓）。\n\n仅当用户在模式 C 中确认「沉淀到 docs/evolution/」时，将对应 `EVOL-*.md` **复制**到本目录，作为可版本管理的知识备忘。\n\n不要把未确认的草案直接提交到这里。\n\nFile v3.7.0:docs/oa/README.md\n\n# 模式 D · 审查答复案例库\n\n运行时数据优先落在操作系统**默认文档目录**（可用 `PATENT_OA_HOME` 覆盖）：\n\n| 路径 | 用途 |\n|------|------|\n| `{Documents}/patent-disclosure-skill/oa/embedding.config.yaml` | 嵌入模型与 sqlite 路径（首次须用户确认） |\n| `{Documents}/patent-disclosure-skill/oa/data/oa_vectors.sqlite` | sqlite-vec 向量库 |\n| `{Documents}/patent-disclosure-skill/oa/` | 无 Obsidian 库时的 oa 回退根 |\n| 本目录 `embedding.config.yaml` | **仓库模板种子**（`config.py seed` 复制到文档目录） |\n\n正式案例优先写入 **Obsidian**（方案 C）：\n\n```\n{vault}/oa/\n  _OA索引.md\n  _OA看板.base\n  _OA关联.canvas\n  cases/history/   # status=history，可检索\n  pending/         # 待答复\n  drafts/          # 人审草稿\n```\n\n刷新：`python tools/oa/refresh_vault.py`  \n查看实际路径：`python tools/oa/config.py recommend`。  \n仓库源稿是 `assets/obsidian/oa.base.yaml`（部分技能市场不允许提交 `.base`）；写入库时仍为 `_OA看板.base`。  \n流程见 `prompts/oa/` 与 [SKILL.md](../../SKILL.md) 模式 D。\n\nFile v3.7.0:README.md\n\n<div align=\"center\">\n\n# 中国专利.skill\n\n> 专利点挖掘与交底书（发明/实用/外观）编写，通俗解读专利，嗅探政策动向，辅助审查答复。\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n[![Python 3.9+](https://img.shields.io/badge/Python-3.9%2B-blue.svg)](https://www.python.org/)\n[![Playwright](https://img.shields.io/badge/Playwright-mermaid%20%2B%20CNIPA-2EAD33.svg)](https://playwright.dev/)\n[![AgentSkills](https://img.shields.io/badge/AgentSkills-Standard-green)](https://agentskills.io)\n\n<br>\n\n有设计文档和代码，但**专利点还没梳**？交底书要**框图 + 可改 Word**？<br>\n定稿后还要**多轮补材料、纠错**并留下修改追溯？<br>\n公开专利晦涩难懂，想**快速看懂权要与落地语境**？\n\n[初衷](#初衷) · [运行效果](#运行效果) · [功能特性](#功能特性) · [示例](#示例) · [支持作者](#支持作者) · [参考文档](#参考文档) · [安装说明](INSTALL.md) · [技能入口](SKILL.md)\n\n</div>\n\n---\n\n## 初衷\n\n### 专利交底书编写\n\n> **做了多年核心研发，专利发明人那一栏从没写过我的名字。**\n\n代码是自己敲的，方案是自己扛的，轮到交底书却卡在「专利点怎么挖、查新怎么写、框图和 Word 怎么一次交得出去」。本技能把这一环打通：覆盖发明 / 实用新型 / 外观设计，结构图与外观图都能读懂、写进交底；从项目材料梳出可申请的点，查新、脱敏、成文、迭代另存——让真正干活的人，也能把技术贡献写进可交付的交底书里。\n\n### 专利通俗解读\n\n> **不止一篇。**\n\n公开专利常把阅读门槛抬得很高：权要绕、术语密、落地语境散落在说明书与附图里。本技能把单篇读成通俗笔记与图谱，并入库 Obsidian；依托双链、图谱、插件与 Bases 等生态，陆续解读的专利可以沉淀成**只属于自己的私有专利知识库**——权要、术语、线索与附图彼此勾连，越读越厚。再叠上 [Obsidian CLI](https://help.obsidian.md/cli) 与库内外连接能力，检索、批处理、和外部工具接力都更容易：从单篇通俗笔记，走向可检索、可关联、可继续生长的个人专利情报层，把沉睡在 PDF 里的技术细节重新点亮。库厚了之后，还能在这层之上做**专利比对、挖掘与分析**——同族对照、技术路线梳理、差异点扫描，把「读懂」推进到「用起来」。\n\n---\n\n## 运行效果\n\n### 专利交底书编写\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">初版生成<br><sub>首次落盘交付</sub></th>\n<th width=\"50%\" align=\"center\">迭代更新<br><sub>多版本并存 + 对话记录</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-初版生成.jpg\" alt=\"初版生成：outputs 目录下的时间戳交底书、mermaid 图目录等\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-迭代更新.jpg\" alt=\"迭代更新：新时间戳文件与交底书修订对话记录\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 实用新型 / 外观 · 看图与出图\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"33%\" align=\"center\">外观线稿<br><sub>从产品图自动提炼造型轮廓</sub></th>\n<th width=\"33%\" align=\"center\">实用新型线稿<br><sub>从结构图自动生成轮廓与部件序号引出</sub></th>\n<th width=\"34%\" align=\"center\">CAD 三维模型投影<br><sub>从工程模型自动提取等轴测等多视角</sub></th>\n</tr>\n<tr>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-外观专利线稿.png\" alt=\"外观辅助线稿：产品造型黑白线稿示意\" width=\"100%\" />\n</td>\n<td width=\"33%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-实用新型专利线稿含部件序号引出线.png\" alt=\"实用新型辅助线稿：结构线稿与部件序号引出线\" width=\"100%\" />\n</td>\n<td width=\"34%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-cad提取等轴测投影图.png\" alt=\"CAD 三维模型等轴测投影：从工程模型自动提取多视角示意\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n### 专利通俗解读\n\n<table width=\"100%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"50%\" align=\"center\">Obsidian 关系图<br><sub>知识图谱与多色节点</sub></th>\n<th width=\"50%\" align=\"center\">解读 Canvas<br><sub>叙事故事线 · 术语 · 公开线索</sub></th>\n</tr>\n<tr>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-obs图谱.jpg\" alt=\"Obsidian 关系图：解读笔记、术语与 Canvas 知识图谱\" width=\"100%\" />\n</td>\n<td width=\"50%\" valign=\"top\" align=\"center\">\n<img src=\"docs/效果例-解读.jpg\" alt=\"专利解读 Canvas：叙事、权要、术语与公开线索图谱\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 功能特性\n\n### 专利交底书编写\n\n支持 **发明**、**实用新型**、**外观设计** 三种专利类型（未指定时默认发明；材料偏结构/外观时可反问切换）。\n\n<!-- 使用 HTML 表格：避免 GitHub 管道表把左列挤窄 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>专利类型</strong></td><td>发明 / 实用新型 / 外观设计<strong>分模板成文</strong>；实用与外观先填 Schema，再写 <code>figure_plan.yaml</code> 排序入文图（成文不扫全 assets 临场挑图）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>项目扫描</strong></td><td>按优先级读文档 / 代码；<code>.docx</code> / <code>.pptx</code> 先转 Markdown 再扫；可选扫描 <code>.step</code>/<code>.stp</code> 与原生 CAD（<strong>默认不解析</strong>，遇 STEP 成文不中断，交底落盘后再问）（<code>project_scan.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>外观线稿</strong></td><td>成文前选用或生成产品线稿（已有合格线稿优先，否则图生图 / 文生图）；与干净实拍一并写入 Markdown 和 Word（<code>design_lineart_assist.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>实用结构线稿</strong></td><td>成文前选用或生成结构线稿，按 <code>structure_schema.parts</code> 写出子 SVG、总图相对引用并叠部件序号（<code>structure_lineart_assist.md</code> / <code>structure_lineart_compose.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>专利点</strong></td><td>候选点讨论与融合（按类型：<code>invention|utility_model|design</code> 挖点文件）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>查新</strong></td><td><strong>优先</strong> <a href=\"http://epub.cnipa.gov.cn/\">国知局 · 中国专利公布公告</a>（<code>tools/crawl/cnipa_epub_search.py</code>，<code>--type</code> 对齐类型）；异常或无果时降级 WebSearch。著录写入第一章（<code>prior_art_search.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>交底书成稿</strong></td><td>脱敏模版；发明用 <strong>mermaid</strong> 框图；实用/外观按 <code>figure_plan</code> 嵌结构图或视图；定稿可出 <strong>.docx</strong></td></tr>\n<tr><td nowrap width=\"1%\"><strong>交付命名</strong></td><td><code>{案件名}_{YYYYMMDDHHmmss}.md</code> 与同名 <code>.docx</code>（<code>disclosure_builder.md</code> §7.3）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>自检 / 迭代</strong></td><td>逻辑与公式自检（不写入正文）；合并 / 纠正另存新文件 + <code>交底书修订对话记录.md</code></td></tr>\n</tbody>\n</table>\n\n怎么开口：自然语言即可（专利挖掘、交底书、查新等），或 `/交底书`、`/patent-disclosure-skill`；尽量带上**项目路径或技术主题**，并点明类型（未指定默认**发明**）。\n\n| 类型 | 典型场景 | 触发示例 |\n|------|----------|----------|\n| **发明** | 方法 / 系统 / 算法流程 | 「按发明写交底」「项目路径 …」 |\n| **实用新型** | 形状、构造、连接与装配 | 「实用新型」「一种…装置/结构」 |\n| **外观设计** | 外形、图案、色彩或其结合 | 「外观设计」「设计说明 / 视图」 |\n\n已有交底上补材料或纠错时，按 `merger.md` / `correction_handler.md` 另存新稿（实用/外观改图或主题时同步 `figure_plan`）。细则见 [SKILL.md](SKILL.md)、`prompts/disclosure/intake.md`。\n\n### 专利通俗解读\n\n**强烈推荐安装 Obsidian**：索引、Canvas 知识图谱、术语网与 callout 配色依赖库内呈现，才能发挥本模式的完整体验。安装与可选社区插件见 [docs/obsidian-setup-guide.md](docs/obsidian-setup-guide.md)。\n\n<table>\n<colgroup>\n<col width=\"1%\">\n<col>\n</colgroup>\n<thead>\n<tr><th align=\"left\" nowrap width=\"1%\">能力</th><th align=\"left\">说明</th></tr>\n</thead>\n<tbody>\n<tr><td nowrap width=\"1%\"><strong>取证解读</strong></td><td>全文 / PDF 抽取 → 权要树、术语表、特征—说明书—附图对照（<code>patent_plain_reader.md</code>）</td></tr>\n<tr><td nowrap width=\"1%\"><strong>叙述故事线</strong></td><td>一句话总览 + 连贯叙事：把权要与说明书「讲成人话」，降低首次通读成本</td></tr>\n<tr><td nowrap width=\"1%\"><strong>知识图谱</strong></td><td>单篇 <code>*_图谱.canvas</code>、多篇 <code>_专利关联.canvas</code>、术语双链与关系图配色；入库<strong>自动</strong>配置 CSS / Bases</td></tr>\n<tr><td nowrap width=\"1%\"><strong>公开线索辅助</strong></td><td>联网检索公开材料（≤3 条）；Agent 读 URL 写摘要；L1–L4 旁注与 <code>clues/</code> 落地，用行业语境辅助理解（<strong>非</strong>权要 / 说明书证据）</td></tr>\n</tbody>\n</table>\n\n怎么开口：读专利、专利解读、`/读专利`、`/patent-read`，并给出**公开号或 PDF 路径**。配置库环境变量 `PATENT_READER_OBSIDIAN_VAULT` 体验更完整；无库时可降级到 `outputs/patent_reader/`。流程见 [tools/patent_reader/README.md](tools/patent_reader/README.md)、[SKILL.md](SKILL.md)。\n\n### 政策感知与技能自进化\n\n审查指南、智能审查口径一变，交底写法很容易「还按老习惯」。需要时可以说一声「技能进化 / 政策雷达 / 政策审查动向嗅探」：联网看看国知局等官网**近期政策与审查动向**，把观点和原文链接整理成**参考清单**（默认 `outputs/evolution/EVOL-*.md`；确认沉淀后再拷到 `docs/evolution/`），帮你判断技能该不该跟、怎么跟。也可 `/patent-evolve`、`/技能进化`。默认不开；你点头确认前，**不会**擅自改交底/解读流程。细则见 [SKILL.md](SKILL.md)「模式 C」与 `prompts/evolution/`。\n\n### 审查答复辅助\n\n审查意见一来，往往要翻旧案、对法条、想策略——经验散落在 PDF 和聊天记录里，很难复用。需要时可以说「审查答复 / 案例入库 / `/审查答复`」：**自动**完成「历史通知书与答复脱敏写入 Obsidian、打上法条/缺陷等标签以固化经验 → 对新通知书做标签过滤（向量模型可选；启用后叠加本地轻量向量相似度检索，相当于外挂一套属于自己的 RAG 知识库）→ 交大模型起草意见陈述」整条链路，提高召回精准度，让答复更贴你的历史口径，而不是凭空瞎编。向量可跳过，也可中途开启并重建索引；向量不可用时仍靠标签检索继续出草稿。默认不开；产出为草稿，须人审后再递交。细则见 [SKILL.md](SKILL.md)「模式 D」、[docs/oa/README.md](docs/oa/README.md)、[tools/oa/README.md](tools/oa/README.md)。\n\n接入宿主、Python / Node、可选 STEP 等见 **[INSTALL.md](INSTALL.md)**。\n\n---\n\n## 示例\n\n索引见 [examples/README.md](examples/README.md)。完整产物落在 **`outputs/`** 或 Obsidian 库。\n\n<!-- 使用 HTML 表格：前两列 nowrap 防挤窄，后两列自动换行 -->\n<table>\n<colgroup>\n<col width=\"1%\">\n<col width=\"1%\">\n<col>\n<col>\n</colgroup>\n<thead>\n<tr>\n<th align=\"left\" nowrap width=\"1%\">示例</th>\n<th align=\"left\" nowrap width=\"1%\">类型</th>\n<th align=\"left\">材料</th>\n<th align=\"left\">怎么开口</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td nowrap width=\"1%\">批任务调度</td>\n<td nowrap width=\"1%\"><strong>发明</strong>交底</td>\n<td><a href=\"examples/example_batch_job_scheduler/\"><code>examples/example_batch_job_scheduler/</code></a>（扫 <code>knowledge/</code>）</td>\n<td>「按发明写交底，项目路径 …/knowledge/」或 <code>/交底书</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">汽车集成式电驱桥</td>\n<td nowrap width=\"1%\"><strong>实用新型</strong>交底</td>\n<td><a href=\"examples/example_utility_model_ev_powertrain/\"><code>examples/example_utility_model_ev_powertrain/</code></a></td>\n<td>「实用新型交底，材料在 …/example_utility_model_ev_powertrain/」</td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">折臂台灯</td>\n<td nowrap width=\"1%\"><strong>外观设计</strong>交底</td>\n<td><a href=\"examples/example_design_desk_lamp/\"><code>examples/example_design_desk_lamp/</code></a></td>\n<td>「外观设计交底，材料在 …/example_design_desk_lamp/」</td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">公开专利 PDF</td>\n<td nowrap width=\"1%\"><strong>通俗解读</strong></td>\n<td><a href=\"examples/example_patent_reader/\"><code>examples/example_patent_reader/</code></a>（PDF 本地自备）</td>\n<td>「读专利」+ 公开号或 PDF；<code>/读专利</code>、<code>/patent-read</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">政策 / 审查动向</td>\n<td nowrap width=\"1%\"><strong>技能自进化</strong></td>\n<td>无需本地样例（联网出清单 → <code>outputs/evolution/EVOL-*.md</code>）</td>\n<td>「技能进化 / 政策雷达 / 政策审查动向嗅探：近 12 个月国知局动向，整理观点↔链接，先别改技能」；<code>/patent-evolve</code>、<code>/技能进化</code></td>\n</tr>\n<tr>\n<td nowrap width=\"1%\">审查答复样例</td>\n<td nowrap width=\"1%\"><strong>审查答复</strong></td>\n<td><a href=\"examples/example_oa_response/\"><code>examples/example_oa_response/</code></a>（2 历史案 + 1 待答复通知书）</td>\n<td>「审查答复：先入库 <code>cases/</code>，再用 <code>pending/oa_notice_pending.md</code> 出草稿；向量可跳过」；<code>/审查答复</code>、<code>/oa</code></td>\n</tr>\n</tbody>\n</table>\n\n---\n\n## 支持作者\n\n如果这个 Skill 对您有帮助，可以请我喝杯咖啡☕随缘支持，感谢感谢🙏🙏\n\n<table width=\"70%\" border=\"1\" cellpadding=\"12\" cellspacing=\"0\">\n<tr>\n<th width=\"40%\" align=\"center\">随缘支持</th>\n<th width=\"60%\" align=\"center\">Star History</th>\n</tr>\n<tr>\n<td width=\"40%\" valign=\"middle\" align=\"center\">\n<img src=\"docs/thanks.jpg\" alt=\"随缘支持\" width=\"200\" />\n</td>\n<td width=\"60%\" valign=\"middle\" align=\"center\">\n<img alt=\"Star History Chart\" src=\"https://raw.githubusercontent.com/handsomestWei/patent-disclosure-skill/star-history/star-history.svg\" width=\"100%\" />\n</td>\n</tr>\n</table>\n\n---\n\n## 参考文档\n\n- [技能入口与 Agent 流程](SKILL.md)（交底 / 解读 / 进化 / 审查答复）\n- [详细安装说明](INSTALL.md)\n- [交底书：图示与转换 / 国知局工具](tools/README.md)\n- [专利解读工具](tools/patent_reader/README.md)\n- [审查答复 · 案例 RAG](tools/oa/README.md)\n- [Obsidian 安装与可选社区插件（Windows）](docs/obsidian-setup-guide.md)\n- [示例案件与原材料](examples/README.md)\n- [交底书模版细则](prompts/disclosure/invention/template_reference.md)\n\n---\n\n<div align=\"center\">\n\nMIT License © [handsomestWei](https://github.com/handsomestWei/)\n\n</div>\n\nFile v3.7.0:references/formulas/README.md\n\n# 公式推荐范式（外挂配置）\n\n发明交底在写 **3.4.1** 前，须依据本目录配置**选题**，再填入案件符号与数值，避免临时发明抽象式子。\n\n| 文件 | 作用 |\n|------|------|\n| [`paradigms.yaml`](paradigms.yaml) | 默认范式库 + 全局规则（禁装饰音、符号上限等） |\n| [`../schemas/formula_plan.schema.yaml`](../schemas/formula_plan.schema.yaml) | 案件级 `formula_plan.yaml` 合同 |\n\n## 加载顺序（后者覆盖同 `id`）\n\n1. 仓库 `references/formulas/paradigms.yaml`\n2. 环境变量 `PATENT_FORMULA_PARADIGMS` 指向的 YAML/JSON\n3. 案件目录 `formula_paradigms.yaml` 或 `...","readmeExcerpt":"Skill: 中国专利.Skill Owner: handsomestwei Summary: 中国专利技能：挖掘专利点与编写交底书（发明/实用/外观），把已有交底改写成申请文件四件套，也可按材料交底申请一起做，按著录字段检索公布公告，通俗解读专利，对照审查口径出政策简报，辅助审查答复。| China patents skill: mine patent points and draft disclosures, rewrite an existing disclosure into application documents, or chain disclosure-then-application from inventor materials in one pass (ask wh Tags: latest:4.5.0 Version history: v4.5.0 | 2026-09-07T08:12:06.771Z |","codeSnippets":[],"executableExamples":[{"language":"text","snippet":"SKILL.md                         # 本文件：子技能路由入口\nskills/patent-disclosure/        # 交底（含填表/线稿/CAD/公式/docx）\nskills/patent-application/       # 申请文件四件套（须显式；须指定交底目录）\nskills/patent-docket/            # 案卷：交底到申请一趟串起来（须显式）\nskills/patent-search/            # 著录检索\nskills/patent-reader/            # 解读\nskills/patent-oa/                # 审查答复\nskills/patent-exam-policy/        # 政策简报（技能进化为旁路）"},{"language":"text","snippet":"□ 已 Read 对应 skills/*/SKILL.md，未把本文件当交底/申请底稿/案卷/检索/解读正文\n□ 交底查新未调用 patent-search\n□ 著录检索未用交底一词一页结果冒充清单\n□ 政策简报 / 审查答复 / 申请文件 / 案卷仅在显式触发时进入\n□ 申请文件已指定交底目录；门禁未过未开写\n□ 案卷未写交底/申请正文；派工只 Read 对方 SKILL.md\n□ 未跨包调用其他子技能的 tools/\n□ 未把政策简报当成改技能；无点名未改交底包以外的目录"},{"language":"bash","snippet":"python skills/patent-docket/tools/init_docket.py --case-id 案件slug --mode from_zero\npython skills/patent-docket/tools/validate_docket.py --yaml outputs/docket/案件slug/docket.yaml\npython skills/patent-docket/tools/emit_tracker.py --yaml outputs/docket/案件slug/docket.yaml"},{"language":"bash","snippet":"python skills/patent-search/tools/cnipa_search.py --inventor \"姓名\" --applicant \"单位\"\npython skills/patent-search/tools/cnipa_search.py --title \"数据处理\" --abstract \"吸附 and 再生\" --class B01J20 --max-pages 2\npython skills/patent-search/tools/cnipa_search.py --abstract \"折叠 and 杯盖\" --type design --derived-from image --type-inferred --derived-note \"折叠杯盖\"\npython skills/patent-search/tools/cnipa_search.py --inventor \"姓名\" --complete"},{"language":"bash","snippet":"python skills/patent-application/tools/material_gate.py --case-dir outputs/{案件}\npython skills/patent-application/tools/render_invention_figures.py \\\n  --plan outputs/patent-application/{案}/figures/invention_figures.yaml \\\n  --out-dir outputs/patent-application/{案}/figures\npython skills/patent-application/tools/audit_claims.py outputs/patent-application/{案}/权利要求书.md\npython skills/patent-application/tools/check_support.py --dir outputs/patent-application/{案}\npython skills/patent-application/tools/compose_application_figure.py \\\n  --source <线稿或场景图> --fig 3 --out-dir outputs/patent-application/{案}/figures\npython skills/patent-application/tools/emit_application_docx.py --dir outputs/patent-application/{案}"},{"language":"text","snippet":"SKILL.md                         # 本文件：子技能路由入口\nskills/patent-disclosure/        # 交底（含填表/线稿/CAD/公式/docx）\nskills/patent-search/            # 著录检索\nskills/patent-reader/            # 解读\nskills/patent-oa/                # 审查答复\nskills/patent-exam-policy/        # 政策简报（技能进化为旁路）"}],"parameters":null,"dependencies":[],"permissions":[],"extractedFiles":[{"path":"SKILL.md","content":"---\nname: patent-disclosure-skill\ndescription: \"中国专利技能：挖掘专利点与编写交底书（发明/实用/外观），把已有交底改写成申请文件四件套，也可按材料交底申请一起做，按著录字段检索公布公告，通俗解读专利，对照审查口径出政策简报，辅助审查答复。| China patents skill: mine patent points and draft disclosures, rewrite an existing disclosure into application documents, or chain disclosure-then-application from inventor materials in one pass (ask when facts are missing; at most three issue-list rounds), search CNIPA bibliographic records, explain patents, brief examination-policy changes, and assist office-action responses.\"\nversion: \"4.5.0\"\nuser-invocable: true\nargument-hint: \"[可选：项目路径 / 交底书 / 申请底稿 / 交底申请一起做 / 专利检索 / 专利号或 PDF / 政策简报 / 审查答复]\"\nallowed-tools: Read, Write, Edit, Grep, Glob, WebSearch, Bash\n---\n\n# 中国专利技能\n\n按用户意图 **`Read`** 对应入口的 `SKILL.md`，再按该流程执行。\n\n| 能力 | 做什么 | 何时进入 | 入口 |\n|------|--------|----------|------|\n| **交底** | 挖专利点 → 查新 → 成稿 → 迭代 | 专利挖掘、交底书、查新、实用新型、外观设计；`/patent-disclosure`、`/交底书` | `skills/patent-disclosure/SKILL.md` |\n| **申请文件** | 已有交底 → 权要 / 说明书 / 摘要 / 附图 | **须显式**且**指定交底目录**：申请文件、申请底稿、申报材料、`/申请底稿`、`/patent-apply`。仅缺材料则终止；内容争议写入问题清单；交付末尾须摘要清单；改已有产出则另存 | `skills/patent-application/SKILL.md` |\n| **案卷** | 按发明人/工程师给的材料一趟写出交底书和申请文件；清单缺口最多来回三轮，缺事实问人、不编 | **须显式**：交底申请一起做、从零出交底和申请、一条龙、帮写交底再出申请、按清单改、会稿、案卷、`/patent-docket`。只写交底或已有交底只出四件套 → 不要进本案。状态 `outputs/docket/` | `skills/patent-docket/SKILL.md` |\n| **检索** | 公布站高级查询（发明人/申请人/分类号/名称/摘要等）；单图或权要可先抽关键字再查 | 按著录字段查公布公告、个人公开清单、以图/权要生成检索式；`/patent-search`。普通多条件**不要**默认翻完全部分页 | `skills/patent-search/SKILL.md` |\n| **解读** | 公开号 / PDF / 全文 → 通俗笔记 + 图谱 | 读专利、公开号或 PDF 且目标为理解；`/patent-read`、`/读专利` | `skills/patent-reader/SKILL.md` |\n| **审查答复** | 审查意见问答与草稿；库薄时引导入库/蒸馏 | **须显式**：审查意见、OA、案例入库、实务书、`/oa` | `skills/patent-oa/SKILL.md` |\n| **政策简报** | 对照国知局口径，说明对交底写法/本稿的影响；改技能仅为旁路 | **须显式**：政策简报、政策雷达、`/政策简报`、`/patent-brief`、`/patent-exam-policy`。「技能进化 / `/patent-evolve`」同一入口，仍先出简报 | `skills/patent-exam-policy/SKILL.md` |\n\n## 路由\n\n- 填表、线稿、CAD、公式、Word 出图在交底包 `prompts/` 与 `tools/`；解读填表用解读包 `prompts/fill_*`；过 WAF 的 `browser.py`、Markdown 转 Word 的 `md_to_docx.py` **各包自带副本**。\n- **禁止跨包调用**其他子技能的 `tools/`。需要同一能力就用本包副本。\n- 专利号或 PDF 且意图为「读懂」→ **优先解读**，不跑交底 Step 1–8。\n- **禁止**因写交底或读专利自动进入政策简报、审查答复、申请文件或案卷。申请文件必须用户点名并给出交底目录；缺 schema / 线稿 / 交底书则停，引导先补交底。内容争议不阻塞主文件。\n- **案卷**必须用户点名（交底申请一起做 / 从零出交底和申请 / 一条龙 / 帮写交底再出申请 / 按清单改 / 会稿 / `/patent-docket`）。点名后 `Read` `skills/patent-docket/SKILL.md`；由案卷再 `Read` 交底或申请入口。调度申请视为已点名申请文件，仍须有交底目录。只写交底、或已有交底只出四件套 → 不要进案卷。\n- 交底 Step 5 查新只用交底包轻量检索（一词一页）；按发明人/申请人等做著录检索时只用检索包，两者不要混用。\n\n## 目录\n\n```\nSKILL.md                         # 本文件：子技能路由入口\nskills/patent-disclosure/        # 交底（含填表/线稿/CAD/公式/docx）\nskills/patent-application/       # 申请文件四件套（须显式；须指定交底目录）\nskills/patent-docket/            # 案卷：交底到申请一趟串起来（须显式）\nskills/patent-search/            # 著录检索\nskills/patent-reader/            # 解读\nskills/patent-oa/                # 审查答复\nskills/patent-exam-policy/        # 政策简报（技能进化为旁路）\n```\n\n## 环境与约定\n\n- **默认语言**：面向用户的检索清单、交底书、申请文件、案卷 TRACKER、解读和审查答复用简体中文；脚本机读前缀与 JSON 字段名保持稳定。\n- **脚本判读（尤其 Windows）**：stderr 有字 "},{"path":"skills/patent-application/SKILL.md","content":"---\nname: patent-application\ndescription: \"申请文件：把已有交底写成权利要求书、说明书、摘要与说明书附图。须指定交底目录；仅缺材料才终止。内容争议写入问题清单，不阻塞主文件。交付后对话末尾须给出清单路径并摘要条目。已有产出上改稿则另存新时间戳目录。须显式触发。\"\nuser-invocable: false\n---\n\n# 申请文件\n\n须用户点名（申请文件 / 申请底稿 / 申报材料 / 权利要求书 / `/申请底稿` / `/patent-apply`），并**指定交底材料目录**。案卷会稿（`patent-docket`）调度本包时视为已点名，仍须有交底目录。  \n缺交底书 / schema / 线稿则**终止**，引导先用交底技能补齐。内容歧义**不阻塞**：先出主文件，缺口写入 `问题清单.md`。发明人/申请人未填只记清单，不终止、不挡案卷轮次。交付后对话末尾须给出该文件路径并摘要条目（见 `issues.md`）。\n\n主交付是**四件套**（Markdown + Word + 黑白图）。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. 已有申请产出上改稿（未要求整案重写）：**`Read`** `iteration_context.md` → `iteration.md`（新时间戳目录、出 Word、问题清单），然后结束，不要再走第 3–5 步\n3. 跑 `tools/material_gate.py --case-dir <交底目录>`；退出码 2 则停\n4. 发明 / 实用新型：`claim_strategy.md` → `claims_builder.md` → `figures.md` → `specification_builder.md` → `numeral_register.md` → `consistency.md`\n5. 外观：先 `Read` `references/design_view_cnipa.md`（或交底包同文），只走 `design_application.md`；不跑 `compose_application_figure.py`\n6. 本包 `tools/emit_application_docx.py` 出 Word；**`Read`** `issues.md`，写 `问题清单.md`（不入正式文件），并在**同一条交付回复末尾**给出路径、摘要条目、请用户先看清单\n\n整仓路径：`python skills/patent-application/tools/…`。  \n产出：`outputs/patent-application/{案件标识}_{时间戳}/`。禁止跨包调用其他子技能 `tools/`。不做 TIFF，不做请求书 / 费减 / CPCNS。"},{"path":"skills/patent-disclosure/SKILL.md","content":"---\nname: patent-disclosure\ndescription: \"中国专利交底书：发明/实用新型/外观设计的专利点挖掘、轻量查新与成文。\"\nuser-invocable: false\n---\n\n# 交底书编写\n\n分步指令在 **`prompts/`**（本包内）。发明 / 实用新型 / 外观是**包内三个目录**，不是三个可触发技能。\n\n| 步骤 | 文件 |\n|------|------|\n| Step 1 | `prompts/intake.md` |\n| Step 2 | `prompts/project_scan.md` |\n| Step 3–4 | `prompts/invention/` · `utility_model/` · `design/` 挖点 |\n| 填表 / 线稿 | `prompts/fill_*`、`image_gen.md`、`*_lineart_*.md`；外观视图口径 `references/design_view_cnipa.md` |\n| Step 5 | `prompts/prior_art_search.md`（轻量查新，一词一页） |\n| Step 6 | `prompts/disclosure_preview.md` |\n| Step 7 | 对应类型 `disclosure_builder.md` + `template_reference.md` |\n| Step 8 | `prompts/disclosure_self_check.md` |\n| 迭代 | `iteration_context.md` / `merger.md` / `correction_handler.md` |\n\n查新工具：`tools/crawl/cnipa_epub_search.py`。整仓安装时路径为 `skills/patent-disclosure/tools/crawl/cnipa_epub_search.py`。著录检索不在本包，**禁止**当查新引擎调用。  \n交底交付后**不要**自动进入申请文件；用户点名并给出本目录后，再走 `skills/patent-application/SKILL.md`。  \n`--type` 与 intake 一致；两段式：关键词 → `EPUB_CLASS_HINT` / IPC·LOC → `--class`；不足 4 条则同分类号回补第一轮。\n\n线稿、CAD、公式、Word 出图用本包 `tools/`（`browser.py`、`mermaid_render.py`、`md_to_docx.py` 等）。"},{"path":"skills/patent-docket/SKILL.md","content":"---\nname: patent-docket\ndescription: \"按发明人/工程师给的材料一趟写出交底书和申请文件；申请问题清单上的缺口最多改三轮。缺技术事实就问人，不编。触发：交底申请一起做、从零出交底和申请、一条龙、帮写交底再出申请、按清单改、会稿、案卷、/patent-docket。\"\nuser-invocable: false\n---\n\n# 案卷会稿\n\n单 agent 协调者。**先 `Read` `prompts/guardrails.md`，再 `Read` `prompts/intake.md`。** 禁止跳过 intake 直接派工。\n\n本包只调度与记案卷，不写交底正文、不出四件套。派工时 **`Read`** 对方 `SKILL.md` 并按该包执行；**禁止**调用其他子技能的 `tools/`。\n\n## 加载顺序（每次进入都走）\n\n1. `prompts/guardrails.md`\n2. `prompts/intake.md`（判定 `from_zero` / `from_disclosure` / `from_application` / `resume`）\n3. 按 intake 结果只加载下列之一，不要一次读完所有 prompt：\n   - 新开或从零 → `prompts/bootstrap.md`\n   - 已有 `docket.yaml` → `prompts/resume.md`\n4. 之后按 `docket.yaml` 的 `phase` **只读**对应文件（见下表）。阶段表在 `references/phases.yaml`。\n\n| `phase` | 再读 |\n|---------|------|\n| `bootstrap_disclosure` / `wait_disclosure` / `dispatch_disclosure` | `prompts/dispatch_disclosure.md` |\n| `bootstrap_application` / `wait_application` / `dispatch_application` | `prompts/dispatch_application.md` |\n| `triage` | `prompts/triage.md` → `references/issue_taxonomy.md` |\n| `ask_human` | `prompts/ask_human.md` |\n| `round_close` | `prompts/round_close.md` |\n| `terminal_*` | `prompts/round_close.md`（只做收口陈述，不再派工） |\n\n阶段合法跳转：`references/phases.yaml`。机器校验：`tools/validate_docket.py`。tracker 落盘：`tools/emit_tracker.py`。交接只传路径：`references/handoff_contract.md`。\n\n## 轮次\n\n- 上限 **`config.yaml` 的 `max_rounds`（默认 3）**，细则 `references/max_rounds.md`。\n- 从零：首套交底 + 首套申请记为第 1 轮。\n- 之后每「分诊 → 派工 → 再出申请并核清单」加 1 轮。\n- 第 3 轮结束后必须停。\n\n## 命令\n\n```bash\npython skills/patent-docket/tools/init_docket.py --case-id 案件slug --mode from_zero\npython skills/patent-docket/tools/validate_docket.py --yaml outputs/docket/案件slug/docket.yaml\npython skills/patent-docket/tools/emit_tracker.py --yaml outputs/docket/案件slug/docket.yaml\n```\n\n案卷目录默认 **`outputs/docket/{case_id}/`**（gitignore 的 `outputs/`）。机读前缀：`DOCKET_DIR:` / `DOCKET_YAML:` / `DOCKET_OK:` / `DOCKET_ERROR:`。\n\n**不做**：审查答复、政策简报、著录检索当会稿引擎、多 agent 分发、把聊天摘要当成技术事实。"},{"path":"skills/patent-exam-policy/SKILL.md","content":"---\nname: patent-exam-policy\ndescription: \"给交底用的政策简报：对照国知局近期口径，说明对交底写法/本稿的影响。技能进化仅为旁路，须另点名才改文件。\"\nuser-invocable: false\n---\n\n# 政策简报（交底用）\n\n须用户点名（政策简报 / 政策雷达 / 审查政策更新 / `/政策简报` / `/patent-brief` / `/patent-exam-policy`）。  \n**默认只出简报，不改技能。** 「技能进化 / `/patent-evolve`」走同一套检索，但仍先出简报；只有用户再点名改技能时才 `Read` `apply_after_confirm.md`。\n\n1. **`Read`** `prompts/guardrails.md` → `intake.md`\n2. **`Read`** `prompts/research.md`（A/B 分层种子 + 实用新型/外观/实施细则 + 相对上次增量）\n3. **`Read`** `prompts/emit_backlog.md` → `outputs/exam-policy/`（含施行日历）\n4. **仅当**用户明确要求改交底技能 → **`Read`** `prompts/apply_after_confirm.md`\n\n主题→文件：`references/topic_prompt_map.md`。信源种子：`references/sources.yaml`（A 可支撑交底口径；B 与地方预审不得单独改技能）。"}],"languages":[],"docsSourceLabel":"CLAWHUB","editorialOverview":null,"editorialQuality":{"score":100,"threshold":65,"status":"thin","wordCount":1424,"uniquenessScore":43,"reasons":["uniqueness-below-45"]}},"media":{"evidence":{"source":"no-media","verified":false,"confidence":"low","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":"No screenshots, media assets, or demo links are available."},"primaryImageUrl":null,"mediaAssetCount":0,"assets":[],"demoUrl":null},"ownerResources":{"evidence":{"source":"unclaimed","verified":false,"confidence":"low","updatedAt":"2026-10-09T09:47:04.262Z","emptyReason":"This page has not been claimed by the agent owner."},"hasCustomPage":false,"customPageUpdatedAt":null,"customLinks":[],"structuredLinks":{"docsUrl":null,"demoUrl":null,"supportUrl":null,"pricingUrl":null,"statusUrl":null},"customPage":null},"relatedAgents":{"evidence":{"source":"protocol-neighbors","verified":false,"confidence":"medium","updatedAt":"2026-10-09T19:09:22.686Z","emptyReason":null},"items":[{"id":"b917f68a-ebff-438e-84f8-3f4b2494c0bc","entityType":"agent","canonicalPath":"/agent/activepieces-activepieces","slug":"activepieces-activepieces","name":"activepieces","description":"AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents","url":"https://github.com/activepieces/activepieces","homepage":"https://www.activepieces.com","source":"GITHUB_REPOS","protocols":["OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-04-15T02:22:12.426Z","createdAt":"2026-02-25T03:38:12.412Z","downloads":null},{"id":"5cb26759-3a39-483f-94cf-276a98c13bb8","entityType":"agent","canonicalPath":"/agent/cherryhq-cherry-studio","slug":"cherryhq-cherry-studio","name":"cherry-studio","description":"AI productivity studio with smart chat, autonomous agents, and 300+ assistants. Unified access to frontier LLMs","url":"https://github.com/CherryHQ/cherry-studio","homepage":"https://cherry-ai.com","source":"GITHUB_REPOS","protocols":["MCP","OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-04-11T14:38:40.986Z","createdAt":"2026-02-25T03:38:19.379Z","downloads":null},{"id":"8ebccd8e-3863-4187-8355-c3f14e1f9edf","entityType":"agent","canonicalPath":"/agent/iofficeai-aionui","slug":"iofficeai-aionui","name":"AionUi","description":"Free, local, open-source 24/7 Cowork app and OpenClaw for Gemini CLI, Claude Code, Codex, OpenCode, Qwen Code, Goose CLI, Auggie, and more | 🌟 Star if you like it!","url":"https://github.com/iOfficeAI/AionUi","homepage":"https://www.aionui.com","source":"GITHUB_REPOS","protocols":["MCP","OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-04-10T18:48:31.762Z","createdAt":"2026-02-25T03:38:16.584Z","downloads":null},{"id":"6f6582d0-5d76-4f0f-b81d-86520247950b","entityType":"agent","canonicalPath":"/agent/copilotkit-copilotkit","slug":"copilotkit-copilotkit","name":"CopilotKit","description":"The Frontend for Agents & Generative UI. React + Angular","url":"https://github.com/CopilotKit/CopilotKit","homepage":"https://docs.copilotkit.ai","source":"GITHUB_REPOS","protocols":["OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-03-25T09:50:57.846Z","createdAt":"2026-02-25T03:39:14.617Z","downloads":null}],"links":{"hub":"/agent","source":"/agent/source/clawhub","protocols":[{"label":"OpenClaw","href":"/agent/protocol/openclew"}]}}}