ln-001-standards-researcher

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Standards Researcher (Worker)

标准研究员(Worker)

This skill researches industry standards and architectural patterns using MCP Ref to generate Standards Research for Story Technical Notes.
本skill通过MCP Ref研究行业标准与架构模式,为Story技术说明生成标准研究内容。

When to Use This Skill

何时使用本Skill

This skill should be used when:
  • Need to research standards and patterns BEFORE Story generation (ensures tasks follow industry best practices)
  • Epic Technical Notes mention specific standards requiring documentation (OAuth, OpenAPI, WebSocket)
  • Prevent situations where tasks use outdated patterns or violate RFC compliance
  • Reusable for ANY skill requiring standards research (ln-220-story-coordinator, ln-300-task-coordinator, ln-510-test-planner, ln-002-best-practices-researcher)
Who calls this skill:
  • ln-220-story-coordinator (Phase 3) - research for Story creation
  • ln-300-task-coordinator (optional) - research for complex Stories
  • ln-510-test-planner (optional) - research for test task planning
  • Manual - user can invoke directly for Epic/Story research
在以下场景中应使用本skill:
  • 需要在Story生成之前研究标准与模式(确保任务遵循行业最佳实践)
  • Epic技术说明中提及需要文档化的特定标准(OAuth、OpenAPI、WebSocket)
  • 避免任务使用过时模式或违反RFC合规性的情况
  • 可复用于任何需要标准研究的skill(ln-220-story-coordinator、ln-300-task-coordinator、ln-510-test-planner、ln-002-best-practices-researcher)
调用本skill的主体:
  • ln-220-story-coordinator(阶段3)——为Story创建开展研究
  • ln-300-task-coordinator(可选)——为复杂Story开展研究
  • ln-510-test-planner(可选)——为测试任务规划开展研究
  • 手动调用——用户可直接调用以进行Epic/Story研究

How It Works

工作原理

The skill follows a 6-phase workflow focused on standards and architectural patterns.
Stack Detection → Identify → Ref Research → Existing Guides → Standards Research
本skill遵循一个聚焦于标准与架构模式的6阶段工作流。
Stack Detection → Identify → Ref Research → Existing Guides → Standards Research

Phase 0: Stack Detection

阶段0:技术栈检测

Objective: Determine project stack BEFORE research to filter queries.
Detection:
IndicatorStackQuery Prefix
*.csproj
,
*.sln
.NET"C# ASP.NET Core"
package.json
+
tsconfig.json
Node.js"TypeScript Node.js"
requirements.txt
,
pyproject.toml
Python"Python"
go.mod
Go"Go Golang"
Cargo.toml
Rust"Rust"
build.gradle
,
pom.xml
Java"Java"
Process:
  1. Check
    context_store.TECH_STACK
    if provided → use directly
  2. Else: Glob for indicator files in project root
  3. Store
    detected_stack.query_prefix
    for Phases 2-3
Output:
detected_stack = {language, framework, query_prefix}
Skip conditions: If no stack detected → proceed without prefix (generic queries)

目标:在研究前确定项目技术栈,以过滤查询内容。
检测方式:
标识文件技术栈查询前缀
*.csproj
,
*.sln
.NET"C# ASP.NET Core"
package.json
+
tsconfig.json
Node.js"TypeScript Node.js"
requirements.txt
,
pyproject.toml
Python"Python"
go.mod
Go"Go Golang"
Cargo.toml
Rust"Rust"
build.gradle
,
pom.xml
Java"Java"
流程:
  1. 若已提供
    context_store.TECH_STACK
    ,则直接使用
  2. 否则:在项目根目录下全局搜索标识文件
  3. 为阶段2-3存储
    detected_stack.query_prefix
输出
detected_stack = {language, framework, query_prefix}
跳过条件:若未检测到技术栈,则不使用前缀继续(通用查询)

Phase 1: Identify Libraries

阶段1:识别库

