Skip to main content

Crate vibe

Crate vibe 

Source
Expand description

VibeScript (vibe-0.1) — a language for humans and machines.

Vibe is the scripting language (the JS replacement). Poet is the human creative environment and CLI that hosts Vibe; other hosts may too.

Copyright © 2026 Timothy Charles Holborn. All rights reserved. No JIT. No raw Quin overlay literals.

Re-exports§

pub use dag::ControlUnit;
pub use dag::DagEdge;
pub use dag::DagError;
pub use dag::DagNode;
pub use dag::DagPipeline;
pub use dag::ExecutionState;
pub use dag::JudgeClaim;
pub use dag::JudgeFrame;
pub use dag::NodeEffect;
pub use dag::NodeStatus;
pub use dag::RouterStrategy;
pub use dag::MAX_DAG_EDGES;
pub use dag::MAX_DAG_NODES;
pub use dag::MAX_JUDGE_CLAIMS;
pub use dag::MAX_NODE_IO;
pub use deontic_interrupt::AgentSandbox;
pub use deontic_interrupt::DeonticInterrupt;
pub use deontic_interrupt::InterruptType;
pub use deontic_interrupt::LeaseError;
pub use deontic_interrupt::Phase;
pub use deontic_interrupt::PhaseLeaser;
pub use deontic_interrupt::MAX_CAPS_PER_PHASE;
pub use deontic_interrupt::MAX_PHASES;
pub use deontic_interrupt::MAX_SANDBOX_AGENTS;
pub use topology_decl::parse_geometry_blocks;
pub use topology_decl::parse_geometry_or_topology;
pub use topology_decl::BoundaryDecl;
pub use topology_decl::GeometryDecl;
pub use topology_decl::HarbouredGraphDecl;
pub use topology_decl::TopologyInvokeDescriptor;
pub use projectional::apply_edit;
pub use projectional::apply_edits;
pub use projectional::make_binary;
pub use projectional::make_call;
pub use projectional::make_field;
pub use projectional::make_float;
pub use projectional::make_ident;
pub use projectional::make_int;
pub use projectional::make_law;
pub use projectional::make_material;
pub use projectional::make_member;
pub use projectional::make_string;
pub use projectional::project_program;
pub use projectional::Edit;
pub use projectional::ProjectOptions;
pub use reactive_cell::ReactiveCell;
pub use reactive_cell::ReactiveCellError;
pub use reactive_cell::ReactiveCellGraph;
pub use reflection::ReflectionConfig;
pub use reflection::ReflectionEngine;
pub use reflection::ReflectionLoop;
pub use reflection::ReflectionResult;
pub use reflection::StageResult;

Modules§

animation
VibeScript Zero-Heap Animation System.
ast_merge
3-Way AST Structural Merge for VibeScript.
bytecode
vibe-bc-0.1 bytecode compiler, VM, and binary codec.
capability_schema
Machine schema exports for all bound host call ids (T51).
catalog
Catalog of host Family.method invoke ids.
conditioning
Vibe-facing conditioning profile DTO and graph projection (P1B). No invented Host invoke IDs. Neutral statements only.
cosmic
Omniversal Coordinate System (OCS) — cosmic coordinate types.
crypto
Cryptographic operations — hashing, AEAD, KDF, signing (T-crypto).
dag
A6 — Multi-Agent DAGs & Autonomous Control Units.
decompiler
Bi-directional Poetic Decompiler for VibeScript (Zero-Heap friendly).
deontic_interrupt
A8 — Hardware Deontic F(φ) Interrupts & Phase Leasing.
extension_registry
VibeScript 0.03 Extension Registry, Cold Preparation, Zero-Heap Hot Dispatch, and Deterministic Domain Provider Adapters (VS03-06, VS03-07, VS03-08).
frame_morphism
Frame morphisms — Galilean now, Lorentz later (W5).
hid
Inbound event record ABI for HID/sensors (T41).
law_package
Law packages as signed content (T72, W10).
locale
Keyword locale tables — multi-lingual keyword views (T37).
metamodel
VibeScript metamodel registry and semantic projection (Prompt Precision P1A).
module_system
Module system — import <iri> as name with a module graph (T63).
observer
Observer context, heraldic lexicon, multi-scale sheaves, civic time, and agent characteristics (W7, W9, W14, W15, T59).
physics
Physics & Creator Physics module (Fields, Materials, Interaction Laws, Continuant WorldLines, and Frame Morphisms).
presentation
Presentation morphism as a sheaf (T69).
pretty
Pretty printer for field/material/law declarations (W16).
projectional
Projectional authoring — structure is the source of truth, text is a view (W1).
quantity
Quantity dimension algebra and unit conversions (T73).
reactive_cell
reflection
A3 — Dynamic Reflection & Self-Healing Loop.
replay_clock
Deterministic replay clock — the only WASM clock (W12, T71).
session
Bounded in-memory checked source sessions for the pinned 0.1 interpreter. This is not durable project recovery, live definition replacement, or a job API.
sheaf
Sheaves, stalks, simplex, and topological tears (T47–T50).
stdlib_v2
VibeScript v0.02 (vibe-0.2) Standard Library — Directory-Backed Library (AGENTS.md §0-B).
task_scheduler
Bounded local deferred tasks. Execution is synchronous on the admitted AST engine.
tick_policy
Tick policy under load — drop / coalesce / tear (T68).
topology_decl
Declarative VibeScript geometry and topology complex parser and capability lowerer.
translate
Bidirectional keyword translation via canonical AST (T38, T39).
trivia
CST trivia — comments, whitespace, and exact token text (T36).
vocab
Vocab chunks: bounded N3/Turtle slices with a content hash (P17.1).
web_runtime
VibeScript v0.02 Web Server, CBOR-LD & Zero-JavaScript UI/Form Runtime (web.*, cbor_ld.*, ui.*, form.*, input.*, selection.*, validate.*, layout.*).

