Skip to main content

keeptabs

Keep tabs on the subjects you care about: say what to follow, let a scheduled run collect what is new, and ask what changed.

pip install keeptabs

This is technology watch, also called horizon scanning, and veille in French. It is built to be driven by an AI agent: the agent writes the specification with you, the package does the collecting, and an agent answers your questions from what was collected.

Quick start

keeptabs init-watch "Generative AI" --example gen-ai --watch-id gen-ai
keeptabs tick
keeptabs whats-new gen-ai --as-text

The first command creates a watch from a shipped example. The second fetches every source that is due, keeps what matches, and stores it. The third prints what is new, grouped by subtopic, with links.

In Python, by watch id:

from keeptabs import tools

tools.tick()
news = tools.whats_new("gen-ai", since="3d")

Or with the stores in hand:

from keeptabs import watch_mall

mall = watch_mall("gen-ai")  # stores: items, dropped, entities, runs, digests, state
recent = [item for item in mall["items"].values() if item["score"] >= 3]

How it works

A watch is one subject you follow. Its specification is a YAML file that starts as a vague idea and gets sharper over time: a scope, subtopics with keywords, named things to track (models, libraries, companies), sources, and how often to report.

A tick is one run. It works out which sources are due from their stored state, fetches them, drops what it has already seen, scores each item against the specification, and stores what is relevant. It is safe to run as often as you like, so any scheduler can trigger it.

A digest is the answer to "what's new": the items acquired since the last one, grouped by subtopic. It is stored locally, and sent to the channels you chose only if you turned that on.

Everything is stored under ~/.local/share/keeptabs/, in stores with a dictionary interface:

specs/<watch id>.yaml
data/<watch id>/{items,dropped,entities,runs,digests,state}/<key>.json

Set KEEPTABS_ROOTDIR, or pass rootdir=, to put it elsewhere.

Building a watch

keeptabs init-watch "Music AI" --intent "real-time music generation and gesture control"
keeptabs add-keywords music-ai "real-time music generation, neural audio synthesis" --subtopic "Real-time generation" --priority high
keeptabs add-entity music-ai "Magenta RealTime" --kind model --aliases "Magenta RT"
keeptabs add-source music-ai arxiv 'cat:cs.SD AND all:"real-time"' --cadence 1d
keeptabs add-source music-ai github_releases magenta/magenta-realtime --keep-all
keeptabs add-source music-ai feed https://example.org/blog/feed.xml --cadence 12h
keeptabs tick --watch music-ai --force
Source kind Target Notes
feed feed URL RSS, Atom or JSON Feed, fetched conditionally
arxiv arXiv query newest first
github_releases owner/name releases of a repository
hackernews search words
news_search search words news articles
email sender address newsletters in a mailbox, read through correspond; needs pip install 'keeptabs[mail]'

Some things only you can do, such as subscribing to a newsletter or providing a key. An agent records them with keeptabs add-action, the sources that depend on them are skipped until keeptabs resolve-action, and keeptabs pending lists what is waiting on you.

Asking

keeptabs whats-new music-ai --since 3d --as-text
keeptabs items music-ai --query "latency" --entity magenta-realtime
keeptabs entities music-ai
keeptabs due          # what runs next, what is failing

Add --json to any command for the full result.

Scheduling

keeptabs schedule                 # a launchd entry on macOS, a cron line elsewhere
keeptabs schedule --kind systemd

It prints the entry and how to install it. It installs nothing.

Digests

In the specification:

digest:
  cadence: 1w
  channels:
    - email:someone@example.org
    - github:owner/repo#12      # a discussion
    - slack:                    # webhook URL in KEEPTABS_SLACK_WEBHOOK_URL
    - slack:team                # webhook URL in KEEPTABS_SLACK_WEBHOOK_URL_TEAM
  auto_send: false

