← Back to Pull requests

Translate function_score with one function over match_all into a Solr function query #178

Open
unknown opened this pull request with 129 lines diff across 1 files
View on GitHub
unknown unknown commented on Nov 30, 2026 17:59 UTC
Author

A converted function_score became q=:, so the operation matched every document with a constant score and measured none of the scoring. A function_score whose query is match_all (or absent) and that has a single field_value_factor (any modifier) or a gauss, exp or linear decay on a geo point now becomes {!func} with the same function. With match_all every document scores 1, so boost_mode does not change the result. Anything else (several functions, weight, missing, numeric or date decays, a scoring inner query) stays untranslated with the existing warning.

Each form was compared with OpenSearch on the same geonames documents, score by score: the ten modifiers, gauss and exp agree to a relative 1.4e-06 or better, and linear to an absolute 1.7e-07. For geonames' two operations the converter now writes what solr-orbit-workloads ships, and over 300 documents each its scores match OpenSearch's to 1.4e-07 (field_value_factor) and 3.3e-06 (gauss). The new tests fail without the change.

Diff: 129 lines (+96 / -33) across 1 files Reviewer: janhoy Review duration: 1897m
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.32) × (1 − Review Confidence (0.47)). Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.32 · 129 lines diff across 1 files
0.32
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
0.02
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
46%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth shallow_review_depth
0.344
Diff Size diff_size
0.291
Real PR Conversation Timeline
1 comments
"Review active on #178"
general weight: 0.35
Reviewers
Assignees
Unassigned
Labels
risk: low confidence: 46.7% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 32.1% (LOW) · Higher = larger blast radius
32.1%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 46.7% · Lower = rushed or shallow review
46.7%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 17.1% · Safe to merge
17.1%