Structs§

AliasRow
Alias row for migrate / suggested_fix (shape doc).
BindDecl
Two-way binding: bind left <-> right using Clamp[0, 1] resolve latest;
Block
Budget
CapSpec
CellDecl
A reactive cell declaration (e.g. cell score := math.clamp(raw, 0, 100);).
CheckResult
ColorLit
Packed sRGB + alpha from a #rgb / #rrggbb / #rrggbbaa literal.
ConservationResult
A conservation law check result (T34).
ConstDecl
DiagnoseReport
Result of diagnose.
Diagnostic
DisclosureBoundary
Four-bit disclosure boundary (T56). Each bit is independent.
Duration
An exact duration: secs + nanos. No float subtraction (T2).
Engine
EnumDecl
A user-defined enum declaration (T9).
EnumValue
A user-defined enum value (T9). Carries the enum name, variant name, and optional payload values. Unit variants have an empty payload.
EnumVariant
A variant of a user-defined enum (T9).
Env
Expr
FieldDecl
A field declaration (T28).
FieldRef
An opaque handle to a sampled field (T5). Scripts do not see the grid.
Frame
A reference frame: origin + basis vectors (T4).
FunctionDecl
HookDecl
ImportDecl
Instant
A point in time with a known scale, exact secs+nanos, and an optional cryptographic seal (T1).
LawDecl
A law declaration (T30).
LexiconPin
Recorded lexicon: "packId@SemVer" pin.
LocalHost
In-process host: graph/pulse/time in memory, catalog kernels for Animation/etc.
LocaleDecl
MatchArm
MaterialDecl
A material declaration (T29).
MaterialRef
An opaque handle to a material signature (T5).
Mixture
A mixture of chemical species with composition data (T33).
ModuleDecl
NamedArg
PackManifest
Minimal pack-manifest field read (fixture / example JSON; no serde).
Param
Policy
A named policy with a query pattern and a violation message.
PolicyViolation
A policy violation found by the AST query engine.
Pose
A pose: position + orientation within a frame (T4).
PrefixDecl
PresentDecl
present lamp { color: glow, pose: spin } — a presentation sheaf surface.
Program
Quantity
A physical quantity: a value with a required unit IRI (T3).
QuinRef
An opaque 48-byte handle to a Super-Quin / NQuin (T7).
Span
SpeciesRef
An opaque handle to a chemical species (T33).
Transform
A transform: translation + rotation + scale (T4).
TypeExpr
WorldLine
A worldline: a continuant through Instant × Pose (T6).

Enums§

AccelerationTier
Acceleration the host will actually use this pass (P16.1). Default is scalar. SIMD/GPU must be measured, not advertised.
Arg
ArmBody
BinOp
BindResolve
CausalRelation
A causal relation between two events in spacetime (T35).
ConservationQuantity
The conserved quantity being checked (T34).
DecodeError
DiagCode
EffectClass
ExprKind
FieldRepresentation
Field representation describes storage/computation (T28).
FieldSupport
Field support describes spatial distribution (T28).
HostEnvironment
Where the host is running (P16.1).
IdentifierPolicyError
The result of validating a Unicode identifier.
Item
LexiconFraming
Pack framing — living senses must not be Thing-washed as artifact.
Literal
Miscibility
Miscibility between mixtures (T33).
MixturePhase
Phase of a mixture (T33).
ModalKind
The first-class logic modalities supported in VibeScript.
Pattern
QueryPattern
An S-expression query pattern that matches against AST nodes.
Stmt
TimeScale
Time scale for an Value::Instant.
UnOp
Value

Constants§

