Packages
Generic Elixir models and portable validation for RelayMark documents and manifests
Current section
Files
Jump to
Current section
Files
priv/relaymark/directives/relay.source_bundle.json
{
"$schema": "../schemas/relaymark-directive.schema.json",
"name": "SourceBundle",
"ast_type": "relay.source_bundle",
"version": 1,
"category": "source",
"description": "A bundle of source references that grounds a note, summary, action, or suggestion.",
"attributes": {
"id": {
"type": "string",
"required": true,
"description": "Stable host source-bundle id for evidence references; distinct from the AST block id."
},
"title": {
"type": "string",
"description": "Human-readable source bundle title."
},
"revision": {
"type": "integer",
"description": "Non-negative bundle revision. Increment when the bundle membership or locators change."
},
"source_hash": {
"type": "string",
"description": "Host-computed digest of the exact source revision set when available."
},
"scope": {
"type": "enum",
"values": ["private", "org", "unlisted", "public"],
"default": "private"
},
"confidence": {
"type": "number",
"description": "Grounding confidence from 0.0 to 1.0 when applicable."
}
},
"children": {
"mode": "block",
"allowed_types": ["relay.evidence_ref", "relay.transcript_segment", "relay.note_ref", "relay.file_ref", "relay.url_ref"],
"min": 1
},
"validation": [
"id must be unique within the document",
"revision must be a non-negative integer when present",
"the same id and revision must identify the same bundle membership and locators",
"children must resolve to concrete source refs or draft source resolution issues",
"scope must be allowed by the current document and user scope"
],
"projections": {
"relay_kit": "SourceBundle",
"html": "source-bundle",
"plain_text": "source labels",
"manifest": ["sources"]
},
"policy": {
"requires_review": false,
"requires_evidence": false,
"allows_agent_creation": true,
"visibility_attribute": "scope"
}
}