Implemented BM25 (Best Matching 25) for high-relevance token scoring, Added a PageRank function (20 iterations) to calculate domain authority, Switched to an in-memory JSON index to eliminate server-side round-trips, Benchmarked 100 results for "Hacker News" in ~0.15s.