Communitygithub.com

動態工作流模式

為Claude動態工作流及其他自適應代理工具設計任務局部化驅動、評估閘門及可重用技能提取。適用於構建任務局部化驅動、添加評估閘門或從臨時工作中提取可重用技能。

動態工作流模式 是什麼?

這個技能(動態工作流模式)旨在將動態工作流轉變為一個有紀律的系統,能為一次性任務生成臨時驅動、為重複工作提取共享技能,並為團隊提供可觀察的控制面板檢查點。它特別適用於Claude Code、Cursor或Codex等AI編碼代理,當任務需要自定義循環、評估器、爬蟲、監視器或本地儀表板時。技能的核心合約要求每個任務局部化驅動必須明確定義目標(包括不該做的事)、輸入(文件、URL、憑證策略)、輸出(提交、報告)、評估(至少一個通過/失敗檢查)以及交接(告訴後續操作者發生什麼的簡短工件)。它還提供了一個動態驅動決策樹和一個任務局部化驅動模板,幫助決定何時保留內聯、何時創建臨時驅動、何時提取為共享技能,以及何時添加控制面板可見性。此外,技能強調評估閘門的重要性,針對不同工作類型(代碼功能、UI、代理工作流、研究/內容、整合)提供了最低成本的評估閘門建議,並列出了常見的反模式,如生成隱藏決策邏輯的腳本、跳過測試、或在需要共享技能時創建一次性文檔。

相容平台✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/affaan-m/ECC/tree/main/skills/dynamic-workflow-mode

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

動態工作流模式 是做什麼的?

當編碼代理能夠生成或調整任務局部化驅動,而非僅遵循靜態指令流程時,使用此技能。目標是將動態工作流模式轉變為一個有紀律的系統:為一次性任務提供臨時驅動,為重複工作提取共享技能,並為團隊提供可觀察的控制面板檢查點。

何時啟用

  • 使用者提到動態工作流、自定義驅動、任務級驅動、自適應工作流或 Claude Code 動態工作流模式。
  • 任務需要自定義循環、評估器、爬蟲、固定數據產生器、監視器或本地儀表板。
  • 多個代理需要相同的可重複流程,但該流程尚未被捕捉為共享技能。
  • 工作流程需要持久的交接工件、評估證據或合併前的人工批准。

核心合約

動態工作流模式僅在任務局部化驅動比手動執行相同步驟更便宜、更安全時才應產生。驅動必須具備:

  • 目標:它負責的結果以及它明確不負責的結果。
  • 輸入:檔案、URL、提示、資料來源、憑證政策以及使用者提供的約束條件。
  • 輸出:提交、報告、螢幕截圖、狀態檔案或控制面板快照。
  • 評估:至少一個與任務相關的通過/失敗檢查,而不僅是「它運行過了」。
  • 交接:一個簡短的工件,告知下一個操作者發生了什麼、哪些被阻塞以及如何恢復。

動態驅動決策樹

  1. 一次性任務:保持內聯。不要發明驅動。
  2. 輸入變化的重複任務:創建任務局部化驅動,並將其保留在臨時或項目局部工作區中。
  3. 跨團隊或儲存庫的重複任務:將模式提取為共享技能。
  4. 涉及外部狀態、佇列或審批的任務:在添加更多自動化之前,先添加控制面板可見性。
  5. 有安全風險的任務:在自主執行之前添加評估閘門和人工合併閘門。

任務局部化驅動模板

在編寫代碼前使用此結構:

# 動態工作流驅動

目標:
- 應交付:
- 不應交付:

輸入:
- 儲存庫或工作區:
- 外部系統:
- 憑證政策:

循環:
1. 發現當前狀態。
2. 生成或更新最小的有用工件。
3. 執行評估檢查。
4. 記錄狀態和交接。
5. 在閘門失敗、歸屬不明確或外部動作不安全時停止。

評估:
- 指令:
- 預期通過信號:
- 失敗歸屬者:

交接:
- 狀態:
- 證據:
- 下一步動作:

共享技能提取

只有當以下條件中至少有兩項成立時,才將任務局部化驅動提升為共享技能:

  • 同一工作流程出現在多個工作階段、儲存庫、團隊或啟動中。
  • 工作流程需要特定的語言、工具或安全順序。
  • 由於操作者跳過閘門或丟失上下文,導致失敗反覆發生。
  • 工作流程具有穩定的輸入/輸出合約。
  • 工作流程受益於控制面板、狀態板或團隊交接。

提取時,首先在 skills/<name>/SKILL.md 中編寫技能。僅當仍需要傳統的斜線入口表面時,才添加指令 shim。

控制面板檢查點

動態工作流模式在暴露狀態時才能被團隊使用。每當任務跨越超過一個工作階段時,記錄這些檢查點:

  • 計劃:目標、負責人、驗收標準以及有風險的外部系統。
  • 佇列:工作項目、分配的代理角色、分支/工作樹以及依賴邊。
  • 運行:活躍的驅動、當前循環步驟、最近的評估結果以及可用的代幣/成本信號。
  • 閘門:測試結果、瀏覽器螢幕截圖、安全性審查以及合併就緒狀態。
  • 交接:已完成的事項、失敗的事項以及需要人工決策的事項。

如果儲存庫已啟用 ECC2 狀態,則優先通過 ECC 控制面板或狀態儲存支援的腳本添加或讀取檢查點,而不是散落未追蹤的筆記。

評估閘門

每個動態驅動都需要一個任務特定的評估。選擇最便宜且可靠的閘門:

