How mih-ap/favourites works
Favourites turns submitted links into searchable Obsidian notes. Telegram (or the CLI) enqueues a URL; the worker claims it, extracts text/media, optionally transcribes audio, analyzes sufficient text with an OpenAI-compatible LLM, writes a Markdown card and updates SQLite, then may notify the submitter. The web app serves the library, search and card actions. README documents key capabilities such as retries, partial cards and photo attachments; unsampled implementation details are represented only where documented.
Main entry points: worker.py Queue worker · db.py SQLite queue · web.py Web API server · bot.py Telegram bot
Components 17
Link intake
- Telegram bot
app/bot.py - CLI
app/cli.py
Content processing
- Queue worker
app/worker.py - Content extraction
app/extract.py - Audio transcription
app/asr.py - Summary analysis
app/analyze.py
Library storage
- SQLite queue
app/db.py - Obsidian card writer
app/vault.py - Vault notes and images
app/vault.py
Web reference
- Web API server
app/web.py - Library interface
web/static/app.js - Interface shell
web/static/index.html - Interface styles
web/static/style.css
External services
- LLM endpoint
- Telegram API
- Content sources
Other components
- Telegram user
Connections 21
- Telegram user → Telegram bot: sends links
README.md - Telegram bot → SQLite queue: enqueues URLs
app/bot.py - Telegram bot → Telegram API: polls and replies
app/bot.py - CLI → SQLite queue: enqueues URLs
app/cli.py - SQLite queue → Queue worker: provides queued items
README.md - Queue worker → SQLite queue: claims and updates
app/worker.py - Queue worker → Content extraction: fetches content
app/worker.py - Content extraction → Content sources: retrieves media
README.md - Content extraction → Audio transcription: requests transcription
README.md - Queue worker → Summary analysis: analyzes extracted data
app/worker.py - Summary analysis → LLM endpoint: requests summary
app/analyze.py - Queue worker → Obsidian card writer: writes analyzed card
app/worker.py - Obsidian card writer → Vault notes and images: writes notes and attachments
README.md - Queue worker → SQLite queue: stores item metadata
app/worker.py - Queue worker → Telegram API: sends completion notice
app/worker.py - Library interface → Web API server: calls library API
README.md - Web API server → SQLite queue: queries and requeues items
app/web.py - Web API server → Obsidian card writer: reads and trashes cards
app/web.py - Web API server → Interface shell: serves interface
app/web.py - Interface shell → Library interface: loads interface logic
- Interface shell → Interface styles: loads styles