Skip to main content

Module bundle

Module bundle 

Source
Expand description

A bot’s bundle: what a builder uploads.

One deterministic ZIP holding component.wasm (the bot, a component for the agent world), the manifest botstadia.toml, and optional ONNX models under artifacts/. A trained-policy bundle’s component.wasm is its own copy of the policy shell.

format = 1
arena = "dance-off"
payload_schema_version = 1
kind = "policy"            # policy | rust | c
nonce = "second-try"       # optional: the same code as a new bot

[[model]]                  # in order: its index is `infer`'s `model`
name = "policy"
path = "artifacts/policy.onnx"

The manifest’s model order is the model index the agent world’s infer takes. The ZIP is built deterministically (entries in name order, fixed times and permissions, one compression), so the same files always give the same bundle digest.

Structs§

Manifest
botstadia.toml.
ModelEntry
One ONNX model in a bundle.

Enums§

BotKind
How a bot was made.

Constants§

ARTIFACTS_DIR
Where models sit inside a bundle.
COMPONENT
The bot’s program inside a bundle.
MANIFEST
The manifest’s file name inside a bundle.
MANIFEST_FORMAT
The manifest format this crate reads and writes.
MAX_BUNDLE_BYTES
The largest bundle, in bytes.
MAX_MODELS
The most ONNX models one bundle may carry.

Functions§

entry_allowed
Whether a ZIP entry may be in a bundle: the component, the manifest, or a model the manifest lists.