mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-18 13:33:53 +08:00
重构主控编排与运行时预热链路,统一工作区提示词/专家调度协议并补齐 wiki 记忆注入与写回闭环。
同时收敛启动与运维脚本默认行为(含 wiki worker)、更新 Admin 可观测性与相关测试,降低首轮时延并提高运行稳定性。 Made-with: Cursor
This commit is contained in:
parent
4a23b715a2
commit
dbbe3add6a
14438 changed files with 2693620 additions and 2546 deletions
|
|
@ -0,0 +1,51 @@
|
|||
# Example 13: Variables & Context
|
||||
#
|
||||
# This example demonstrates using let/const bindings to capture session
|
||||
# outputs and pass them as context to subsequent sessions.
|
||||
|
||||
# Define specialized agents for the workflow
|
||||
agent researcher:
|
||||
model: sonnet
|
||||
prompt: "You are a thorough research assistant who gathers comprehensive information on topics."
|
||||
|
||||
agent analyst:
|
||||
model: opus
|
||||
prompt: "You are a data analyst who identifies patterns, trends, and key insights."
|
||||
|
||||
agent writer:
|
||||
model: opus
|
||||
prompt: "You are a technical writer who creates clear, well-structured documents."
|
||||
|
||||
# Step 1: Gather initial research (captured in a variable)
|
||||
let research = session: researcher
|
||||
prompt: "Research the current state of quantum computing, including recent breakthroughs, major players, and potential applications."
|
||||
|
||||
# Step 2: Analyze the research findings (using research as context)
|
||||
let analysis = session: analyst
|
||||
prompt: "Analyze the key findings and identify the most promising directions."
|
||||
context: research
|
||||
|
||||
# Step 3: Get additional perspectives (refreshing context)
|
||||
let market-trends = session: researcher
|
||||
prompt: "Research market trends and commercial applications of quantum computing."
|
||||
context: []
|
||||
|
||||
# Step 4: Combine multiple contexts for final synthesis
|
||||
const report = session: writer
|
||||
prompt: "Write a comprehensive executive summary covering research, analysis, and market trends."
|
||||
context: [research, analysis, market-trends]
|
||||
|
||||
# Step 5: Iterative refinement with variable reassignment
|
||||
let draft = session: writer
|
||||
prompt: "Create an initial draft of the technical deep-dive section."
|
||||
context: research
|
||||
|
||||
# Refine the draft using its own output as context
|
||||
draft = session: writer
|
||||
prompt: "Review and improve this draft for clarity and technical accuracy."
|
||||
context: draft
|
||||
|
||||
# Final polish
|
||||
draft = session: writer
|
||||
prompt: "Perform final editorial review and polish the document."
|
||||
context: draft
|
||||
Loading…
Add table
Add a link
Reference in a new issue