Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

+++ title = “The Archive Format” section = “technical” +++

The Archive Format (v2)

htpy uses a self-describing JSON archive format for storing and exchanging spectral sequence data. The format has two entity types: ModuleDefinition (input) and ComputationRecord (output).

ModuleDefinition

A module definition specifies an $A$-module:

{
  "htpy_archive": "module_definition",
  "version": 2,
  "algebra": { "type": "adem", "p": 2 },
  "generators": [
    { "name": "x0", "degree": 0 },
    { "name": "x4", "degree": 4 }
  ],
  "actions": [
    { "op": "Sq4", "input": "x0", "output": { "x4": 1 } }
  ]
}

Fields:

FieldTypeDescription
htpy_archivestringMust be "module_definition"
versionintegerFormat version (currently 2)
algebraobjectAlgebra specification (type + prime)
generatorsarrayNamed generators with degrees
actionsarraySteenrod algebra actions on generators
content_hashstringSHA-256 hash for verification

ComputationRecord

A computation record stores the output of an Ext computation:

{
  "htpy_archive": "computation_record",
  "version": 2,
  "prime": 2,
  "coordinate_system": "adams",
  "max_stem": 60,
  "max_filtration": 15,
  "num_gens": [[0, 0, 1], [1, 1, 1], ...],
  "products": { "h0": { "bidegree": [0, 1], "matrices": [...] } },
  "differentials": [...],
  "generator_names": [...]
}

Fields:

FieldTypeDescription
htpy_archivestringMust be "computation_record"
primeintegerThe prime $p$
coordinate_systemstring"adams" or "adams_novikov"
max_stem, max_filtrationintegerComputation range
num_gensarray of [n, s, dim]Ext dimensions per bidegree
productsobjectProduct matrices per generator
differentialsarrayDifferential matrices per page
generator_namesarrayOptional: names per bidegree

Product matrices

Each product entry specifies the bidegree shift and a list of matrices:

{
  "h0": {
    "bidegree": [0, 1],
    "matrices": [
      { "source": [0, 0], "matrix": [[1]] },
      { "source": [1, 1], "matrix": [[1, 0], [0, 1]] }
    ]
  }
}

The matrix at source bidegree $(n, s)$ has dimensions $\dim \operatorname{Ext}^{s,n+s} \times \dim \operatorname{Ext}^{s+s_h, n+n_h+s+s_h}$ where $(n_h, s_h)$ is the product’s bidegree shift.

Differential matrices

Each differential entry specifies a page, source bidegree, and matrix:

{ "page": 2, "source": [14, 2], "matrix": [[1, 0, 1]] }

The matrix has dimensions $\dim E_2^{s,n+s} \times \dim E_2^{s+r, n-1+s+r}$.

Motivic extensions

For motivic spectral sequences, the computation record includes:

  • has_weight: true
  • weight_range: [min_w, max_w]
  • Per-generator weights: [w_1, w_2, ...] in each node
  • Per-generator tautorsion: [k_1, k_2, ...] ($\tau$-torsion orders)

Content hashing

Module definitions include a SHA-256 content hash computed from the canonical JSON serialization (sorted keys, no whitespace). This allows verification that a computation record was produced from a specific module definition.

Backward compatibility

The v2 format uses the JSON field htpy_archive (with serde(alias = "homotopy_archive") for backward compatibility with the v1 field name). The loader tries v2 first, then falls back to v1 format.