优化

其他 社区

技能解读

当前原文的自动摘译,尚未人工审校。

论点

对于优化模式: 资源:资源标识符 - 可以是: 代理名称:python-expert、refactor-agent 命名空间代理:research-team:research-specialist 完整路径:.claude/agents/dev-python-expert.md

基础优化

自动运行完整的优化管道。

有审查检查点

在研究、测试生成和评估后暂停以供您审核。

插件代理

优化插件代理。

创建新代理

使用上下文工程创建初始代理草稿,然后进行优化。

流狐档案 运行与权限由流狐静态检查推断,不代表作者声明或实际测试结果。
领域
通用
作者声明的智能体
未找到明确声明;不据此推断已兼容或已测试
静态检查
88 / 100 · 启发式扫描,不代表运行安全
运行环境证据
未执行;当前没有隔离运行测试证据
作者 / 版本 / 许可证
@tomevault-io · 未声明许可证
上下文用量评级
低消耗
接入复杂程度
需简单配置
是否需要外部接口密钥
不需要
兼容的系统
未声明(默认跨平台)
运行环境要求
Python
检测到的文件与系统行为
  • 只读
  • 允许写入 / 修改
  • 命令执行
网络行为
仅限本地
安装命令数
无(仅作为资料)

需要注意: 未声明工具权限范围;实际权限由运行环境决定。

作者说明文件(原文) SKILL.md

# CGF Optimize Skill

This skill launches the CGF (Claude Gradient Feedback) optimization pipeline for a specified resource or creates a new resource from description.

## Usage

### Optimization Mode (Existing Resource)
```
/cgf-optimize <resource> <optimization_goal> [--review]
```

### Creation Mode (New Resource)
```
/cgf-create <description> [--review]
```

### Arguments

**For optimization mode:**
- **resource**: Resource identifier - can be:
  - Agent name: `python-expert`, `refactor-agent`
  - Namespaced agent: `research-team:research-specialist`
  - Full path: `.claude/agents/dev-python-expert.md`

- **optimization_goal**: What to optimize for:
  - `async programming`
  - `better error handling`
  - `code quality improvements`
  - `Context7 usage patterns`

**For creation mode:**
- **description**: Natural language description of the desired resource:
  - `Python async expert that helps with asyncio patterns`
  - `Kubernetes deployment agent for managing k8s resources`
  - `Code review skill for security-focused reviews`

- **--review** (optional): Enable checkpoint mode for human review at each phase

## Examples

### Basic Optimization
```
/cgf-optimize python-expert async programming
```
Runs full optimization pipeline automatically.

### With Review Checkpoints
```
/cgf-optimize typescript-expert --review
```
Pauses after research, test generation, and evaluation for your review.

### Plugin Agent
```
/cgf-optimize research-team:research-specialist Context7 integration
```
Optimizes a plugin agent.

### Create New Agent
```
/cgf-create Python async expert that helps with asyncio patterns
```
Creates initial agent draft using context-engineer, then optimizes.

### Create With Review
```
/cgf-create Kubernetes deployment agent --review
```
Creates and optimizes with human review at each phase.

## Workflow

### Optimization Mode
1. **INIT**: Creates workspace, detects resource type
2. **RESEARCH**: Investigates domain best practices (via research-team)
3. **RESEARCH_ITERATE**: Agentic optimization using research findings and LLM self-critique
4. **EVALUATE**: Assesses results, recommends accept/refine/reject
5. **FINALIZE**: Applies recommendation

### Creation Mode
1. **INIT**: Creates workspace, detects creation mode
2. **CREATE**: Spawns context-engineer to create initial resource draft
3. **RESEARCH**: Investigates domain best practices
4. **RESEARCH_ITERATE**: Agentic optimization using research findings and LLM self-critique
5. **EVALUATE**: Assesses results, recommends accept/refine/reject
6. **FINALIZE**: Applies recommendation

## Output

Results saved to `workspace/{resource_id}/`:
- `run_state.json` - Current state (supports resume)
- `{resource_id}-v{N}.md` - Optimized version
- `reviews/v{N}_review.md` - Evaluation report

## Resume

If optimization was interrupted, simply re-run the same command - it will resume from the last checkpoint.

---
> Source: [andisab/casdk-harness](https://github.com/andisab/casdk-harness) — distributed by [TomeVault](https://tomevault.io).
<!-- tomevault:4.0:skill_md:2026-05-22 -->

讨论

基于 GitHub Discussions。登录 GitHub 即可参与讨论、点赞、订阅更新。