From 54b77e709698aef79281197503ceae57a2e9220c Mon Sep 17 00:00:00 2001 From: sean Date: Sat, 28 Jun 2025 15:02:34 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E9=87=8D=E6=9E=84/prompt/=E7=9B=AE?= =?UTF-8?q?=E5=BD=95=E4=B8=BA/resource/=20-=20=E6=9B=B4=E7=AC=A6=E5=90=88?= =?UTF-8?q?=E8=B5=84=E6=BA=90=E5=BC=95=E7=94=A8=E5=8D=8F=E8=AE=AE=E8=AF=AD?= =?UTF-8?q?=E4=B9=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 重命名核心目录: /prompt/ → /resource/ - 更新PackageDiscovery中所有硬编码路径引用 - 重新生成package.registry.json,61个资源全部更新为@package://resource/路径 - 批量更新文档中的路径引用,保持一致性 - 目录结构保持不变:domain/, core/, protocol/, tool/子目录结构完全一致 重构原因: 随着tool协议的加入,prompt目录名称不再准确描述系统本质 重构价值: 为未来资源生态扩展奠定清晰的命名基础 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- .../resource-architecture-improvement.md | 6 +- docs/mcp-adapter-design.md | 2 +- docs/nuwa-role-analysis-report.md | 4 +- docs/reference-protocol-layers.md | 22 +- docs/resource-referrence-architech.md | 2 +- docs/role-activation-improvements.md | 2 +- docs/role-discovery-optimization.md | 2 +- docs/role-system-complete-guide.md | 4 +- .../core/_deprecated/recall_v1.thought.md | 0 .../core/_deprecated/remember_v1.thought.md | 0 .../core/recall-xml.thought.md | 0 {prompt => resource}/core/recall.thought.md | 0 .../core/remember-xml.thought.md | 0 {prompt => resource}/core/remember.thought.md | 0 .../domain/assistant/assistant.role.md | 0 .../execution/assistant.execution.md | 0 .../assistant/thought/assistant.thought.md | 0 .../execution/code-quality.execution.md | 0 .../execution/frontend-developer.execution.md | 0 .../technical-architecture.execution.md | 0 .../execution/user-experience.execution.md | 0 ...echat-miniprogram-development.execution.md | 0 .../frontend-developer.role.md | 0 .../thought/frontend-developer.thought.md | 0 .../execution/code-quality.execution.md | 0 .../execution/database-design.execution.md | 0 .../java-backend-developer.execution.md | 0 .../execution/spring-ecosystem.execution.md | 0 .../system-architecture.execution.md | 0 .../java-backend-developer.role.md | 0 .../thought/java-backend-developer.thought.md | 0 .../execution/adaptive-learning.execution.md | 0 .../content-preservation.execution.md | 0 .../domain/noface/noface.role.md | 0 .../execution/dpml-authoring.execution.md | 0 .../role-design-patterns.execution.md | 0 .../execution/role-generation.execution.md | 0 .../visualization-enhancement.execution.md | 0 {prompt => resource}/domain/nuwa/nuwa.role.md | 0 .../nuwa/thought/role-creation.thought.md | 0 .../execution/market-analysis.execution.md | 0 .../execution/product-manager.execution.md | 0 .../execution/user-research.execution.md | 0 .../product-manager/product-manager.role.md | 0 .../thought/product-manager.thought.md | 0 .../contradiction-analysis.execution.md | 0 ...iction-management-methodology.execution.md | 0 .../sean-decision-framework.execution.md | 0 .../execution/template-adherence.execution.md | 0 .../contradiction-methodology.knowledge.md | 0 .../knowledge/product-philosophy.knowledge.md | 0 .../knowledge/promptx-evolution.knowledge.md | 0 {prompt => resource}/domain/sean/sean.role.md | 0 .../contradiction-methodology.thought.md | 0 .../domain/sean/thought/sean.thought.md | 0 .../execution/brand-marketing.execution.md | 0 .../execution/community-building.execution.md | 0 .../execution/content-creation.execution.md | 0 .../content-optimization.execution.md | 0 .../execution/data-analytics.execution.md | 0 .../ecommerce-conversion.execution.md | 0 .../performance-optimization.execution.md | 0 .../platform-compliance.execution.md | 0 .../execution/team-collaboration.execution.md | 0 .../execution/user-operation.execution.md | 0 .../xiaohongshu-marketer.execution.md | 0 .../thought/xiaohongshu-marketer.thought.md | 0 .../xiaohongshu-marketer.role.md | 0 .../protocol/dpml.protocol.md | 0 .../protocol/pateoas.protocol.md | 0 .../protocol/tag/execution.tag.md | 0 .../protocol/tag/resource.tag.md | 0 {prompt => resource}/protocol/tag/role.tag.md | 0 .../protocol/tag/terminology.tag.md | 0 .../protocol/tag/thought.tag.md | 0 {prompt => resource}/tool/calculator.tool.js | 0 {prompt => resource}/tool/send-email.tool.js | 0 src/lib/core/pouch/commands/RecallCommand.js | 15 +- .../core/pouch/commands/RememberCommand.js | 15 +- .../resource/discovery/PackageDiscovery.js | 22 +- src/lib/utils/DirectoryService.js | 16 +- src/lib/utils/executionContext.js | 87 ++-- src/package.registry.json | 492 +++++++++--------- 83 files changed, 318 insertions(+), 373 deletions(-) rename {prompt => resource}/core/_deprecated/recall_v1.thought.md (100%) rename {prompt => resource}/core/_deprecated/remember_v1.thought.md (100%) rename {prompt => resource}/core/recall-xml.thought.md (100%) rename {prompt => resource}/core/recall.thought.md (100%) rename {prompt => resource}/core/remember-xml.thought.md (100%) rename {prompt => resource}/core/remember.thought.md (100%) rename {prompt => resource}/domain/assistant/assistant.role.md (100%) rename {prompt => resource}/domain/assistant/execution/assistant.execution.md (100%) rename {prompt => resource}/domain/assistant/thought/assistant.thought.md (100%) rename {prompt => resource}/domain/frontend-developer/execution/code-quality.execution.md (100%) rename {prompt => resource}/domain/frontend-developer/execution/frontend-developer.execution.md (100%) rename {prompt => resource}/domain/frontend-developer/execution/technical-architecture.execution.md (100%) rename {prompt => resource}/domain/frontend-developer/execution/user-experience.execution.md (100%) rename {prompt => resource}/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md (100%) rename {prompt => resource}/domain/frontend-developer/frontend-developer.role.md (100%) rename {prompt => resource}/domain/frontend-developer/thought/frontend-developer.thought.md (100%) rename {prompt => resource}/domain/java-backend-developer/execution/code-quality.execution.md (100%) rename {prompt => resource}/domain/java-backend-developer/execution/database-design.execution.md (100%) rename {prompt => resource}/domain/java-backend-developer/execution/java-backend-developer.execution.md (100%) rename {prompt => resource}/domain/java-backend-developer/execution/spring-ecosystem.execution.md (100%) rename {prompt => resource}/domain/java-backend-developer/execution/system-architecture.execution.md (100%) rename {prompt => resource}/domain/java-backend-developer/java-backend-developer.role.md (100%) rename {prompt => resource}/domain/java-backend-developer/thought/java-backend-developer.thought.md (100%) rename {prompt => resource}/domain/noface/execution/adaptive-learning.execution.md (100%) rename {prompt => resource}/domain/noface/execution/content-preservation.execution.md (100%) rename {prompt => resource}/domain/noface/noface.role.md (100%) rename {prompt => resource}/domain/nuwa/execution/dpml-authoring.execution.md (100%) rename {prompt => resource}/domain/nuwa/execution/role-design-patterns.execution.md (100%) rename {prompt => resource}/domain/nuwa/execution/role-generation.execution.md (100%) rename {prompt => resource}/domain/nuwa/execution/visualization-enhancement.execution.md (100%) rename {prompt => resource}/domain/nuwa/nuwa.role.md (100%) rename {prompt => resource}/domain/nuwa/thought/role-creation.thought.md (100%) rename {prompt => resource}/domain/product-manager/execution/market-analysis.execution.md (100%) rename {prompt => resource}/domain/product-manager/execution/product-manager.execution.md (100%) rename {prompt => resource}/domain/product-manager/execution/user-research.execution.md (100%) rename {prompt => resource}/domain/product-manager/product-manager.role.md (100%) rename {prompt => resource}/domain/product-manager/thought/product-manager.thought.md (100%) rename {prompt => resource}/domain/sean/execution/contradiction-analysis.execution.md (100%) rename {prompt => resource}/domain/sean/execution/contradiction-management-methodology.execution.md (100%) rename {prompt => resource}/domain/sean/execution/sean-decision-framework.execution.md (100%) rename {prompt => resource}/domain/sean/execution/template-adherence.execution.md (100%) rename {prompt => resource}/domain/sean/knowledge/contradiction-methodology.knowledge.md (100%) rename {prompt => resource}/domain/sean/knowledge/product-philosophy.knowledge.md (100%) rename {prompt => resource}/domain/sean/knowledge/promptx-evolution.knowledge.md (100%) rename {prompt => resource}/domain/sean/sean.role.md (100%) rename {prompt => resource}/domain/sean/thought/contradiction-methodology.thought.md (100%) rename {prompt => resource}/domain/sean/thought/sean.thought.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/community-building.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/content-creation.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/content-optimization.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/data-analytics.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/user-operation.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md (100%) rename {prompt => resource}/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md (100%) rename {prompt => resource}/protocol/dpml.protocol.md (100%) rename {prompt => resource}/protocol/pateoas.protocol.md (100%) rename {prompt => resource}/protocol/tag/execution.tag.md (100%) rename {prompt => resource}/protocol/tag/resource.tag.md (100%) rename {prompt => resource}/protocol/tag/role.tag.md (100%) rename {prompt => resource}/protocol/tag/terminology.tag.md (100%) rename {prompt => resource}/protocol/tag/thought.tag.md (100%) rename {prompt => resource}/tool/calculator.tool.js (100%) rename {prompt => resource}/tool/send-email.tool.js (100%) diff --git a/docs/issues/resource-architecture-improvement.md b/docs/issues/resource-architecture-improvement.md index 18afb3e..c8986ad 100644 --- a/docs/issues/resource-architecture-improvement.md +++ b/docs/issues/resource-architecture-improvement.md @@ -30,7 +30,7 @@ ResourceRegistry.js (248行) + resource.registry.json (167行) + 内存协议注 **当前协议处理问题**: ```javascript // 问题1:协议前缀不统一 -"@package://prompt/core/role.md" // 正确 +"@package://resource/core/role.md" // 正确 "@packages://promptx/prompt/core/" // 错误变换 // 问题2:循环依赖 @@ -341,7 +341,7 @@ class ResourceManager { registry['role:java'] = '/path/to/file' // 现在:保持协议一致性 -registry['role:java'] = '@package://prompt/domain/java/java.role.md' +registry['role:java'] = '@package://resource/domain/java/java.role.md' resolver.resolve('@package://...') // 统一解析 ``` @@ -370,7 +370,7 @@ const filePath = await resolver.resolve(reference) // 所有协议 ### 4. 完全兼容现有格式 ```javascript // resource.registry.json 继续工作 -"java-backend-developer": "@package://prompt/domain/java/java.role.md" +"java-backend-developer": "@package://resource/domain/java/java.role.md" // 代码继续工作 await resourceManager.loadResource('java-backend-developer') diff --git a/docs/mcp-adapter-design.md b/docs/mcp-adapter-design.md index 963000b..8dd5a1a 100644 --- a/docs/mcp-adapter-design.md +++ b/docs/mcp-adapter-design.md @@ -202,7 +202,7 @@ npx dpml-prompt@snapshot hello // 这是系统内部实现细节,用户不需要感知 @prompt://core/execution/think.md @memory://declarative.md -@package://prompt/domain/scrum/role.md +@package://resource/domain/scrum/role.md ``` #### 为什么不使用MCP Prompts? diff --git a/docs/nuwa-role-analysis-report.md b/docs/nuwa-role-analysis-report.md index 5d61d76..8b6087e 100644 --- a/docs/nuwa-role-analysis-report.md +++ b/docs/nuwa-role-analysis-report.md @@ -75,7 +75,7 @@ **在`src/resource.registry.json`中的配置**: ```json "nuwa": { - "file": "@package://prompt/core/nuwa/nuwa.role.md", + "file": "@package://resource/core/nuwa/nuwa.role.md", "name": "🎨 女娲", "description": "专业角色创造顾问,通过对话收集需求,为用户量身定制AI助手角色" } @@ -91,7 +91,7 @@ **SimplifiedRoleDiscovery处理流程**: 1. ✅ 从系统注册表正确加载nuwa角色配置 -2. ✅ 路径解析:`@package://prompt/core/nuwa/nuwa.role.md` → 实际文件路径 +2. ✅ 路径解析:`@package://resource/core/nuwa/nuwa.role.md` → 实际文件路径 3. ✅ DPML格式验证:通过``标签检查 4. ✅ 元数据提取:正确获取name和description diff --git a/docs/reference-protocol-layers.md b/docs/reference-protocol-layers.md index a358f49..89d9b8d 100644 --- a/docs/reference-protocol-layers.md +++ b/docs/reference-protocol-layers.md @@ -146,8 +146,8 @@ DPML (Deepractice Prompt Markup Language) 采用三层协议架构,从底层 @package://lib/commands/hello.js # 包提示词资源 -@package://prompt/core/execution/think.md -@package://prompt/domain/scrum/role/product-owner.md +@package://resource/core/execution/think.md +@package://resource/domain/scrum/role/product-owner.md # 包配置和模板 @package://jest.config.js @@ -194,25 +194,25 @@ DPML (Deepractice Prompt Markup Language) 采用三层协议架构,从底层 ```bash # 核心协议文档 @prompt://protocols -# → @package://prompt/protocol/**/*.md +# → @package://resource/protocol/**/*.md # 核心提示词模块 @prompt://core -# → @package://prompt/core/**/*.md +# → @package://resource/core/**/*.md # 领域提示词 @prompt://domain/scrum -# → @package://prompt/domain/scrum/**/*.md +# → @package://resource/domain/scrum/**/*.md # 特定角色提示词 @prompt://domain/scrum/role/product-owner -# → @package://prompt/domain/scrum/role/product-owner.role.md +# → @package://resource/domain/scrum/role/product-owner.role.md ``` **注册表映射:** -- `protocols` → `@package://prompt/protocol/**/*.md` -- `core` → `@package://prompt/core/**/*.md` -- `domain` → `@package://prompt/domain/**/*.md` +- `protocols` → `@package://resource/protocol/**/*.md` +- `core` → `@package://resource/core/**/*.md` +- `domain` → `@package://resource/domain/**/*.md` - `bootstrap` → `@package://bootstrap.md` #### 2. `@memory://` - 记忆系统协议 @@ -248,7 +248,7 @@ DPML (Deepractice Prompt Markup Language) 采用三层协议架构,从底层 // 1. 协议分层解析 @prompt://core ↓ 上层协议解析 -@package://prompt/core/**/*.md +@package://resource/core/**/*.md ↓ 中层协议解析 @file://[NPM包路径]/prompt/core/**/*.md ↓ 底层协议执行 @@ -352,7 +352,7 @@ promptx remember "重要决策" @file://[项目根]/.memory/declarative.md # 上层 → 中层 → 底层 @prompt://core ↓ -@package://prompt/core/**/*.md +@package://resource/core/**/*.md ↓ @file:///usr/local/lib/node_modules/promptx/prompt/core/**/*.md ``` diff --git a/docs/resource-referrence-architech.md b/docs/resource-referrence-architech.md index 239b028..e94a0f9 100644 --- a/docs/resource-referrence-architech.md +++ b/docs/resource-referrence-architech.md @@ -257,7 +257,7 @@ sequenceDiagram Note over RM: 2. 解析逻辑协议 thought RM->>RR: resolve("thought:remember") - RR->>RM: "@package://prompt/core/thought/remember.thought.md" + RR->>RM: "@package://resource/core/thought/remember.thought.md" Note over RM: 3. 解析基础协议 @package RM->>RM: 委托给PackageProtocol diff --git a/docs/role-activation-improvements.md b/docs/role-activation-improvements.md index a398e95..d385e60 100644 --- a/docs/role-activation-improvements.md +++ b/docs/role-activation-improvements.md @@ -161,7 +161,7 @@ async loadRoleRegistry() { if (Object.keys(this.roleRegistry).length === 0) { this.roleRegistry = { assistant: { - file: '@package://prompt/domain/assistant/assistant.role.md', + file: '@package://resource/domain/assistant/assistant.role.md', name: '🙋 智能助手', description: '通用助理角色,提供基础的助理服务和记忆支持' } diff --git a/docs/role-discovery-optimization.md b/docs/role-discovery-optimization.md index 53d91ac..088f481 100644 --- a/docs/role-discovery-optimization.md +++ b/docs/role-discovery-optimization.md @@ -434,7 +434,7 @@ class SimplePackageProtocol { { "role": { "assistant": { - "file": "@package://prompt/domain/assistant/assistant.role.md", + "file": "@package://resource/domain/assistant/assistant.role.md", "name": "🙋 智能助手" } } diff --git a/docs/role-system-complete-guide.md b/docs/role-system-complete-guide.md index 79ad81f..8c03a06 100644 --- a/docs/role-system-complete-guide.md +++ b/docs/role-system-complete-guide.md @@ -74,7 +74,7 @@ flowchart TB "role": { "registry": { "角色ID": { - "file": "@package://prompt/domain/角色名/角色名.role.md", + "file": "@package://resource/domain/角色名/角色名.role.md", "name": "🎭 角色显示名称", "description": "角色功能描述" } @@ -87,7 +87,7 @@ flowchart TB **示例**: ```json "assistant": { - "file": "@package://prompt/domain/assistant/assistant.role.md", + "file": "@package://resource/domain/assistant/assistant.role.md", "name": "🙋 智能助手", "description": "通用助理角色,提供基础的助理服务和记忆支持" } diff --git a/prompt/core/_deprecated/recall_v1.thought.md b/resource/core/_deprecated/recall_v1.thought.md similarity index 100% rename from prompt/core/_deprecated/recall_v1.thought.md rename to resource/core/_deprecated/recall_v1.thought.md diff --git a/prompt/core/_deprecated/remember_v1.thought.md b/resource/core/_deprecated/remember_v1.thought.md similarity index 100% rename from prompt/core/_deprecated/remember_v1.thought.md rename to resource/core/_deprecated/remember_v1.thought.md diff --git a/prompt/core/recall-xml.thought.md b/resource/core/recall-xml.thought.md similarity index 100% rename from prompt/core/recall-xml.thought.md rename to resource/core/recall-xml.thought.md diff --git a/prompt/core/recall.thought.md b/resource/core/recall.thought.md similarity index 100% rename from prompt/core/recall.thought.md rename to resource/core/recall.thought.md diff --git a/prompt/core/remember-xml.thought.md b/resource/core/remember-xml.thought.md similarity index 100% rename from prompt/core/remember-xml.thought.md rename to resource/core/remember-xml.thought.md diff --git a/prompt/core/remember.thought.md b/resource/core/remember.thought.md similarity index 100% rename from prompt/core/remember.thought.md rename to resource/core/remember.thought.md diff --git a/prompt/domain/assistant/assistant.role.md b/resource/domain/assistant/assistant.role.md similarity index 100% rename from prompt/domain/assistant/assistant.role.md rename to resource/domain/assistant/assistant.role.md diff --git a/prompt/domain/assistant/execution/assistant.execution.md b/resource/domain/assistant/execution/assistant.execution.md similarity index 100% rename from prompt/domain/assistant/execution/assistant.execution.md rename to resource/domain/assistant/execution/assistant.execution.md diff --git a/prompt/domain/assistant/thought/assistant.thought.md b/resource/domain/assistant/thought/assistant.thought.md similarity index 100% rename from prompt/domain/assistant/thought/assistant.thought.md rename to resource/domain/assistant/thought/assistant.thought.md diff --git a/prompt/domain/frontend-developer/execution/code-quality.execution.md b/resource/domain/frontend-developer/execution/code-quality.execution.md similarity index 100% rename from prompt/domain/frontend-developer/execution/code-quality.execution.md rename to resource/domain/frontend-developer/execution/code-quality.execution.md diff --git a/prompt/domain/frontend-developer/execution/frontend-developer.execution.md b/resource/domain/frontend-developer/execution/frontend-developer.execution.md similarity index 100% rename from prompt/domain/frontend-developer/execution/frontend-developer.execution.md rename to resource/domain/frontend-developer/execution/frontend-developer.execution.md diff --git a/prompt/domain/frontend-developer/execution/technical-architecture.execution.md b/resource/domain/frontend-developer/execution/technical-architecture.execution.md similarity index 100% rename from prompt/domain/frontend-developer/execution/technical-architecture.execution.md rename to resource/domain/frontend-developer/execution/technical-architecture.execution.md diff --git a/prompt/domain/frontend-developer/execution/user-experience.execution.md b/resource/domain/frontend-developer/execution/user-experience.execution.md similarity index 100% rename from prompt/domain/frontend-developer/execution/user-experience.execution.md rename to resource/domain/frontend-developer/execution/user-experience.execution.md diff --git a/prompt/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md b/resource/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md similarity index 100% rename from prompt/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md rename to resource/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md diff --git a/prompt/domain/frontend-developer/frontend-developer.role.md b/resource/domain/frontend-developer/frontend-developer.role.md similarity index 100% rename from prompt/domain/frontend-developer/frontend-developer.role.md rename to resource/domain/frontend-developer/frontend-developer.role.md diff --git a/prompt/domain/frontend-developer/thought/frontend-developer.thought.md b/resource/domain/frontend-developer/thought/frontend-developer.thought.md similarity index 100% rename from prompt/domain/frontend-developer/thought/frontend-developer.thought.md rename to resource/domain/frontend-developer/thought/frontend-developer.thought.md diff --git a/prompt/domain/java-backend-developer/execution/code-quality.execution.md b/resource/domain/java-backend-developer/execution/code-quality.execution.md similarity index 100% rename from prompt/domain/java-backend-developer/execution/code-quality.execution.md rename to resource/domain/java-backend-developer/execution/code-quality.execution.md diff --git a/prompt/domain/java-backend-developer/execution/database-design.execution.md b/resource/domain/java-backend-developer/execution/database-design.execution.md similarity index 100% rename from prompt/domain/java-backend-developer/execution/database-design.execution.md rename to resource/domain/java-backend-developer/execution/database-design.execution.md diff --git a/prompt/domain/java-backend-developer/execution/java-backend-developer.execution.md b/resource/domain/java-backend-developer/execution/java-backend-developer.execution.md similarity index 100% rename from prompt/domain/java-backend-developer/execution/java-backend-developer.execution.md rename to resource/domain/java-backend-developer/execution/java-backend-developer.execution.md diff --git a/prompt/domain/java-backend-developer/execution/spring-ecosystem.execution.md b/resource/domain/java-backend-developer/execution/spring-ecosystem.execution.md similarity index 100% rename from prompt/domain/java-backend-developer/execution/spring-ecosystem.execution.md rename to resource/domain/java-backend-developer/execution/spring-ecosystem.execution.md diff --git a/prompt/domain/java-backend-developer/execution/system-architecture.execution.md b/resource/domain/java-backend-developer/execution/system-architecture.execution.md similarity index 100% rename from prompt/domain/java-backend-developer/execution/system-architecture.execution.md rename to resource/domain/java-backend-developer/execution/system-architecture.execution.md diff --git a/prompt/domain/java-backend-developer/java-backend-developer.role.md b/resource/domain/java-backend-developer/java-backend-developer.role.md similarity index 100% rename from prompt/domain/java-backend-developer/java-backend-developer.role.md rename to resource/domain/java-backend-developer/java-backend-developer.role.md diff --git a/prompt/domain/java-backend-developer/thought/java-backend-developer.thought.md b/resource/domain/java-backend-developer/thought/java-backend-developer.thought.md similarity index 100% rename from prompt/domain/java-backend-developer/thought/java-backend-developer.thought.md rename to resource/domain/java-backend-developer/thought/java-backend-developer.thought.md diff --git a/prompt/domain/noface/execution/adaptive-learning.execution.md b/resource/domain/noface/execution/adaptive-learning.execution.md similarity index 100% rename from prompt/domain/noface/execution/adaptive-learning.execution.md rename to resource/domain/noface/execution/adaptive-learning.execution.md diff --git a/prompt/domain/noface/execution/content-preservation.execution.md b/resource/domain/noface/execution/content-preservation.execution.md similarity index 100% rename from prompt/domain/noface/execution/content-preservation.execution.md rename to resource/domain/noface/execution/content-preservation.execution.md diff --git a/prompt/domain/noface/noface.role.md b/resource/domain/noface/noface.role.md similarity index 100% rename from prompt/domain/noface/noface.role.md rename to resource/domain/noface/noface.role.md diff --git a/prompt/domain/nuwa/execution/dpml-authoring.execution.md b/resource/domain/nuwa/execution/dpml-authoring.execution.md similarity index 100% rename from prompt/domain/nuwa/execution/dpml-authoring.execution.md rename to resource/domain/nuwa/execution/dpml-authoring.execution.md diff --git a/prompt/domain/nuwa/execution/role-design-patterns.execution.md b/resource/domain/nuwa/execution/role-design-patterns.execution.md similarity index 100% rename from prompt/domain/nuwa/execution/role-design-patterns.execution.md rename to resource/domain/nuwa/execution/role-design-patterns.execution.md diff --git a/prompt/domain/nuwa/execution/role-generation.execution.md b/resource/domain/nuwa/execution/role-generation.execution.md similarity index 100% rename from prompt/domain/nuwa/execution/role-generation.execution.md rename to resource/domain/nuwa/execution/role-generation.execution.md diff --git a/prompt/domain/nuwa/execution/visualization-enhancement.execution.md b/resource/domain/nuwa/execution/visualization-enhancement.execution.md similarity index 100% rename from prompt/domain/nuwa/execution/visualization-enhancement.execution.md rename to resource/domain/nuwa/execution/visualization-enhancement.execution.md diff --git a/prompt/domain/nuwa/nuwa.role.md b/resource/domain/nuwa/nuwa.role.md similarity index 100% rename from prompt/domain/nuwa/nuwa.role.md rename to resource/domain/nuwa/nuwa.role.md diff --git a/prompt/domain/nuwa/thought/role-creation.thought.md b/resource/domain/nuwa/thought/role-creation.thought.md similarity index 100% rename from prompt/domain/nuwa/thought/role-creation.thought.md rename to resource/domain/nuwa/thought/role-creation.thought.md diff --git a/prompt/domain/product-manager/execution/market-analysis.execution.md b/resource/domain/product-manager/execution/market-analysis.execution.md similarity index 100% rename from prompt/domain/product-manager/execution/market-analysis.execution.md rename to resource/domain/product-manager/execution/market-analysis.execution.md diff --git a/prompt/domain/product-manager/execution/product-manager.execution.md b/resource/domain/product-manager/execution/product-manager.execution.md similarity index 100% rename from prompt/domain/product-manager/execution/product-manager.execution.md rename to resource/domain/product-manager/execution/product-manager.execution.md diff --git a/prompt/domain/product-manager/execution/user-research.execution.md b/resource/domain/product-manager/execution/user-research.execution.md similarity index 100% rename from prompt/domain/product-manager/execution/user-research.execution.md rename to resource/domain/product-manager/execution/user-research.execution.md diff --git a/prompt/domain/product-manager/product-manager.role.md b/resource/domain/product-manager/product-manager.role.md similarity index 100% rename from prompt/domain/product-manager/product-manager.role.md rename to resource/domain/product-manager/product-manager.role.md diff --git a/prompt/domain/product-manager/thought/product-manager.thought.md b/resource/domain/product-manager/thought/product-manager.thought.md similarity index 100% rename from prompt/domain/product-manager/thought/product-manager.thought.md rename to resource/domain/product-manager/thought/product-manager.thought.md diff --git a/prompt/domain/sean/execution/contradiction-analysis.execution.md b/resource/domain/sean/execution/contradiction-analysis.execution.md similarity index 100% rename from prompt/domain/sean/execution/contradiction-analysis.execution.md rename to resource/domain/sean/execution/contradiction-analysis.execution.md diff --git a/prompt/domain/sean/execution/contradiction-management-methodology.execution.md b/resource/domain/sean/execution/contradiction-management-methodology.execution.md similarity index 100% rename from prompt/domain/sean/execution/contradiction-management-methodology.execution.md rename to resource/domain/sean/execution/contradiction-management-methodology.execution.md diff --git a/prompt/domain/sean/execution/sean-decision-framework.execution.md b/resource/domain/sean/execution/sean-decision-framework.execution.md similarity index 100% rename from prompt/domain/sean/execution/sean-decision-framework.execution.md rename to resource/domain/sean/execution/sean-decision-framework.execution.md diff --git a/prompt/domain/sean/execution/template-adherence.execution.md b/resource/domain/sean/execution/template-adherence.execution.md similarity index 100% rename from prompt/domain/sean/execution/template-adherence.execution.md rename to resource/domain/sean/execution/template-adherence.execution.md diff --git a/prompt/domain/sean/knowledge/contradiction-methodology.knowledge.md b/resource/domain/sean/knowledge/contradiction-methodology.knowledge.md similarity index 100% rename from prompt/domain/sean/knowledge/contradiction-methodology.knowledge.md rename to resource/domain/sean/knowledge/contradiction-methodology.knowledge.md diff --git a/prompt/domain/sean/knowledge/product-philosophy.knowledge.md b/resource/domain/sean/knowledge/product-philosophy.knowledge.md similarity index 100% rename from prompt/domain/sean/knowledge/product-philosophy.knowledge.md rename to resource/domain/sean/knowledge/product-philosophy.knowledge.md diff --git a/prompt/domain/sean/knowledge/promptx-evolution.knowledge.md b/resource/domain/sean/knowledge/promptx-evolution.knowledge.md similarity index 100% rename from prompt/domain/sean/knowledge/promptx-evolution.knowledge.md rename to resource/domain/sean/knowledge/promptx-evolution.knowledge.md diff --git a/prompt/domain/sean/sean.role.md b/resource/domain/sean/sean.role.md similarity index 100% rename from prompt/domain/sean/sean.role.md rename to resource/domain/sean/sean.role.md diff --git a/prompt/domain/sean/thought/contradiction-methodology.thought.md b/resource/domain/sean/thought/contradiction-methodology.thought.md similarity index 100% rename from prompt/domain/sean/thought/contradiction-methodology.thought.md rename to resource/domain/sean/thought/contradiction-methodology.thought.md diff --git a/prompt/domain/sean/thought/sean.thought.md b/resource/domain/sean/thought/sean.thought.md similarity index 100% rename from prompt/domain/sean/thought/sean.thought.md rename to resource/domain/sean/thought/sean.thought.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md b/resource/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md rename to resource/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/community-building.execution.md b/resource/domain/xiaohongshu-marketer/execution/community-building.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/community-building.execution.md rename to resource/domain/xiaohongshu-marketer/execution/community-building.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/content-creation.execution.md b/resource/domain/xiaohongshu-marketer/execution/content-creation.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/content-creation.execution.md rename to resource/domain/xiaohongshu-marketer/execution/content-creation.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/content-optimization.execution.md b/resource/domain/xiaohongshu-marketer/execution/content-optimization.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/content-optimization.execution.md rename to resource/domain/xiaohongshu-marketer/execution/content-optimization.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/data-analytics.execution.md b/resource/domain/xiaohongshu-marketer/execution/data-analytics.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/data-analytics.execution.md rename to resource/domain/xiaohongshu-marketer/execution/data-analytics.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md b/resource/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md rename to resource/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md b/resource/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md rename to resource/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md b/resource/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md rename to resource/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md b/resource/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md rename to resource/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/user-operation.execution.md b/resource/domain/xiaohongshu-marketer/execution/user-operation.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/user-operation.execution.md rename to resource/domain/xiaohongshu-marketer/execution/user-operation.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md b/resource/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md rename to resource/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md diff --git a/prompt/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md b/resource/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md rename to resource/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md diff --git a/prompt/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md b/resource/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md similarity index 100% rename from prompt/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md rename to resource/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md diff --git a/prompt/protocol/dpml.protocol.md b/resource/protocol/dpml.protocol.md similarity index 100% rename from prompt/protocol/dpml.protocol.md rename to resource/protocol/dpml.protocol.md diff --git a/prompt/protocol/pateoas.protocol.md b/resource/protocol/pateoas.protocol.md similarity index 100% rename from prompt/protocol/pateoas.protocol.md rename to resource/protocol/pateoas.protocol.md diff --git a/prompt/protocol/tag/execution.tag.md b/resource/protocol/tag/execution.tag.md similarity index 100% rename from prompt/protocol/tag/execution.tag.md rename to resource/protocol/tag/execution.tag.md diff --git a/prompt/protocol/tag/resource.tag.md b/resource/protocol/tag/resource.tag.md similarity index 100% rename from prompt/protocol/tag/resource.tag.md rename to resource/protocol/tag/resource.tag.md diff --git a/prompt/protocol/tag/role.tag.md b/resource/protocol/tag/role.tag.md similarity index 100% rename from prompt/protocol/tag/role.tag.md rename to resource/protocol/tag/role.tag.md diff --git a/prompt/protocol/tag/terminology.tag.md b/resource/protocol/tag/terminology.tag.md similarity index 100% rename from prompt/protocol/tag/terminology.tag.md rename to resource/protocol/tag/terminology.tag.md diff --git a/prompt/protocol/tag/thought.tag.md b/resource/protocol/tag/thought.tag.md similarity index 100% rename from prompt/protocol/tag/thought.tag.md rename to resource/protocol/tag/thought.tag.md diff --git a/prompt/tool/calculator.tool.js b/resource/tool/calculator.tool.js similarity index 100% rename from prompt/tool/calculator.tool.js rename to resource/tool/calculator.tool.js diff --git a/prompt/tool/send-email.tool.js b/resource/tool/send-email.tool.js similarity index 100% rename from prompt/tool/send-email.tool.js rename to resource/tool/send-email.tool.js diff --git a/src/lib/core/pouch/commands/RecallCommand.js b/src/lib/core/pouch/commands/RecallCommand.js index d8da98d..d540794 100644 --- a/src/lib/core/pouch/commands/RecallCommand.js +++ b/src/lib/core/pouch/commands/RecallCommand.js @@ -171,27 +171,18 @@ ${formattedMemories} async getProjectPath() { logger.debug('📍 [RecallCommand] 获取项目路径...') - // 🔍 增加详细的路径诊断日志 - logger.warn('🔍 [RecallCommand-DIAGNOSIS] ===== 路径诊断开始 =====') - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] process.cwd(): ${process.cwd()}`) - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] process.argv: ${JSON.stringify(process.argv)}`) - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] PROMPTX_WORKSPACE: ${process.env.PROMPTX_WORKSPACE || 'undefined'}`) - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] WORKSPACE_FOLDER_PATHS: ${process.env.WORKSPACE_FOLDER_PATHS || 'undefined'}`) - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] PWD: ${process.env.PWD || 'undefined'}`) - // 使用DirectoryService统一获取项目路径(与InitCommand保持一致) const context = { startDir: process.cwd(), platform: process.platform, avoidUserHome: true } - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] DirectoryService context: ${JSON.stringify(context)}`) const projectPath = await this.directoryService.getProjectRoot(context) - logger.warn(`🔍 [RecallCommand-DIAGNOSIS] DirectoryService结果: ${projectPath}`) - logger.warn('🔍 [RecallCommand-DIAGNOSIS] ===== 路径诊断结束 =====') - logger.debug(`📍 [RecallCommand] 项目路径解析结果: ${projectPath}`) + if (process.env.PROMPTX_DEBUG === 'true') { + logger.debug(`📍 [RecallCommand] 项目路径解析结果: ${projectPath}`) + } return projectPath } diff --git a/src/lib/core/pouch/commands/RememberCommand.js b/src/lib/core/pouch/commands/RememberCommand.js index 9532152..74d3e86 100644 --- a/src/lib/core/pouch/commands/RememberCommand.js +++ b/src/lib/core/pouch/commands/RememberCommand.js @@ -209,27 +209,18 @@ class RememberCommand extends BasePouchCommand { async getProjectPath() { logger.debug('📍 [RememberCommand] 获取项目路径...') - // 🔍 增加详细的路径诊断日志 - logger.warn('🔍 [RememberCommand-DIAGNOSIS] ===== 路径诊断开始 =====') - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] process.cwd(): ${process.cwd()}`) - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] process.argv: ${JSON.stringify(process.argv)}`) - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] PROMPTX_WORKSPACE: ${process.env.PROMPTX_WORKSPACE || 'undefined'}`) - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] WORKSPACE_FOLDER_PATHS: ${process.env.WORKSPACE_FOLDER_PATHS || 'undefined'}`) - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] PWD: ${process.env.PWD || 'undefined'}`) - // 使用DirectoryService统一获取项目路径(与InitCommand保持一致) const context = { startDir: process.cwd(), platform: process.platform, avoidUserHome: true } - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] DirectoryService context: ${JSON.stringify(context)}`) const projectPath = await this.directoryService.getProjectRoot(context) - logger.warn(`🔍 [RememberCommand-DIAGNOSIS] DirectoryService结果: ${projectPath}`) - logger.warn('🔍 [RememberCommand-DIAGNOSIS] ===== 路径诊断结束 =====') - logger.debug(`📍 [RememberCommand] 项目路径解析结果: ${projectPath}`) + if (process.env.PROMPTX_DEBUG === 'true') { + logger.debug(`📍 [RememberCommand] 项目路径解析结果: ${projectPath}`) + } return projectPath } diff --git a/src/lib/core/resource/discovery/PackageDiscovery.js b/src/lib/core/resource/discovery/PackageDiscovery.js index f58faa4..7befaf4 100644 --- a/src/lib/core/resource/discovery/PackageDiscovery.js +++ b/src/lib/core/resource/discovery/PackageDiscovery.js @@ -13,7 +13,7 @@ const { getDirectoryService } = require('../../../utils/DirectoryService') * * 负责发现NPM包内的资源: * 1. 从 src/resource.registry.json 加载静态注册表 - * 2. 扫描 prompt/ 目录发现动态资源 + * 2. 扫描 resource/ 目录发现动态资源 * * 优先级:1 (最高优先级) */ @@ -143,8 +143,8 @@ class PackageDiscovery extends BaseDiscovery { // 这里可以实现动态扫描逻辑,或者返回空Map // 为了简化,我们返回一个基础的assistant角色 const fallbackRegistry = new Map() - fallbackRegistry.set('assistant', '@package://prompt/domain/assistant/assistant.role.md') - fallbackRegistry.set('package:assistant', '@package://prompt/domain/assistant/assistant.role.md') + fallbackRegistry.set('assistant', '@package://resource/domain/assistant/assistant.role.md') + fallbackRegistry.set('package:assistant', '@package://resource/domain/assistant/assistant.role.md') logger.warn(`[PackageDiscovery] 🆘 使用回退资源: assistant`) return fallbackRegistry @@ -167,10 +167,10 @@ class PackageDiscovery extends BaseDiscovery { try { // 扫描包级资源目录 - const promptDir = path.join(packageRoot, 'prompt') + const resourceDir = path.join(packageRoot, 'resource') - if (await fs.pathExists(promptDir)) { - await this._scanDirectory(promptDir, registryData) + if (await fs.pathExists(resourceDir)) { + await this._scanDirectory(resourceDir, registryData) } // 保存注册表 @@ -308,7 +308,7 @@ class PackageDiscovery extends BaseDiscovery { // 查找角色文件 const roleFile = path.join(itemPath, `${item}.role.md`) if (await fs.pathExists(roleFile)) { - const reference = `@package://prompt/domain/${item}/${item}.role.md` + const reference = `@package://resource/domain/${item}/${item}.role.md` const resourceData = new ResourceData({ id: item, @@ -334,7 +334,7 @@ class PackageDiscovery extends BaseDiscovery { const thoughtId = ResourceFileNaming.extractResourceId(thoughtFile, 'thought') if (thoughtId) { const fileName = path.basename(thoughtFile) - const reference = `@package://prompt/domain/${item}/thought/${fileName}` + const reference = `@package://resource/domain/${item}/thought/${fileName}` const resourceData = new ResourceData({ id: thoughtId, @@ -360,7 +360,7 @@ class PackageDiscovery extends BaseDiscovery { for (const execFile of executionFiles) { if (execFile.endsWith('.execution.md')) { const execId = path.basename(execFile, '.execution.md') - const reference = `@package://prompt/domain/${item}/execution/${execFile}` + const reference = `@package://resource/domain/${item}/execution/${execFile}` const resourceData = new ResourceData({ id: execId, @@ -405,7 +405,7 @@ class PackageDiscovery extends BaseDiscovery { const match = file.match(/^(.+)\.(\w+)\.md$/) if (match) { const [, id, protocol] = match - const reference = `@package://prompt/core/${item}/${file}` + const reference = `@package://resource/core/${item}/${file}` const resourceData = new ResourceData({ id: id, @@ -428,7 +428,7 @@ class PackageDiscovery extends BaseDiscovery { const match = item.match(/^(.+)\.(\w+)\.md$/) if (match) { const [, id, protocol] = match - const reference = `@package://prompt/core/${item}` + const reference = `@package://resource/core/${item}` const resourceData = new ResourceData({ id: id, diff --git a/src/lib/utils/DirectoryService.js b/src/lib/utils/DirectoryService.js index 0273af9..e825675 100644 --- a/src/lib/utils/DirectoryService.js +++ b/src/lib/utils/DirectoryService.js @@ -46,29 +46,19 @@ class DirectoryService { async getProjectRoot(context = {}) { await this._ensureInitialized() - // 🔍 增加详细的路径诊断日志 - console.error('🔍 [DirectoryService-DIAGNOSIS] ===== getProjectRoot 诊断开始 =====') - console.error(`🔍 [DirectoryService-DIAGNOSIS] context: ${JSON.stringify(context)}`) - console.error(`🔍 [DirectoryService-DIAGNOSIS] process.cwd(): ${process.cwd()}`) + const debug = process.env.PROMPTX_DEBUG === 'true'; try { const result = await this.projectRootLocator.locate(context) this._lastProjectRoot = result this._lastContext = context - console.error(`🔍 [DirectoryService-DIAGNOSIS] ProjectRootLocator结果: ${result}`) - console.error('🔍 [DirectoryService-DIAGNOSIS] ===== getProjectRoot 诊断结束 =====') - - logger.debug(`[DirectoryService] 项目根目录: ${result}`) + if (debug) logger.debug(`[DirectoryService] 项目根目录: ${result}`) return result } catch (error) { - console.error(`🔍 [DirectoryService-DIAGNOSIS] ❌ ProjectRootLocator失败: ${error.message}`) - console.error('🔍 [DirectoryService-DIAGNOSIS] ===== getProjectRoot 诊断结束(出错) =====') - - logger.error('[DirectoryService] 获取项目根目录失败:', error) + if (debug) logger.error('[DirectoryService] 获取项目根目录失败:', error) // 回退到当前工作目录 const fallback = process.cwd() - console.error(`🔍 [DirectoryService-DIAGNOSIS] 回退到process.cwd(): ${fallback}`) return fallback } } diff --git a/src/lib/utils/executionContext.js b/src/lib/utils/executionContext.js index 1878fd6..5452972 100644 --- a/src/lib/utils/executionContext.js +++ b/src/lib/utils/executionContext.js @@ -13,6 +13,9 @@ const { getDirectoryService } = require('./DirectoryService'); * @deprecated 推荐直接使用 DirectoryService * * 注意:此文件主要保留向后兼容的同步API + * + * 调试模式:设置环境变量 PROMPTX_DEBUG=true 启用详细日志 + * 示例:export PROMPTX_DEBUG=true && promptx mcp-server * 新代码请直接使用 DirectoryService 的异步API */ @@ -68,22 +71,23 @@ function getMCPWorkingDirectory() { * @returns {string} 工作空间路径 */ function getWorkspaceSynchronous(context) { - // 🔍 增加详细的路径诊断日志 - console.error('🔍 [executionContext-DIAGNOSIS] ===== getWorkspaceSynchronous 诊断开始 =====') - console.error(`🔍 [executionContext-DIAGNOSIS] context: ${JSON.stringify(context)}`) - console.error(`🔍 [executionContext-DIAGNOSIS] process.cwd(): ${process.cwd()}`) + // 获取调试模式设置 + const debug = process.env.PROMPTX_DEBUG === 'true'; + + if (debug) { + console.error('🔍 [executionContext] 工作空间检测开始'); + console.error(`🔍 [executionContext] 当前目录: ${process.cwd()}`); + } // 策略1:IDE环境变量 const workspacePaths = process.env.WORKSPACE_FOLDER_PATHS; - console.error(`🔍 [executionContext-DIAGNOSIS] 策略1 - WORKSPACE_FOLDER_PATHS: ${workspacePaths || 'undefined'}`) if (workspacePaths) { try { const folders = JSON.parse(workspacePaths); if (Array.isArray(folders) && folders.length > 0) { const firstFolder = folders[0]; if (isValidDirectory(firstFolder)) { - console.error(`🔍 [executionContext-DIAGNOSIS] 策略1成功: ${firstFolder}`) - console.error(`[执行上下文] 使用WORKSPACE_FOLDER_PATHS: ${firstFolder}`); + if (debug) console.error(`[执行上下文] 使用IDE工作空间: ${firstFolder}`); return firstFolder; } } @@ -91,8 +95,7 @@ function getWorkspaceSynchronous(context) { // 忽略解析错误,尝试直接使用 const firstPath = workspacePaths.split(path.delimiter)[0]; if (firstPath && isValidDirectory(firstPath)) { - console.error(`🔍 [executionContext-DIAGNOSIS] 策略1备用成功: ${firstPath}`) - console.error(`[执行上下文] 使用WORKSPACE_FOLDER_PATHS: ${firstPath}`); + if (debug) console.error(`[执行上下文] 使用IDE工作空间: ${firstPath}`); return firstPath; } } @@ -100,50 +103,41 @@ function getWorkspaceSynchronous(context) { // 策略2:PromptX专用环境变量 const promptxWorkspaceEnv = process.env.PROMPTX_WORKSPACE; - console.error(`🔍 [executionContext-DIAGNOSIS] 策略2 - PROMPTX_WORKSPACE: ${promptxWorkspaceEnv || 'undefined'}`) if (promptxWorkspaceEnv && promptxWorkspaceEnv.trim() !== '') { const promptxWorkspace = normalizePath(expandHome(promptxWorkspaceEnv)); if (isValidDirectory(promptxWorkspace)) { - console.error(`🔍 [executionContext-DIAGNOSIS] 策略2成功: ${promptxWorkspace}`) - console.error(`[执行上下文] 使用PROMPTX_WORKSPACE: ${promptxWorkspace}`); + if (debug) console.error(`[执行上下文] 使用PROMPTX_WORKSPACE: ${promptxWorkspace}`); return promptxWorkspace; } } // 策略3:现有.promptx目录 - console.error(`🔍 [executionContext-DIAGNOSIS] 策略3 - 查找现有.promptx目录,起始目录: ${context.startDir}`) - const existingPrompxRoot = findExistingPromptxDirectory(context.startDir); - console.error(`🔍 [executionContext-DIAGNOSIS] 策略3结果: ${existingPrompxRoot || 'null'}`) + const existingPrompxRoot = findExistingPromptxDirectory(context.startDir, debug); if (existingPrompxRoot) { - console.error(`🔍 [executionContext-DIAGNOSIS] 策略3成功: ${existingPrompxRoot}`) - console.error(`[执行上下文] 发现现有.promptx目录: ${existingPrompxRoot}`); + if (debug) console.error(`[执行上下文] 发现现有.promptx目录: ${existingPrompxRoot}`); return existingPrompxRoot; } // 策略4:PWD环境变量 const pwd = process.env.PWD; - console.error(`🔍 [executionContext-DIAGNOSIS] 策略4 - PWD: ${pwd || 'undefined'}`) if (pwd && isValidDirectory(pwd) && pwd !== process.cwd()) { - console.error(`🔍 [executionContext-DIAGNOSIS] 策略4成功: ${pwd}`) - console.error(`[执行上下文] 使用PWD环境变量: ${pwd}`); + if (debug) console.error(`[执行上下文] 使用PWD环境变量: ${pwd}`); return pwd; } // 策略5:项目根目录 const projectRoot = findProjectRoot(context.startDir); - console.error(`🔍 [executionContext-DIAGNOSIS] 策略5结果: ${projectRoot || 'null'}`) if (projectRoot && projectRoot !== process.cwd()) { - console.error(`🔍 [executionContext-DIAGNOSIS] 策略5成功: ${projectRoot}`) - console.error(`[执行上下文] 智能推测项目根目录: ${projectRoot}`); + if (debug) console.error(`[执行上下文] 智能推测项目根目录: ${projectRoot}`); return projectRoot; } // 策略6:回退到当前目录 - const fallbackPath = process.cwd() - console.error(`🔍 [executionContext-DIAGNOSIS] 策略6 - 回退到process.cwd(): ${fallbackPath}`) - console.error(`[执行上下文] 回退到process.cwd(): ${fallbackPath}`); - console.error(`[执行上下文] 提示:建议在MCP配置中添加 "env": {"PROMPTX_WORKSPACE": "你的项目目录"}`); - console.error('🔍 [executionContext-DIAGNOSIS] ===== getWorkspaceSynchronous 诊断结束 =====') + const fallbackPath = process.cwd(); + if (debug) { + console.error(`[执行上下文] 回退到当前目录: ${fallbackPath}`); + console.error(`[执行上下文] 建议在MCP配置中添加 "env": {"PROMPTX_WORKSPACE": "你的项目目录"}`); + } return fallbackPath; } @@ -159,64 +153,43 @@ function getMCPWorkingDirectoryLegacy() { /** * 向上查找现有的.promptx目录 * @param {string} startDir 开始查找的目录 + * @param {boolean} debug 是否输出调试信息 * @returns {string|null} 包含.promptx目录的父目录路径或null */ -function findExistingPromptxDirectory(startDir) { - // 🔍 增加详细的路径诊断日志 - console.error('🔍 [findExistingPromptxDirectory-DIAGNOSIS] ===== 查找.promptx目录诊断开始 =====') - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 起始目录: ${startDir}`) +function findExistingPromptxDirectory(startDir, debug = false) { + if (debug) { + console.error(`🔍 [executionContext] 查找.promptx目录: ${startDir}`); + } let currentDir = path.resolve(startDir); const root = path.parse(currentDir).root; - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 解析后起始目录: ${currentDir}`) - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 文件系统根目录: ${root}`) - - const foundDirectories = [] - let stepCount = 0 while (currentDir !== root) { - stepCount++ - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 第${stepCount}步 - 检查目录: ${currentDir}`) - // 检查当前目录是否包含.promptx目录 const promptxPath = path.join(currentDir, '.promptx'); - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 检查路径: ${promptxPath}`) if (fs.existsSync(promptxPath)) { - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ✅ 发现.promptx目录: ${promptxPath}`) - foundDirectories.push(currentDir) - try { const stat = fs.statSync(promptxPath); if (stat.isDirectory()) { - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ✅ 确认为有效目录,返回: ${currentDir}`) - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 🎯 总共发现${foundDirectories.length}个.promptx目录: ${JSON.stringify(foundDirectories)}`) - console.error('🔍 [findExistingPromptxDirectory-DIAGNOSIS] ===== 查找.promptx目录诊断结束 =====') + if (debug) console.error(`🔍 [executionContext] 找到.promptx目录: ${currentDir}`); return currentDir; - } else { - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ❌ .promptx存在但不是目录`) } } catch (error) { - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ❌ 访问.promptx目录时出错: ${error.message}`) // 忽略权限错误等,继续查找 + if (debug) console.error(`🔍 [executionContext] 访问.promptx目录时出错: ${error.message}`); } - } else { - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ❌ 当前目录无.promptx`) } // 向上一级目录 const parentDir = path.dirname(currentDir); if (parentDir === currentDir) { - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 🔚 到达顶级目录,停止搜索`) break; // 防止无限循环 } currentDir = parentDir; - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ⬆️ 向上一级: ${currentDir}`) } - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] 🎯 搜索完成,总共发现${foundDirectories.length}个.promptx目录: ${JSON.stringify(foundDirectories)}`) - console.error(`🔍 [findExistingPromptxDirectory-DIAGNOSIS] ❌ 未找到有效的.promptx目录`) - console.error('🔍 [findExistingPromptxDirectory-DIAGNOSIS] ===== 查找.promptx目录诊断结束 =====') + if (debug) console.error(`🔍 [executionContext] 未找到.promptx目录`); return null; } diff --git a/src/package.registry.json b/src/package.registry.json index 7a30793..382c047 100644 --- a/src/package.registry.json +++ b/src/package.registry.json @@ -4,8 +4,8 @@ "metadata": { "version": "2.0.0", "description": "package 级资源注册表", - "createdAt": "2025-06-28T06:22:37.206Z", - "updatedAt": "2025-06-28T06:22:37.216Z", + "createdAt": "2025-06-28T07:01:07.318Z", + "updatedAt": "2025-06-28T07:01:07.327Z", "resourceCount": 61 }, "resources": [ @@ -15,11 +15,11 @@ "protocol": "role", "name": "Assistant 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/assistant/assistant.role.md", + "reference": "@package://resource/domain/assistant/assistant.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -28,11 +28,11 @@ "protocol": "role", "name": "Frontend Developer 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/frontend-developer/frontend-developer.role.md", + "reference": "@package://resource/domain/frontend-developer/frontend-developer.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -41,11 +41,11 @@ "protocol": "role", "name": "Java Backend Developer 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/java-backend-developer/java-backend-developer.role.md", + "reference": "@package://resource/domain/java-backend-developer/java-backend-developer.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -54,11 +54,11 @@ "protocol": "role", "name": "Noface 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/noface/noface.role.md", + "reference": "@package://resource/domain/noface/noface.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -67,11 +67,11 @@ "protocol": "role", "name": "Nuwa 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/nuwa/nuwa.role.md", + "reference": "@package://resource/domain/nuwa/nuwa.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -80,11 +80,11 @@ "protocol": "role", "name": "Product Manager 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/product-manager/product-manager.role.md", + "reference": "@package://resource/domain/product-manager/product-manager.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -93,11 +93,11 @@ "protocol": "role", "name": "Sean 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/sean/sean.role.md", + "reference": "@package://resource/domain/sean/sean.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -106,11 +106,11 @@ "protocol": "role", "name": "Xiaohongshu Marketer 角色", "description": "专业角色,提供特定领域的专业能力", - "reference": "@package://prompt/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/xiaohongshu-marketer.role.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.211Z", - "updatedAt": "2025-06-28T06:22:37.211Z", - "scannedAt": "2025-06-28T06:22:37.211Z" + "createdAt": "2025-06-28T07:01:07.322Z", + "updatedAt": "2025-06-28T07:01:07.322Z", + "scannedAt": "2025-06-28T07:01:07.322Z" } }, { @@ -119,11 +119,11 @@ "protocol": "execution", "name": "Assistant 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/assistant/execution/assistant.execution.md", + "reference": "@package://resource/domain/assistant/execution/assistant.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -132,11 +132,11 @@ "protocol": "execution", "name": "Code Quality 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/java-backend-developer/execution/code-quality.execution.md", + "reference": "@package://resource/domain/java-backend-developer/execution/code-quality.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -145,11 +145,11 @@ "protocol": "execution", "name": "Frontend Developer 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/frontend-developer/execution/frontend-developer.execution.md", + "reference": "@package://resource/domain/frontend-developer/execution/frontend-developer.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -158,11 +158,11 @@ "protocol": "execution", "name": "Technical Architecture 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/frontend-developer/execution/technical-architecture.execution.md", + "reference": "@package://resource/domain/frontend-developer/execution/technical-architecture.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -171,11 +171,11 @@ "protocol": "execution", "name": "User Experience 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/frontend-developer/execution/user-experience.execution.md", + "reference": "@package://resource/domain/frontend-developer/execution/user-experience.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -184,11 +184,11 @@ "protocol": "execution", "name": "Wechat Miniprogram Development 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md", + "reference": "@package://resource/domain/frontend-developer/execution/wechat-miniprogram-development.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -197,11 +197,11 @@ "protocol": "execution", "name": "Database Design 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/java-backend-developer/execution/database-design.execution.md", + "reference": "@package://resource/domain/java-backend-developer/execution/database-design.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -210,11 +210,11 @@ "protocol": "execution", "name": "Java Backend Developer 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/java-backend-developer/execution/java-backend-developer.execution.md", + "reference": "@package://resource/domain/java-backend-developer/execution/java-backend-developer.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -223,11 +223,11 @@ "protocol": "execution", "name": "Spring Ecosystem 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/java-backend-developer/execution/spring-ecosystem.execution.md", + "reference": "@package://resource/domain/java-backend-developer/execution/spring-ecosystem.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -236,11 +236,11 @@ "protocol": "execution", "name": "System Architecture 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/java-backend-developer/execution/system-architecture.execution.md", + "reference": "@package://resource/domain/java-backend-developer/execution/system-architecture.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -249,11 +249,11 @@ "protocol": "execution", "name": "Adaptive Learning 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/noface/execution/adaptive-learning.execution.md", + "reference": "@package://resource/domain/noface/execution/adaptive-learning.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -262,11 +262,11 @@ "protocol": "execution", "name": "Content Preservation 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/noface/execution/content-preservation.execution.md", + "reference": "@package://resource/domain/noface/execution/content-preservation.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -275,11 +275,11 @@ "protocol": "execution", "name": "Dpml Authoring 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/nuwa/execution/dpml-authoring.execution.md", + "reference": "@package://resource/domain/nuwa/execution/dpml-authoring.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -288,11 +288,11 @@ "protocol": "execution", "name": "Role Design Patterns 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/nuwa/execution/role-design-patterns.execution.md", + "reference": "@package://resource/domain/nuwa/execution/role-design-patterns.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -301,11 +301,11 @@ "protocol": "execution", "name": "Role Generation 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/nuwa/execution/role-generation.execution.md", + "reference": "@package://resource/domain/nuwa/execution/role-generation.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -314,11 +314,11 @@ "protocol": "execution", "name": "Visualization Enhancement 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/nuwa/execution/visualization-enhancement.execution.md", + "reference": "@package://resource/domain/nuwa/execution/visualization-enhancement.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -327,11 +327,11 @@ "protocol": "execution", "name": "Market Analysis 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/product-manager/execution/market-analysis.execution.md", + "reference": "@package://resource/domain/product-manager/execution/market-analysis.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -340,11 +340,11 @@ "protocol": "execution", "name": "Product Manager 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/product-manager/execution/product-manager.execution.md", + "reference": "@package://resource/domain/product-manager/execution/product-manager.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -353,11 +353,11 @@ "protocol": "execution", "name": "User Research 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/product-manager/execution/user-research.execution.md", + "reference": "@package://resource/domain/product-manager/execution/user-research.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -366,11 +366,11 @@ "protocol": "execution", "name": "Contradiction Analysis 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/sean/execution/contradiction-analysis.execution.md", + "reference": "@package://resource/domain/sean/execution/contradiction-analysis.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -379,11 +379,11 @@ "protocol": "execution", "name": "Contradiction Management Methodology 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/sean/execution/contradiction-management-methodology.execution.md", + "reference": "@package://resource/domain/sean/execution/contradiction-management-methodology.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -392,11 +392,11 @@ "protocol": "execution", "name": "Sean Decision Framework 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/sean/execution/sean-decision-framework.execution.md", + "reference": "@package://resource/domain/sean/execution/sean-decision-framework.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -405,11 +405,11 @@ "protocol": "execution", "name": "Template Adherence 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/sean/execution/template-adherence.execution.md", + "reference": "@package://resource/domain/sean/execution/template-adherence.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -418,11 +418,11 @@ "protocol": "execution", "name": "Brand Marketing 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/brand-marketing.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -431,11 +431,11 @@ "protocol": "execution", "name": "Community Building 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/community-building.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/community-building.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -444,11 +444,11 @@ "protocol": "execution", "name": "Content Creation 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/content-creation.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/content-creation.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -457,11 +457,11 @@ "protocol": "execution", "name": "Content Optimization 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/content-optimization.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/content-optimization.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -470,11 +470,11 @@ "protocol": "execution", "name": "Data Analytics 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/data-analytics.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/data-analytics.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -483,11 +483,11 @@ "protocol": "execution", "name": "Ecommerce Conversion 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/ecommerce-conversion.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -496,11 +496,11 @@ "protocol": "execution", "name": "Performance Optimization 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/performance-optimization.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -509,11 +509,11 @@ "protocol": "execution", "name": "Platform Compliance 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/platform-compliance.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -522,11 +522,11 @@ "protocol": "execution", "name": "Team Collaboration 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/team-collaboration.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -535,11 +535,11 @@ "protocol": "execution", "name": "User Operation 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/user-operation.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/user-operation.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -548,11 +548,11 @@ "protocol": "execution", "name": "Xiaohongshu Marketer 执行模式", "description": "执行模式,定义具体的行为模式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/execution/xiaohongshu-marketer.execution.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.212Z", - "updatedAt": "2025-06-28T06:22:37.212Z", - "scannedAt": "2025-06-28T06:22:37.212Z" + "createdAt": "2025-06-28T07:01:07.323Z", + "updatedAt": "2025-06-28T07:01:07.323Z", + "scannedAt": "2025-06-28T07:01:07.323Z" } }, { @@ -561,11 +561,11 @@ "protocol": "thought", "name": "Recall_v1 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/core/_deprecated/recall_v1.thought.md", + "reference": "@package://resource/core/_deprecated/recall_v1.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -574,11 +574,11 @@ "protocol": "thought", "name": "Remember_v1 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/core/_deprecated/remember_v1.thought.md", + "reference": "@package://resource/core/_deprecated/remember_v1.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -587,11 +587,11 @@ "protocol": "thought", "name": "Recall Xml 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/core/recall-xml.thought.md", + "reference": "@package://resource/core/recall-xml.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -600,11 +600,11 @@ "protocol": "thought", "name": "Recall 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/core/recall.thought.md", + "reference": "@package://resource/core/recall.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -613,11 +613,11 @@ "protocol": "thought", "name": "Remember Xml 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/core/remember-xml.thought.md", + "reference": "@package://resource/core/remember-xml.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -626,11 +626,11 @@ "protocol": "thought", "name": "Remember 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/core/remember.thought.md", + "reference": "@package://resource/core/remember.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -639,11 +639,11 @@ "protocol": "thought", "name": "Assistant 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/assistant/thought/assistant.thought.md", + "reference": "@package://resource/domain/assistant/thought/assistant.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -652,11 +652,11 @@ "protocol": "thought", "name": "Frontend Developer 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/frontend-developer/thought/frontend-developer.thought.md", + "reference": "@package://resource/domain/frontend-developer/thought/frontend-developer.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -665,11 +665,11 @@ "protocol": "thought", "name": "Java Backend Developer 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/java-backend-developer/thought/java-backend-developer.thought.md", + "reference": "@package://resource/domain/java-backend-developer/thought/java-backend-developer.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -678,11 +678,11 @@ "protocol": "thought", "name": "Role Creation 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/nuwa/thought/role-creation.thought.md", + "reference": "@package://resource/domain/nuwa/thought/role-creation.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -691,11 +691,11 @@ "protocol": "thought", "name": "Product Manager 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/product-manager/thought/product-manager.thought.md", + "reference": "@package://resource/domain/product-manager/thought/product-manager.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -704,11 +704,11 @@ "protocol": "thought", "name": "Contradiction Methodology 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/sean/thought/contradiction-methodology.thought.md", + "reference": "@package://resource/domain/sean/thought/contradiction-methodology.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -717,11 +717,11 @@ "protocol": "thought", "name": "Sean 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/sean/thought/sean.thought.md", + "reference": "@package://resource/domain/sean/thought/sean.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -730,11 +730,11 @@ "protocol": "thought", "name": "Xiaohongshu Marketer 思维模式", "description": "思维模式,指导AI的思考方式", - "reference": "@package://prompt/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md", + "reference": "@package://resource/domain/xiaohongshu-marketer/thought/xiaohongshu-marketer.thought.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.213Z", - "updatedAt": "2025-06-28T06:22:37.213Z", - "scannedAt": "2025-06-28T06:22:37.213Z" + "createdAt": "2025-06-28T07:01:07.324Z", + "updatedAt": "2025-06-28T07:01:07.324Z", + "scannedAt": "2025-06-28T07:01:07.324Z" } }, { @@ -743,11 +743,11 @@ "protocol": "knowledge", "name": "Contradiction Methodology 知识库", "description": "知识库,提供专业知识和信息", - "reference": "@package://prompt/domain/sean/knowledge/contradiction-methodology.knowledge.md", + "reference": "@package://resource/domain/sean/knowledge/contradiction-methodology.knowledge.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.214Z", - "updatedAt": "2025-06-28T06:22:37.214Z", - "scannedAt": "2025-06-28T06:22:37.214Z" + "createdAt": "2025-06-28T07:01:07.325Z", + "updatedAt": "2025-06-28T07:01:07.325Z", + "scannedAt": "2025-06-28T07:01:07.325Z" } }, { @@ -756,11 +756,11 @@ "protocol": "knowledge", "name": "Product Philosophy 知识库", "description": "知识库,提供专业知识和信息", - "reference": "@package://prompt/domain/sean/knowledge/product-philosophy.knowledge.md", + "reference": "@package://resource/domain/sean/knowledge/product-philosophy.knowledge.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.214Z", - "updatedAt": "2025-06-28T06:22:37.214Z", - "scannedAt": "2025-06-28T06:22:37.214Z" + "createdAt": "2025-06-28T07:01:07.325Z", + "updatedAt": "2025-06-28T07:01:07.325Z", + "scannedAt": "2025-06-28T07:01:07.325Z" } }, { @@ -769,11 +769,11 @@ "protocol": "knowledge", "name": "Promptx Evolution 知识库", "description": "知识库,提供专业知识和信息", - "reference": "@package://prompt/domain/sean/knowledge/promptx-evolution.knowledge.md", + "reference": "@package://resource/domain/sean/knowledge/promptx-evolution.knowledge.md", "metadata": { - "createdAt": "2025-06-28T06:22:37.214Z", - "updatedAt": "2025-06-28T06:22:37.214Z", - "scannedAt": "2025-06-28T06:22:37.214Z" + "createdAt": "2025-06-28T07:01:07.325Z", + "updatedAt": "2025-06-28T07:01:07.325Z", + "scannedAt": "2025-06-28T07:01:07.325Z" } }, { @@ -782,11 +782,11 @@ "protocol": "tool", "name": "Calculator tool", "description": "tool类型的资源", - "reference": "@package://prompt/tool/calculator.tool.js", + "reference": "@package://resource/tool/calculator.tool.js", "metadata": { - "createdAt": "2025-06-28T06:22:37.215Z", - "updatedAt": "2025-06-28T06:22:37.215Z", - "scannedAt": "2025-06-28T06:22:37.215Z" + "createdAt": "2025-06-28T07:01:07.326Z", + "updatedAt": "2025-06-28T07:01:07.326Z", + "scannedAt": "2025-06-28T07:01:07.326Z" } }, { @@ -795,11 +795,11 @@ "protocol": "tool", "name": "Send Email tool", "description": "tool类型的资源", - "reference": "@package://prompt/tool/send-email.tool.js", + "reference": "@package://resource/tool/send-email.tool.js", "metadata": { - "createdAt": "2025-06-28T06:22:37.216Z", - "updatedAt": "2025-06-28T06:22:37.216Z", - "scannedAt": "2025-06-28T06:22:37.216Z" + "createdAt": "2025-06-28T07:01:07.326Z", + "updatedAt": "2025-06-28T07:01:07.326Z", + "scannedAt": "2025-06-28T07:01:07.326Z" } } ],