Smart Automated Assistant for Routine Task Handling & Intelligent scheduling
The planner that decides when your work happens, and learns how you work.
Most to-do apps give you a list and leave the hard part to you: fitting the work into your week. Saarthi does that part.
You tell it what needs doing (how long, how much energy it takes, when it's due) and the weekly things that never move, like classes, work and sleep. A constraint solver then places every task into the gaps, splits long work into sessions with breaks, and puts demanding work at the hours you're sharpest. As you start, finish, move or skip sessions, a learning model picks up when you actually get things done, so the next plan fits you better.
Saarthi (सारथी) means charioteer: the one who steers, so you can focus on the work.
Enzo is Saarthi's face and its assistant: an orange screen-head drawn entirely in code, whose expressions come from his pixel screen and the way his head moves. He looks at what you're doing, nods when he talks, celebrates finished work, and looks worried when a plan doesn't fit.
- Talk to him: type or speak in the chat, or hold him on the Home screen to talk walkie-talkie style. He understands everyday language ("move my gym to tomorrow evening", "how's my week looking?").
- He always asks first: commands come back as a Yes / No question, and nothing changes until you answer.
- He's on your home screen: an "Ask Enzo" widget on iOS and Android, with a mic that opens the chat already listening.
|
|
|
|
Insights and adding a fixed slot, in light mode · the Ask Enzo widget · Settings
flowchart LR
A["📝 Tasks<br/>chat · voice · form"] --> B["🧩 CP-SAT solver<br/>deadlines first"]
F["📅 Fixed week<br/>classes · sleep · calendar"] --> B
B --> C["🗓️ Sessions<br/>on your timeline"]
C --> D["⏱️ You work<br/>start · done · move · skip"]
D --> E["🎯 Outcomes<br/>rewards & penalties"]
E --> G["🧠 Slot bandit<br/>+ energy curves"]
G -->|better hours next time| B
- Tasks come in through the chat (typed or spoken), the task form, or the API, each with a duration, an energy level, a priority and an optional deadline.
- The solver plans deadline work first with OR-Tools CP-SAT, then fills the remaining free time, scoring every candidate hour with energy curves, the learned time-of-day preferences and the ML models.
- You work the plan. Starting, finishing, moving, skipping or abandoning a session is recorded on the server.
- Outcomes become rewards. A task finished at the planned hour scores higher than one that had to be moved; dropped work scores negatively. The slot bandit and energy curves update, and the next plan leans toward the hours that worked.
Three companion pages walk through the backend's logic in depth. Each opens in your browser, and two are interactive.
| Explainer | What it covers | |
|---|---|---|
| 🗺️ | SAARTHI Intent Map | A case-by-case reference for how the task endpoints connect: each endpoint's decision tree, the slot bandit's reward for every outcome, and the task lifecycle from draft to completed. |
| 🧭 | Saarthi Pipeline Atlas | One example day traced through the whole V1.3.0 backend: inputs, the CP-SAT planning run, reminders and outcome tracking, and the learning that adjusts future plans. Includes a file map, the database tables and a "try it" section. |
| 🦉 | Night Owl Simulator | An interactive simulation of a user who works best at 22:00, showing day by day how the slot bandit, slot scores and energy curve learn where to place their work. |
flowchart TB
subgraph Phone["📱 Flutter app (iOS · Android)"]
UI["Screens · Provider stores"]
W["Home-screen widget"]
end
subgraph Server["☁️ AURA backend (AWS EC2, Docker)"]
Caddy["Caddy<br/>HTTPS"] --> API["FastAPI"]
API --> Solver["CP-SAT solver<br/>(OR-Tools)"]
API --> ML["Slot bandit · energy curves<br/>XGBoost · LightGBM"]
API --> DB[("PostgreSQL")]
Worker["Celery worker + beat"] --> DB
Worker --> Redis[("Redis")]
end
FB["🔐 Firebase Auth"]
LLM["💬 Gemini<br/>(+ fallback model)"]
UI -- "HTTPS + Firebase ID token" --> Caddy
W -- "saarthi://chat" --> UI
UI -- "sign in" --> FB
API -- "verify token" --> FB
API -- "understand messages" --> LLM
- The app holds no scheduling logic. Every task, commitment and session lives in PostgreSQL, scoped to the signed-in Firebase account; the phone renders and acts.
- Auth is Firebase end to end. The app signs in with Firebase, and the backend verifies the same ID token with the Firebase Admin SDK on every request.
- Enzo's understanding runs on the server (
/voice/understand→ a reply, or a question;/voice/confirm→ the answer). Commands never run without a Yes. - Background work (reminders, model retraining, nightly rewards) runs on Celery with Redis.
| Layer | Technology |
|---|---|
| App | Flutter 3.47 · Dart 3.10 · Provider · speech_to_text · flutter_tts · flutter_local_notifications · device_calendar_plus · app_links |
| Widget | SwiftUI WidgetKit extension (iOS) · AppWidgetProvider + RemoteViews (Android) |
| Backend | FastAPI · SQLAlchemy · PostgreSQL · Redis · Celery |
| Planning | Google OR-Tools (CP-SAT) |
| Learning | Thompson-sampling slot bandit · energy curves · XGBoost · LightGBM · scikit-learn |
| Language | Gemini, with a fallback model for unsure commands |
| Auth & telemetry | Firebase Auth · Firebase Analytics · Crashlytics (no task titles or message text are ever sent) |
| Hosting | AWS EC2 · Docker Compose · Caddy (automatic HTTPS) · DuckDNS |
| Type | Bricolage Grotesque (display) · Geist (text), both bundled under the SIL OFL |
SAARTHI/
├── SAARTHI V1.3.0/ ← current version
│ ├── app files/ Flutter app (iOS, Android), widget extensions, tests
│ └── backend/ AURA: FastAPI, solver, ML, Celery, deploy/ bundle
├── SAARTHI V1.2.0/ earlier versions, kept for reference
├── SAARTHI V1.1.0/
└── docs/ README images: brand/ (animated SVGs), screenshots/
Each side has its own detailed guide: app files/README.md and backend/README.md. Design decisions are logged phase by phase in backend/docs/INTEGRATION_LOG.md.
Run it locally (backend in Docker, app on a simulator or phone)
1. Backend
cd "SAARTHI V1.3.0/backend"
cp .env.example .env # fill in the values; see backend/README.md
# put the Firebase Admin key at secrets/firebase-service-account.json (see secrets/README.md)
docker compose up -d # API, Postgres, Redis, Celery worker and beat
curl http://localhost:8000/ # {"message": "AURA is alive"}2. App
cd "SAARTHI V1.3.0/app files"
flutter pub get
flutter run # iOS Simulator reaches the Mac at localhost:8000On a physical phone, point the app at your machine (or a server) at build time:
flutter run --release --dart-define=AURA_API_BASE_URL=http://<your-mac>.local:8000The Android emulator reaches the host at 10.0.2.2:8000 automatically.
Deploy to a server (AWS EC2 + HTTPS)
Everything for production is in backend/deploy/: a production Compose file, a Caddyfile for automatic HTTPS, a one-time bootstrap.sh (swap, Docker, firewall, DuckDNS updater, nightly database backups) and deploy.sh, which copies everything to the box and starts the stack. Step-by-step instructions are in deploy/README.md.
The Android release is built with tool/release_android.sh, which builds a signed APK against the production URL and refreshes the download page. Installed apps offer new versions on their next launch.
- Your data is yours: tasks and plans are tied to your Firebase account and are visible only to you.
- Calendar stays on the phone: only event times are sent, so the planner can avoid them. Titles, places and guests never leave the device.
- Telemetry is anonymous: usage events carry outcomes only, never task titles or what you said to Enzo.
- No secrets in this repository: API keys, the Firebase Admin key and signing keys are kept out of git.
The full privacy policy and terms ship with the app's download page.
Ashmeen · Sahil · Shabd · Shreya · Shubham
Made with ☕ and a lot of re-planning by Team Saarthi.
Fonts: Bricolage Grotesque and Geist, under the SIL Open Font License. The animations in docs/brand/ are drawn from Enzo's real geometry, with text as outlines of the app's own fonts.






