Optimafly: A Multi-City Optimized Flight Planner

Position:Backend Engineer, Frontend Engineer, Product Lead Type:Personal project Duration:Sep 2025 - Present Stack:Backend — Python · FastAPI · Uvicorn · SQL Frontend — React Skills:API design, caching, optimization, constraint modeling, UX/UI design, machine learning (ML), database

Overview

Construct flexible, cost-minimized itineraries given travel windows, stay durations, and required or optional destinations. Treat the itinerary as a constraint-optimization task so the system finds the most cost-efficient multi-city plan that fits the schedule and is the lowest-cost option.

Summary

≈30% speed up Optimization: skip dead-end airport queries after 3 consecutive no-connection days.
24h timeline cache Per-session TTL to avoid refetching identical legs within a day.
User data & recommendations PostgreSQL stores user interactions for analytics; feeds into an ML recommendation system.
Deployment FastAPI backend deployed with Uvicorn; React frontend served via static hosting.

Why This Project?

We want to travel and gain as many new experiences as possible on tight budgets and narrow windows. Current tools assume fixed destinations or single routes, which breaks down when the goal is flexible exploration across multiple cities. This project fixes that by letting you specify time windows; must vs. optional cities; and min/max stay days so the system searches and builds a plan that actually fits your constraints.

Algorithms

Cache

Reachability Gate

Key Features

Next Steps