Skip to main content

kmint

The Assertion ingestion engine — one installable, one console script (kmint) that executes the URBA-0003 micro-decision lifecycle as graph + lake mutations. It is the write engine of the sovereign Knowledge map's Assertion face; kledger is the read appliance it writes into.

Implements ADR-TECH-STRAT-001 (§"kmint — the Assertion ingestion engine") and ADR-TECH-STRAT-004 (the 5-state / 4-event machine + actor model), both in banking-knowledge.

Where kmint sits

Repo Org Role
banking-knowledge papeete-foundry The contract — schema v1 + lifecycle ADRs. Documentary.
kledger papeete-foundry The appliance — schema + deploy + read-only resolver + validation.
kmint (this repo) papeete-hub The ingestion CLI — writes both planes. Sibling of kpack.

kmint is to Assertion what kpack is to packaging: a single shared engine, run against a running kledger appliance over the same env-var substrate contract (NEO4J_*, S3_*). It does not import kledger; the appliance owns schema application and the read path.

The lifecycle it executes (the URBA-0003 spine)

S0 Capture   →  S1 Distillation (N→1)  →  S2 Refinement  →  S3 Archival / Purge
  • S0 Capture — store verbatim bytes in the immutable lake (content-addressed by checksum), mint a :Capture + :Capturing activity. Bytes are immutable from here.
  • S1 Distillation — read 1..N sources (:Capture, the Published corpus, prior candidates) and mint a brand-new :MicroDecision in SubmittedForRefinement (sources never mutated), DERIVED_FROM all of them, GENERATED_BY a :Distillation carrying the disposition. Non-Candidate dispositions are recorded but do not advance. Idempotent on contentHash = sha256(text + sorted(lineage)) + the sequential id.
  • S2 RefinementSubmittedForRefinement → Published, gated by the transition policy. Only the deterministic actor may auto-advance; everything else is human-gated (a recorded validator basis is required). Human refinement adds VALIDATED_BY without changing primalProvider (provider ≠ validator).
  • S3 Archival / Purge — supersede/amend (prior → Archived, on a temporal or authority axis) or end-of-retention (Purged tombstone). Never deletes.

Three distillation modes behind one interface

Selected by the source-type binding (URBA-0004), one per transition actor: deterministic (the :Script actor — reproducible, audited, may auto-advance) / llm (LLM-bounded, defaults to human-gated) / human (human-gated). Conservative default: origin uncertain ⇒ llm-tool ⇒ human-gated.

Ingestion is cadence-driven and hybrid: the URBA-0004 cadence selects batch (one-shot | static) vs streaming (recurring-stream | continuous).

Append-never-erase

kmint is the only writer, and it never deletes: graph.GraphWriter refuses any query containing DELETE/REMOVE as a hard backstop (Rule F). Discard/replace is a state change plus a SUPERSEDES / REVISION_OF edge.

Install & use

pip install -e ".[dev]"        # or: pip install -e ".[dev,lake]" for the S3 writer
make test                      # unit tests — no engine needed

kmint capture transcript.txt --form verbatim --capture-id cap-1 --domain MEMORY --dry-run
kmint distill --text "Retention defaults to 7 years." --domain MEMORY \
      --actor human --source cap-1 --source-confidence 3
kmint refine BNK.KNOW.MD.MEMORY.001 --actor human --validator alice
kmint archive BNK.KNOW.MD.MEMORY.001 --by BNK.KNOW.MD.MEMORY.005 --axis authority

make smoke runs an end-to-end capture→distill→refine against a throwaway neo4j:5-enterprise (point KLEDGER_SCHEMA at kledger/schema/schema.cypher to exercise the LOCKED constraints too).

Design

See docs/kmint-design.md for the ADR → implementation map and the scaffold's deferred internals.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kmint-0.1.1.tar.gz (29.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kmint-0.1.1-py3-none-any.whl (29.3 kB view details)

Uploaded Python 3

File details

Details for the file kmint-0.1.1.tar.gz.

File metadata

  • Download URL: kmint-0.1.1.tar.gz
  • Upload date:
  • Size: 29.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for kmint-0.1.1.tar.gz
Algorithm Hash digest
SHA256 36fe75b43be70951b7dacbb5c6b9c6262bb3f9f5b59c6a30bebe3f9f0c5cd04d
MD5 78a874e425e6089db21b7a49dbd579e3
BLAKE2b-256 dfed39e26d7a955a10fb3005c6ee3c1ee7b3f1899f21a2dda833e3876a036a1a

See more details on using hashes here.

Provenance

The following attestation bundles were made for kmint-0.1.1.tar.gz:

Publisher: release.yml on papeete-hub/kmint

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kmint-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: kmint-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 29.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for kmint-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d5a5fd70d5baede9574608c6836181c5eb4dfefa04f522c726616b699157b010
MD5 9f4547d36005a37974559ff3905a8021
BLAKE2b-256 3a152d0b96e8387c0d45513d7af5a013751851a951240b3757e4e55fc795e531

See more details on using hashes here.

Provenance

The following attestation bundles were made for kmint-0.1.1-py3-none-any.whl:

Publisher: release.yml on papeete-hub/kmint

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page