Algorithms

SPRE — Speculative Pre-Ranking

Speculative Pre-Ranking Engine. SPRE dramatically reduces the cost of HyperFusion ranking by running a fast lightweight scorer before the full 8-signal ranking pass. Only the top candidates proceed to full scoring.

The problem SPRE solves

A typical search returns 50–200 raw results across multiple backends. Running full HyperFusion on every result is expensive — especially when semantic embedding similarity is involved. SPRE filters this to the top 30 candidates before full scoring, reducing ranking time by ~70%.

SPRE scoring signals

SignalWeightCost
BM25 title match40%~0.1ms
URL keyword match20%~0.01ms
Domain reputation (cached)25%~0.01ms
Result position (backend rank)15%~0.01ms

Pipeline integration

1. Multi-backend parallel fetch → 50–200 raw results
2. SPRE fast-score all results (~2ms total)
3. Keep top-30 by SPRE score
4. CEP extraction on top-30 only
5. HyperFusion full 8-signal ranking on top-30
6. Return top-10 ranked results

Performance impact

  • Without SPRE: CEP extracts all 100+ results → ~10s latency
  • With SPRE: CEP extracts only top-30 → ~2s latency
  • SPRE adds ~2ms overhead to filter 10× fewer extractions
  • Recall@10: 94%+ (SPRE rarely filters out relevant top results)

Configuring the candidate pool size

The SPRE candidate pool size (default: 30) can be tuned based on your quality vs. speed trade-off:

  • 15 candidates — fastest, suitable for key_facts tier
  • 30 candidates — default, good balance for most queries
  • 50 candidates — highest quality, use for detailed tier

Next steps