Skip to content

feat(instructions): refine Milestone Discovery Protocol Step 6 for schema awareness #492

@WilliamBerryiii

Description

@WilliamBerryiii

Summary

Refine Milestone Discovery Protocol Step 6 in github-backlog-planning.instructions.md to describe how agents should parse, validate, and apply .github/milestone-strategy.yml when the file exists. Currently Step 6 says to "apply the declared strategy" without specifying what fields to read, how to interpret them, or how to handle invalid configs.

Problem

The current Step 6 text:

When confidence is low, check for .github/milestone-strategy.yml in the repository. If found, apply the declared strategy. If not found, present the discovered milestones to the user and request classification. When no user input is available, assign unclassified and flag for human review.

This gives agents no guidance on:

  1. What fields exist in the config file (strategy, roles)
  2. How to interpret the strategy enum (what each named strategy implies)
  3. How the roles object maps to milestone title matching
  4. What to do when the config file exists but is invalid (fails schema validation)
  5. How config-declared roles interact with discovery-inferred roles (conflict resolution)

Step 1 also references the file: "when comprehensive coverage is required, check for .github/milestone-strategy.yml as a supplement." This note similarly lacks detail on what "supplement" means operationally.

Design

Refined Step 6 Text

Replace the current Step 6 with text that covers:

  1. File location check: Read .github/milestone-strategy.yml from the repository root
  2. Schema awareness: The config follows the milestone strategy schema; invalid configs are treated as absent
  3. Field processing: Read strategy to identify the versioning scheme; read optional roles to map abstract role names to milestone title patterns
  4. Strategy interpretation: Named strategies (semver, semver-even-odd, calver, sprint, linear) carry default role semantics; custom requires explicit roles
  5. Conflict resolution: When both discovery and config assign roles, config takes precedence (explicit beats inferred)
  6. Fallback chain: config present and valid > config absent, prompt user > no user input, assign unclassified

Refined Step 1 Supplement Note

Update the Step 1 note to explain that the config file provides a known set of milestone names and roles, filling gaps left by the API query (which only surfaces milestones with open issues).

Scope Boundary

This issue modifies only the Step 6 (and Step 1 note) text in github-backlog-planning.instructions.md. It does not change other sections, triage instructions, or discovery instructions.

Implementation Touchpoints

File Section Action
.github/instructions/github-backlog-planning.instructions.md Step 6 (Milestone Discovery Protocol) Replace text with schema-aware version
.github/instructions/github-backlog-planning.instructions.md Step 1 supplement note Clarify operational meaning

Acceptance Criteria

  • Step 6 references the strategy and roles fields by name
  • Step 6 describes how each named strategy maps to role classification
  • Step 6 specifies that invalid configs are treated as absent (not error states)
  • Step 6 defines conflict resolution: config roles override discovery-inferred roles
  • Step 6 preserves the existing fallback chain (no config > prompt user > assign unclassified)
  • Step 1 supplement note explains that the config fills gaps from API-only discovery
  • The custom strategy's requirement for explicit roles is mentioned
  • No other sections of the planning instructions are modified

Dependencies

Related Issues

Metadata

Metadata

Labels

agentsCustom chat agents (.agent.md)instructionsCopilot instruction files (.instructions.md)

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions