Skip to content

Model Selection Matrix + Context Budgeting #29

Description

@kanfil

Summary

Epic issue for Tier 3 Model Selection Strategy - Complete Overview

Sub-items

Tier 3.1 - Core & Admin Command Model Selection Matrix

  • Core Workflow Commands: Define defaults and options for /specify, /clarify, /plan, /implement, /analyze, /trace, /levelup
  • Admin Commands: Define defaults for /architect, /constitution, /mode, /checklist
  • Integration: Add --model parameter to all commands above

Tier 3.2 - Model-Aware Context Budgeting

  • Context Window Limits: Document effective context windows per model
  • Token Cost Calculator: Implement utility to estimate tokens for spec.md + plan.md + tasks.md
  • Recommendation Engine: Show context utilization during execution
  • Model Downgrade Suggestions: Auto-suggest Haiku when context > 70%
  • Transparency in Prompts: Log context size in delegation prompts

Tier 3.3 - Two-Model Review Strategy

  • Review Model Configuration: Store preferred review model in config.json
  • Quality Gate Integration: Invoke review model for ASYNC task validation
  • SYNC vs ASYNC Review: Apply two-model review only to critical SYNC tasks
  • User Override: Support --review-model parameter to force specific reviewer
  • Review Quality Thresholds: Document when review model is invoked

Tier 3.4 - Cost Optimization Guidance

  • Usage Documentation: Create guide on when to use each tier (Haiku, Sonnet, Opus)
  • Cost Calculator: Implement simple calculator with examples
  • Budget Tracking: Optional logging of model usage per project/team
  • Org Policy Templates: Provide templates for enforcing model choices per team

Tier 3.5 - Model Preference in Team Directives

  • Directive Format: Define structure in team-ai-directives for model preferences per command
  • Fallback Hierarchy: Implement precedence: user CLI override → project config → team directive → hardcoded default
  • Org-Wide Defaults: Enable shared model policies across projects via team directives

Tier 3.6 - Command-Level --model Parameter Implementation

  • CLI Parameter Addition: Add --model to all command templates
  • Config Validation: Validate model choice against available models
  • Preference Persistence: Store user's recent model choice per command
  • Documentation: Update quickstart and command help text

Priority

Medium - Optimize cost & performance

Labels

epic, model-selection, cost


This issue consolidates all Tier 3 Model Selection Strategy tasks. Original part 2 task (#30) has been merged here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions