# KingClawArmy - Pipeline 與排程 > 平台:Paperclip > 日期:2026-04-10 --- ## 1. 量化研究 Pipeline 量化策略師主導整個 pipeline,CEO 只管啟動和例外處理。 ``` CEO → 量化策略師(pipeline owner) │ ├─ 財經情報研究員 │ └─ Finance_Research_Brief.json │ ├─ 市場結構研究員(等情報完成) │ └─ Market_Structure_Report.json │ ├─ 多方研究員 ──┐ ├─ 空方研究員 ──┘ 並行 │ └─ Bullish_Brief.json / Bearish_Brief.json │ ├─ 策略師收斂 │ └─ Strategy_Thesis.json │ ├─ 審查員 │ ├─ pass → 繼續 │ ├─ revise → 重跑被退回角色(最多 3 輪) │ └─ block → escalate CEO │ ├─ 資料分析師(審查 pass 後) │ └─ Data_Analysis_Report.json │ └─ CEO → 董事長審批 ``` ### Pipeline 步驟定義 | Step | Agent | 依賴 | 輸出 | |---|---|---|---| | intel | finance-researcher | — | Finance_Research_Brief.json | | structure | market-structure-researcher | intel | Market_Structure_Report.json | | bull | bullish-researcher | structure | Bullish_Brief.json | | bear | bearish-researcher | structure | Bearish_Brief.json | | converge | quant-strategist | bull, bear | Strategy_Thesis.json | | review | reviewer | converge | Review_Report.json | | analysis | data-analyst | review (pass) | Data_Analysis_Report.json | | approve | HITL (董事長) | analysis | — | ### 例外處理 | 情況 | 處理方式 | |---|---| | revise(審查退回) | 重新指派被退回的 agent,帶上修改意見,最多 3 輪 | | block(審查否決) | escalate 到 CEO,CEO 通知董事長 | | revise 超過 3 輪 | escalate 到 CEO,CEO 通知董事長 | | agent 執行超時 | 重新指派,帶上 timeout 通知 | | agent 回傳 missing_fields | 重新指派,明確要求補齊 | --- ## 2. 排程(Routines) 時區統一:`Asia/Taipei` ### .paperclip.yaml routines 定義 ```yaml routines: daily-quant-pipeline: triggers: - kind: schedule cronExpression: "30 7 * * 1-5" timezone: Asia/Taipei enabled: true # CEO 啟動量化 pipeline daily-post-market: triggers: - kind: schedule cronExpression: "30 18 * * 1-5" timezone: Asia/Taipei enabled: true # CEO spawn 財經情報研究員做盤後整理 daily-market-intel: triggers: - kind: schedule cronExpression: "0 10 * * *" timezone: Asia/Taipei enabled: true # 市場研究員每日市場情報 weekly-market-report: triggers: - kind: schedule cronExpression: "0 9 * * 1" timezone: Asia/Taipei enabled: true # 市場研究員每週市場分析報告 daily-ads-check: triggers: - kind: schedule cronExpression: "30 9 * * *" timezone: Asia/Taipei enabled: true # 投放分析師每日 KPI 檢查 daily-data-summary: triggers: - kind: schedule cronExpression: "0 20 * * *" timezone: Asia/Taipei enabled: true # 資料分析師每日資料摘要 weekly-data-report: triggers: - kind: schedule cronExpression: "0 10 * * 1" timezone: Asia/Taipei enabled: true # 資料分析師每週數據報告 ``` ### 排程對應 Agent | Routine | Agent | 頻率 | 說明 | |---|---|---|---| | daily-quant-pipeline | ceo | 週一至五 07:30 | 盤前啟動量化 pipeline | | daily-post-market | ceo | 週一至五 18:30 | 盤後情報整理 | | daily-market-intel | market-researcher | 每日 10:00 | 每日市場情報 | | weekly-market-report | market-researcher | 每週一 09:00 | 每週市場分析 | | daily-ads-check | ads-analyst | 每日 09:30 | 投放 KPI 檢查 | | daily-data-summary | data-analyst | 每日 20:00 | 每日資料摘要 | | weekly-data-report | data-analyst | 每週一 10:00 | 每週數據報告 | --- ## 3. 審批機制(HITL) 以下動作需要董事長批准: | 需要審批的事 | 觸發者 | |---|---| | 量化策略正式執行 | CEO | | 正式部署 | CEO | | DB schema 變更 | CEO | | 廣告正式發布 | CEO | | 對外訊息發送 | CEO | | 金流操作 | CEO | ### Review Gate | 必審節點 | 觸發方式 | 審查標準 | |---|---|---| | 量化策略提交 | 策略師指派審查員 | schema 完整性 + 風控邏輯 | | 回測結果提交 | 策略師指派審查員 | 績效指標合理性 | | 工程交付 | CEO 指派審查員 | 程式碼品質 + 測試覆蓋 | | 文案對外 | CEO 指派審查員 | 品牌一致性 + 法規合規 | --- ## 4. 模型分級 搭配 GPT 與 Claude 雙模型,依任務特性分配: | 等級 | GPT 模型 | Claude 模型 | 適用 Agent | |---|---|---|---| | reasoning-heavy | gpt-5.4 | claude-opus-4-6 | CEO, 審查員, 策略師, 市場結構研究員, 多方/空方研究員, 策略總監 | | general | gpt-5.4-mini | claude-sonnet-4-6 | 秘書, 投放分析師, 資料分析師, 小安 | | research | gpt-5.4-mini | claude-haiku-4-5 | 財經情報研究員, 市場研究員 | | coder | gpt-5.4 | claude-sonnet-4-6 | 回測工程師 | | creative | gpt-5.4 | claude-sonnet-4-6 | 文案撰寫員, 創意總監 | 每個 agent 可在 `.paperclip.yaml` 中指定主要使用的模型,視任務需求切換。 --- ## 5. 成本控制 | 策略 | 做法 | |---|---| | 模型分級 | 日常用 research/general,策略收斂才用 reasoning-heavy | | 排程頻率合理 | 不需要的 agent 不排太密的 cron | | review 輪數上限 | revise 最多 3 輪,超過 escalate | | 記憶壓縮 | 定期壓縮避免 context 膨脹 |