Skip to main content

throughline-history

How a throughline graph came to be, read from git: who created each item, who signed it and when, how it changed and how the graph grew. And, for training, how several people's independent signings of the same items compare with each other and with what was finally kept.

It is the reader behind history.iddn.uk and learn.iddn.uk. Those pages run it in your own browser tab, under Pyodide, so no server ever sees your token or your graph. The same functions run on your machine through tl-history.

pipx install throughline-history
tl-history -C idd                    # every event, oldest first
tl-history -C idd summary            # per person: created, amended, signed
tl-history graphs                    # every graph in the repository: sources, registers, recorded lineage
tl-history -C idd compare --base main~3 --final main junior=review/junior senior=review/senior

Add --format json to any of them for the data the pages use.

As a library

from throughline_history import Commit, derive, summarise, compare

history = derive([(Commit(sha, author, at, message), {path: text_or_None, ...}), ...], root="idd")
history.to_json()     # {"schemaVersion": 1, "events": [...], "commits": [...]}
summarise(history)    # per item and per person
compare(base_files, {"junior": files, "senior": files}, final_files, root="idd")

For a whole repository, derive_repo follows every graph together: when each was born and removed, the sources it declares (a sibling graph, another path, or another repository at a ref), its registers, node types and link types, every item inside it, and where its links reach. A graph is shown as shaped by another only where its own throughline.toml says so in a [shaped_by] table (the tl:shape skill writes one); nothing is inferred from order, comments or composition.

from throughline_history.repo import derive_repo
derive_repo(steps).to_json()   # {"schemaVersion": 2, "graphs": [...], "lineage": [...], "events": [...], "commits": [...]}

Every commit is read against each of its parents with its own version of each file, merges included, so a branch's work is its commits' and what a merge itself changed is the merge's; a moved file is its old path going and its new one coming.

derive, summarise, compare and derive_repo read only what they are given: no git, no network, no process. The caller fetches the commits; tl-history does that from a local checkout, a page does it from GitHub.

What it reads, and what it does not

  • Items are read through throughline's own reader, so every format the graph was ever written in reads as one history. A migration rewrites a signature; it does not make one.
  • A signature is dated by the time it recorded (format 4) or, before that, by the commit that carried it, and each event says which. It carries the role it was given in and what it supersedes.
  • Every item is judged at every commit by the rules the graph's throughline.toml declared then ([ratify.roles], [ratify.requires.<type>]), through throughline's own standing: the history says when an item's signatures came to meet what its kind requires and when they stopped, when an amendment left a signature covering wording that is no longer there, and when the rules changed. A graph that declares no rules needs one signature of anyone.
  • A comparison says, for each attempt, whether its signatures would meet those rules: a junior's can be the right decision and still not be enough.
  • Roles come only from the signatures in the graph. Nothing is inferred from GitHub, and nothing is ever written.

Its own requirements are in idd/; tl -C idd context explains them.

Metadata

Release files for throughline-history 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 throughline-history 0.2.0
File Size Uploaded Provenance Actions
throughline_history-0.2.0.tar.gz 30.8 kB With provenance Details for throughline_history-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for throughline-history 0.2.0
File Interpreter ABI Platform Actions
throughline_history-0.2.0-py3-none-any.whl Python 3 none any Details for throughline_history-0.2.0-py3-none-any.whl

Total release size: 56.3 kB

Release files / throughline_history-0.2.0.tar.gz

Download URL throughline_history-0.2.0.tar.gz
Size 30.8 kB
Tags Source
SHA-256 checksum
How to use checksums
afb0be872730533e498de00e21736a5813287515fc8a13529ff86cc77fc065bf
BLAKE2b-256 checksum
How to use checksums
cda83f1a162f8eed3ad10acb97e3fb7bf3bd8ab26d68e54174fc22a92aed2d8d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Oct 26, 2026.

Transparency log

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

Download URL throughline_history-0.2.0-py3-none-any.whl
Size 25.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
869cdb06c5fddbae6df428f7ebdbffc9f231a3f5b1f4e3e5bf2f299d5b79157b
BLAKE2b-256 checksum
How to use checksums
160ef4383435e1af99f5f1b756dc9c0af6122c70f600fb49af3697cd6afeb2c2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Oct 26, 2026.

Transparency log

Security for throughline-history 0.2.0

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for throughline_history-0.2.0.tar.gz

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 Oct 26, 2026.

Transparency log

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.0 This release

2 release files Full 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