Objective: Parse Epic/Story for libraries and technology keywords.
Process:
  1. Read Epic/Story description (provided as input)
    • Parse Epic Technical Notes for mentioned libraries/frameworks
    • Parse Epic Scope In for technology keywords (authentication, rate limiting, payments, etc.)
    • Identify Story domain from Epic goal statement (e.g., "Add rate limiting" → domain = "rate limiting")
  2. Extract library list:
    • Primary libraries (explicitly mentioned)
    • Inferred libraries (e.g., "REST API" → FastAPI, "caching" → Redis)
    • Filter out well-known libraries with stable APIs (e.g., requests, urllib3)
  3. Determine Story domain:
    • Extract from Epic goal or Story title
    • Examples: rate limiting, authentication, payment processing, file upload
Output: Library list (3-5 libraries max) + Story domain
Skip conditions:
  • NO libraries mentioned in Epic → Output empty Research Summary
  • Trivial CRUD operation with well-known libraries → Output empty Research Summary
  • Epic explicitly states "research not needed" → Skip

目标:解析Epic/Story以提取库与技术关键词。
流程
  1. 读取Epic/Story描述(作为输入提供)
    • 解析Epic技术说明中提及的库/框架
    • 解析Epic包含范围中的技术关键词(身份验证、限流、支付等)
    • 从Epic目标语句中识别Story领域(例如:"添加限流" → 领域 = "限流")
  2. 提取库列表
    • 主要库(明确提及的)
    • 推断库(例如:"REST API" → FastAPI,"缓存" → Redis)
    • 过滤掉API稳定的知名库(例如:requests、urllib3)
  3. 确定Story领域
    • 从Epic目标或Story标题中提取
    • 示例:限流、身份验证、支付处理、文件上传
输出:库列表(最多3-5个) + Story领域
跳过条件
  • Epic中未提及任何库 → 输出空的研究摘要
  • 使用知名稳定API库的简单CRUD操作 → 输出空的研究摘要
  • Epic明确说明"无需研究" → 跳过

Phase 2: MCP Ref Research

阶段2:MCP Ref研究

Objective: Get industry standards and architectural patterns.
Process:
  1. Focus on standards/RFCs:
    • Call
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [story_domain] RFC standard specification")
    • Example:
      "C# ASP.NET Core rate limiting RFC standard specification"
    • Extract: RFC/spec references (OAuth 2.0 RFC 6749, OpenAPI 3.0, WebSocket RFC 6455)
  2. Focus on architectural patterns:
    • Call
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [story_domain] architectural patterns best practices")
    • Example:
      "TypeScript Node.js authentication architectural patterns best practices"
    • Extract: Middleware, Dependency Injection, Decorator pattern
Output: Standards compliance table + Architectural patterns list

目标:获取行业标准与架构模式。
流程:
  1. 聚焦标准/RFC:
    • 调用
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [story_domain] RFC standard specification")
    • 示例:
      "C# ASP.NET Core rate limiting RFC standard specification"
    • 提取:RFC/规范参考(OAuth 2.0 RFC 6749、OpenAPI 3.0、WebSocket RFC 6455)
  2. 聚焦架构模式:
    • 调用
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [story_domain] architectural patterns best practices")
    • 示例:
      "TypeScript Node.js authentication architectural patterns best practices"
    • 提取:中间件、依赖注入、装饰器模式
输出:标准合规性表格 + 架构模式列表

Phase 3: MCP Ref Research

阶段3:MCP Ref研究

