Expand description
The SourcePlugin contract — what a source is, to the engine.
A plugin’s only job is to land raw material in the run directory the engine hands it; the curation agent is the universal adapter, so the engine never parses source payloads. Builtins implement the trait in-process; external plugins speak the same shapes over stdio RON (harness arrives with tap support).
Structs§
- Auth
Challenge - An interactive sign-in challenge (device-code style): show the code,
send the human to the URL, poll until done. The
handleis an opaque continuation forauth_poll— the engine holds it server-side. - Context
- What the engine hands a plugin for AUTH operations. Paths are engine-owned: plugins never invent storage locations.
- Describe
- What a plugin declares about itself.
- Fetch
Request - One fetch invocation (ADR 0001). The checkpoint is a READ-ONLY snapshot of the last successfully PUBLISHED run’s successor — plugins carry no writable durable state, so no crash before publication can suppress a future fetch.
- Fetch
Result - A fetch’s result. The engine publishes the manifest atomically and only
then treats
next_checkpointas the authoritative cursor. - Item
- One PROVIDER item — a message, an event, a chat message, a recording
session, a file version. Identity is
source instance + kind + id(ADR 0001); run ids, filenames and bundle names are never identity. Serde defaults keep legacy aggregate manifests parseable.
Enums§
- Auth
Poll Result - Auth
Status - Fetch
Style - How runs of this source are bounded.
- Plugin
Request - One request to a tap binary:
<binary> --plugin <name>with this as RON on stdin, onePluginResponseas RON on stdout. Mirrors the schema protocol: a fresh process per call, no session state — checkpoints and ledgers are engine-owned, so plugins have nothing to keep alive. - Plugin
Response - RunSpec
- What the engine asks a fetch to do (matches the plugin’s declared style).
Constants§
- PROTOCOL
- The plugin contract version this engine speaks (ADR 0001).
Traits§
- Source
Plugin - The contract (ADR 0001). Builtins implement it in-process; the stdio harness for external plugins wraps the same shapes.
Functions§
- tap_
main - The whole main() of a tap binary: parse
--plugin <name>, resolve it through the tap’s own table, serve one request. Progress goes to stderr (the harness forwards it to the host’s progress sink). - version_
fingerprint - See
Item::version_fingerprint— shared with engine projections that store the components rather than the item.