Local macOS app for browsing, summarizing, and chatting about your iMessage history. Private by default.
Project description
msg-summarizer
A local macOS app for browsing, summarizing, chatting about, and
semantically searching your iMessage history. Reads chat.db read-only;
your messages stay on your Mac.
pipx install msg-summarizer
msg-summarizer serve
…then open the browser tab it launches and add your Anthropic API key in the banner.
What it does
- Profiles for every conversation and every person, with per-month stats (message counts, who initiates, response latencies, active hours, top emojis) — no API calls, all local.
- Stored monthly summaries — backfill once, reuse forever. Each new month's summary gets prior months' summaries as context, so the long-history story stays consistent across years.
- Live-editable notes per contact that the model treats as ground truth — type "PIP = project plan, not a person" and the summary respects it.
- Semantic search with on-device embeddings (no embedding API calls either). Search by meaning: "trip planning", "feeling burned out", "what we said about the new car".
- Chat about a conversation — ask anything, draft replies, get advice. Range-scoped + retrieval-augmented, so questions about specific topics pull the relevant snippets, not just the most recent.
- People merging — a contact's phone, iCloud email, and SMS handle collapse into one person via macOS Contacts (same Contact card → same person). Group chats with no name are labelled by their participants in alphabetical order.
Privacy
- Reads, never writes
~/Library/Messages/chat.db. - The semantic index, profile stats, monthly summaries, and notes all live
in
~/.msg-summarizer/app.dbon your Mac. - Embeddings run on-device (fastembed, ONNX). No data leaves your machine for search.
- The Anthropic API receives only the specific text you ask to summarize or chat about — never your whole history, and never anything else.
- Contact names are pulled directly from the macOS AddressBook database on your Mac (covered by the same Full Disk Access permission), not from any network call.
- Your Anthropic API key is stored locally in
~/.msg-summarizer/.envwith mode 0600.
Requirements
- macOS (tested on Sonoma+). iMessage's
chat.dbis Mac-only. - Python 3.11+.
- Full Disk Access for the terminal/launcher you run
msg-summarizer servefrom. The app shows a step-by-step screen if it can't readchat.db. - An Anthropic API key — get one at https://console.anthropic.com/. Summary and Chat use it; everything else works without.
- ~50 MB for the embedding model, downloaded the first time you build a semantic index.
Install
pipx gives the cleanest install (pip with an
isolated env):
brew install pipx
pipx ensurepath
pipx install msg-summarizer
Or use pip in a venv:
python3 -m venv ~/.venvs/msg-summarizer
~/.venvs/msg-summarizer/bin/pip install msg-summarizer
~/.venvs/msg-summarizer/bin/msg-summarizer serve
Run
msg-summarizer serve
Opens the app at http://127.0.0.1:8765. The first time:
- If Full Disk Access isn't granted, the app shows a step-by-step page —
add your terminal app (Terminal / iTerm / Warp / VS Code / Cursor /
whichever you ran
servefrom) to System Settings → Privacy & Security → Full Disk Access, quit and reopen it, then click Re-check. - Paste your Anthropic API key into the banner at the top of the app
(or skip if you only want Profile / Search). It's saved to
~/.msg-summarizer/.env. - Click a chat or person in the sidebar. Profile loads instantly with stats. Use the tabs at the top to view messages, build the semantic index, generate a summary, or chat.
CLI features (without the UI)
The app also has direct commands:
msg-summarizer list-contacts # show known handles + counts
msg-summarizer messages "+15551234567" # dump a full thread as plain text
msg-summarizer summarize "+15551234567" --days 30
msg-summarizer chat "+15551234567" # interactive chat in the terminal
msg-summarizer serve # launch the web UI
Pass --help to any command for more.
Costs
Summarize and Chat hit the Anthropic API; you pay your usual rate. The app paces requests under your tier's input-tokens-per-minute limit (30k on tier 1) so it can't spike your bill. All-time summarize on a heavy contact (hundreds of thousands of messages) is in the dollars-to-tens of dollars range and takes ~20 minutes; once stored, re-opening is free.
Stats, Search, the semantic index, message browsing, and Contact-name resolution cost zero dollars and zero network calls.
Development
git clone https://github.com/andrewjyuan/msg-summarizer
cd msg-summarizer
pip install -e .
cd frontend && npm install && npm run build && cd ..
msg-summarizer serve
The frontend is React + Vite (TypeScript). For UI development, run
npm run dev in frontend/ alongside serve — Vite's dev server
proxies /api to the backend.
License
MIT.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file msg_summarizer-0.1.1-py3-none-any.whl.
File metadata
- Download URL: msg_summarizer-0.1.1-py3-none-any.whl
- Upload date:
- Size: 99.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2ea3c9205e326f2488a37e17d2cc4bef0031a8c958c5f74016884c21a4576eaf
|
|
| MD5 |
03660816b63386c250e606cb7ddad9de
|
|
| BLAKE2b-256 |
8858f3767f2170ada77879d9935f5ba79c7db63c94044c187084bf6e6491d529
|