Skip to content

Make pred inspect respect exact problem variants - #1121

Merged
isPANN merged 3 commits into
1075-growth-domainfrom
codex/fix-inspect-exact-variant
Aug 7, 2026
Merged

Make pred inspect respect exact problem variants#1121
isPANN merged 3 commits into
1075-growth-domainfrom
codex/fix-inspect-exact-variant

Conversation

@isPANN

@isPANN isPANN commented Aug 7, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • query outgoing reductions from the loaded problem exact variant
  • report only witness-executable reductions, matching pred reduce defaults
  • render non-default target variants as directly reusable slash specs
  • apply the same behavior to CLI and MCP inspection

Verification

  • make check
  • regression tests execute every target advertised by inspect
  • regression coverage separates unit and weighted sibling variants
  • regression coverage excludes non-witness reductions

Stacked on #1083.

Fixes #1114

@isPANN
isPANN marked this pull request as ready for review August 7, 2026 09:24
@isPANN
isPANN requested a lite review from Copilot August 7, 2026 09:26

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates pred inspect (CLI and MCP) to compute reduces_to from the loaded problem’s exact normalized variant, and to list only witness-executable reductions (matching pred reduce defaults). It also renders non-default target variants as reusable slash specs (e.g., Name/Variant/...) and adds regression coverage to ensure every advertised inspection target is actually reducible.

Changes:

  • Add ReductionGraph::outgoing_reductions_from(...) to query outgoing reductions for an exact variant and reduction mode.
  • Update CLI + MCP inspection to derive targets from the exact variant and filter to witness-capable reductions, formatting non-default targets as slash specs.
  • Add unit + CLI regression tests covering exact-variant separation and witness-only inspection output.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/rules/graph.rs Adds an exact-variant outgoing reduction query API used by inspection logic.
src/unit_tests/rules/graph.rs Adds unit tests verifying exact-variant and mode filtering behavior, plus unknown-variant rejection.
problemreductions-cli/src/commands/inspect.rs Switches inspection to exact-variant, witness-executable targets and formats non-default variants as slash specs.
problemreductions-cli/src/mcp/tools.rs Aligns MCP inspection output with the updated CLI inspection behavior.
problemreductions-cli/tests/cli_tests.rs Adds CLI regressions ensuring inspect advertises only executable targets and excludes non-witness reductions.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/rules/graph.rs
Comment on lines +1404 to +1405
/// Get executable outgoing reductions from one exact problem variant.
pub fn outgoing_reductions_from(
@isPANN
isPANN merged commit 61521b4 into 1075-growth-domain Aug 7, 2026
@isPANN
isPANN deleted the codex/fix-inspect-exact-variant branch August 7, 2026 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants