Expand description
FXAR v2 archive format – gear-hash chunking, BLAKE3 CAS, binary index. FXAR v2: variable-size gear-hash chunking + BLAKE3 CAS + binary index. Replaces v1’s tar+whole-file-dedup with true chunk-level deduplication.
Archive layout: HEADER | MANIFEST | CHUNK INDEX | CHUNK DATA [ | FOOTER ]
Structs§
- Chunk
Index Entry - Binary chunk index entry (48 bytes, little-endian).
- File
Version Info - Information about available versions for a file in the archive.
- Fxar
Export Stats - Statistics from an FXAR export operation.
- Fxar
Extension Directory - Directory of extension sections appended to an FXAR archive.
- Fxar
Extension Entry - A single entry in the FXAR extension section directory.
- Fxar
Header - Binary header for FXAR v2 archives (64 bytes, little-endian).
- Fxar
Import Stats - Statistics from an FXAR import/restore operation.
- Fxar
Inspect Result - Result of inspecting an FXAR archive without extracting.
- Fxar
Manifest - Archive manifest listing all files and their chunk references.
- Fxar
Manifest Entry - A single file entry in the FXAR manifest.
- Fxar
Reader - Read an FXAR v2 archive with random access.
Constants§
- FLAG_
HAS_ EXTENSION_ DIR - Flag indicating the archive contains an extension section directory.
Set in
FxarHeader.flags(bit 31 – does not overlap compression bits 0-4). - FXAR_
EXT_ CHUNK_ MAP - Extension section type: chunk-level content map.
- FXAR_
EXT_ FILE_ MAP - Extension section type: file-level content map.
- FXAR_
EXT_ HNSW - Extension section type: HNSW vector index.
Functions§
- detect_
format - Detect archive format by reading magic bytes. Returns “fxar2” for FXAR v2, “tar” for tar archives, “unknown” otherwise.
- inspect_
archive - Inspect an FXAR v2 archive and return summary info.
- prepare_
ai_ extension_ sections - Read
.foxing_index/files from disk and return them as raw(section_type, bytes)pairs ready forwrite_archive_seekable_with_ai. - read_
archive_ stream - Read an FXAR v2 archive from a non-seekable stream.
- update_
fxar_ ai_ sections - Update the AI extension sections of an existing FXAR archive in-place.
- write_
archive - Write an FXAR v2 archive from a VersionStore (streaming – appends footer).
- write_
archive_ from_ directory - Write an FXAR v2 archive directly from a directory (no VersionStore required).
- write_
archive_ from_ directory_ stream - Write an FXAR v2 archive from a directory to a non-seekable stream (appends footer).
- write_
archive_ seekable - Write FXAR v2 with seekable writer – updates header offsets in-place.
- write_
archive_ seekable_ with_ ai - write_
archive_ with_ ai_ index - Convenience wrapper: reads
.foxing_index/files viaprepare_ai_extension_sections, then writes the archive withwrite_archive_seekable_with_ai.