Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions action/build-review-prompt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ set -euo pipefail
MAX_DIFF_CHARS=15000 # Per-file diff limit
MAX_FILE_CHARS=30000 # Per-file content limit
MAX_PROMPT_CHARS=100000 # Overall prompt limit
MODEL_THRESHOLD_FILES=5 # Use opus for PRs with more than this many files

# Files to skip (generated, binary, lock files)
SKIP_PATTERNS=(
Expand Down Expand Up @@ -221,11 +220,8 @@ build_prompt() {
local file_count
file_count=$(echo "$files_json" | jq 'length')

# Determine model based on file count
local model="haiku"
if [[ "$file_count" -gt "$MODEL_THRESHOLD_FILES" ]]; then
model="opus"
fi
# Always use opus for reviews
local model="opus"

# Fetch review rules
local review_rules
Expand Down
Loading