Objective: Get industry standards and best practices.
Process:
  1. FOR EACH library + Story domain combination:
    • Call
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [library] [domain] best practices 2025")
    • Call
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [domain] industry standards RFC")
    • Example:
      "C# ASP.NET Core Polly rate limiting best practices 2025"
  2. Extract from results (NO CODE - text/tables only):
    • Industry standards (RFC/spec references: OAuth 2.0, REST API, OpenAPI 3.0)
    • Common patterns (do/don't descriptions, anti-patterns to avoid)
    • Integration approaches (middleware, dependency injection, decorators)
    • Security considerations (OWASP compliance, vulnerability mitigation)
    • Official docs URLs (link to stack-appropriate authoritative sources)
  3. Store results for Research Summary compilation
Output: Standards compliance table (RFC/Standard name, how to comply) + Best practices list

目标:获取行业标准与最佳实践。
流程
  1. 针对每个库 + Story领域组合:
    • 调用
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [library] [domain] best practices 2025")
    • 调用
      mcp__Ref__ref_search_documentation(query="[detected_stack.query_prefix] [domain] industry standards RFC")
    • 示例:
      "C# ASP.NET Core Polly rate limiting best practices 2025"
  2. 从结果中提取禁止代码 - 仅使用文本/表格):
    • 行业标准(RFC/标准名称:OAuth 2.0、REST API、OpenAPI 3.0)
    • 常见模式(应做/不应做说明、需避免的反模式)
    • 集成方式(中间件、依赖注入、装饰器)
    • 安全考量(OWASP合规、漏洞缓解)
    • 官方文档URL(链接到适合技术栈的权威来源)
  3. 存储结果以用于研究摘要编译
输出:标准合规性表格(RFC/标准名称、合规方式) + 最佳实践列表

Phase 4: Scan Existing Guides

阶段4:扫描现有指南

