Agent Teams Lite Documentation

repository·main·Indexed 22 days ago

https://github.com/gentleman-programming/agent-teams-lite

A deprecated project for agent orchestration and skill management, now replaced by gentle-ai. It utilizes a delegate-only Orchestrator to coordinate specialized sub-agents (such as EXPLORE, PROPOSE, and VERIFY) through a structured dependency graph. The system features a Skill Registry for project conventions, a pluggable store for artifact persistence (engram, openspec, hybrid, or none), and a Spec-Driven Development archive cycle using Delta Specs and RFC 2119 keywords.

Tokens
33K
Snippets
52
Records
133
Agent score
78%

What's inside Agent Teams Lite

  1. Project structure and skill organization

    main

    The repository is organized into functional areas:

    • skills/: Contains the core logic for all agents. Each skill is defined in a SKILL.md file.
      • _shared/: Contains shared conventions like persistence-contract.md, engram-convention.md, openspec-convention.md, and skill-resolver.md.
      • Individual skill directories (e.g., sdd-apply/, sdd-verify/) contain the specific instructions for that agent.
    • examples/: Provides configuration files for various tools (Claude Code, OpenCode, Gemini CLI, Cursor, etc.).
    • scripts/: Contains setup and installation scripts for Unix (.sh) and Windows (.ps1).

    Note on Generated Files: When used in a target project, a .atl/skill-registry.md file is automatically generated to serve as the skill catalog for sub-agents.

  2. What is the judgment-day skill and when to use it

    main

    The judgment-day skill is a parallel adversarial review protocol. It launches two independent, blind judge sub-agents simultaneously to review a target (code, features, or architecture). The orchestrator synthesizes their findings, applies fixes via a separate agent, and re-judges the target. This process repeats for a maximum of 2 fix iterations before escalating to a human.

    Use this skill when:

    • You explicitly trigger it (e.g., saying "judgment day", "review adversarial", or "dual review").
    • You need high-confidence review before merging significant implementations.
    • You want to catch edge cases or blind spots that a single reviewer might miss.
    • The cost of a production bug outweighs the cost of two review rounds.
  3. Use Delta Specs to describe requirement changes

    main

    Instead of rewriting entire specification files, use Delta Specs to describe only what has changed. This allows for incremental updates that are eventually merged into the main specifications.

    There are two primary types of deltas:

    1. ADDED Requirements: Used to introduce new functionality. Use the ## ADDED Requirements heading followed by the new requirement and its associated scenarios.
    2. MODIFIED Requirements: Used to update existing functionality. Use the ## MODIFIED Requirements heading, state the new requirement, and include a note about the previous state (e.g., (Previously: ...)).

    Once a change is archived, these deltas are automatically merged into the main specs.

    ## ADDED Requirements
    
    ### Requirement: CSV Export
    The system SHALL support exporting data to CSV format.
    
    #### Scenario: Export all observations
    - GIVEN the user has observations stored
    - WHEN the user requests CSV export
    - THEN a CSV file is generated with all observations
    - AND column headers match the observation fields
    
    ## MODIFIED Requirements
    
    ### Requirement: Data Export
    The system SHALL support multiple export formats.
    (Previously: The system SHALL support JSON export.)
  4. Understand sdd-tasks artifact modes and persistence

    main

    The sdd-tasks skill operates in different modes that dictate how it reads input and where it saves the resulting tasks.md file. The orchestrator provides the artifact store mode to the agent.

    ModeInput Source (Read)Output Destination (Write)
    engramsdd/{change-name}/proposal, sdd/{change-name}/spec, sdd/{change-name}/designsdd/{change-name}/tasks
    openspecFollows skills/_shared/openspec-convention.mdopenspec/changes/{change-name}/tasks.md
    hybridPrimary: Engram; Fallback: FilesystemPersists to BOTH Engram AND openspec/changes/{change-name}/tasks.md
    noneN/AReturns result only; no files created

    Note: If mode is openspec or hybrid, the agent creates a directory structure under openspec/changes/{change-name}/ containing the proposal, specs, design, and the newly created tasks.md.

  5. How Agent Teams Lite orchestration works

    main

    Agent Teams Lite uses a delegate-only Orchestrator to manage a sequence of specialized sub-agents. The Orchestrator does not perform real work; instead, it coordinates tasks, tracks state, and asks for user approval between phases.

    Key Components

    • Orchestrator: The coordinator. It launches sub-agents via a Task tool, shows summaries to the user, and manages the dependency graph. It uses minimal context (only state and summaries).
    • Sub-agents: Specialized workers (e.g., EXPLORE, PROPOSE, SPEC, DESIGN, TASKS, APPLY, VERIFY, ARCHIVE) that receive pre-resolved compact rules from the Orchestrator to execute specific phases.
    • Skill Registry: An auto-discovered catalog of coding skills and project conventions (defined in agents.md) that sub-agents use to follow project-specific patterns.
    • Pluggable Store: A mechanism to persist artifacts using modes like engram, openspec, hybrid, or none.
  6. Understand sdd-spec artifact modes and persistence

    main

    The sdd-spec skill operates under different artifact store modes, which dictate how the agent reads existing specifications and where it saves new ones.

    ModeRead BehaviorPersistence Behavior
    engramRead sdd/{change-name}/proposal.Concatenate into a single artifact with domain headers. Save as sdd/{change-name}/spec.
    openspecRead openspec/specs/{domain}/spec.md.Create files in openspec/changes/{change-name}/specs/{domain}/spec.md.
    hybridRead openspec/specs/{domain}/spec.md.Follow BOTH: Persist to Engram AND write domain files to the filesystem.
    noneNo reading.Return result only. Never create or modify project files.
  7. Understand the `sdd-archive` skill purpose and triggers

    main

    The sdd-archive skill is a sub-agent responsible for completing the Software Design Document (SDD) cycle. Its primary purpose is to merge delta specifications into the main specifications (the source of truth) and then move the completed change folder to an archive.

    Trigger: This skill is launched by the orchestrator after a change has been implemented and verified.

  8. Understand the Agent Teams Lite Orchestrator role

    main

    The sdd-orchestrator is a COORDINATOR, not an executor. Its primary responsibility is to maintain a thin conversation thread, delegate all substantive work to specialized sub-agents, and synthesize their results.

    Delegation Rules

    To prevent context inflation, follow these guidelines for deciding when to act inline versus when to delegate:

    ActionInlineDelegate
    Read to decide/verify (1-3 files)
    Read to explore/understand (4+ files)
    Read as preparation for writing✅ together with the write
    Write atomic (one file, mechanical)
    Write with analysis (multiple files, new logic)
    Bash for state (git, gh)
    Bash for execution (test, build, install)

    Anti-patterns to avoid:

    • Reading 4+ files to "understand" the codebase inline (delegate an exploration instead).
    • Writing a feature across multiple files inline (delegate the task).
    • Running tests or builds inline (delegate the execution).
    • Reading files as preparation for edits, then editing (delegate the whole process together).
  9. Synthesize Verdicts (Pattern 2)

    main

    After both delegation_read calls return, the orchestrator compares the results to categorize findings:

    Result TypeDefinitionAction
    ConfirmedFound by BOTH agentsHigh confidence; fix immediately
    Suspect AFound ONLY by Judge ANeeds triage
    Suspect BFound ONLY by Judge BNeeds triage
    ContradictionAgents DISAGREE on the same itemFlag for manual decision

    Findings should be presented in a structured verdict table.

  10. Execution and Persistence Contract for `sdd-apply`

    main

    The sdd-apply skill operates in one of four artifact store modes, which dictates how it reads context and persists progress:

    ModeContext ReadingPersistence Method
    engramReads sdd/{change-name}/proposal, spec, design, and tasks.Uses mem_update(id: {tasks-observation-id}, content: "...") for tasks and saves to sdd/{change-name}/apply-progress.
    openspecFollows skills/_shared/openspec-convention.md.Updates tasks.md directly with [x] marks.
    hybridFollows BOTH conventions.Uses mem_update for tasks AND updates tasks.md on the filesystem.
    noneN/AReturns progress only; does not update any project artifacts.
  11. How the Skill Resolver protocol works

    main

    The Skill Resolver is a universal protocol used by any agent that delegates work to sub-agents (such as the ATL orchestrator, judgment-day, or pr-review). It ensures sub-agents receive relevant project standards and technical rules without needing to manually search for SKILL.md files.

    The Workflow

    1. Obtain Registry: The orchestrator retrieves a skill registry containing a Compact Rules section (pre-digested rules of 5-15 lines per skill).
    2. Match Skills: Skills are matched based on Code Context (file patterns like .tsx or app/**) and Task Context (actions like "Create a PR" or "Run tests").
    3. Inject Rules: The matching Compact Rules blocks are injected into the sub-agent's prompt under a ## Project Standards (auto-resolved) header before the task instructions.
    4. Include Conventions: If available, project-specific file paths and notes from the Project Conventions section are also included.

    Token Management

    • Aim for 50-150 tokens per skill.
    • If more than 5 skill blocks match, only include the 5 most relevant, prioritizing Code Context matches over Task Context matches.
  12. When to create an AI agent skill

    main

    A skill should be created when a pattern is used repeatedly and the AI requires specific guidance, when project-specific conventions deviate from generic best practices, when complex workflows require step-by-step instructions, or when decision trees are needed to help the AI choose the correct approach.

    Do not create a skill if:

    • Documentation already exists (use a references/ link instead).
    • The pattern is trivial or self-explanatory.
    • The task is a one-off occurrence.