来源信息
- 仓库
- parcadei/Continuous-Claude-v3
- 最近来源活动
- 2026年1月10日 01:54
- 检测到的 SKILL.md 语言
- 英语
- 星标
- 3,943
- 分支
- 303
安装方式
默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。
检查来源文件
决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。
正在显示 SKILL.md
SKILL.md
来源说明 · 只读预览- name
- parallel-agent-contracts
- description
- Parallel Agent Type Contracts
- user-invocable
- false
# Parallel Agent Type Contracts
When launching parallel agents for code implementation, prevent type duplication.
## Required in Every Agent Prompt
### 1. Verification Command (MANDATORY)
```markdown
## Before Marking Complete
Run verification:
\`\`\`bash
npx tsc --noEmit 2>&1 | head -20
\`\`\`
If ANY type errors exist, fix them before completing.
```
### 2. Grep-Before-Create
```markdown
## Before Creating Any Type/Interface
First check if it exists:
\`\`\`bash
grep -r "interface YourTypeName\|type YourTypeName" src/
\`\`\`
If found, import it. NEVER duplicate existing types.
```
### 3. Canonical Type Map
Include relevant entries from this map in agent prompts:
| Type | Owner File | Import From |
|------|-----------|-------------|
| `NormalizedTool` | `src/sdk/agent.ts` | `'./agent'` |
| `ToolCall` | `src/sdk/agent.ts` | `'./agent'` |
| `ToolResult` | `src/sdk/agent.ts` | `'./agent'` |
| `ToolDefinition` | `src/sdk/agent.ts` | `'./agent'` |
| `Message` | `src/sdk/types.ts` | `'./types'` |
| `ContentBlock` | `src/sdk/types.ts` | `'./types'` |
| `TokenUsage` | `src/sdk/types.ts` | `'./types'` |
| `ProviderAdapter` | `src/sdk/providers/index.ts` | `'./providers'` |
| `RiggClient` | `src/sdk/client.ts` | `'./client'` |
## Prompt Template
When spawning implementation agents:
```markdown
# Task: [Description]
## Type Ownership (DO NOT recreate)
- [List relevant types from canonical map]
## Before Creating New Types
Run: `grep -r "interface TypeName" src/` - if exists, import it.
## Before Marking Complete
Run: `npx tsc --noEmit 2>&1 | head -20`
Fix all type errors before completing.
## Your Implementation
[Actual task description]
```
## Why This Works
1. **Type checker is the contract** - tsc catches conflicts automatically
2. **Grep is fast** - 1 second to check if type exists
3. **Explicit ownership** - No ambiguity about where types live
4. **Fail fast** - Agent can't claim "done" with broken types
在 GitHub 查看