version: 1
kit_version: "{{KIT_VERSION}}"

project:
  name: "{{PROJECT_NAME}}"
  agent_language: "{{LANG}}"

package_manager: npm

pipeline:
  require_spec_review: true
  require_design_brief: false
  max_active_changes: 1
  # Policy: status prints it; "archive --if-ready" and the opt-in CI job honour it; a manual archive ignores it.
  archive_after_merge: true
  task_contract: warn
  # Size budget of tasks.md and all change artifacts: gate-check --review warns (warn), fails (strict) or stays silent (off).
  artifact_budget: warn
  # Opt-in: when on, and review.md is an accepted Tier 2 REQUEST CHANGES (a Tier 1 record does not
  # qualify) with local blockers in 1-2 tasks (no design.md or delta spec change), the architect may fix
  # tasks.md and apply-notes.md only; after gate-check --review exit 0 and your explicit approval the
  # conductor records Verdict APPROVE (fast-fix, approved by user) without a new Tier 2 review. Risks:
  # the side effects of the edit are not reviewed, the independent check is dropped, apply-notes.md may
  # be stale.
  review_fast_fix: off
  # Paths gate-check treats as product code: git pathspecs separated by
  # commas or spaces. Widen it when code lives outside src/
  # (e.g. "src/,lib/,app/") or the review gate never fires.
  src_glob: "src/"

roles:
  explorer:
    command: /opsx:explore
    mode: read-only
  design_intake:
    command: /opsx:design
    mode: brief-only
  architect:
    command: /opsx:propose
    mode: specs-only
  spec_reviewer:
    command: /opsx:review
    mode: read-only
  implementer:
    command: /opsx:apply
    mode: code
  verifier:
    type: ci
    gates:
      - openspec-validate-strict
      - lint
      - build

handoff:
  explore_to_propose: decision_brief
  propose_to_review: validate_strict
  review_to_apply: explicit_approve
  apply_to_verify: all_tasks_checked
  restore_on_start: true
  persist_on_exit: true
  emit_next_session_prompt: true
  prompt_self_contained: true
  spawn_handoff_subagent: false

memory:
  enabled: true
  file: .cursor/memory.json
  launcher: scripts/memory-mcp-launcher.cjs

mcp:
  baseline:
    - memory
  optional:
    - figma
    - github
    - gitlab
    - browser

skills:
  kit:
    - agent-orchestration
    - openspec-howto
    - openspec-explore
    - openspec-propose
    - openspec-apply-change
    - openspec-archive-change
    - openspec-sync-specs
    - spec-workflow-openspec
  stack: []
  external: ""

figma:
  env_file: .agents/figma.local.env
  token_key: FIGMA_ACCESS_TOKEN
  mcp_launcher: scripts/figma-mcp-launcher.cjs

# Opt-in local agent hook runtime (context delivery + local diagnostics).
# Distinct from the Git pre-commit hooks-setup/init --hooks gate.
# mode observe only advises; enforce requires explicit global and per-policy opt-in.
hooks:
  enabled: false
  mode: observe
  policies:
    verification:
      enabled: false
      mode: observe
    completion:
      enabled: false
      mode: observe
    scope:
      enabled: false
      mode: observe
    checks:
      enabled: false
      mode: observe
    owned-sync:
      enabled: false
      mode: observe
    workflow-notifications:
      enabled: false
      mode: observe

verifier:
  lint_command: "npm run lint"
  build_command: "npm run build"
  test_command: ""

# Amp/Cursor often lack global bins — agents must use npx/npm (see .agents/rules/cli-via-npm.mdc)
cli:
  status: npx agent-orchestrator-kit status
  gate_check: npx agent-orchestrator-kit gate-check
  handoff: npx agent-orchestrator-kit handoff <name>
  handoff_restore: npx agent-orchestrator-kit handoff --restore
  memory_setup: npx agent-orchestrator-kit memory-setup
  mcp_setup: npx agent-orchestrator-kit mcp-setup
  hooks_setup: npx agent-orchestrator-kit hooks-setup
  openspec_list: npx openspec list
  openspec_validate_change: npx openspec validate <name> --strict --type change
  openspec_validate_all: npx openspec validate --all --strict
  openspec_status: npx openspec status --change <name> --json
