Skip to main content

Digest Generator

Python PyTorch CUDA License

Overview

Digest Generator is a Python pipeline that aggregates articles from RSS feeds you define, generates fact-dense per-article summaries via an LLM, classifies them with zero-shot NLI, and produces a Markdown digest via Ollama. Feeds, sections, and prompts are all user-supplied; the tool ships generic baselines so it runs on any topic out of the box.

How It Works

flowchart LR
    Feeds[("RSS")]:::storage

    subgraph S["run --no-digest"]
        direction TB
        Fetch:::compute --> Summarize:::compute --> Classify:::compute
    end

    JSON[("JSON")]:::storage

    subgraph D["digest"]
        direction TB
        Writer:::compute --> Editor:::compute
        Editor --> Framer:::compute --> Watcher:::compute --> Composer:::compute
        Editor --> Composer
        Framer --> Composer
    end

    MD[("digest.md")]:::storage

    Feeds --> Fetch
    Classify --> JSON
    JSON --> Writer
    Composer --> MD

    classDef compute fill:#fed7aa,stroke:#9a3412,color:#0f172a
    classDef storage fill:#e5e7eb,stroke:#374151,color:#0f172a

digest-generator run does both halves end to end, writing the JSON corpus and the final Markdown digest into the same run directory. You can also run the halves separately: run --no-digest stops after building the corpus, and digest <run_dir> turns an existing corpus into a digest.

For full usage details, see docs/usage.md.

Installation

pip install digest-generator          # or: uv tool install digest-generator
digest-generator init                 # write a starter feeds.yaml
# edit ~/.config/digest-generator/feeds.yaml to add your categories and feeds

init creates ~/.config/digest-generator/feeds.yaml from a starter template. Edit it to define your own sections (categories:) and the feeds in each, then run digest-generator feeds to check it. The digest stages need a running Ollama; the topic classifier downloads a public model on first use.

Working from a clone instead (for development or audio/GPU extras):

git clone https://github.com/laplacef/digest-generator.git
cd digest-generator
uv sync --extra dev

Configuration

Every setting has a sensible default, so most setups need no environment variables. Override via the environment or a .env file in the working directory. The common ones:

Variable Purpose Default
OLLAMA_HOST Ollama endpoint http://localhost:11434
OLLAMA_API_KEY Set to use cloud Ollama instead of local unset (local)
HF_TOKEN HuggingFace token, only for gated/private models unset
DIGEST_CONFIG Config directory holding feeds.yaml (and optional prompts/) discovery
PROMPTS_DIR Directory of prompt-template overrides bundled baselines

Every field in digest_generator/shared/settings.py maps to an uppercase env var. Full setup (prerequisites, optional audio rendering, optional GPU acceleration) is in docs/setup.md.

Usage

digest-generator init                 # write a starter feeds.yaml
digest-generator run                  # full pipeline (fetch + summarize + classify + digest)
digest-generator run --no-digest      # corpus build only (skip digest generation)
digest-generator run --audio          # full pipeline + Piper TTS rendition
digest-generator digest <run_dir>     # regenerate the digest from an existing run directory
digest-generator audio <run_dir>      # render audio for an existing digest (no LLM cost)
digest-generator lint <digest.md>     # check a digest before publishing (exits 1 on errors)
digest-generator feeds                # list available feeds

Each run lands in its own timestamped directory under output/, containing the per-stage caches, the final Markdown digest, run metadata, and a log of the run. See docs/usage.md for the full CLI reference, programmatic API, and output layout.

Contributing

Bug reports, feature requests, and pull requests are all welcome. See CONTRIBUTING.md for development setup, coding standards, and the contribution workflow.

This project follows a Code of Conduct. By participating, you are expected to uphold it.

License

This project is licensed under the Apache License 2.0. You are free to use, modify, and distribute this project, provided you include proper attribution. See the NOTICE file for details.

Release files for digest-generator 0.2.0

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

Source distribution (sdist)

Source distribution for digest-generator 0.2.0
File Size Uploaded
digest_generator-0.2.0.tar.gz 306.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for digest-generator 0.2.0
File Interpreter ABI Platform
digest_generator-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 479.7 kB

Release files / digest_generator-0.2.0.tar.gz

Download URL digest_generator-0.2.0.tar.gz
Size 306.0 kB
Tags Source
SHA-256 checksum
How to use checksums
6e8041a8a6f3ec51d057a3a53c8eb0b087e9a95ef9a0031a2e066d8af03858b3
BLAKE2b-256 checksum
How to use checksums
96a07900a30f2c362157f395ee6167f0a7645a43e0129088010ee18c373f0422
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 28, 2026.

Transparency log

Release files / digest_generator-0.2.0-py3-none-any.whl

Download URL digest_generator-0.2.0-py3-none-any.whl
Size 173.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e821821407defa7574af946d8b0e8d1442f3aedc80f56d0a01fc4dbd248713ef
BLAKE2b-256 checksum
How to use checksums
f0df828acd8298841939d3c96f7b5581456dff37b9a49a91d503534223d5e9f5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 28, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files

0.1.0

2 release files

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