Objective: Find relevant pattern guides in docs/guides/ directory.
Process:
  1. Scan guides directory:
    • Use
      Glob
      to find
      docs/guides/*.md
    • Read guide filenames
  2. Match guides to Story domain:
    • Match keywords (e.g., rate limiting guide for rate limiting Story)
    • Fuzzy match (e.g., "authentication" matches "auth.md", "oauth.md")
  3. Collect guide paths for linking in Technical Notes
Output: Existing guides list (relative paths from project root)

目标:在docs/guides/目录中查找相关模式指南。
流程
  1. 扫描指南目录
    • 使用
      Glob
      查找
      docs/guides/*.md
    • 读取指南文件名
  2. 匹配指南与Story领域
    • 关键词匹配(例如:限流指南对应限流Story)
    • 模糊匹配(例如:"authentication"匹配"auth.md"、"oauth.md")
  3. 收集指南路径以在技术说明中链接
输出:现有指南列表(项目根目录的相对路径)

Phase 5: Generate Standards Research

阶段5:生成标准研究内容

Objective: Compile research results into Standards Research for Story Technical Notes subsection.
NO_CODE Rule: No code snippets. Use tables + links to official docs only.
Format Priority:
┌─────────────────────────────────────┐
│ 1. TABLES + ASCII diagrams ← Priority │
│ 2. Lists (enumerations only)        │
│ 3. Text (last resort)               │
└─────────────────────────────────────┘
Output Format (Table-First):
markdown
undefined
目标:将研究结果编译为Story技术说明小节的标准研究内容。
禁止代码规则: 不得包含代码片段。仅使用表格 + 官方文档链接。
格式优先级:
┌─────────────────────────────────────┐
│ 1. 表格 + ASCII 图 ← 最高优先级 │
│ 2. 列表(仅枚举)        │
│ 3. 文本(最后选择)               │
└─────────────────────────────────────┘
输出格式(表格优先):
markdown
undefined

Standards Research

标准研究

Standards compliance:
StandardRequirementHow to ComplyReference
RFC 6749OAuth 2.0Use PKCE for public clientsRFC 6749
RFC 6585Rate LimitingReturn 429 + Retry-AfterRFC 6585
Architectural patterns:
PatternWhen to UseReference
MiddlewareRequest interceptionOfficial docs
DecoratorCross-cutting concernsOfficial docs
Existing guides:
  • guide_path.md - Brief description

**Return Standards Research** to calling skill (ln-220, ln-310, ln-510)

**Output:** Standards Research (Markdown string) for insertion into Story Technical Notes subsection

**Important notes:**
- Focus on STANDARDS and PATTERNS only (no library details - libraries researched at Task level)
- Prefer official docs and RFC standards over blog posts
- Link to stack-appropriate docs (Microsoft docs for .NET, MDN for JS, etc.)
- If Standards Research is empty (no standards/patterns) → Return "No standards research needed"

---
标准合规性:
标准要求合规方式参考链接
RFC 6749OAuth 2.0为公共客户端使用PKCERFC 6749
RFC 6585限流返回429 + Retry-AfterRFC 6585
架构模式:
模式使用场景参考链接
中间件请求拦截官方文档
装饰器横切关注点官方文档
现有指南:
  • guide_path.md - 简要说明

**返回标准研究内容**给调用skill(ln-220、ln-310、ln-510)

**输出**:用于插入到Story技术说明小节的标准研究内容(Markdown字符串)

**重要说明:**
- 仅聚焦于**标准与模式**(库的研究在任务级别进行)
- 优先选择官方文档与RFC标准而非博客文章
- 链接到适合技术栈的文档(.NET用微软文档,JS用MDN等)
- 若标准研究内容为空(无标准/模式)→ 返回"无需标准研究"

---

Integration with Ecosystem

与生态系统的集成

Called by:
  • ln-220-story-coordinator (Phase 2) - research for ALL Stories in Epic
  • ln-300-task-coordinator (optional) - research for complex technical Stories
  • ln-510-test-planner (optional) - research for test infrastructure
Dependencies:
  • MCP Ref (ref_search_documentation) - industry standards and patterns
  • Glob (scan docs/guides/)
Input parameters (from calling skill):
  • epic_description
    (string) - Epic Technical Notes + Scope In + Goal
  • story_domain
    (string, optional) - Story domain (e.g., "rate limiting")
Output format:
  • Markdown string (Standards Research for Technical Notes subsection)
  • Format: Standards + Patterns (libraries researched at Task level)

调用方:
  • ln-220-story-coordinator(阶段2)——为Epic中的所有Story开展研究
  • ln-300-task-coordinator(可选)——为复杂技术Story开展研究
  • ln-510-test-planner(可选)——为测试基础设施开展研究
依赖项:
  • MCP Ref (ref_search_documentation) —— 行业标准与模式
  • Glob —— 扫描docs/guides/目录
输入参数(来自调用skill):
  • epic_description
    (字符串)—— Epic技术说明 + 包含范围 + 目标
  • story_domain
    (字符串,可选)—— Story领域(例如:"限流")
输出格式:
  • Markdown字符串(技术说明小节的标准研究内容)
  • 格式:标准 + 模式(库的研究在任务级别进行)

Time-Box and Performance

时间盒与性能

Time-box: 15-20 minutes maximum per Epic
Performance:
  • Research is done ONCE per Epic
  • Results reused for all Stories (5-10 Stories benefit from single research)
  • Parallel MCP calls when possible (Context7 + Ref)
Token efficiency:
  • Context7: max 3000 tokens per library
  • Total: ~10,000 tokens for typical Epic (3-4 libraries)

时间盒: 每个Epic最多15-20分钟
性能:
  • 每个Epic仅开展一次研究
  • 结果可复用给所有Story(5-10个Story可从单次研究中受益)
  • 尽可能并行调用MCP(Context7 + Ref)
Token效率:
  • Context7:每个库最多3000个token
  • 总计:典型Epic约10,000个token(3-4个库)

References

参考资料

Tools:
  • mcp__Ref__ref_search_documentation()
    - Search best practices and standards
  • Glob
    - Scan docs/guides/ directory
Templates:
  • research_guidelines.md - Research quality guidelines (official docs > blog posts, prefer LTS versions)

Version: 3.0.0 Last Updated: 2025-12-23
工具:
  • mcp__Ref__ref_search_documentation()
    —— 搜索最佳实践与标准
  • Glob
    —— 扫描docs/guides/目录
模板:
  • research_guidelines.md —— 研究质量指南(官方文档 > 博客文章,优先选择LTS版本)

版本: 3.0.0 最后更新: 2025-12-23