Skip to main content

Metatron

Multi-project web feed manager with cross-outlet deduplication.

You point Metatron at sources, organized by project. It polls them, dedups the articles (URL canonicalization → normalized title → token overlap → LLM tiebreaker), and serves you the unique articles via a small HTTP API. RSS is the source it speaks today; the architecture is medium-agnostic and grows to other web sources over time.

It does this one thing. It doesn't curate, it doesn't summarize, it doesn't have opinions about what's interesting. That's for whatever calls it.

Install

The CLI is metatron. The published package is metatron-cli (the bare metatron name was already taken on PyPI):

pipx install metatron-cli                                   # from PyPI
pipx install git+https://github.com/mattweberio/metatron    # from GitHub (latest main)

Configure

metatron config init       # writes ~/.config/metatron/config.toml
metatron config show       # prints the resolved config

Edit ~/.config/metatron/config.toml. The LLM tiebreaker — needed to catch "same story, different outlet" duplicates — requires an Anthropic API key:

[llm]
api_key = "sk-ant-..."
model = "claude-sonnet-4-6"

[api]
api_token = "your-bearer-token"

Without an LLM key, dedup falls back to URL + normalized-title matching only. Cross-outlet duplicates from different sources will leak through.

Run

metatron serve             # HTTP API on 127.0.0.1:8765

Use

Bearer-token auth on everything except /health.

TOKEN="your-bearer-token"
BASE="http://127.0.0.1:8765"

# Create a project
curl -s -X POST "$BASE/projects" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name": "ai-news"}'

# Add feeds
PROJECT_ID=...
curl -s -X POST "$BASE/projects/$PROJECT_ID/feeds" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://hnrss.org/frontpage"}'

# List deduplicated articles
curl -s -H "Authorization: Bearer $TOKEN" \
  "$BASE/projects/$PROJECT_ID/articles?limit=20"

# Force a synchronous refresh
curl -s -X POST -H "Authorization: Bearer $TOKEN" \
  "$BASE/projects/$PROJECT_ID/refresh"

Bulk feed import

metatron seed-feeds my-project ./feeds.json

Where feeds.json is:

{
  "feeds": [
    { "url": "https://hnrss.org/frontpage", "name": "Hacker News", "category": "tech" },
    { "url": "https://www.theverge.com/rss/index.xml", "name": "The Verge", "category": "tech" }
  ]
}

How dedup works

Cheapest-to-most-expensive, short-circuits on first match:

  1. Canonical URL. Strip utm_*, fbclid, etc. Same canonical URL → exact duplicate, dropped.
  2. Normalized title. Lowercase, drop punctuation, strip newsroom prefixes ("BREAKING: ", "UPDATE - "). Same → joins the existing article's cluster.
  3. Token overlap. Jaccard similarity on title + summary tokens. ≥0.12 → shortlist candidate (top 5).
  4. Sonnet tiebreaker. Claude Sonnet reads both articles and decides "same story" or "different story." Same → joins cluster.

Articles in a cluster are stored individually (you can see the alternative sources via GET /articles/{id}) but /projects/{id}/articles returns only the canonical from each cluster.

Storage

Single SQLite file at ~/.local/share/metatron/metatron.db. WAL mode, FK constraints on. Override with [database].path in config.

API endpoints

Method Path Description
GET /health Liveness; reports LLM enablement
POST /projects Create a project
GET /projects List projects
DELETE /projects/{id} Delete a project (cascades feeds + articles)
POST /projects/{id}/feeds Add a feed
GET /projects/{id}/feeds List feeds
DELETE /feeds/{id} Remove a feed
GET /projects/{id}/articles?since=&limit= List deduped articles
POST /projects/{id}/refresh Synchronously poll project's feeds
GET /articles/{id} Article detail + cluster members

Development

python3 -m pytest -q

Tests cover normalization, the DB layer, the dedup pipeline (with a fake LLM judge), the feed poller (with mocked RSS), and the API surface.

License

MIT. See LICENSE.

Metadata

Release files for metatron-cli 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for metatron-cli 0.2.1
File Size Uploaded Provenance Actions
metatron_cli-0.2.1.tar.gz 41.9 kB Without provenance Details for metatron_cli-0.2.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for metatron-cli 0.2.1
File Interpreter ABI Platform Actions
metatron_cli-0.2.1-py3-none-any.whl Python 3 none any Details for metatron_cli-0.2.1-py3-none-any.whl

Total release size: 71.4 kB

Release files / metatron_cli-0.2.1.tar.gz

Download URL metatron_cli-0.2.1.tar.gz
Size 41.9 kB
Tags Source
SHA-256 checksum
How to use checksums
33491e37f70cc61a85e4816f4d7babbd5ae007ddcb390215c41ecad8c12ec145
BLAKE2b-256 checksum
How to use checksums
0de415cb416b4c285e5ad25411d613ccbb03b26d9c94811a7864fddf18ca955e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release files / metatron_cli-0.2.1-py3-none-any.whl

Download URL metatron_cli-0.2.1-py3-none-any.whl
Size 29.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5e0c9f57663da9041a4b68ff4c7e56ebc824716ff1e5aec4ad1292dd04b75257
BLAKE2b-256 checksum
How to use checksums
fd74a826f9cda6f9e4ddad5150cc16b2d83ffe1abec37096181e775a71b87e06
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Security for metatron-cli 0.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page