Expand description
§World Manifest — the document format of the Thread
The Thread is the open, spatial, present, time-aware successor to the web: worlds are pearls strung along one Thread, linked by portals (veils you step through). This crate defines the World Manifest — the “HTML” of the Thread: an open, renderer-agnostic description of a place that any browser (Infinite is the first) can resolve and render.
Design principles (mirroring why the web won):
- Narrow waist. Every browser implements this format or nothing interops.
- Renderer-agnostic. Geometry is glTF + prefab refs + a standard material model — never a specific engine’s internals.
- Static-first, presence-optional. A world is just files (host it anywhere). Presence (shared, multi-user) is an upgrade you opt into by naming a relay; without one, the world gracefully degrades to solo.
- Meaning is native. Anything can link to a canonical [
Codex] entry. - Time is an axis. A world declares a
year; the same place is addressable across time.
See world-manifest-v0.1 for the normative specification — that document is the standard, and this crate is one implementation of it.
Modules§
- arch
- arch — the shared architecture math of the Thread
- lint
- World lint — the quality eye that runs before any screenshot
- markup
- Thread markup — the HTML/CSS authoring surface for worlds.
- model
- Model — the agent-native 3D format of the Thread
- plan
- Plan — a level design, before it knows what it is made of
- shape
- Shape — procedural geometry as manifest data
- texture
- Texture — procedural PBR materials as manifest data
Structs§
- Animate
- Declarative idle motion for a placement. Kinds (v0.1):
"spin"(rotate about the object’s own Y axis),"bob"(rise and fall around the base position), and"path"(travel a looping polyline ofpoints, offsets from the placement’s position — a patrol, a tour, a journey retraced).speedscales time (metres/second forpath);ampis metres of travel forbob. Browsers phase-shift instances so fields of movers don’t march in lockstep. - Asset
- External content referenced by id.
- Behavior
- A sandboxed WASM behavior module the world runs.
- Bounds
- Axis-aligned world bounds (advisory).
- Environment
- Environmental setup: time, sky, bounds, and the game mechanics this place enforces.
- Identity
- A portable, provider-agnostic identity (the open form of the Passport).
- Interaction
- A declarative, codeless interaction a creator attaches to a placed object.
- Light
Emitter - A point light emitted from a placement’s position. Declarative, like everything else in a manifest: worlds say what glows; the browser’s deferred lighting pass decides how the glow falls on surfaces.
- Locator
- A parsed Locator. Round-trips through
Locator::parse/ [Locator::to_string]. - Material
Ref - Standard PBR material (renderer-agnostic). Texture fields are
Assetids. - MeshRef
- How a prefab’s geometry is sourced. Exactly one field should be set.
- Placement
- One placed instance of a prefab.
- Portal
- A veil to another world — the hyperlink of the Thread.
- Prefab
- A unique renderable prefab (mesh + optional material), keyed by
StructuredId. - Presence
- Presence policy — the (optional) upgrade from a solo world to a shared one.
- Sky
- A simple gradient sky (zenith→horizon) with an optional sun direction.
- Spawn
- An arrival point.
- Structured
Id - The prefab/item id scheme, re-exported so consumers of the manifest don’t need
a direct
thread-iddependency. A structured decimal ID encoding category, subcategory, and item number. - Style
Rule - A CSS-like style rule: a selector + the properties it attaches to matching
placements. Lets a world define behaviour by
type/.class/#idonce, instead of inline on every placement — restyle everything from one rule. - Text
Link - One hyperlink in a
TextPanel:textis the phrase inside the panel’s content it anchors to (first occurrence);tois any Locator. - Text
Panel - Readable text a browser typesets onto a placement’s surface (a
quadprefab is the natural carrier). The browser owns fonts and layout — the world ships only the words, exactly like the old web shipping text and letting the browser render it. - World
Manifest - A World Manifest — one place on the Thread.
- World
Meta - Identity + descriptive metadata for the world.
- World
Rules - Opt-in game mechanics a world enforces. Default all off — the browser ships these as capabilities; a place turns on only what it needs (like a page opting into pointer lock). Interact/inspect are always available and are NOT gated here — only the game-y mechanics are.
Enums§
- Asset
Kind - What an
Assetis. - Interaction
Effect - One outcome of a completed
Interaction. Deliberately small + declarative; serialized snake_case (unit variants as bare strings) so manifests read clean. - Manifest
Error - An error parsing or validating a manifest.
- Preview
Policy - Portal preview fidelity.
Constants§
- SCHEME
- The URL scheme of the Thread.
- THREAD_
VERSION - The format version tag carried in every manifest’s
threadfield.
Functions§
- effective_
mode_ of Presence::effective_modefor callers holding raw JSON.- well_
known_ url - The canonical
.well-knownmanifest URL for a host + world path —https://<host>/.well-known/thread[/<path>]/world.json. This is the decentralized, zero-registry convention: serve a world here and any browser can reach it atthread://<host>[/<path>]. Single source of truth shared by the browser resolver and thethreadCLI.
Type Aliases§
- Extra
- Fields this build doesn’t know about, carried through untouched.