orchestrator

ingpoc's avatarfrom ingpoc

Use when managing agent state transitions (START/INIT/IMPLEMENT/TEST/COMPLETE), triggering context compression at 80% capacity, or handling session lifecycle. Load at session start, on state change, or when context exceeds threshold. Core skill for single-orchestrator architecture.

⭐5stars🔀0forks📁View on GitHub🕐Updated Jan 2, 2026

When & Why to Use This Skill

The Orchestrator skill provides a robust state-machine framework designed for managing complex AI agent workflows within a single-orchestrator architecture. It automates the lifecycle of agent tasks—ranging from initialization to final implementation—while optimizing performance through intelligent context compression at 80% capacity. By enforcing strict state transitions and managing session persistence, this skill ensures that AI agents remain reliable, efficient, and context-aware during long-running or multi-stage operations.

Use Cases

  • Software Development Lifecycle: Managing an agent's progression through INIT, IMPLEMENT, and TEST phases to ensure code is verified before completion.
  • Context Limit Management: Automatically triggering context compression and summarization when token usage reaches the 80% threshold, preventing session crashes or performance degradation.
  • Session Recovery and Resumption: Utilizing state-machine logs to resume interrupted tasks with a fresh context and summary, ensuring no progress is lost in long-running workflows.
  • Workflow Validation: Enforcing logical state transitions (e.g., preventing an agent from moving to 'COMPLETE' without passing 'TEST') to maintain high-quality output and operational guardrails.
nameorchestrator
description"Use when managing agent state transitions (START/INIT/IMPLEMENT/TEST/COMPLETE), triggering context compression at 80% capacity, or handling session lifecycle. Load at session start, on state change, or when context exceeds threshold. Core skill for single-orchestrator architecture."
keywordsstate-machine, compression, session, transitions, context-management

Orchestrator

State machine management for single-orchestrator architecture.

Instructions

  1. Check current state: scripts/check-state.sh
  2. Validate transition allowed: scripts/validate-transition.sh FROM TO
  3. Load skill for current state
  4. Execute until exit conditions (code verified, not judged)
  5. Compress when scripts/check-context.sh returns threshold exceeded

State → Skill Mapping

State Load Skill
INIT initialization/
IMPLEMENT implementation/
TEST testing/
COMPLETE context-graph/

References

File Load When
references/state-machine.md Designing state transitions
references/compression.md Context exceeds 50% (progressive checkpoints)
references/session-management.md Session start/recovery
references/session-resumption.md Resuming with fresh context + summary

Scripts

Script Purpose Output
scripts/check-state.sh Get current state JSON state
scripts/validate-transition.sh Check if transition valid exit 0/1
scripts/check-context.sh Check context usage threshold level
scripts/enter-state.sh Transition to new state Updated state.json