How it works

From a saved file to a history you can trust.

A precise account of what happens to your work inside AFTRIMGE, using the same terms as the architecture documentation.

  1. 01

    Your folder

    Source

    A folder you chose. AFTRIMGE only reads it, except when you restore. Its own archive is never inside it.

    watcher, normaliser, debouncer, ignore rules

  2. 02

    Observation

    Ingest

    When a file has settled, its bytes are streamed once: hashed and written to a staging file in the same pass, flushed to disk, and only then published under their digest.

    SHA-256 over exactly the bytes written, sync, rename

  3. 03

    Canonical data

    Canonical object

    Content addressed by its digest, stored once however many versions share it. Its identity and size come from the bytes themselves.

    objects/ab/cdef..., one row per distinct content

  4. 04

    Historical observation

    Snapshot

    A version of one file at one time, pointing at an object, recorded in one transaction with its event. What was observed then is never rewritten.

    files, snapshots, events in SQLite

  5. 05

    Liveness

    Retention and preservation

    Something holds content while a retained snapshot, an archived image or a preservation points at it. Retention can release a snapshot's hold; collection removes only what nothing holds.

    HolderKind: SNAPSHOT, ARCHIVED_ARTIFACT, PRESERVATION

  6. 06

    Integrity

    Integrity and recovery

    Verification reads bytes and hashes them. Restore checks stored bytes, stages, checks, replaces and checks again. Repair uses only verified sources.

    VERIFIED, CORRUPT, MISSING, UNREADABLE, UNVERIFIED

Six things AFTRIMGE keeps apart

KindWhat it isWhere it comes fromCan it change?
Canonical dataAn object's identity and sizeThe bytesNo. Different bytes are a different object.
Historical observationA path, a time, the size a snapshot sawWhat was recorded thenNo. It is kept as observed.
Derived informationThumbnails, measurements, relationship grades, tracesComputation over the aboveRecomputed; a newer analysis version is reported as newer, not substituted.
LivenessWhether content is still heldThe holders that point at itYes, as holders are added or withdrawn.
IntegrityWhether stored bytes still match their identityReading and hashing the bytesOnly by checking again.
PreservationYour decision to keep contentYouOnly by you.

The storage ledger

Every piece of content AFTRIMGE knows about, or finds on disk, has exactly one state.

HELD
Something holds it. A sweep will not remove it.
RECLAIMABLE
Nothing holds it. A sweep may remove it.
MISSING
Known, and its bytes are not on disk. The record is kept on purpose.
UNTRACKED
Bytes on disk with no record, the residue of an interrupted write.

When something goes wrong

AFTRIMGE is tested by terminating its own process at arbitrary moments during capture, collection and restore. After every kill the database passes SQLite's integrity check, no reference dangles, no version that claims its bytes lacks them, and a restored file is always one whole version.

What a crash can leave is stated rather than hidden: partial staging files, cleared at next launch; untracked bytes, reported and later swept; and a temporary copy beside a file being restored. Power loss has not been tested.

Recovery and restore

Evidence grades

GradeMeansExample
FACTProven by the operating system or by identical content hashesA rename the OS reported; two files with the same bytes
INFERREDA reproducible deterministic deduction from real evidenceA move recognised by content; an image measured as a resized copy
POSSIBLEReal evidence that did not reach the thresholdA plausible but unconfirmed source
TEMPORALKnown only from timing. Says when, never whyOne file appearing shortly after another changed

The full design, including every invariant and the defects found while building it, is in the architecture documentation.