Skip to content

v0.4.0

Choose a tag to compare

@mr-karan mr-karan released this 25 Mar 07:00
· 74 commits to main since this release

What's Changed

Token Optimization (biggest impact)

  • Pre-embed diff: For PRs ≤200KB, the full diff is embedded directly in the prompt, eliminating per-file git diff tool calls. Tested on a 300-line PR: 61→20 turns, 2.28M→1.17M tokens.
  • Incremental reviews: Posts a <!-- hodor:sha:HEAD --> marker in review comments. On re-runs, only diffs changes since the last review (three-dot syntax, excludes upstream changes). Handles force-push gracefully.
  • Enable compaction: SDK auto-summarizes older turns when context grows too large (safety net for large PRs).

SDK Upgrade

  • Upgraded @mariozechner/pi-ai and pi-coding-agent from 0.55.1 → 0.62.0
  • 1M context window for Claude Opus 4.6/Sonnet 4.6 (was 200K)
  • Better auto-compaction resilience
  • Faster startup via lazy-loaded provider SDKs
  • Added promptSnippet to submit_review tool (required since SDK v0.60.0)

New Features

  • --bedrock-tags '{"team":"platform"}' — AWS Bedrock cost allocation tagging (appears in Cost Explorer)
  • --prometheus-push <url> — Push review metrics (tokens, cost, turns, duration) to Prometheus Pushgateway. Best-effort, never fails the CI run.

Bug Fixes

  • Fixed metrics display: inputTokens from the SDK is fresh-only, not total. Now correctly computes totalInput = fresh + cached for accurate percentages.