How tpatel1208/talking-to-air works
Talking to Air is a conversational atmospheric-data application: users ask questions in a React chat, the backend streams a supervisor-routed response, and satellite or EPA ground-sensor workflows produce visualizations and analysis. The product also supports discovery, variable guidance, long-running jobs, exports, provenance, and persistent sessions. The README documents the main routing and product branches; source-index references and excerpts support selected internal links. Several API routes and feature implementations were not sampled, so their internal wiring is not inferred.
Main entry points: chat_stream_service.py Chat orchestration · App.jsx Application shell · supervisor_agent.py Supervisor agent · retrieval_tools.py Satellite tools
Components 26
Web application
- Application shell
Frontend/src/App.jsx - Chat interface
Frontend/src/components/Chat.jsx - Chat and SSE client
Frontend/src/hooks/useChat.js - Discovery client
Frontend/src/hooks/useDiscovery.js - Jobs client
Frontend/src/hooks/useJobs.js - Results panels
Frontend/src/components/OutputPanel.jsx
Conversation and routing
- FastAPI backend
Backend/tta_backend/api.py - Chat orchestration
Backend/tta_backend/services/chat_stream_service.py - Supervisor agent
Backend/tta_backend/agents/supervisor_agent.py - Satellite agent
Backend/tta_backend/agents/earthdata_agent.py - Ground-sensor agent
Backend/tta_backend/agents/ground_sensor_agent.py
Data workflows
- Satellite tools
Backend/tta_backend/tools/satellite_tools/retrieval_tools.py - Earthdata MCP client
Backend/tta_backend/earthdata_mcp/client.py - Data aggregation
Backend/tta_backend/preprocessing/aggregation_service.py - Dataset discovery
Backend/tta_backend/services/discovery_service.py - EPA sensor tools
Backend/tta_backend/tools/ground_sensor_tools/epa_aqs_tools.py
Results and persistence
- Maps and plots
Backend/tta_backend/utils/plotting.py - Data exports
Backend/tta_backend/services/export_service.py - Session history
Backend/tta_backend/repositories/session_repository.py - Artifact storage
Backend/tta_backend/services/artifact_store.py
Runtime infrastructure
- PostgreSQL
Backend/tta_backend/utils/db.py - Runtime settings
Backend/tta_backend/config/settings.py
Other components
- Researcher
- Earthdata retrieval MCP
- EPA AQS API
- Language-model provider
Connections 26
- Researcher → Application shell: asks questions
README.md - Application shell → Chat interface: renders
Frontend/src/App.jsx - Application shell → Chat and SSE client: uses
Frontend/src/App.jsx - Application shell → Discovery client: uses
Frontend/src/App.jsx - Application shell → Jobs client: uses
Frontend/src/App.jsx - Application shell → Results panels: renders
Frontend/src/App.jsx - Chat and SSE client → FastAPI backend: streams chat
README.md - FastAPI backend → Chat orchestration: routes chat
- Chat orchestration → Supervisor agent: routes query
README.md - Supervisor agent → Satellite agent: dispatches
README.md - Supervisor agent → Ground-sensor agent: dispatches
README.md - Satellite agent → Satellite tools: uses tools
- Satellite tools → Earthdata MCP client: parses results
Backend/tta_backend/tools/satellite_tools/retrieval_tools.py - Earthdata MCP client → Earthdata retrieval MCP: retrieves data
README.md - Satellite tools → Data aggregation: uses
Backend/tta_backend/tools/satellite_tools/retrieval_tools.py - Ground-sensor agent → EPA sensor tools: queries
README.md - EPA sensor tools → EPA AQS API: requests observations
README.md - Chat orchestration → Dataset discovery: dispatches discovery
- Chat orchestration → Artifact storage: stores artifacts
Backend/tta_backend/services/chat_stream_service.py - Chat orchestration → Maps and plots: creates charts
- Chat orchestration → Session history: persists history
- Session history → PostgreSQL: reads and writes
Backend/tta_backend/repositories/session_repository.py - Artifact storage → PostgreSQL: indexes artifacts
- Results panels → Data exports: requests export
README.md - Chat orchestration → Language-model provider: runs agents
README.md - Chat orchestration → Runtime settings: reads settings
Backend/tta_backend/services/chat_stream_service.py