CELL_BATCH_NATIVE
Native ready-cluster ceiling (P16.2).
CELL_BATCH_WASM
WASM sequential chunk (P16.3).
DEFAULT_CONTEXT_IRI
DIAGNOSTIC_SCHEMA_JSON
EBNF
EXAMPLE_PIN
Example pin matching docs/manuals/standards/lexicon-pack-manifest-example.json.
GBNF
HELD_OPEN_PACK
Soft why-text for missing / unknown pack. Never “broken”.
HOST_VERSION
Current host ABI stamp (Host::host_version). vibe-host-0.1 is the incorporation outcome, not an ALL_BOUND freeze.
LANGUAGE_VERSION
LEXICON_MANIFEST_ID
Live bind id (already in ALL_BOUND). Catalog-honest; not a new Host method.
MAX_DIAGNOSTICS
Collect up to 8 diagnostics instead of stopping at the first (audit §7.12).
MAX_IDENT_LEN
Maximum identifier length.
SENTINEL_BYTES
42 MB Prolog Sentinel ceiling (AGENTS.md).
SOURCE_SCHEMA_JSON
TAG_CBOR_LD_COMPRESSED
TAG_CBOR_LD_UNCOMPRESSED
TAG_VIBE_AST
TAG_VIBE_DISCLOSURE_DENIED
TAG_VIBE_DURATION
TAG_VIBE_INSTANT
TAG_VIBE_IRI
TAG_VIBE_QUANTITY
TAG_VIBE_QUIN_REF

Traits§

Host
Host supplied by Qualia / tests.

Functions§

add_f64_slices
Elementwise out[i] = a[i] + b[i]. AVX-512 when present; else scalar.
alias_migrate_report
Held report whose suggested_fix is alias-row JSON (migrate / upgrade).
alias_rows_suggested_fix
Encode alias rows as suggested_fix JSON array.
apply_upgrade_map
Applies upgrade-map.
builtin_policies
The built-in policy set: mandatory-take, forbidden-call, tick-no-external.
call_cbor_ld
Dispatches cbor_ld.* built-in calls for VibeScript (vibe-0.1).
cell_batch_cap
Cell batch capacity.
check_cell
Checks cell.
check_custom_policies
Run a custom set of policy queries against a program.
check_policies
Run all built-in policies against a program. Returns a list of violations. If empty, the program passes all policies.
check_program
Checks program.
check_program_all
Checks program-all.
check_program_with_vocab
After a successful check, fail closed on prefixed names missing from a loaded vocab chunk.
compress_iri
Compresses an IRI or property term into either a compact static table ID (1..=1023) or a deterministic 60-bit FNV-1a token with bit 59 set (DYNAMIC_TERM_BIT).
could_be_unicode_ident_start
Check if a byte sequence could be the start of a Unicode identifier (i.e., a multi-byte UTF-8 sequence starting with a non-ASCII byte that is XID_Continue).
decode
Decodes CBOR.
decode_value_cbor_ld
Decodes compressed (0x0501) or uncompressed (0x0500) CBOR-LD bytes into (context_iri, Value).
derive_provider_namespace
Derives (normalized_host, effective_tld, namespace_iri) from a provider domain, URL, or TLD.
detect_available_tier
What the CPU/adapter could run. Not what this eval pass is using.
diagnose
Parse and type/effect-check. Cells start with =. Does not evaluate. When a contradiction/conflict is detected, attaches evidential annotations (μ = 1.0, λ = 0.0).
diagnose_lexicon_pin
Pin-aware diagnose hook for Neo (no disk).
dispatch_hook
Dispatch a hook event on a checked program.
encode
Encodes CBOR.
encode_value_cbor_ld
Encodes a runtime Value into deterministic compressed W3C CBOR-LD (0xD9 0x0501).
eval_cell
Parse, check, and evaluate a Pure cell (= expr).
eval_function
Evaluate a named function from a checked program. Import aliases from the program are populated into env before evaluation.
expand_term
Expands a compressed term ID back to a static IRI/term or a deterministic did:q42:term:<hex> topological identifier for dynamic 60-bit tokens.
function_has_budget
Check if a function has a budget.
gpu_missing
GPU missing → stay on bytecode / scalar CPU.
hook_has_budget
Check if a hook has a budget.
ingest_json_with_provider_ns
Parses raw JSON, uplifts all bare property keys into the provider’s domain/TLD namespace (https://{host}/ns#{key}), and encodes the uplifted structure into compressed CBOR-LD (0x0501).
is_bidi_control
Check if a character is a BiDi control character.
is_xid_continue
Check if a character is XID_Continue (valid in identifiers).
is_xid_start
Check if a character is XID_Start (valid as first character). We use XID_Continue for both (like Rust), which allows _ as a start character.
living_rewritten_as_artifact
true when living content was rewritten as an artifact.
llm_missing
Local model missing → diagnostic. Consented remote is not implied.
load_program
Parse and check a module. Does not run hooks.
missing_pack_report
Expected DiagnoseReport when lexicon_manifest is missing / unknown.
parse_alias_rows_json
Round-trip alias rows out of a suggested_fix JSON array (or mixed text).
parse_cell
Parses cell.
parse_lexicon_pin_from_source
Scan comment/header lexicon: "packId@SemVer" and const lexicon = "…".
parse_pack_manifest_json
Parses pack-manifest-json.
parse_program
Parses program.
parse_query
Parse an S-expression query string into a QueryPattern.
populate_import_aliases
Populate env.aliases from a program’s import declarations. Each import "vibe:0.1/graph" as g; maps g -> graph. Also supports Vibe 0.03 extension namespace IRIs and short aliases (mech, gpu, infer, qgraph, modality).
run_policies
Run a set of policies against a program and return all violations.
validate_identifier
Validate a Unicode identifier against the full security policy.