lazy-graph-expansion #2

Merged
Mrixs merged 9 commits from lazy-graph-expansion into master 2026-08-14 22:17:37 +00:00
Owner
No description provided.
Mrixs added 9 commits 2026-08-14 22:15:58 +00:00
- Add SearchRoutes method to yandex client for on-demand station pair searches
- Implement hub expansion via on-demand /search calls in lazy graph expansion
- Integrate cache key generation for search results (search:{from}:{to}:{date})
- Update expandFromStation and expandFromCityHub to use Yandex API
- Add NewGraphWithoutYandex constructor for testability
- Add tests for on-demand search integration and cache TTL policies
- Mark all Task 2 checkboxes as [x] in the plan file
- SearchRoutes method added to yandex client
- Hub expansion implemented via on-demand /search
- Cache key generation integrated
- Tests written for search integration and cache TTL policies
All lazy graph expansion requirements verified:
- Lazy on-demand graph expansion with hub stations
- BFS/Dijkstra with depth limiting (4-5 transfers max)
- On-demand /search requests for relevant station pairs
- Aggressive caching with TTL policies
- Transfer limit enforcement
- MCT calculation during lazy expansion
- Task 1: Hub station selection and BuildGraphFromHubs
- Task 2: Yandex /search on-demand edge expansion with caching
- Task 3: FindRoute with lazy expansion and 4-5 transfer depth limit
- Task 4: Cache-aware search results with TTL policies (near-term: 2-6h, far-term: 7d)
- Task 5: End-to-end verification and documentation
- Task 6: Final verification - all internal/routing unit tests pass (22/22)

Co-Authored-By: Claude <noreply@anthropic.com>
- Remove Population field from HubStation; hub selection now uses only outgoing flights criterion
- Simplify SelectHubStations criteria (minPopulation removed from function calls)
- Add synthetic edge fallback in FindRoute when lazy expansion fails
- Add ResetCircuitBreaker helper to yandex client for test reset
- Update test criteria to match new hub selection logic
- Remove TestLazySearchCacheIntegration (replaced by integration tests)
Mrixs merged commit a2944e633f into master 2026-08-14 22:17:37 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mrixs/trip-planner#2