Skip to main content

Crate spec_spine_types

Crate spec_spine_types 

Source
Expand description

§spec-spine-types

The typed data substrate for spec-spine: configuration, the spec frontmatter grammar, the authority-unit and typed-edge vocabulary, the registry DTOs, schema-version constants, and the stable Error enum.

Everything here is plain, owned, serde-serializable data (no lifetimes, generics, or trait objects at the public boundary) so the same types back both the spec-spine-core engine and future FFI bindings.

See docs/design/00-architecture.md for the design and the provenance of the ported semantics.

§Layout

Re-exports§

pub use attest::ATTESTATION_SCHEMA_VERSION;
pub use attest::CompileVerdict;
pub use attest::CorpusAttestation;
pub use attest::CoupleVerdict;
pub use attest::LedgerSeal;
pub use attest::LintVerdict;
pub use attest::ToolStamp;
pub use attest::Verdicts;
pub use codebase::CodebaseIndex;
pub use codebase::Diagnostic;
pub use codebase::Diagnostics;
pub use codebase::ImplementingPath;
pub use codebase::IndexBuild;
pub use codebase::IndexPackageShard;
pub use codebase::IndexSpecShard;
pub use codebase::LineSpan;
pub use codebase::PackageKind;
pub use codebase::PackageRecord;
pub use codebase::ResolvedLocation;
pub use codebase::ResolvedUnit;
pub use codebase::SourceField;
pub use codebase::TraceMapping;
pub use codebase::TraceSource;
pub use codebase::Traceability;
pub use config::AllowlistConfig;
pub use config::BrandingConfig;
pub use config::Config;
pub use config::CouplingConfig;
pub use config::FrontmatterConfig;
pub use config::IndexConfig;
pub use config::LayoutConfig;
pub use config::ManifestConfig;
pub use config::ProvenanceConfig;
pub use config::load_config;
pub use edges::CoAuthorityItem;
pub use edges::ConstrainItem;
pub use edges::ExtendItem;
pub use edges::Origin;
pub use edges::Provenance;
pub use edges::ReferenceItem;
pub use edges::RefineItem;
pub use edges::SupersedeItem;
pub use edges::SupersedeScope;
pub use edges::SupersedeScoped;
pub use error::Error;
pub use error::Result;
pub use frontmatter::Frontmatter;
pub use frontmatter::FrontmatterIssue;
pub use frontmatter::Implementation;
pub use frontmatter::KNOWN_KEYS;
pub use frontmatter::Risk;
pub use frontmatter::Status;
pub use frontmatter::parse_frontmatter;
pub use frontmatter::parse_frontmatter_with;
pub use frontmatter::split_frontmatter;
pub use registry::Build;
pub use registry::BuildMeta;
pub use registry::Registry;
pub use registry::RegistrySpecShard;
pub use registry::Severity;
pub use registry::SpecRecord;
pub use registry::ValidationReport;
pub use registry::Violation;
pub use schema::BUILD_META_SCHEMA;
pub use schema::INDEX_PACKAGE_SHARD_SCHEMA;
pub use schema::INDEX_SCHEMA;
pub use schema::INDEX_SPEC_SHARD_SCHEMA;
pub use schema::REGISTRY_SCHEMA;
pub use schema::REGISTRY_SPEC_SHARD_SCHEMA;
pub use unit::Unit;
pub use version::BUILD_META_SCHEMA_VERSION;
pub use version::CONFIG_VERSION;
pub use version::INDEX_SCHEMA_VERSION;
pub use version::REGISTRY_SCHEMA_VERSION;
pub use version::parse_semver;

Modules§

attest
Ledger-seal DTOs (spec 023): the CorpusAttestation payload and the detached LedgerSeal envelope.
codebase
Codebase-index DTOs: the code-as-source view, emitted by spec-spine index as index.json. Field names serialize to camelCase. Shapes are ported from OAP codebase-index.schema.json (3.0.0), pruned to the generic v1 surface and re-versioned to this library’s own schema line (currently 0.3.0; see crate::version::INDEX_SCHEMA_VERSION).
config
The spec-spine.toml configuration model.
edges
The typed relationship edges and the bootstrap origin marker.
error
The single, stable error type for spec-spine.
frontmatter
The spec frontmatter grammar: the typed Frontmatter struct, the value enums, the extra_frontmatter overflow, and the parse entry points.
registry
Registry DTOs: the spec-as-source view, emitted by compile as registry.json. Field names serialize to camelCase (the JSON contract), distinct from the snake_case authored crate::Frontmatter grammar.
schema
The embedded JSON Schemas.
unit
The authority-unit grammar.
version
Schema-version constants: library-owned, started fresh at 0.1.0.