Capsule build input¶
The capsule build input records exactly what bake built one capsule from. Every input is named by digest, so the capsule can be traced back to the precise files and declarations it came from, and the record means the same thing whenever it is read.
{
"contract_version": "capsule.build_input.v1",
"produced_by": "bake",
"interface_seed": {"reusable_capability_block_id": "acme.billing", "interface_hash": "xci-sha256:a5cb0b94…"},
"source_file_digests": {"billing.py": "ec2504a0…", "billing.xci.json": "ab5db03a…"},
"generated_artifacts": [
{"kind": "adapter", "path": "capsule/acme/billing/ledger_adapter_dispatch.py", "digest": "20f83de2…"},
{"kind": "binding", "path": "python/acme/billing/ledger_guest.py", "digest": "e097f9eb…"},
{"kind": "binding", "path": "rust/acme/billing/ledger.rs", "digest": "abfc130f…"}
],
"dependency_intent": {"python": {"backend": "none", "requirements": []}, "apt": [], "image": ""},
"package_archive_digest": "9c8dc1d987eca10970c86629ca215315885382ed61e52576385caaff63a20cda",
"execution_authority_kind": "sealed_capsule_digest"
}
(The interface seed is trimmed here; the build input carries it whole.)
What it records¶
- The interface seed, whole: the block's identity, compiled interface, method numbers and dependency intent, exactly as generation wrote them.
- Every source file, by path and digest.
- Every generated file, by kind, path and digest. A generated file is
either a
bindingor theadapter, the dispatch module. - The package archive's bundle digest, linking the capsule to the archive it ships in.
- The execution authority:
sealed_capsule_digest. A capsule runs by its digest, and only by its digest.
The capsule manifest refers to the build input by its digest in
provenance.build_input_digest. See Provenance.
What it refuses¶
The build input accepts only generated bindings and dispatch modules, each named by digest, and states its execution authority as a sealed digest. Anything that could change after it was approved is refused:
generated_artifacts[0].kind must be one of ['binding', 'adapter']; a runtime stub tree is not a capsule input
Mutable paths, generated stub trees and unsealed intent are each refused by name as execution authority, because each could change after it was checked.