name: e2e-team-leader-refill-threshold
description: E2E test for team_leader refill threshold behavior
piece_config:
  provider_options:
    codex:
      network_access: true
    opencode:
      network_access: true
max_movements: 5
movements:
  - name: execute
    edit: true
    persona: ../agents/test-team-leader-refill-threshold.md
    required_permission_mode: edit
    team_leader:
      max_parts: 3
      refill_threshold: 2
      part_persona: ../agents/test-coder.md
      part_edit: true
      part_allowed_tools:
        - Read
        - Write
        - Edit
    instruction_template: |
      {task}
    rules:
      - condition: Task completed
        next: COMPLETE
