feat: Implement adaptive RRF weights and query intent detection

- Added integration tests for adaptive RRF weights in hybrid search.
- Enhanced query intent detection with new classifications: keyword, semantic, and mixed.
- Introduced symbol boosting in search results based on explicit symbol matches.
- Implemented embedding-based reranking with configurable options.
- Added global symbol index for efficient symbol lookups across projects.
- Improved file deletion handling on Windows to avoid permission errors.
- Updated chunk configuration to increase overlap for better context.
- Modified package.json test script to target specific test files.
- Created comprehensive writing style guidelines for documentation.
- Added TypeScript tests for query intent detection and adaptive weights.
- Established performance benchmarks for global symbol indexing.
This commit is contained in:
catlog22
2025-12-26 15:08:47 +08:00
parent ecd5085e51
commit 4061ae48c4
29 changed files with 2685 additions and 828 deletions

View File

@@ -466,7 +466,18 @@ class TestDiagnostics:
yield db_path
if db_path.exists():
db_path.unlink()
for attempt in range(5):
try:
db_path.unlink()
break
except PermissionError:
time.sleep(0.05 * (attempt + 1))
else:
# Best-effort cleanup (Windows SQLite locks can linger briefly).
try:
db_path.unlink(missing_ok=True)
except (PermissionError, OSError):
pass
def test_diagnose_empty_database(self, empty_db):
"""Diagnose behavior with empty database."""