keeptabs digest <watch> is a dry run: it shows the digest and what would be sent where, and changes nothing. keeptabs digest <watch> --send sends that same digest, and from then on its items count as reported. The scheduled run writes the digest to the local store, and sends it only when auto_send is true. With channels and no auto_send, the items wait for your --send. Items count as reported only once every channel took the digest, so one that did not arrive is sent again. Email and GitHub go through correspond, so they pass its outbound checks.

What the items say was written by other people. Titles and summaries are escaped in a digest, and every link is built from a stored item's URL.

Agent skills

Two skills ship with the package, in keeptabs/data/skills/:

  • keeptabs-spec: create and refine a watch with the user.
  • keeptabs-ask: answer questions from what a watch collected.

Extending

Each part that you may want to replace is one keyword argument of tick or make_digest, with a default that works out of the box.

Argument Default Replace it to
rootdir= ~/.local/share/keeptabs keep the local files elsewhere
specs=, malls=, lock= local files, a local file lock store elsewhere, with any MutableMapping
fetchers=, http_get= standard library HTTP, feedparser add a source kind, or use another HTTP client
matcher= whole-word keyword scoring score with embeddings or a model, detect near-duplicates
summarizer= Markdown, no model write the digest with a model
senders= correspond, a Slack webhook add a delivery channel

A source kind is any name that has a fetcher at run time. A kind of your own says what to fetch in its target field:

from keeptabs import tick


def fetch_my_api(source, *, state, http_get):
    reply = http_get(f"https://api.example.org/new?q={source['target']}")
    ...
    return items, state  # items: dicts with at least 'url' and 'title'


tick(fetchers={"my_api": fetch_my_api})  # for sources with kind: my_api

A matcher receives the watch's stores, so it can compare an item with what is already there:

def matcher(item, spec, *, mall):
    ...
    return {
        "score": 3.0,
        "subtopics": [],
        "entities": [],
        "matched": [],
        "duplicate_of": None,
    }

To keep everything in stores of your own, give both, and the run takes no local lock:

tick(specs=my_specs, malls=lambda watch_id: my_stores_for(watch_id))

The command line and the shipped skills run with what keeptabs.tools.components returns, which is the one place to change for another surface.

What it does not do yet

  • It does not discover new things to track by itself: an agent adds them with add-entity. A matcher of your own may name new things, which are stored as candidates.
  • It matches by keywords. Near-duplicates under different URLs are stored separately.
  • An item judged irrelevant is not judged again when the keywords change later. It is kept in the dropped store, with its score.
  • Newsletter reading keeps one item per message, filtered by sender.

Metadata

Release files for keeptabs 0.0.2

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

Source distribution (sdist)

Source distribution for keeptabs 0.0.2
File Size Uploaded Provenance Actions
keeptabs-0.0.2.tar.gz 44.1 kB Without provenance Details for keeptabs-0.0.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for keeptabs 0.0.2
File Interpreter ABI Platform Actions
keeptabs-0.0.2-py3-none-any.whl Python 3 none any Details for keeptabs-0.0.2-py3-none-any.whl

Total release size: 86.9 kB

Release files / keeptabs-0.0.2.tar.gz

Download URL keeptabs-0.0.2.tar.gz
Size 44.1 kB
Tags Source
SHA-256 checksum
How to use checksums
be3b7855b3464ba0656c725a6cb4341f89cceed2d4215321f44a15874b46cc86
BLAKE2b-256 checksum
How to use checksums
59c1efd510f4b2cd0077e359b86dae0c0cf5533d7477c3824b1eb3d928869260
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.9 {"installer":{"name":"uv","version":"0.13.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / keeptabs-0.0.2-py3-none-any.whl

Download URL keeptabs-0.0.2-py3-none-any.whl
Size 42.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f78f8231b338175dc70d41849490334d2f02fe5e7f3fd13213cf726a30378d28
BLAKE2b-256 checksum
How to use checksums
a0a06fcff501e85db6c7d495f01b2185a8074cb3011b5ec92e1fc29e92bb8fa4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.9 {"installer":{"name":"uv","version":"0.13.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for keeptabs 0.0.2

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.0.2 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