论文审查
- 作者仓库星标 3,783
- 作者更新于 实时读取
- 作者仓库 Continuous-Claude-v3
- 领域
- AI 智能
- 兼容 Agent
-
- Claude Code
- Cursor
- Cline
- Codex
- Windsurf
- Gemini CLI
- +20
- 信任分
- 88 / 100 · 社区维护
- 作者 / 版本 / 许可
- @parcadei · 未声明 license
- Token 消耗评级
- 低消耗
- 接入复杂程度
- 即装即用
- 是否需要外部 API Key
- 不需要
- 兼容的系统
- 未声明(默认跨平台)
- 底层运行要求
- Python
- 文件与系统权限
-
- 只读
- 允许写入 / 修改
- 网络行为
- 仅限本地
- 安装命令数
- 26 条
档案由构建时根据 SKILL.md 与安装命令自动衍生,可能与作者实际意图存在差异。
需要注意: 未限定 allowed-tools,默认拥有全部工具权限。
---
name: agentica-prompts
description: Write reliable prompts for Agentica/REPL agents that avoid LLM instruction ambiguity Write promp…
category: AI 智能
runtime: Python
---
# agentica-prompts 输出预览
## PART A: 任务判断
- 适用问题:提示词、Agent 工作流、模型评估或自动化推理。
- 输入要求:目标材料、限制条件、期望输出和验收方式。
- 证据边界:围绕“The Orchestration Pattern / Agent System Prompt Template / AGENT IDENTITY”读取原文规则,不把推断写成作者承诺。
## PART B: 执行结果
- **01** 任务判断:确认你的需求是否属于提示词、Agent 工作流、模型评估或自动化推理,并标出输入、限制和预期结果。
- **02** 执行计划:优先按“The Orchestration Pattern / Agent System Prompt Template / AGENT IDENTITY”拆成步骤,说明每一步会读取什么、修改什么、产出什么。
- **03** 交付结果:给出可复制的命令、文件改动、检查清单或内容草稿,并说明如何继续迭代。
- **04** 风险边界:结合 读取文件、写入/修改文件、主要在本地完成、通常不需要额外 API Key 给出执行前确认项。
## Running Rules
- 读取文件、写入/修改文件;主要在本地完成;通常不需要额外 API Key。
- 先小样例验证,再放大到真实任务。
- 交付时同时给结果、检查口径和下一步迭代建议。 原文没有稳定的斜杠命令要求。安装验证后通常全局生效,直接在对话里点名这个 Skill 并描述任务即可。
告诉 Agent 目标文件或材料、期望结果、不可改范围、是否允许联网或执行命令。本 Skill 的权限画像是:读取文件、写入/修改文件。
先用一个小任务确认它会围绕“The Orchestration Pattern / Agent System Prompt Template / AGENT IDENTITY”工作;涉及文件或命令时,先看 diff、日志、预览或测试结果。
检查最终产物是否包含明确结果、必要证据和下一步动作;如果输出泛泛而谈,就补充输入、边界和验收标准后重跑。
---
name: agentica-prompts
description: Write reliable prompts for Agentica/REPL agents that avoid LLM instruction ambiguity Write promp…
category: AI 智能
source: parcadei/Continuous-Claude-v3
---
# agentica-prompts
## 什么时候使用
- 把 AI / Agent方向的常用动作沉淀成 Agent 可调用的技能 适合处理AI Agent、提示词、模型评估与自动化推理,核心价值是把输入、判断、执行、验证和交付边界固定下来,避免 Agent 泛泛回答。 把任务拆成可执行、可检查…
- 面向提示词、Agent 工作流、模型评估或自动化推理,优先处理能明确输入、步骤和验收标准的工作。
## 需要提供什么
- 目标材料、目录范围、期望结果和不可改动内容。
- 是否允许联网、执行命令、读写文件或调用外部服务。
## 执行规则
- 围绕「The Orchestration Pattern / Agent System Prompt Template / AGENT IDENTITY」组织步骤,不把推断写成作者事实。
- 读取文件、写入/修改文件;主要在本地完成;通常不需要额外 API Key。
- 先跑小样例,确认结果可检查后再扩大任务范围。
## 输出要求
- 给出最终产物、关键证据、验证方式和下一步动作。
- 信息不足时标记 unknown,不编造命令、平台或依赖。 作者原文负责流程事实;仓库文件负责来源和命令;流狐只补充适用场景、限制和质量判断。
skill "agentica-prompts" {
输入层 -> 用户目标 + 目标文件 + 禁止范围 + 验收标准
上下文层 -> The Orchestration Pattern / Agent System Prompt Template / AGENT IDENTITY
规则层 -> SKILL.md 触发条件 / 执行顺序 / 输出格式
运行层 -> Python | 读取文件、写入/修改文件 | 主要在本地完成
安全层 -> 通常不需要额外 API Key + 小任务验证 + diff / 日志复核
输出层 -> 可复制结果 + 检查清单 + 下一步迭代
} Agentica Prompt Engineering
Write prompts that Agentica agents reliably follow. Standard natural language prompts fail ~35% of the time due to LLM instruction ambiguity.
The Orchestration Pattern
Proven workflow for context-preserving agent orchestration:
1. RESEARCH (Nia) → Output to .claude/cache/agents/research/
↓
2. PLAN (RP-CLI) → Reads research, outputs .claude/cache/agents/plan/
↓
3. VALIDATE → Checks plan against best practices
↓
4. IMPLEMENT (TDD) → Failing tests first, then pass
↓
5. REVIEW (Jury) → Compare impl vs plan vs research
↓
6. DEBUG (if needed) → Research via Nia, don't assume
Key: Use Task (not TaskOutput) + directory handoff = clean context
Agent System Prompt Template
Inject this into each agent's system prompt for rich context understanding:
## AGENT IDENTITY
You are {AGENT_ROLE} in a multi-agent orchestration system.
Your output will be consumed by: {DOWNSTREAM_AGENT}
Your input comes from: {UPSTREAM_AGENT}
## SYSTEM ARCHITECTURE
You are part of the Agentica orchestration framework:
- Memory Service: remember(key, value), recall(query), store_fact(content)
- Task Graph: create_task(), complete_task(), get_ready_tasks()
- File I/O: read_file(), write_file(), edit_file(), bash()
Session ID: {SESSION_ID} (all your memory/tasks scoped here)
## DIRECTORY HANDOFF
Read your inputs from: {INPUT_DIR}
Write your outputs to: {OUTPUT_DIR}
Output format: Write a summary file and any artifacts.
- {OUTPUT_DIR}/summary.md - What you did, key findings
- {OUTPUT_DIR}/artifacts/ - Any generated files
## CODE CONTEXT
{CODE_MAP} <- Inject RepoPrompt codemap here
## YOUR TASK
{TASK_DESCRIPTION}
## CRITICAL RULES
1. RETRIEVE means read existing content - NEVER generate hypothetical content
2. WRITE means create/update file - specify exact content
3. When stuck, output what you found and what's blocking you
4. Your summary.md is your handoff to the next agent - be precise
Pattern-Specific Prompts
Swarm (Research)
## SWARM AGENT: {PERSPECTIVE}
You are researching: {QUERY}
Your unique angle: {PERSPECTIVE}
Other agents are researching different angles. You don't need to be comprehensive.
Focus ONLY on your perspective. Be specific, not broad.
Output format:
- 3-5 key findings from YOUR perspective
- Evidence/sources for each finding
- Uncertainties or gaps you identified
Write to: {OUTPUT_DIR}/{PERSPECTIVE}/findings.md
Hierarchical (Coordinator)
## COORDINATOR
Task to decompose: {TASK}
Available specialists (use EXACTLY these names):
{SPECIALIST_LIST}
Rules:
1. ONLY use specialist names from the list above
2. Each subtask should be completable by ONE specialist
3. 2-5 subtasks maximum
4. If task is simple, return empty list and handle directly
Output: JSON list of {specialist, task} pairs
Generator/Critic (Generator)
## GENERATOR
Task: {TASK}
{PREVIOUS_FEEDBACK}
Produce your solution. The Critic will review it.
Output structure (use EXACTLY these keys):
{
"solution": "your main output",
"code": "if applicable",
"reasoning": "why this approach"
}
Write to: {OUTPUT_DIR}/solution.json
Generator/Critic (Critic)
## CRITIC
Reviewing solution at: {SOLUTION_PATH}
Evaluation criteria:
1. Correctness - Does it solve the task?
2. Completeness - Any missing cases?
3. Quality - Is it well-structured?
If APPROVED: Write {"approved": true, "feedback": "why approved"}
If NOT approved: Write {"approved": false, "feedback": "specific issues to fix"}
Write to: {OUTPUT_DIR}/critique.json
Jury (Voter)
## JUROR #{N}
Question: {QUESTION}
Vote independently. Do NOT try to guess what others will vote.
Your vote should be based solely on the evidence.
Output: Your vote as {RETURN_TYPE}
Verb Mappings
| Action | Bad (ambiguous) | Good (explicit) |
|---|---|---|
| Read | "Read the file at X" | "RETRIEVE contents of: X" |
| Write | "Put this in the file" | "WRITE to X: {content}" |
| Check | "See if file has X" | "RETRIEVE contents of: X. Contains Y? YES/NO." |
| Edit | "Change X to Y" | "EDIT file X: replace 'old' with 'new'" |
Directory Handoff Mechanism
Agents communicate via filesystem, not TaskOutput:
# Pattern implementation
OUTPUT_BASE = ".claude/cache/agents"
def get_agent_dirs(agent_id: str, phase: str) -> tuple[Path, Path]:
"""Return (input_dir, output_dir) for an agent."""
input_dir = Path(OUTPUT_BASE) / f"{phase}_input"
output_dir = Path(OUTPUT_BASE) / agent_id
output_dir.mkdir(parents=True, exist_ok=True)
return input_dir, output_dir
def chain_agents(phase1_id: str, phase2_id: str):
"""Phase2 reads from phase1's output."""
phase1_output = Path(OUTPUT_BASE) / phase1_id
phase2_input = phase1_output # Direct handoff
return phase2_input
Anti-Patterns
| Pattern | Problem | Fix |
|---|---|---|
| "Tell me what X contains" | May summarize or hallucinate | "Return the exact text" |
| "Check the file" | Ambiguous action | Specify RETRIEVE or VERIFY |
| Question form | Invites generation | Use imperative "RETRIEVE" |
| "Read and confirm" | May just say "confirmed" | "Return the exact text" |
| TaskOutput for handoff | Floods context with transcript | Directory-based handoff |
| "Be thorough" | Subjective, inconsistent | Specify exact output format |
Expected Improvement
- Without fixes: ~60% success rate
- With RETRIEVE + explicit return: ~95% success rate
- With structured tool schemas: ~98% success rate
- With directory handoff: Context preserved, no transcript pollution
Code Map Injection
Use RepoPrompt to generate code map for agent context:
# Generate codemap for agent context
rp-cli --path . --output .claude/cache/agents/codemap.md
# Inject into agent system prompt
codemap=$(cat .claude/cache/agents/codemap.md)
Memory Context Injection
Explain the memory system to agents:
## MEMORY SYSTEM
You have access to a 3-tier memory system:
1. **Core Memory** (in-context): remember(key, value), recall(query)
- Fast key-value store for current session facts
2. **Archival Memory** (searchable): store_fact(content), search_memory(query)
- FTS5-indexed long-term storage
- Use for findings that should persist
3. **Recall** (unified): recall(query)
- Searches both core and archival
- Returns formatted context string
All memory is scoped to session_id: {SESSION_ID}
References
- ToolBench (2023): Models fail ~35% retrieval tasks with ambiguous descriptions
- Gorilla (2023): Structured schemas improve reliability by 3x
- ReAct (2022): Explicit reasoning before action reduces errors by ~25%
先判断是否适合
作者设计意图
作者的方法与取舍
边界和复核