技能甲板
- 作者仓库星标 435
- 作者仓库 nvim
- 领域
- 通用
- 作者声明的智能体
- 未找到明确声明;不据此推断已兼容或已测试
- 静态检查
- 88 / 100 · 启发式扫描,不代表运行安全
- 运行环境证据
- 未执行;当前没有隔离运行测试证据
- 作者 / 版本 / 许可证
- @benbrastmckie · 未声明许可证
- 上下文用量评级
- 低消耗
- 接入复杂程度
- 需简单配置
- 是否需要外部接口密钥
- 不需要
- 兼容的系统
- 未声明(默认跨平台)
- 运行环境要求
- 未检出明确要求
- 检测到的文件与系统行为
-
- 只读
- 允许写入 / 修改
- 命令执行
- 网络行为
- 仅限本地
- 安装命令数
- 无(仅作为资料)
需要注意: 未声明工具权限范围;实际权限由运行环境决定。
# Deck Skill
Thin wrapper that routes pitch deck generation requests to the `deck-agent`.
## Context Pointers
Reference (do not load eagerly):
- Path: `.opencode/context/core/formats/subagent-return.md`
- Purpose: Return validation
- Load at: Subagent execution only
Note: This skill is a thin wrapper. Context is loaded by the delegated agent, not this skill.
## Trigger Conditions
This skill activates when:
### Direct Invocation
- User explicitly runs `/deck` command
- User requests pitch deck generation in conversation
### Implicit Invocation (during task implementation)
When an implementing agent encounters any of these patterns:
**Plan step language patterns**:
- "Generate pitch deck"
- "Create investor deck"
- "Build presentation for investors"
- "Make YC-style slides"
- "Create startup pitch"
**Target mentions**:
- "pitch deck"
- "investor presentation"
- "seed round slides"
- "fundraising deck"
- "touying pitch"
**Task description keywords**:
- "pitch deck generation"
- "investor slides"
- "startup presentation"
- "YC deck"
### When NOT to trigger
Do not invoke for:
- Converting existing presentations (use skill-presentation)
- General slide conversion from PPTX (use skill-presentation)
- Document format conversions (use skill-filetypes)
- Creating non-investor presentation slides
---
## Execution
### 1. Input Validation
Validate required inputs:
- At least one of: `prompt` (text description) OR `source_path` (file path)
- `output_path` - Optional, defaults based on input
- `theme` - Optional, defaults to "simple"
- `slide_count` - Optional, defaults to 10
```bash
# Validate at least one input source
if [ -z "$prompt" ] && [ -z "$source_path" ]; then
return error "Either a prompt or source file path is required"
fi
# If source_path provided, validate it exists
if [ -n "$source_path" ] && [ ! -f "$source_path" ]; then
return error "Source file not found: $source_path"
fi
# Convert source_path to absolute if relative
if [ -n "$source_path" ] && [[ "$source_path" != /* ]]; then
source_path="$(pwd)/$source_path"
fi
# Determine output path if not provided
if [ -z "$output_path" ]; then
if [ -n "$source_path" ]; then
source_dir=$(dirname "$source_path")
source_base=$(basename "$source_path" | sed 's/\.[^.]*$//')
output_path="${source_dir}/${source_base}-deck.typ"
else
output_path="$(pwd)/pitch-deck.typ"
fi
fi
# Convert output_path to absolute if relative
if [[ "$output_path" != /* ]]; then
output_path="$(pwd)/$output_path"
fi
```
### 2. Context Preparation
Prepare delegation context:
```json
{
"prompt": "Startup description from user",
"source_path": "/absolute/path/to/startup-info.md",
"output_path": "/absolute/path/to/pitch-deck.typ",
"theme": "simple",
"slide_count": 10,
"metadata": {
"session_id": "sess_{timestamp}_{random}",
"delegation_depth": 1,
"delegation_path": ["orchestrator", "deck", "skill-deck"]
}
}
```
### 3. Invoke Agent
**CRITICAL**: You MUST use the **Task** tool to spawn the agent.
**Required Tool Invocation**:
```
Tool: Task (NOT Skill)
Parameters:
- subagent_type: "deck-agent"
- prompt: [Include prompt, source_path, output_path, theme, slide_count, metadata]
- description: "Generate pitch deck from input"
```
The agent will:
- Parse and validate inputs
- Read source file if provided
- Map content to YC's 10-slide structure
- Generate Typst code using touying
- Include speaker notes and TODO placeholders
- Return standardized JSON result
### 4. Return Validation
Validate return matches `subagent-return.md` schema:
- Status is one of: generated, partial, failed
- Summary is non-empty and <100 tokens
- Artifacts array present with output file path
- Metadata contains slide_count and slides_with_todos
### 5. Return Propagation
Return validated result to caller without modification.
---
## Return Format
Expected successful return:
```json
{
"status": "generated",
"summary": "Generated 10-slide pitch deck for Acme AI in Typst format. 2 slides have TODO placeholders.",
"artifacts": [
{
"type": "implementation",
"path": "/absolute/path/to/pitch-deck.typ",
"summary": "Touying pitch deck with speaker notes"
}
],
"metadata": {
"session_id": "sess_...",
"agent_type": "deck-agent",
"delegation_depth": 2,
"theme": "simple",
"slide_count": 10,
"slides_with_todos": 2,
"input_type": "prompt_and_file"
},
"next_steps": "Review and compile: typst compile pitch-deck.typ"
}
```
---
## Error Handling
### Input Validation Errors
Return immediately with failed status if neither prompt nor source file provided.
### Source File Not Found
Return failed status with clear message about the missing file.
### Agent Errors
Pass through the agent's error return verbatim.
### Write Failure
Return failed status with directory/permission guidance.
章节与文件索引
按说明文件中的顺序排列。
上下文指针
直接调用
隐式调用(任务执行期间)
何时不触发
1. 输入验证
文件/命令 -> deck-agent · .opencode/context/core/formats/subagent-return.md · /deck · source_path · output_path · theme · slide_count · subagent-return.md
内容校验值 -> 41ba0c371b09
当前原文的自动摘译,尚未人工审校。
上下文指针
参考(不要急于加载): 路径:
.opencode/context/core/formats/subagent-return.md目的:返回验证 加载于:仅子代理执行 注意:此技能是一个薄包装。上下文由委托代理加载,而不是由该技能加载。直接调用
用户明确运行
/deck命令 用户请求在对话中生成宣传材料隐式调用(任务执行期间)
当实施代理遇到以下任何一种模式时: 计划步骤语言模式:“生成宣传材料”“创建投资者材料”“为投资者构建演示文稿”
何时不触发
请勿调用: 转换现有演示文稿(使用技能演示文稿) 从 PPTX 进行常规幻灯片转换(使用技能演示文稿) 文档格式转换(使用技能文件类型) 创建非投资者演示文稿幻灯片
1. 输入验证
验证所需的输入: 至少其中之一:
prompt(文本描述)或source_path(文件路径)output_path- 可选,默认基于输入theme- 可选,默认为“简单”slide_count- 可选,默认为 10