Transcendental compaction

PiLSMer

A data-free key-value store. Pi for storage. Regret for reads.

PiLSMer writes your data normally, then uses planning or compaction to replace stored values with instructions for finding equivalent byte sequences inside a deterministic stream. Reads still work. Everything else gets worse.

0
philosophical user bytes stored after pure planning
philosophical compression ratio, when purity survives
4
deterministic stream families in the demo build
2 codecs
compact binary and ceremonial CBOR regret
01Demo

The value survives. The storage does not.

The canonical demo writes a JSON invoice, explains the raw envelope, rewrites it into a plan, explains the damage, and reads the original bytes back.

pilsmer-demo - zsh
$ cargo run -q --bin pilsmer -- init /tmp/pilsmer-demo/db
$ printf '{"total":49.99,"status":"paid"}' > /tmp/pilsmer-demo/invoice.json
$ cargo run -q --bin pilsmer -- put /tmp/pilsmer-demo/db invoice:123 /tmp/pilsmer-demo/invoice.json
$ cargo run -q --bin pilsmer -- explain /tmp/pilsmer-demo/db invoice:123
storage_class: Raw
logical_user_bytes: 31
physical_value_bytes: 56

$ cargo run -q --bin pilsmer -- plan-key /tmp/pilsmer-demo/db invoice:123
planned: invoice:123

$ cargo run -q --bin pilsmer -- get /tmp/pilsmer-demo/db invoice:123
{"total":49.99,"status":"paid"}

After planning

storage_classPlan
logical_user_bytes31
physical_value_bytes1,184
plan_metadata_bytes1,128
philosophical_user_value_bytes_stored0
philosophical_compression_ratioinfinity
metadata_amplification38.19x
02Mechanism

Compaction into nonexistence.

PiLSMer keeps SlateDB as the storage engine and moves the absurdity into envelopes, stream indexes, planner output, reconstruction, and the compaction filter.

PUT bytes normal write Raw envelope SlateDB value Planner find bytes in stream Plan offsets and hashes pi / e / sqrt2 / sha256 deterministic stream registry GET reconstructs logical hash verified π
04Metrics

Everything else gets worse.

The metrics are intentionally incriminating. The system can report zero philosophical user bytes stored while physical metadata grows.

pilsmer metrics
$ cargo run -q --bin pilsmer -- metrics /tmp/pilsmer-demo/db
pilsmer_raw_values_total 1
pilsmer_planned_values_total 2
pilsmer_logical_bytes_total 98
pilsmer_physical_value_bytes_total 3184
pilsmer_plan_metadata_bytes_total 2960
pilsmer_stream_prefix_bytes_indexed 65536
pilsmer_metadata_amplification_ratio 30.20
pilsmer_philosophical_compression_ratio infinity
pilsmer_philosophical_purity_violations_total 0

Useful damage

MetricValue
raw values1
planned values2
logical bytes98
physical value bytes3,184
plan metadata bytes2,960
stream prefix indexed64 KiB
metadata amplification30.20x
purity violations0
05Capabilities

Properties of a worse storage engine.

05.1

SlateDB-backed LSM

PiLSMer keeps the object-storage-native LSM and wraps the value semantics.

05.2

Value envelopes

Raw and planned values use typed envelopes so direct engine reads stay honest.

05.3

Stream registry

Plans refer to versioned stream identities and fingerprints, not a private cache file.

05.4

Dynamic planner

The planner chooses located chunks across indexed deterministic stream prefixes.

05.5

Hash verification

Reconstruction checks logical hashes before bytes leave the wrapper.

05.6

Guarded planning

`plan-key` rewrites a single key after checking the source envelope has not changed.

05.7

VACUUM MEANING

Existing values can be replanned under a budget to improve the shape of regret.

05.8

Standalone compactor

The compactor path makes compaction into nonexistence observable in demos.

Your data is not stored. It is merely located.

See the demo · Source on GitHub