OrchestralFlow 🎼
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
**Autonomous Agent Orchestration Layer — Scaling Claude Code from Solo Instruments to Full Symphonies**
Inspired by the paradigm shift between *dynamic-workflows-claude-code*, where skills, subagents, agent teams, and cost ladders define the frontier of autonomous code generation, **OrchestralFlow** reimagines the entire pipeline as a living musical score. Instead of managing workflows as rigid DAGs or isolated prompts, you conduct an ensemble of specialized agents that improvise within structured movements—balancing cost, complexity, and creative depth like a composer balancing orchestral sections.
**OrchestralFlow** is a zero-dependency, declarative orchestration framework that translates Claude Code's latent multi-agent capabilities into a scalable, cost-aware, and dynamically reconfigurable system. Think of it as the difference between a solo pianist (single agent) and a full symphony: each section (strings, woodwinds, brass, percussion) has its own voice, yet all follow the same conductor's baton—your /goal.
---
🧠 The Core Insight: From Tools to Instruments
Claude Code (Opus 4.8) offers unprecedented depth in reasoning and code generation. But raw power without orchestration leads to expensive, incoherent outputs—like an orchestra playing without a score. **OrchestralFlow** introduces the **Cost Ladder**: an explicit hierarchy of agent capabilities and associated token costs. You don't just assign tasks; you assign them to the right *instrument* at the right *price point*.
**Key differentiators from traditional workflow engines:**
- **No dependency hell** – zero external packages, pure Claude Code native
- **Dynamic agent team assembly** per /goal context, not per static config
- **Cost-aware routing** – the system automatically escalates complex sub-tasks to more capable agents and defers simple lookups to lightweight "tutti" agents
- **/goal vs. Workflow** – a /goal is an intent; a Workflow is a composed movement. OrchestralFlow bridges both in real-time
---
🎻 Overview: The Anatomy of an Orchestral Score
| Component | Analogy | Function in OrchestralFlow |
|-----------|---------|----------------------------|
| /goal | The Conductor's Baton | High-level intent declaration; the "why" behind the code |
| Skills | Instrument Techniques | Atomic capabilities (refactoring, testing, documentation) |
| Subagents | Section Players | Specialized agents (frontend, backend, security) |
| Agent Teams | Orchestral Sections | Groups of subagents that harmonize on a movement |
| Cost Ladder | Dynamic Dynamics | Real-time cost optimization per sub-task complexity |
---
🚀
---
🎯 Key Features
1. 🎼 **Dynamic Score Generation**
Your /goal is parsed into a **Generative Score** – a living blueprint that grows as the system discovers new sub-tasks. Unlike static JSON workflows, OrchestralFlow's score can modulate key (change agent team composition) mid-execution based on unexpected complexity.
2. 💸 **Cost Ladder Automation**
Each sub-task is evaluated on a **novelty-complexity matrix**. Simple lookups (e.g., "what is the syntax for async/await in Python?") route to a **Tutti Agent** (lowest cost). Architectural decisions route to a **Soloist Agent** (medium cost). Meta-reasoning and cross-cutting concerns route to the **Conductor Agent** (highest cost). This ladder is recalculated dynamically every 5 movements.
3. 🧩 **UltraCode Compression**
Inspired by the UltraCode concept, OrchestralFlow includes an **UltraCode Transformer** – a lossless compression layer that reduces prompt token cost by up to 40% without sacrificing context. It works by identifying repeated structural patterns and encoding them as "musical motifs" that agents recognize and expand in-place.