You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A comprehensive review of Phases 3 & 4 against the consolidated requirements and review checklist identified several discrepancies, missing deliverables, and bugs:
Missing Chunk-and-Summarize Execution for Large Diffs:
When TokenBudgetManager.assess() returns BudgetStrategy.NEEDS_CHUNKING, generate_commit_message in src/gitmate/fallback.py previously short-circuited directly to a template-based fallback (is_fallback=True), skipping LLM generation entirely. As specified in plan.md and the Phase 4 review checklist, Phase 4 must consume BudgetDecision.omitted_diffs (which preserves the untruncated original patches), summarize each chunk via active_provider.generate(), merge the summaries into the prompt's summary_note, and generate the final commit message (with graceful degradation if the provider fails).
Missing gemini-3.5-flash in DEFAULT_MODEL_CONTEXT_WINDOWS: DEFAULT_MODEL_CONTEXT_WINDOWS in src/gitmate/config.py contained gemini-3.5-flash-lite, gemini-3-flash, and gemini-flash, but omitted gemini-3.5-flash (non-lite) and lacked an explanatory comment clarifying that gemini-3.5-flash-lite remains the configured default. Users setting model = "gemini-3.5-flash" received UnknownModelError.
Missing RetryableError Alias in providers/base.py:
The transient error marker was named RetryableProviderError, but the review checklist and callers expect RetryableError.
Stale SDK and Provider References in plan.md: plan.md retained stale references to AnthropicProvider (Phase 4, line 90) and Anthropic SDK token counting (Phase 2, lines 57 & 63, and design decision table line 15), contradicting the locked-in decision in AGENTS.md specifying Gemini as default.
template_overhead Calibration:
The 500 token default estimate was evaluated against the actual template files (commit_conventional.txt: ~329 tokens, commit_plain.txt: ~210 tokens, pr_summary.txt: ~206 tokens), confirming 500 tokens provides a safe upper bound with ~170+ tokens of headroom for dynamic notes.
Proposed Resolution
Implement _chunk_patch_text and summarize_omitted_diffs in src/gitmate/fallback.py to execute chunk-and-summarize on NEEDS_CHUNKING, merging notes into the final prompt while retaining graceful degradation on provider failure.
Add "gemini-3.5-flash": 1_048_576 to DEFAULT_MODEL_CONTEXT_WINDOWS in src/gitmate/config.py with explanatory comments.
Export RetryableError = RetryableProviderError in src/gitmate/providers/base.py.
Update plan.md to eliminate stale Anthropic SDK references in favor of the Google GenAI SDK and document Phase 4 chunk-and-summarize delivery.
Add test coverage across tests/test_orchestrator.py, tests/test_config.py, and tests/test_providers.py.
Activity
fix: address PR #12 review feedback on exit codes, stderr routing, an…