How simeononsecurity/meshtastic-ai-bridge works
Local Meshtastic AI Bridge turns mesh text requests into AI-assisted radio replies, with deterministic help/status commands and optional retrieval context. The main workflow runs through the bridge’s packet filtering and queued processing, routes eligible requests to retrieval adapters, sends context and prompts to an OpenAI-compatible model endpoint, then chunks and returns the answer over Meshtastic. The dashboard reads bridge status and logs and manages selected services and model settings. Some bridge source is omitted, so links between orchestration stages are limited to documented behavior and visible calls.
Main entry points: bridge.py Bridge runtime · dashboard.py Web dashboard · retrieval.py Retrieval adapters · local_wiki.py SQLite wiki search
Components 19
Mesh interface
- meshtasticd
Assistant runtime
- Bridge runtime
bridge/bridge.py - Request queue
bridge/bridge.py - AI API
- Response history
bridge/bridge.py - Bridge control API
bridge/bridge.py
Knowledge retrieval
- Retrieval adapters
bridge/retrieval.py - SQLite wiki search
bridge/local_wiki.py - Wiki index
bridge/local_wiki.py - Kiwix search
bridge/local_kiwix.py - Kiwix server
- wttr.in
- Google News RSS
- Local sensor endpoint
Operations dashboard
- Web dashboard
dashboard/dashboard.py - Live model config
dashboard/dashboard.py - Ollama service
- Host services
Other components
- Mesh user
Connections 20
- Mesh user → meshtasticd: sends message
- meshtasticd → Bridge runtime: delivers packets
- Bridge runtime → Request queue: queues requests
- Request queue → Bridge runtime: processes request
- Bridge runtime → Retrieval adapters: routes retrieval
- Retrieval adapters → wttr.in: fetches weather
- Retrieval adapters → Google News RSS: fetches news
- Retrieval adapters → Local sensor endpoint: reads telemetry
- Bridge runtime → Kiwix search: searches offline
- Kiwix search → Kiwix server: queries library
- Bridge runtime → SQLite wiki search: searches index
- SQLite wiki search → Wiki index: queries
- Bridge runtime → AI API: requests completion
- Bridge runtime → meshtasticd: sends reply
- Bridge runtime → Response history: appends interaction
- Web dashboard → Bridge control API: requests status
- Web dashboard → Response history: reads history
- Web dashboard → Live model config: updates model
- Web dashboard → Host services: manages services
- Web dashboard → Ollama service: lists or pulls models