工作類型評估閘門
代碼功能重點測試、lint、覆蓋率以及一個整合路徑
UI/控制面板帶有螢幕截圖及溢位/錯誤檢查的瀏覽器煙霧測試
代理工作流固定數據逐字稿或帶有預期路由的播種工作項目
研究/內容中立來源摘要、主張檢查清單以及可發布的大綱
整合試運行指令、配置驗證以及無秘密掃描

在評估可以被另一位團隊成員重新執行之前,不要聲稱動態工作流是可重用的。

反模式

  • 生成隱藏真實決策邏輯的腳本,使操作者無法察覺。
  • 將動態工作流模式視為跳過測試的許可。
  • 在需要共享技能或狀態工件時創建一次性文件。
  • 在沒有歸屬、合併閘門或衝突政策的情況下運行多個代理。
  • 將原始私人研究數據洩漏到公開文件中。

輸出標準

結束時提供:

  • 驅動或技能路徑。
  • 評估指令和結果。
  • 控制面板或交接工件路徑。
  • 下一個可重用的提取候選項。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

accessibility

Design, implement, and audit inclusive digital products using WCAG 2.2 Level AA. Use when building or auditing UI that must meet WCAG 2.2 Level AA, or when reviewing a change for keyboard, contrast, or screen-reader support.

affaan-m/content-engine

Create platform-native content systems for X, LinkedIn, TikTok, YouTube, newsletters, and repurposed multi-platform campaigns. Use when the user wants social posts, threads, scripts, content calendars, or one source asset adapted cleanly across platforms.

affaan-m/ECC

Multi-platform content distribution across X, LinkedIn, Threads, and Bluesky. Adapts content per platform using content-engine patterns. Never posts identical content cross-platform. Use when the user wants to distribute content across social platforms.

affaan-m/fal-ai-media

Unified media generation via fal.ai MCP — image, video, and audio. Covers text-to-image (Nano Banana), text/image-to-video (Seedance, Kling, Veo 3), text-to-speech (CSM-1B), and video-to-audio (ThinkSound). Use when the user wants to generate images, videos, or audio with AI.

affaan-m/manim-video

日本語翻訳:このファイルは manim-video 用の日本語翻訳が必要です

affaan-m/remotion-video-creation

Remotion のベストプラクティス - React で動画を作成する。3D、アニメーション、音声、字幕、チャート、トランジションなどをカバーするドメイン固有の29のルール。

affaan-m/video-editing

AI-assisted video editing workflows for cutting, structuring, and augmenting real footage. Covers the full pipeline from raw capture through FFmpeg, Remotion, ElevenLabs, fal.ai, and final polish in Descript or CapCut. Use when the user wants to edit video, cut footage, create vlogs, or build video content.

agent-architecture-audit

Full-stack diagnostic for agent and LLM applications. Audits the 12-layer agent stack for wrapper regression, memory pollution, tool discipline failures, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes. Essential for developers building agent applications, autonomous loops, or any LLM-powered feature. Use when an agent or LLM feature misbehaves and the failing layer is unknown, or before shipping an agent stack.

agent-eval

Head-to-head comparison of coding agents (Claude Code, Aider, Codex, etc.) on custom tasks with pass rate, cost, time, and consistency metrics. Use when choosing between coding agents, or when a change to an agent setup needs measured pass rate, cost, and time rather than an impression.

agent-harness-construction

Design and optimize AI agent action spaces, tool definitions, and observation formatting for higher completion rates. Use when defining or revising an agent

agentic-engineering

Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing. Use when planning or executing engineering work that agents will carry out end to end.

agentic-os

Build persistent multi-agent operating systems on Claude Code. Covers kernel architecture, specialist agents, slash commands, file-based memory, scheduled automation, and state management without external databases. Use when building a persistent multi-agent system on Claude Code with its own memory, commands, and scheduling.

agent-introspection-debugging

Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports. Use when an agent run fails and you need a reproducible diagnosis instead of a retry.

agent-payment-x402

Add x402 payment execution to AI agents with per-task budgets, spending controls, and non-custodial wallets. Supports Base through agentwallet-sdk and X Layer through OKX Payments / OKX Agent Payments Protocol. Use when an agent must pay for something itself and needs per-task budgets, spending controls, and a non-custodial wallet.

agent-self-evaluation

Use after completing any non-trivial task. The agent self-rates its output on 5 axes — accuracy, completeness, clarity, actionability, conciseness — with concrete evidence per criterion. Produces a structured 1-5 scorecard with specific improvement suggestions.

agent-sort

Build an evidence-backed ECC install plan for a specific repo by sorting skills, commands, rules, hooks, and extras into DAILY vs LIBRARY buckets using parallel repo-aware review passes. Use when ECC should be trimmed to what a project actually needs instead of loading the full bundle.

ai-first-engineering

Engineering operating model for teams where AI agents generate a large share of implementation output. Use when setting team process, review gates, or ownership rules for a codebase largely written by agents.

ai-regression-testing

Regression testing strategies for AI-assisted development. Sandbox-mode API testing without database dependencies, automated bug-check workflows, and patterns to catch AI blind spots where the same model writes and reviews code. Use when adding regression coverage to AI-assisted code, or when the same model both wrote and reviewed a change.

android-clean-architecture

Clean Architecture patterns for Android and Kotlin Multiplatform projects — module structure, dependency rules, UseCases, Repositories, and data layer patterns. Use when structuring modules, layers, or data flow in an Android or KMP project.

angular-developer

Generates Angular code and provides architectural guidance. Trigger when creating projects, components, or services, or for best practices on reactivity (signals, linkedSignal, resource), forms, dependency injection, routing, SSR, accessibility (ARIA), animations, styling (component styles, Tailwind CSS), testing, or CLI tooling.

相關技能