KB-6DDD

P3D — Vector Search Hybrid Boost — Design Report

3 min read Revision 1
p3dvector-searchdesign-reportrerank

P3D — Vector Search Hybrid Boost — Design Report

Date: 2026-05-11 Author: Opus 4.7

Status Fields

phase_status=PASS
mode=DESIGN_AND_PROMPT_ONLY
implementation_allowed=false
root_cause=SEARCH_RANKING_NO_PATH_TITLE_BOOST_NOT_VECTOR_FRESHNESS
no_mutation_performed=true
next_required_action=GPT_REVIEW_IMPLEMENTATION_PROMPT
pack1_paused=true

Deliverables

# Output Path Status
1 Design (10 sections A–J) design/p3d-vector-search-hybrid-path-title-boost-design.md ✅ Rev 1
2 Implementation Prompt prompts/p3d-vector-search-hybrid-path-title-boost-implementation-prompt.md ✅ Rev 1 DRAFT
3 Report (this file) reports/p3d-vector-search-hybrid-path-title-boost-design-report.md

Top 7 Design Decisions

  1. App-layer rerank only — no Qdrant mutation, no reindex
  2. Boost formula: combined_score = vector_score + path_boost(0.30) + basename_boost(0.20) + title_boost(0.15) + tag_boost(0.15) + path_dir_boost(0.10)
  3. Token overlap threshold: ≥50% for basename/title match, any match for tags/path_dir
  4. Feature flag: SEARCH_RERANK_ENABLED=true env var — instant rollback
  5. Patch point: after Qdrant dedup, before return (single function insertion)
  6. No NLP dependency — simple regex tokenizer on whitespace/hyphens/underscores
  7. Debug fields: _boost and _original_score added to results for transparency

Acceptance Tests

# Query Expected Baseline rank Target rank
T1 GPT Review P3D Step 1... ≤2 5 ≤2
T2 p3d-pack1-readonly-inventory-prompt rev 2 =1 3 =1
T3 gpt-directive-agent-run-step1... =1 1 =1
T4 p3d-agent-vector-search-freshness-audit... =1 1 =1
T5 vector search freshness root cause top 5 relevant OK OK (no regression)
T6 operating rules SSOT top 3 relevant OK OK (no regression)

GPT/User Implementation Review Required

YES — implementation prompt is DRAFT. Dispatch only after GPT + User explicit approval.


Design Report | 2026-05-11 | Opus 4.7 | DESIGN_AND_PROMPT_ONLY

Back to Knowledge Hub knowledge/dev/laws/dieu44-trien-khai/reports/p3d-vector-search-hybrid-path-title-boost-design-report.md