A11 (C++ runtime)
Native C++ implementation of the A11 streaming action runtime
Loading...
Searching...
No Matches
catalogue_data.h
Go to the documentation of this file.
1// Copyright 2026 The A11 Authors
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14//
15// GENERATED by scripts/generate_flow_catalogue.py. Do not edit.
16//
17// The snapshot of the world the standalone tools know with nothing
18// configured: every action the SDK registers and every type its
19// serialization registry knows. A frontend with a live registry
20// passes its own catalogue, which is merged over this.
21
22#ifndef A11_FLOW_CATALOGUE_DATA_H_
23#define A11_FLOW_CATALOGUE_DATA_H_
24
25#include <string_view>
26
27namespace a11::flow::catalogue {
28
29inline constexpr std::string_view kCatalogueSnapshot = R"catalogue(
30{
31 "actions": [
32 {
33 "description": "Describe one action this peer serves, as an a11.actions/v1 document. Fails NOT_FOUND when the name is not registered here.",
34 "inputs": [
35 {
36 "description": "Name of the action to describe.",
37 "name": "action",
38 "required": true,
39 "type": "text/plain"
40 }
41 ],
42 "name": "__get_schema__",
43 "outputs": [
44 {
45 "description": "The a11.actions/v1 document for that one action.",
46 "name": "schema",
47 "required": true,
48 "type": "application/json"
49 }
50 ]
51 },
52 {
53 "description": "List the actions this peer serves, with their schemas, as one a11.actions/v1 document. Takes an optional request object on 'request': 'names' (full-match patterns), 'exact' (names), 'ports' (\"callable\" or \"all\"), 'include_reserved', and 'runnable_only'.",
54 "inputs": [
55 {
56 "description": "Action selection and port visibility filters. Absent means all non-reserved actions.",
57 "name": "request",
58 "type": "application/json"
59 }
60 ],
61 "name": "__list_actions__",
62 "outputs": [
63 {
64 "description": "The a11.actions/v1 document, whole.",
65 "name": "actions",
66 "required": true,
67 "type": "application/json"
68 }
69 ]
70 },
71 {
72 "description": "Ping the server to check if it is alive. Requires a single value on the port `input`, which it returns as a single value on the port `output`.",
73 "inputs": [
74 {
75 "description": "Ping input value",
76 "name": "input",
77 "type": "text/plain",
78 "unary": false
79 }
80 ],
81 "name": "__ping",
82 "outputs": [
83 {
84 "description": "Pong response value",
85 "name": "output",
86 "type": "text/plain",
87 "unary": false
88 }
89 ]
90 },
91 {
92 "description": "Capture audio from an input device and stream fixed-size AudioBuffers until a stop control event arrives or the action is cancelled.",
93 "headers": [
94 {
95 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The action stops gracefully once it is reached.",
96 "name": "x-a11-deadline",
97 "type": "string"
98 }
99 ],
100 "inputs": [
101 {
102 "description": "Control commands; a stop command finishes capture gracefully.",
103 "name": "control_events",
104 "required": true,
105 "type": "application/json;type=a11.sdk.AudioControlEvent",
106 "unary": false
107 },
108 {
109 "description": "Capture parameters: device selection, sample rate, channels and the delivered buffer size.",
110 "name": "options",
111 "required": true,
112 "type": "application/json;type=a11.sdk.AudioInputOptions"
113 }
114 ],
115 "name": "capture_audio",
116 "outputs": [
117 {
118 "description": "Stream of captured AudioBuffers.",
119 "name": "audio",
120 "type": "application/x-msgpack;type=a11.sdk.AudioBuffer",
121 "unary": false
122 },
123 {
124 "description": "Stream of capture lifecycle and dropped-buffer events.",
125 "name": "events",
126 "type": "application/json;type=a11.sdk.AudioCaptureEvent",
127 "unary": false
128 }
129 ]
130 },
131 {
132 "description": "Capture audio and stream recognized text pieces until a stop control event arrives or the action is cancelled.",
133 "headers": [
134 {
135 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The action stops gracefully once it is reached.",
136 "name": "x-a11-deadline",
137 "type": "string"
138 }
139 ],
140 "inputs": [
141 {
142 "description": "Speech recognition parameters; model is required.",
143 "name": "asr_options",
144 "type": "application/json;type=a11.sdk.SpeechRecognizerOptions"
145 },
146 {
147 "description": "Optional capture parameters; the default input is used if omitted.",
148 "name": "capture_options",
149 "type": "application/json;type=a11.sdk.AudioInputOptions"
150 },
151 {
152 "description": "Control commands; a stop command finishes transcription gracefully.",
153 "name": "control_events",
154 "required": true,
155 "type": "application/json;type=a11.sdk.AudioControlEvent",
156 "unary": false
157 }
158 ],
159 "name": "capture_transcription",
160 "outputs": [
161 {
162 "description": "Stream of capture and inference lifecycle events.",
163 "name": "events",
164 "type": "application/json;type=a11.sdk.TranscriptionEvent",
165 "unary": false
166 },
167 {
168 "description": "Recognized text pieces as utterances are decoded.",
169 "name": "transcription_pieces",
170 "type": "text/plain",
171 "unary": false
172 }
173 ]
174 },
175 {
176 "description": "Copy a file or, with `options.recursive`, a directory tree. Use `read_file` and `write_file` when a Flow needs streamed progress.",
177 "headers": [
178 {
179 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
180 "name": "x-a11-deadline",
181 "type": "string"
182 }
183 ],
184 "inputs": [
185 {
186 "description": "Optional: recursive (false), overwrite (false).",
187 "name": "options",
188 "type": "application/json"
189 },
190 {
191 "description": "Path to copy; relative paths use the current directory.",
192 "name": "path",
193 "required": true,
194 "type": "text/plain"
195 },
196 {
197 "description": "Destination; relative paths use the current directory.",
198 "name": "to",
199 "required": true,
200 "type": "text/plain"
201 }
202 ],
203 "name": "copy_path",
204 "outputs": [
205 {
206 "description": "The absolute destination.",
207 "name": "resolved",
208 "type": "text/plain"
209 }
210 ]
211 },
212 {
213 "description": "Read explicitly named environment variables permitted by the host. Absent names appear on missing; an empty value remains present.",
214 "headers": [
215 {
216 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
217 "name": "x-a11-deadline",
218 "type": "string"
219 }
220 ],
221 "inputs": [
222 {
223 "description": "The variable names to read, as a string or a list of strings.",
224 "name": "names",
225 "required": true,
226 "type": "application/json"
227 },
228 {
229 "description": "Optional: omit -- output port names to close immediately rather than write; and encoding -- \"json\" (the default) or \"msgpack\", which is both cheaper downstream of a `| packb` and the only one of the two that can carry a path or a line that is not valid UTF-8.",
230 "name": "options",
231 "type": "application/json"
232 }
233 ],
234 "name": "env_get",
235 "outputs": [
236 {
237 "description": "The names that were not set at all -- which is a different thing from being set to an empty string.",
238 "name": "missing",
239 "type": "application/json"
240 },
241 {
242 "description": "An object of the names that were set to their values.",
243 "name": "values",
244 "type": "application/json"
245 }
246 ]
247 },
248 {
249 "description": "Optionally discover missing contracts for actions a flow may call. Pass names to request only the actions needed for the next step; omit names to list all permitted composable actions. Returns input and output ports plus runnable flags. Reuse known contracts in flow_run without this lookup.",
250 "inputs": [
251 {
252 "description": "Optional list of up to 12 unique action names.",
253 "name": "names",
254 "type": "application/json"
255 }
256 ],
257 "name": "flow_actions",
258 "outputs": [
259 {
260 "description": "One entry per composable action: its name, description, and its input and output ports.",
261 "name": "actions",
262 "required": true,
263 "type": "application/json"
264 }
265 ]
266 },
267 {
268 "description": "Optionally compile a Flow without dispatching actions. Returns the composition or a diagnostic with its location. Use this when compiler feedback would help; flow_run also compiles before running.",
269 "inputs": [
270 {
271 "description": "The text of one or more flow declarations.",
272 "name": "source",
273 "required": true,
274 "type": "text/plain"
275 }
276 ],
277 "name": "flow_check",
278 "outputs": [
279 {
280 "description": "The compiled composition, as data.",
281 "name": "plan",
282 "required": true,
283 "type": "application/json"
284 }
285 ]
286 },
287 {
288 "description": "Default execution tool for almost every tool operation, including a single read, search, edit, command, or request. Invoke underlying tools inside the Flow. Prefer composing specialized non-shell tools and Flow stages whenever they can solve the task. Combine independent work and known chains; use another Flow after a new decision. Compiles, checks permissions, and executes permitted actions. Proactively limit sources, filter and project results, and combine item caps with text truncation on returned evidence. Keep full intermediates needed by downstream actions inside the Flow. Returns declared outputs as an object keyed by port name. Discovery and a separate flow_check call are optional.",
289 "inputs": [
290 {
291 "description": "Which flow in the source to run. Defaults to the first one declared, which is the one a file is usually about.",
292 "name": "flow",
293 "type": "text/plain"
294 },
295 {
296 "description": "Input ports you will fill yourself, as nodes, while the flow runs -- named here because otherwise a port you do not send a value for is closed empty. Write each one at `<this call's id>-flow#<port name>` in the session's node map (`flow_input_node_id` computes it) and close it when you are done: nothing else will, and a flow reading a port nobody closes waits. This is how a value reaches a running flow rather than being decided before it starts, and how a port that carries a real type is fed at all, since a value in `inputs` arrives as plain JSON. A caller with no node map of its own -- a model calling this as a tool -- wants `inputs`.",
297 "name": "input_streams",
298 "type": "application/json"
299 },
300 {
301 "description": "Object keyed by input port name. Supply one value for a unary port and a list of items for a stream port. Omitted ports are closed without values.",
302 "name": "inputs",
303 "type": "application/json"
304 },
305 {
306 "description": "Raw, unfenced Flow source. A one-action Flow is enough; use exact action and port names from known contracts and return only bounded evidence needed for the next decision.",
307 "name": "source",
308 "required": true,
309 "type": "text/plain"
310 }
311 ],
312 "name": "flow_run",
313 "outputs": [
314 {
315 "description": "The flow's outputs, keyed by port name: one value for an ordinary port, a list for a `stream` one.",
316 "name": "result",
317 "required": true,
318 "type": "application/json"
319 }
320 ]
321 },
322 {
323 "description": "Route a conversation to the selected LLM provider. Streams response text, reasoning, events, and updated interactions. Optional tools dispatch nested A11 actions; headers select the provider, model, and usage tracking policy.",
324 "headers": [
325 {
326 "description": "The allowed downstream LLM action (tool) name patterns, comma-separated.",
327 "name": "x-a11-allowed-llm-actions",
328 "type": "string"
329 },
330 {
331 "description": "Signed A11 subject and caller delegation chain.",
332 "name": "x-a11-auth",
333 "type": "string"
334 },
335 {
336 "description": "Deadline for execution in milliseconds since epoch.",
337 "name": "x-a11-deadline",
338 "type": "string"
339 },
340 {
341 "description": "API key for the downstream provider.",
342 "name": "x-a11-llm-api-key",
343 "type": "string"
344 },
345 {
346 "description": "Optional JSON LLM context compression/compaction policy.",
347 "name": "x-a11-llm-context-config",
348 "type": "string"
349 },
350 {
351 "description": "Optional LLM usage attribution for a nested summarization action.",
352 "name": "x-a11-llm-context-operation",
353 "type": "string"
354 },
355 {
356 "description": "Optional JSON owner, conversation, branch and expected view revision.",
357 "name": "x-a11-llm-context-scope",
358 "type": "string"
359 },
360 {
361 "description": "SDK projection ownership for the current action identity.",
362 "name": "x-a11-llm-context-stage",
363 "type": "string"
364 },
365 {
366 "description": "The downstream model.",
367 "name": "x-a11-llm-model",
368 "type": "string"
369 },
370 {
371 "description": "The downstream provider.",
372 "name": "x-a11-llm-provider",
373 "type": "string"
374 },
375 {
376 "description": "Request dedicated usage streams with 'on'; inherited 'off' suppresses them.",
377 "name": "x-a11-usage-tracking",
378 "type": "string"
379 },
380 {
381 "description": "OpenTelemetry baggage header.",
382 "name": "x-otel-baggage",
383 "type": "string"
384 },
385 {
386 "description": "OpenTelemetry traceparent header.",
387 "name": "x-otel-traceparent",
388 "type": "string"
389 },
390 {
391 "description": "OpenTelemetry tracestate header.",
392 "name": "x-otel-tracestate",
393 "type": "string"
394 }
395 ],
396 "inputs": [
397 {
398 "description": "Options for the provider selected by x-a11-llm-provider. Choose that provider's object schema.",
399 "name": "config",
400 "type": "application/json"
401 },
402 {
403 "name": "interactions",
404 "required": true,
405 "type": "application/json",
406 "unary": false
407 },
408 {
409 "name": "tools",
410 "type": "application/json",
411 "unary": false
412 }
413 ],
414 "name": "interact_with_llm",
415 "outputs": [
416 {
417 "name": "event_stream",
418 "type": "application/json",
419 "unary": false
420 },
421 {
422 "name": "new_interactions",
423 "required": true,
424 "type": "application/json",
425 "unary": false
426 },
427 {
428 "name": "text_output",
429 "type": "text/plain",
430 "unary": false
431 },
432 {
433 "name": "thoughts",
434 "type": "text/plain",
435 "unary": false
436 },
437 {
438 "description": "References to direct and nested usage producers.",
439 "name": "usage_sources",
440 "type": "application/json",
441 "unary": false
442 }
443 ]
444 },
445 {
446 "description": "List the host's available audio input devices, one AudioDeviceInfo per input, as a stream.",
447 "headers": [
448 {
449 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The action stops gracefully once it is reached.",
450 "name": "x-a11-deadline",
451 "type": "string"
452 }
453 ],
454 "name": "list_audio_inputs",
455 "outputs": [
456 {
457 "description": "One AudioDeviceInfo per available audio input device.",
458 "name": "inputs",
459 "type": "application/json;type=a11.sdk.AudioDeviceInfo",
460 "unary": false
461 }
462 ]
463 },
464 {
465 "description": "Stream directory entries as they are discovered. `truncated` reports whether a configured limit stopped the listing. Apply `where`, `first`, or `map` to `entries` before forwarding a large result.",
466 "headers": [
467 {
468 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The listing fails once it is reached.",
469 "name": "x-a11-deadline",
470 "type": "string"
471 }
472 ],
473 "inputs": [
474 {
475 "description": "All optional: recursive (false), max_depth, hidden (false -- whether to report dot files), match (one or more `*`/`?` patterns matched against the name), kinds (file, directory, symlink, ...), max_entries, and omit -- output port names to close immediately rather than write; and encoding -- \"json\" (the default) or \"msgpack\", which is both cheaper downstream of a `| packb` and the only one of the two that can carry a path or a line that is not valid UTF-8.",
476 "name": "options",
477 "type": "application/json"
478 },
479 {
480 "description": "Directory to list; relative paths use the current directory.",
481 "name": "path",
482 "required": true,
483 "type": "text/plain"
484 }
485 ],
486 "name": "list_directory",
487 "outputs": [
488 {
489 "description": "How many entries were reported.",
490 "name": "count",
491 "type": "integer"
492 },
493 {
494 "description": "One {path, name, kind, exists, size, modified, mode, depth} per entry, as the walk reaches it.",
495 "name": "entries",
496 "type": "application/json",
497 "unary": false
498 },
499 {
500 "description": "Whether a limit stopped the listing before the walk finished.",
501 "name": "truncated",
502 "type": "bool"
503 }
504 ]
505 },
506 {
507 "description": "Create a directory and, by default, its parents. An existing directory succeeds with `created: false`.",
508 "headers": [
509 {
510 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
511 "name": "x-a11-deadline",
512 "type": "string"
513 }
514 ],
515 "inputs": [
516 {
517 "description": "Optional: parents (true).",
518 "name": "options",
519 "type": "application/json"
520 },
521 {
522 "description": "Directory to create; relative paths use the current directory.",
523 "name": "path",
524 "required": true,
525 "type": "text/plain"
526 }
527 ],
528 "name": "make_directory",
529 "outputs": [
530 {
531 "description": "Whether this call made it, as opposed to finding it there.",
532 "name": "created",
533 "type": "bool"
534 },
535 {
536 "description": "The absolute path.",
537 "name": "resolved",
538 "type": "text/plain"
539 }
540 ]
541 },
542 {
543 "description": "Perform one HTTP request. Status and headers arrive before the body; body chunks stream as received. Trailers, redirect history, connection details and supported server pushes have separate ports. HTTP error responses still produce a status_code and body. Action headers without the x-a11- prefix become HTTP request headers.",
544 "headers": [
545 {
546 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. Whichever of it and options.timeout is tighter bounds the request.",
547 "name": "x-a11-deadline",
548 "type": "string"
549 }
550 ],
551 "inputs": [
552 {
553 "description": "Request method; GET when omitted.",
554 "name": "method",
555 "type": "text/plain"
556 },
557 {
558 "description": "Request settings, all optional: max_redirects (5), timeout (seconds), request_body (\"buffer\" | \"stream\"), http_version (\"auto\" | \"2\" | \"1.1\"), accept_pushes (false), reuse_connection (true), max_body_bytes, user_agent, headers (an object, merged over the action's own headers and the way to send an x-a11- one), tls {verify_peer, ca_file, certificate_file, key_file}, and omit -- output port names to close immediately rather than write.",
559 "name": "options",
560 "type": "application/json"
561 },
562 {
563 "description": "Request body, in order. Read to its end and sent with a content-length by default; with options.request_body=\"stream\" each chunk is sent as it arrives, which is what an upload of unknown length needs.",
564 "name": "request_body",
565 "type": "application/octet-stream",
566 "unary": false
567 },
568 {
569 "description": "Absolute http or https URL to request.",
570 "name": "url",
571 "required": true,
572 "type": "text/plain"
573 }
574 ],
575 "name": "make_http_request",
576 "outputs": [
577 {
578 "description": "Response body chunks, in order, as they arrive.",
579 "name": "body",
580 "type": "application/octet-stream",
581 "unary": false
582 },
583 {
584 "description": "How the exchange was carried: {url (after redirects), http_version, secure, reused}.",
585 "name": "connection",
586 "type": "application/json"
587 },
588 {
589 "description": "Every response header field as a [name, value] pair, in wire order and with repeats intact.",
590 "name": "fields",
591 "type": "application/json",
592 "unary": false
593 },
594 {
595 "description": "Response header fields as an object, lower-cased. Repeated fields are joined with ', ' -- with '\\n' for set-cookie, whose values contain commas. Use `fields` where the exact wire form matters.",
596 "name": "headers",
597 "type": "application/json"
598 },
599 {
600 "description": "One record per response the server pushed: {method, url, path, status, headers, request_headers, body}, where `body` is the id of a node the pushed body is streamed into -- attach to it to read it. Needs options.accept_pushes, and the node is reachable where the action's node map is.",
601 "name": "pushes",
602 "type": "application/json",
603 "unary": false
604 },
605 {
606 "description": "One {url, status, location} per redirect followed, in order.",
607 "name": "redirects",
608 "type": "application/json",
609 "unary": false
610 },
611 {
612 "description": "The final response's status code, written before the body so a caller can act on it while the body is still arriving.",
613 "name": "status_code",
614 "type": "integer"
615 },
616 {
617 "description": "The trailer section that followed the body, as an object; empty when the peer sent none. Written only once `body` has ended.",
618 "name": "trailers",
619 "type": "application/json"
620 }
621 ]
622 },
623 {
624 "description": "Create a unique temporary file or directory and return its path. When the host restricts filesystem roots, the path is created inside the first permitted root.",
625 "headers": [
626 {
627 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
628 "name": "x-a11-deadline",
629 "type": "string"
630 }
631 ],
632 "inputs": [
633 {
634 "description": "Optional: directory (true -- a directory rather than a file), prefix (\"a11-\"), suffix, in (directory, relative to the current directory).",
635 "name": "options",
636 "type": "application/json"
637 }
638 ],
639 "name": "make_temp",
640 "outputs": [
641 {
642 "description": "The path that was made.",
643 "name": "path",
644 "type": "text/plain"
645 }
646 ]
647 },
648 {
649 "description": "Rename a path atomically within one filesystem. Cross-filesystem moves fail; use `copy_path` followed by `remove_path` for that case.",
650 "headers": [
651 {
652 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
653 "name": "x-a11-deadline",
654 "type": "string"
655 }
656 ],
657 "inputs": [
658 {
659 "description": "Optional: overwrite (false).",
660 "name": "options",
661 "type": "application/json"
662 },
663 {
664 "description": "Path to move; relative paths use the current directory.",
665 "name": "path",
666 "required": true,
667 "type": "text/plain"
668 },
669 {
670 "description": "Destination; relative paths use the current directory.",
671 "name": "to",
672 "required": true,
673 "type": "text/plain"
674 }
675 ],
676 "name": "move_path",
677 "outputs": [
678 {
679 "description": "The absolute destination.",
680 "name": "resolved",
681 "type": "text/plain"
682 }
683 ]
684 },
685 {
686 "description": "Generate unique identifiers. They are identifiers, not secrets; use random_bytes for tokens and nonces.",
687 "headers": [
688 {
689 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
690 "name": "x-a11-deadline",
691 "type": "string"
692 }
693 ],
694 "inputs": [
695 {
696 "description": "Optional: count (1).",
697 "name": "options",
698 "type": "application/json"
699 }
700 ],
701 "name": "new_uuid",
702 "outputs": [
703 {
704 "description": "The identifiers, one per value.",
705 "name": "ids",
706 "type": "text/plain",
707 "unary": false
708 }
709 ]
710 },
711 {
712 "description": "Generate cryptographically secure random bytes. Use the bytes output for tokens and nonces; text supplies the selected encoding. The host may omit this action from its registry.",
713 "headers": [
714 {
715 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
716 "name": "x-a11-deadline",
717 "type": "string"
718 }
719 ],
720 "inputs": [
721 {
722 "description": "Optional: count (32 bytes) and format (hex, base64, base64url or raw -- raw writes only `bytes`). Named `format` because `encoding` already means json-or-msgpack on every action here.",
723 "name": "options",
724 "type": "application/json"
725 }
726 ],
727 "name": "random_bytes",
728 "outputs": [
729 {
730 "description": "The bytes themselves.",
731 "name": "bytes",
732 "type": "application/octet-stream",
733 "unary": false
734 },
735 {
736 "description": "The bytes in the requested format, or nothing when raw.",
737 "name": "text",
738 "type": "text/plain"
739 }
740 ]
741 },
742 {
743 "description": "Read a file as streamed bytes, complete text, or lines. Metadata is emitted before content. Route `bytes` to a streaming consumer for large files; filter or bound `lines` before forwarding them.",
744 "headers": [
745 {
746 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The read fails with deadline_exceeded once it is reached, because a partial file is not a shorter file.",
747 "name": "x-a11-deadline",
748 "type": "string"
749 }
750 ],
751 "inputs": [
752 {
753 "description": "All optional: chunk_bytes (65536), offset, length, max_bytes, and omit -- output port names to close immediately rather than write; and encoding -- \"json\" (the default) or \"msgpack\", which is both cheaper downstream of a `| packb` and the only one of the two that can carry a path or a line that is not valid UTF-8.",
754 "name": "options",
755 "type": "application/json"
756 },
757 {
758 "description": "File to read; relative paths use the current directory.",
759 "name": "path",
760 "required": true,
761 "type": "text/plain"
762 }
763 ],
764 "name": "read_file",
765 "outputs": [
766 {
767 "description": "The contents, in order, as they are read.",
768 "name": "bytes",
769 "type": "application/octet-stream",
770 "unary": false
771 },
772 {
773 "description": "{path, name, kind, exists, size, modified, mode}, written before any content.",
774 "name": "info",
775 "type": "application/json"
776 },
777 {
778 "description": "One value per line, without its line ending. A trailing line with no newline after it is still a line.",
779 "name": "lines",
780 "type": "text/plain",
781 "unary": false
782 },
783 {
784 "description": "The whole file as one text value. Held in memory, so `bytes` or `lines` is what a large file wants.",
785 "name": "text",
786 "type": "text/plain"
787 }
788 ]
789 },
790 {
791 "description": "Read standard input as streamed bytes and lines. Output readers control upstream pacing. `is_tty` is emitted before input reads begin.",
792 "headers": [
793 {
794 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. Reading ends gracefully once it is reached.",
795 "name": "x-a11-deadline",
796 "type": "string"
797 }
798 ],
799 "inputs": [
800 {
801 "description": "Control commands; a {\"command\": \"stop\"} stops reading.",
802 "name": "control_events",
803 "type": "application/json",
804 "unary": false
805 },
806 {
807 "description": "Optional: chunk_bytes (65536), and omit -- output port names to close immediately rather than write; and encoding -- \"json\" (the default) or \"msgpack\", which is both cheaper downstream of a `| packb` and the only one of the two that can carry a path or a line that is not valid UTF-8.",
808 "name": "options",
809 "type": "application/json"
810 }
811 ],
812 "name": "read_stdin",
813 "outputs": [
814 {
815 "description": "Standard input, as it arrives.",
816 "name": "bytes",
817 "type": "application/octet-stream",
818 "unary": false
819 },
820 {
821 "description": "Whether standard input is a terminal, written before any reading.",
822 "name": "is_tty",
823 "type": "bool"
824 },
825 {
826 "description": "Standard input, one value per line, without its line ending.",
827 "name": "lines",
828 "type": "text/plain",
829 "unary": false
830 }
831 ]
832 },
833 {
834 "description": "Remove a path. Directory removal requires `options.recursive`. An absent path succeeds by default.",
835 "headers": [
836 {
837 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The call fails once it is reached.",
838 "name": "x-a11-deadline",
839 "type": "string"
840 }
841 ],
842 "inputs": [
843 {
844 "description": "Optional: recursive (false), missing_ok (true).",
845 "name": "options",
846 "type": "application/json"
847 },
848 {
849 "description": "Path to remove; relative paths use the current directory.",
850 "name": "path",
851 "required": true,
852 "type": "text/plain"
853 }
854 ],
855 "name": "remove_path",
856 "outputs": [
857 {
858 "description": "How many entries were removed.",
859 "name": "removed",
860 "type": "integer"
861 }
862 ]
863 },
864 {
865 "description": "Run a shell command and stream back its output lines (stdout and stderr, interleaved). Target a shell started with shell_start via the x-a11-shell-id header to reuse its state; omit the header to run the command in a throwaway shell that is discarded afterwards. The command is terminated if it exceeds the timeout, the action's deadline, 1000 output lines, or 128 KiB of output. Truncated output ends with a descriptive marker. When web-fetch is also offered, use it for HTTP retrieval and keep shell_execute for work that requires shell syntax, process state, or an installed command.",
866 "headers": [
867 {
868 "description": "Comma-separated regex patterns of actions the LLM may call as tools.",
869 "name": "x-a11-allowed-llm-actions",
870 "type": "string"
871 },
872 {
873 "description": "Signed A11 subject and caller delegation chain.",
874 "name": "x-a11-auth",
875 "type": "string"
876 },
877 {
878 "description": "Deadline for execution in milliseconds since epoch.",
879 "name": "x-a11-deadline",
880 "type": "string"
881 },
882 {
883 "description": "Id of the shell to run the command in. If absent, a transient shell is started for this command and terminated when it completes.",
884 "name": "x-a11-shell-id",
885 "type": "string"
886 },
887 {
888 "description": "OpenTelemetry baggage header.",
889 "name": "x-otel-baggage",
890 "type": "string"
891 },
892 {
893 "description": "OpenTelemetry traceparent header.",
894 "name": "x-otel-traceparent",
895 "type": "string"
896 },
897 {
898 "description": "OpenTelemetry tracestate header.",
899 "name": "x-otel-tracestate",
900 "type": "string"
901 }
902 ],
903 "inputs": [
904 {
905 "description": "The command to execute. When web-fetch is also offered, do not use curl, wget, or a language HTTP client here.",
906 "name": "command",
907 "type": "text/plain"
908 },
909 {
910 "description": "Execution parameters; defaults are used if omitted.",
911 "name": "parameters",
912 "type": "application/json"
913 }
914 ],
915 "name": "shell_execute",
916 "outputs": [
917 {
918 "description": "Output lines produced by the command, bounded by the requested limits and hard caps of 1000 lines and 128 KiB. A final marker says when output was truncated.",
919 "name": "output_lines",
920 "type": "text/plain",
921 "unary": false
922 }
923 ]
924 },
925 {
926 "description": "Terminate a shell started with shell_start, releasing its resources. Fails with NOT_FOUND if no shell with the given id is running.",
927 "headers": [
928 {
929 "description": "Id of the shell to terminate (required).",
930 "name": "x-a11-shell-id",
931 "type": "string"
932 }
933 ],
934 "name": "shell_exit"
935 },
936 {
937 "description": "List the ids of shells currently running in the caller's scope (the current Session, or the global scope when outside one).",
938 "name": "shell_list",
939 "outputs": [
940 {
941 "description": "Id of each running shell in the caller's scope.",
942 "name": "shell_ids",
943 "type": "text/plain",
944 "unary": false
945 }
946 ]
947 },
948 {
949 "description": "Start a new persistent shell and return its id, which later shell_execute calls can target via the x-a11-shell-id header. The shell keeps its state (working directory, environment variables, shell functions) across commands until it is exited. A shell is scoped to the current Session, or globally scoped when started outside one. Each Session may keep at most 4 running shells and the global scope at most 10; starting one beyond the limit fails with RESOURCE_EXHAUSTED. Exit shells you no longer need with shell_exit.",
950 "name": "shell_start",
951 "outputs": [
952 {
953 "description": "Id of the newly started shell.",
954 "name": "shell_id",
955 "required": true,
956 "type": "text/plain"
957 }
958 ]
959 },
960 {
961 "description": "Wait for a duration and report when the wait ends. A stop command or cancellation interrupts the wait; woke.interrupted records this. Use `after` to order later Flow statements after the result.",
962 "headers": [
963 {
964 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The wait ends gracefully once it is reached.",
965 "name": "x-a11-deadline",
966 "type": "string"
967 }
968 ],
969 "inputs": [
970 {
971 "description": "Control commands; a {\"command\": \"stop\"} ends the wait early.",
972 "name": "control_events",
973 "type": "application/json",
974 "unary": false
975 },
976 {
977 "description": "How long to wait, written as Flow writes a duration (30s, 250ms, 1m30s) or as a number of seconds.",
978 "name": "duration",
979 "required": true,
980 "type": "text/plain"
981 }
982 ],
983 "name": "sleep_for",
984 "outputs": [
985 {
986 "description": "{at, elapsed_ms, interrupted} -- where `interrupted` says the wait was cut short rather than ran its course.",
987 "name": "woke",
988 "type": "application/json"
989 }
990 ]
991 },
992 {
993 "description": "Run a program with separate standard output and error streams, each available as bytes or lines. Emits `pid` when the process starts. A nonzero exit appears on `exit_code` without failing the action. Cancellation sends SIGTERM, waits `options.grace`, then sends SIGKILL. Connect `stdin` directly to a byte stream and bound output lines before forwarding them.",
994 "headers": [
995 {
996 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The process is sent SIGTERM once it is reached, then SIGKILL after options.grace, and the action fails with deadline_exceeded.",
997 "name": "x-a11-deadline",
998 "type": "string"
999 }
1000 ],
1001 "inputs": [
1002 {
1003 "description": "The arguments, one per element. A single string is one argument and is not split on spaces -- splitting is how a path with a space in it becomes two arguments.",
1004 "name": "arguments",
1005 "type": "application/json"
1006 },
1007 {
1008 "description": "Control commands: {\"command\": \"stop\"} to wind the process down, or {\"command\": \"signal\", \"signal\": \"HUP\"} to send one of TERM, KILL, INT, HUP, QUIT, USR1, USR2 or CONT to the process group.",
1009 "name": "control_events",
1010 "type": "application/json",
1011 "unary": false
1012 },
1013 {
1014 "description": "All optional: cwd (checked against the same filesystem policy as any other path), environment (an object of names to values), clear_environment, grace (how long SIGTERM is given before SIGKILL, default 5s), max_output_bytes, max_output_lines (stop after this many combined stdout/stderr lines), and omit -- output port names to close immediately rather than write.",
1015 "name": "options",
1016 "type": "application/json"
1017 },
1018 {
1019 "description": "The program to run.",
1020 "name": "program",
1021 "required": true,
1022 "type": "text/plain"
1023 },
1024 {
1025 "description": "What to write to the program's standard input, in order. Closed when the stream ends, which is what a program reading to EOF waits for. A program that stops reading early is not an error. In Flow, connect an upstream byte output directly to `process.stdin`.",
1026 "name": "stdin",
1027 "type": "application/octet-stream",
1028 "unary": false
1029 }
1030 ],
1031 "name": "spawn_process",
1032 "outputs": [
1033 {
1034 "description": "The exit code, or 128 plus the signal number when it was killed.",
1035 "name": "exit_code",
1036 "type": "integer"
1037 },
1038 {
1039 "description": "Whether max_output_lines stopped the process at its line bound.",
1040 "name": "output_truncated",
1041 "type": "boolean"
1042 },
1043 {
1044 "description": "The process id, written as soon as there is one.",
1045 "name": "pid",
1046 "type": "integer"
1047 },
1048 {
1049 "description": "What confinement was applied to the child: a Landlock ruleset on Linux, a Seatbelt profile on macOS, or why neither was.",
1050 "name": "sandbox",
1051 "type": "text/plain"
1052 },
1053 {
1054 "description": "The name of the signal that ended it, or nothing when it exited of its own accord.",
1055 "name": "signal",
1056 "type": "text/plain"
1057 },
1058 {
1059 "description": "Standard error, as it arrives, and never mixed into standard output.",
1060 "name": "stderr",
1061 "type": "application/octet-stream",
1062 "unary": false
1063 },
1064 {
1065 "description": "Standard error, one value per line, without its line ending.",
1066 "name": "stderr_lines",
1067 "type": "text/plain",
1068 "unary": false
1069 },
1070 {
1071 "description": "Standard output, as it arrives.",
1072 "name": "stdout",
1073 "type": "application/octet-stream",
1074 "unary": false
1075 },
1076 {
1077 "description": "Standard output, one value per line, without its line ending.",
1078 "name": "stdout_lines",
1079 "type": "text/plain",
1080 "unary": false
1081 },
1082 {
1083 "description": "{user_ms, system_ms, max_rss_bytes, output_bytes} once it has finished.",
1084 "name": "usage",
1085 "type": "application/json"
1086 }
1087 ]
1088 },
1089 {
1090 "description": "Read metadata for one path. An absent path returns `exists: false` without failing the action.",
1091 "headers": [
1092 {
1093 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The lookup fails once it is reached.",
1094 "name": "x-a11-deadline",
1095 "type": "string"
1096 }
1097 ],
1098 "inputs": [
1099 {
1100 "description": "Optional: omit -- output port names to close immediately rather than write; and encoding -- \"json\" (the default) or \"msgpack\", which is both cheaper downstream of a `| packb` and the only one of the two that can carry a path or a line that is not valid UTF-8.",
1101 "name": "options",
1102 "type": "application/json"
1103 },
1104 {
1105 "description": "Path to inspect; relative paths use the current directory.",
1106 "name": "path",
1107 "required": true,
1108 "type": "text/plain"
1109 }
1110 ],
1111 "name": "stat_path",
1112 "outputs": [
1113 {
1114 "description": "Whether anything is there.",
1115 "name": "exists",
1116 "type": "bool"
1117 },
1118 {
1119 "description": "{path, name, kind, exists, size, modified, mode}.",
1120 "name": "info",
1121 "type": "application/json"
1122 }
1123 ]
1124 },
1125 {
1126 "description": "Emit timed ticks. count, for, the deadline header and stop commands can bound the stream; otherwise it continues until cancellation. Scheduling uses the start time as its origin. Missed intervals appear in the skipped count unless catch_up is enabled.",
1127 "headers": [
1128 {
1129 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The stream ends gracefully once it is reached.",
1130 "name": "x-a11-deadline",
1131 "type": "string"
1132 }
1133 ],
1134 "inputs": [
1135 {
1136 "description": "Control commands; a {\"command\": \"stop\"} ends the stream gracefully, which is how a flow stops a clock it started.",
1137 "name": "control_events",
1138 "type": "application/json",
1139 "unary": false
1140 },
1141 {
1142 "description": "All optional: every (interval, default 1s, minimum 1ms), count (how many ticks, default unbounded), for (how long to keep going), immediate (tick once at the start rather than after the first interval), catch_up (deliver ticks a slow reader missed instead of skipping them), and omit -- output port names to close immediately rather than write.",
1143 "name": "options",
1144 "type": "application/json"
1145 }
1146 ],
1147 "name": "ticker",
1148 "outputs": [
1149 {
1150 "description": "How many ticks were delivered.",
1151 "name": "count",
1152 "type": "integer"
1153 },
1154 {
1155 "description": "How many ticks were not delivered because a reader was more than an interval behind. Zero unless there was a reason.",
1156 "name": "skipped",
1157 "type": "integer"
1158 },
1159 {
1160 "description": "One {number, at, scheduled, late_ms} per tick, as it fires.",
1161 "name": "ticks",
1162 "type": "application/json",
1163 "unary": false
1164 }
1165 ]
1166 },
1167 {
1168 "description": "Transcribe a caller-supplied stream of AudioBuffers, emitting the same text pieces and lifecycle events as capture_transcription. Stopping is driven by closing the audio input or cancelling the action; there are no control events. Transcription is endpointed if the input stalls.",
1169 "headers": [
1170 {
1171 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The action stops gracefully once it is reached.",
1172 "name": "x-a11-deadline",
1173 "type": "string"
1174 }
1175 ],
1176 "inputs": [
1177 {
1178 "description": "Speech recognition parameters; model is required.",
1179 "name": "asr_options",
1180 "type": "application/json;type=a11.sdk.SpeechRecognizerOptions"
1181 },
1182 {
1183 "description": "Stream of AudioBuffers to transcribe; closing it ends the run.",
1184 "name": "audio",
1185 "required": true,
1186 "type": "application/x-msgpack;type=a11.sdk.AudioBuffer",
1187 "unary": false
1188 }
1189 ],
1190 "name": "transcribe_audio",
1191 "outputs": [
1192 {
1193 "description": "Stream of inference lifecycle events.",
1194 "name": "events",
1195 "type": "application/json;type=a11.sdk.TranscriptionEvent",
1196 "unary": false
1197 },
1198 {
1199 "description": "Recognized text pieces as utterances are decoded.",
1200 "name": "transcription_pieces",
1201 "type": "text/plain",
1202 "unary": false
1203 }
1204 ]
1205 },
1206 {
1207 "description": "Fetch a URL and decode its body as text, JSON, bytes or streamed items. HTTP 4xx and 5xx responses set ok to false and retain the response body. Action headers without the x-a11- prefix become request headers. Use make_http_request to inspect trailers, redirects and connection data.",
1208 "headers": [
1209 {
1210 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. Whichever of it and options.timeout is tighter bounds the request.",
1211 "name": "x-a11-deadline",
1212 "type": "string"
1213 }
1214 ],
1215 "inputs": [
1216 {
1217 "description": "Request method; GET when omitted.",
1218 "name": "method",
1219 "type": "text/plain"
1220 },
1221 {
1222 "description": "Request settings, all optional: max_redirects (5), timeout (seconds), request_body (\"buffer\" | \"stream\"), http_version, headers (an object), tls {verify_peer, ca_file, certificate_file, key_file}, max_body_bytes, user_agent, and omit -- output port names to close immediately rather than write.",
1223 "name": "options",
1224 "type": "application/json"
1225 },
1226 {
1227 "description": "Request body, in order. Read to its end and sent with a content-length by default; with options.request_body=\"stream\" each chunk is sent as it arrives, which is what an upload of unknown length needs.",
1228 "name": "request_body",
1229 "type": "application/octet-stream",
1230 "unary": false
1231 },
1232 {
1233 "description": "Absolute http or https URL to request.",
1234 "name": "url",
1235 "required": true,
1236 "type": "text/plain"
1237 }
1238 ],
1239 "name": "web-fetch",
1240 "outputs": [
1241 {
1242 "description": "The body as it arrives, for a payload too large to hold.",
1243 "name": "body",
1244 "type": "application/octet-stream",
1245 "unary": false
1246 },
1247 {
1248 "description": "Response header fields as an object, lower-cased.",
1249 "name": "headers",
1250 "type": "application/json"
1251 },
1252 {
1253 "description": "The body decoded into values, chosen by its content type: one record per event for text/event-stream, one value per line for NDJSON, one element for each member of a top-level JSON array. Empty for anything else. Events and lines are emitted as they arrive.",
1254 "name": "items",
1255 "type": "application/json",
1256 "unary": false
1257 },
1258 {
1259 "description": "The body parsed as JSON. Closes with nothing when it is not JSON, rather than failing the fetch.",
1260 "name": "json",
1261 "type": "application/json"
1262 },
1263 {
1264 "description": "Whether the status is below 400.",
1265 "name": "ok",
1266 "type": "bool"
1267 },
1268 {
1269 "description": "The response's status code.",
1270 "name": "status_code",
1271 "type": "integer"
1272 },
1273 {
1274 "description": "The whole body as text.",
1275 "name": "text",
1276 "type": "text/plain"
1277 }
1278 ]
1279 },
1280 {
1281 "description": "Render an HTTP(S) page with the platform WebKit engine and return the post-script HTML and rendered text. `options.include_image` adds a bounded PNG snapshot. Filter or truncate `text` before forwarding large results. Use `web-fetch` for raw HTTP content.",
1282 "headers": [
1283 {
1284 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. Whichever of it and options.timeout is tighter bounds the request.",
1285 "name": "x-a11-deadline",
1286 "type": "string"
1287 }
1288 ],
1289 "inputs": [
1290 {
1291 "description": "Rendering settings: headers, user_agent, timeout, max_redirects, max_body_bytes, include_image, image_screen_heights (1 through 10), max_image_bytes, and omit.",
1292 "name": "options",
1293 "type": "application/json"
1294 },
1295 {
1296 "description": "Absolute HTTP(S) URL to render.",
1297 "name": "url",
1298 "required": true,
1299 "type": "text/plain"
1300 }
1301 ],
1302 "name": "web-render",
1303 "outputs": [
1304 {
1305 "description": "Final top-frame URL.",
1306 "name": "final_url",
1307 "type": "text/plain"
1308 },
1309 {
1310 "description": "Final top-frame response headers, lower-cased.",
1311 "name": "headers",
1312 "type": "application/json"
1313 },
1314 {
1315 "description": "Serialized post-render document HTML.",
1316 "name": "html",
1317 "type": "text/plain"
1318 },
1319 {
1320 "description": "Optional rendered PNG, with pixel dimensions in chunk attributes.",
1321 "name": "image",
1322 "type": "image/png"
1323 },
1324 {
1325 "description": "Whether the HTTP status is below 400.",
1326 "name": "ok",
1327 "type": "bool"
1328 },
1329 {
1330 "description": "Final top-frame HTTP status code.",
1331 "name": "status_code",
1332 "type": "integer"
1333 },
1334 {
1335 "description": "Visible page text extracted by the browser DOM.",
1336 "name": "text",
1337 "type": "text/plain"
1338 }
1339 ]
1340 },
1341 {
1342 "description": "Write a file from streamed content. Atomic mode writes to a temporary sibling and renames it on completion. A cancelled atomic write leaves the destination unchanged. Append mode is not atomic. Connect an upstream byte stream directly to `content` to avoid buffering.",
1343 "headers": [
1344 {
1345 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The write fails once it is reached, and leaves the destination as it was.",
1346 "name": "x-a11-deadline",
1347 "type": "string"
1348 }
1349 ],
1350 "inputs": [
1351 {
1352 "description": "The contents, in order. Read to its end; the write is the backpressure point, so a producer is held behind the disk rather than buffered ahead of it. A Flow can pipe a byte stream here with `file.bytes -> write.content`.",
1353 "name": "content",
1354 "type": "application/octet-stream",
1355 "unary": false
1356 },
1357 {
1358 "description": "All optional: append (false), atomic (true unless appending), create_parents (false), sync (false), mode (0644), max_bytes, and omit -- output port names to close immediately rather than write; and encoding -- \"json\" (the default) or \"msgpack\", which is both cheaper downstream of a `| packb` and the only one of the two that can carry a path or a line that is not valid UTF-8.",
1359 "name": "options",
1360 "type": "application/json"
1361 },
1362 {
1363 "description": "File to write; relative paths use the current directory.",
1364 "name": "path",
1365 "required": true,
1366 "type": "text/plain"
1367 }
1368 ],
1369 "name": "write_file",
1370 "outputs": [
1371 {
1372 "description": "How many bytes were written.",
1373 "name": "bytes_written",
1374 "type": "integer"
1375 },
1376 {
1377 "description": "The metadata of the finished file.",
1378 "name": "info",
1379 "type": "application/json"
1380 },
1381 {
1382 "description": "The absolute path that was written. Named `resolved` rather than `path` because a port name is one node whichever way it faces.",
1383 "name": "resolved",
1384 "type": "text/plain"
1385 }
1386 ]
1387 },
1388 {
1389 "description": "Write streamed content to this process's standard error. Writes apply backpressure to the input stream.",
1390 "headers": [
1391 {
1392 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The write fails once it is reached.",
1393 "name": "x-a11-deadline",
1394 "type": "string"
1395 }
1396 ],
1397 "inputs": [
1398 {
1399 "description": "What to write, in order.",
1400 "name": "content",
1401 "type": "application/octet-stream",
1402 "unary": false
1403 }
1404 ],
1405 "name": "write_stderr",
1406 "outputs": [
1407 {
1408 "description": "How many bytes were written.",
1409 "name": "bytes_written",
1410 "type": "integer"
1411 }
1412 ]
1413 },
1414 {
1415 "description": "Write streamed content to this process's standard output. Writes apply backpressure to the input stream.",
1416 "headers": [
1417 {
1418 "description": "Absolute execution deadline: a base-10 count of milliseconds since the Unix epoch, or nanoseconds with an 'ns' suffix. The write fails once it is reached.",
1419 "name": "x-a11-deadline",
1420 "type": "string"
1421 }
1422 ],
1423 "inputs": [
1424 {
1425 "description": "What to write, in order.",
1426 "name": "content",
1427 "type": "application/octet-stream",
1428 "unary": false
1429 }
1430 ],
1431 "name": "write_stdout",
1432 "outputs": [
1433 {
1434 "description": "How many bytes were written.",
1435 "name": "bytes_written",
1436 "type": "integer"
1437 }
1438 ]
1439 }
1440 ],
1441 "format": "flow.catalogue/v1",
1442 "types": [
1443 {
1444 "description": "A message invoking a named action with input and output ports.",
1445 "fields": [
1446 {
1447 "description": "Approximate in-memory size of the message in bytes.",
1448 "name": "approx_bytes",
1449 "type": "json"
1450 },
1451 {
1452 "description": "Byte-string header map attached to the action.",
1453 "name": "headers",
1454 "type": "json"
1455 },
1456 {
1457 "description": "Identifier of the action invocation.",
1458 "name": "id",
1459 "type": "json"
1460 },
1461 {
1462 "description": "Input ports of the action.",
1463 "name": "inputs",
1464 "type": "json"
1465 },
1466 {
1467 "description": "Name of the action being invoked.",
1468 "name": "name",
1469 "type": "json"
1470 },
1471 {
1472 "description": "Output ports of the action.",
1473 "name": "outputs",
1474 "type": "json"
1475 }
1476 ],
1477 "tag": "a11.ActionMessage"
1478 },
1479 {
1480 "description": "A unit of node data with optional metadata and ref.",
1481 "fields": [
1482 {
1483 "description": "Approximate in-memory size of the chunk in bytes.",
1484 "name": "approx_bytes",
1485 "type": "json"
1486 },
1487 {
1488 "description": "Raw payload bytes of the chunk.",
1489 "name": "data",
1490 "type": "json"
1491 },
1492 {
1493 "description": "Optional metadata describing the chunk.",
1494 "name": "metadata",
1495 "type": "json"
1496 },
1497 {
1498 "description": "Reference identifying the chunk's stored payload.",
1499 "name": "ref",
1500 "type": "json"
1501 }
1502 ],
1503 "tag": "a11.Chunk"
1504 },
1505 {
1506 "description": "Metadata describing a chunk of node data.",
1507 "fields": [
1508 {
1509 "description": "Approximate in-memory size of the metadata in bytes.",
1510 "name": "approx_bytes",
1511 "type": "json"
1512 },
1513 {
1514 "description": "Byte-string attribute map attached to the chunk.",
1515 "name": "attributes",
1516 "type": "json"
1517 },
1518 {
1519 "description": "MIME type describing the chunk payload.",
1520 "name": "mimetype",
1521 "type": "json"
1522 },
1523 {
1524 "description": "Optional timestamp associated with the chunk.",
1525 "name": "timestamp",
1526 "type": "json"
1527 }
1528 ],
1529 "tag": "a11.ChunkMetadata"
1530 },
1531 {
1532 "fields": [
1533 {
1534 "description": "The duration as a whole number of nanoseconds.",
1535 "name": "nanoseconds_value",
1536 "type": "json"
1537 }
1538 ],
1539 "tag": "a11.Duration"
1540 },
1541 {
1542 "description": "A fragment of a logical node carrying a Chunk or NodeRef.",
1543 "fields": [
1544 {
1545 "description": "Approximate in-memory size of the fragment in bytes.",
1546 "name": "approx_bytes",
1547 "type": "json"
1548 },
1549 {
1550 "description": "Whether more fragments follow for this node.",
1551 "name": "continued",
1552 "type": "json"
1553 },
1554 {
1555 "description": "Payload of the fragment as either a Chunk or a NodeRef.",
1556 "name": "data",
1557 "type": "json"
1558 },
1559 {
1560 "description": "Identifier of the logical node this fragment belongs to.",
1561 "name": "id",
1562 "type": "json"
1563 },
1564 {
1565 "description": "Optional sequence number of the fragment.",
1566 "name": "seq",
1567 "type": "json"
1568 }
1569 ],
1570 "tag": "a11.NodeFragment"
1571 },
1572 {
1573 "description": "Reference to a fragment range of another logical node.",
1574 "fields": [
1575 {
1576 "description": "Approximate in-memory size of the ref in bytes.",
1577 "name": "approx_bytes",
1578 "type": "json"
1579 },
1580 {
1581 "description": "Identifier of the referenced node.",
1582 "name": "id",
1583 "type": "json"
1584 },
1585 {
1586 "description": "Optional number of referenced fragments.",
1587 "name": "length",
1588 "type": "json"
1589 },
1590 {
1591 "description": "First referenced fragment sequence.",
1592 "name": "offset",
1593 "type": "json"
1594 },
1595 {
1596 "description": "Optional host-resolved storage namespace.",
1597 "name": "storage",
1598 "type": "json"
1599 }
1600 ],
1601 "tag": "a11.NodeRef"
1602 },
1603 {
1604 "description": "A named input or output port of an action.",
1605 "fields": [
1606 {
1607 "description": "Approximate in-memory size of the port in bytes.",
1608 "name": "approx_bytes",
1609 "type": "json"
1610 },
1611 {
1612 "description": "Identifier of the node bound to the port.",
1613 "name": "id",
1614 "type": "json"
1615 },
1616 {
1617 "description": "Name of the port.",
1618 "name": "name",
1619 "type": "json"
1620 }
1621 ],
1622 "tag": "a11.Port"
1623 },
1624 {
1625 "fields": [
1626 {
1627 "description": "The canonical status code.",
1628 "name": "code",
1629 "type": "json"
1630 },
1631 {
1632 "description": "The structured status details, as a list.",
1633 "name": "details",
1634 "type": "json"
1635 },
1636 {
1637 "description": "The human-readable status message.",
1638 "name": "message",
1639 "type": "json"
1640 }
1641 ],
1642 "tag": "a11.Status"
1643 },
1644 {
1645 "fields": [
1646 {
1647 "description": "The time as nanoseconds since the Unix epoch.",
1648 "name": "nanoseconds_since_epoch",
1649 "type": "json"
1650 }
1651 ],
1652 "tag": "a11.Time"
1653 },
1654 {
1655 "description": "A wire-format message bundling node fragments and actions.",
1656 "fields": [
1657 {
1658 "description": "Action messages carried by the message.",
1659 "name": "actions",
1660 "type": "json"
1661 },
1662 {
1663 "description": "Approximate in-memory size of the message in bytes.",
1664 "name": "approx_bytes",
1665 "type": "json"
1666 },
1667 {
1668 "description": "Byte-string header map attached to the message.",
1669 "name": "headers",
1670 "type": "json"
1671 },
1672 {
1673 "description": "Node fragments carried by the message.",
1674 "name": "node_fragments",
1675 "type": "json"
1676 }
1677 ],
1678 "tag": "a11.WireMessage"
1679 },
1680 {
1681 "description": "!!! abstract \"Usage Documentation\"",
1682 "fields": [
1683 {
1684 "description": "Who should run the action.",
1685 "name": "peer",
1686 "type": "json"
1687 },
1688 {
1689 "description": "A map of header names to autofill values.",
1690 "name": "header_autofills",
1691 "type": "object"
1692 }
1693 ],
1694 "tag": "a11.sdk.ActionConfig"
1695 },
1696 {
1697 "description": "A captured block of samples stored channel-major (planar). Use `memoryview(buffer)` for a zero-copy (channels x frames) float view, or `channel(i)` for one channel.",
1698 "fields": [
1699 {
1700 "description": "Best-effort instant the final sample in this buffer was taken.",
1701 "name": "end_time",
1702 "type": "json"
1703 },
1704 {
1705 "description": "Number of channels in this buffer.",
1706 "name": "num_channels",
1707 "type": "json"
1708 },
1709 {
1710 "description": "Number of samples per channel in this buffer.",
1711 "name": "num_frames",
1712 "type": "json"
1713 },
1714 {
1715 "description": "Sample rate, in hertz, the samples were captured at.",
1716 "name": "sample_rate",
1717 "type": "json"
1718 },
1719 {
1720 "description": "A zero-copy read-only ``(channels, frames)`` float view.",
1721 "name": "samples",
1722 "type": "json"
1723 }
1724 ],
1725 "tag": "a11.sdk.AudioBuffer"
1726 },
1727 {
1728 "description": "A capture lifecycle or dropped-buffer notification from capture_audio.",
1729 "fields": [
1730 {
1731 "description": "Buffers dropped since the previous event.",
1732 "name": "dropped",
1733 "type": "json"
1734 },
1735 {
1736 "description": "The event kind: 'started', 'buffers_dropped' or 'stopped'.",
1737 "name": "kind",
1738 "type": "json"
1739 }
1740 ],
1741 "tag": "a11.sdk.AudioCaptureEvent"
1742 },
1743 {
1744 "description": "A command on an Action's control_events input; 'stop' finishes capture gracefully.",
1745 "fields": [
1746 {
1747 "description": "The command name, e.g. 'stop'.",
1748 "name": "command",
1749 "type": "json"
1750 }
1751 ],
1752 "tag": "a11.sdk.AudioControlEvent"
1753 },
1754 {
1755 "description": "How an AudioInput opens its capture stream.",
1756 "fields": [
1757 {
1758 "description": "Frames per PortAudio callback block.",
1759 "name": "block_frames",
1760 "type": "json"
1761 },
1762 {
1763 "description": "Frames per delivered subscription buffer, or 0 for the block size.",
1764 "name": "buffer_frames",
1765 "type": "json"
1766 },
1767 {
1768 "description": "Requested channel count, or 0 for the device's count.",
1769 "name": "channels",
1770 "type": "json"
1771 },
1772 {
1773 "description": "Device index to capture from, or negative for default.",
1774 "name": "device_index",
1775 "type": "json"
1776 },
1777 {
1778 "description": "Input device name to capture from; empty selects by index or the default input.",
1779 "name": "device_name",
1780 "type": "json"
1781 },
1782 {
1783 "description": "Depth of the internal callback-to-fiber ring, in blocks.",
1784 "name": "ring_blocks",
1785 "type": "json"
1786 },
1787 {
1788 "description": "Requested sample rate in hertz, or 0 for the default.",
1789 "name": "sample_rate",
1790 "type": "json"
1791 }
1792 ],
1793 "tag": "a11.sdk.AudioInputOptions"
1794 },
1795 {
1796 "description": "Parameters for one Claude Code session.",
1797 "fields": [
1798 {
1799 "description": "Claude Code's own tools. `false` offers the model A11 actions alone; `true` offers the full Claude Code toolset, which reads and writes the filesystem and runs commands; a list offers the named subset. Enabling a tool also permits it \u2014 a session driven through A11 answers no permission prompt \u2014 so name only what the turn should be able to do, and use `disallowed_tools` to carve back a command shape.",
1800 "name": "builtin_tools",
1801 "type": "json"
1802 },
1803 {
1804 "description": "Claude Code's permission mode, such as `plan` for a read-only session or `acceptEdits` for unattended file edits.",
1805 "name": "permission_mode",
1806 "type": "json"
1807 },
1808 {
1809 "description": "Tool names or scoped rules the model may never use, such as `Bash(rm *)`. A scoped rule is refused in every permission mode.",
1810 "element": "string",
1811 "name": "disallowed_tools",
1812 "type": "list"
1813 },
1814 {
1815 "description": "Maximum agent turns before the session stops.",
1816 "name": "max_turns",
1817 "type": "integer"
1818 },
1819 {
1820 "description": "Stop the session once the estimated cost reaches this.",
1821 "name": "max_budget_usd",
1822 "type": "number"
1823 },
1824 {
1825 "description": "Working directory for the session's tools.",
1826 "name": "cwd",
1827 "type": "string"
1828 },
1829 {
1830 "description": "Extra directories the session's tools may reach.",
1831 "element": "string",
1832 "name": "add_dirs",
1833 "type": "list"
1834 },
1835 {
1836 "description": "Which on-disk Claude Code settings to load. Omitted loads none, which keeps a session's behaviour independent of the host's configuration; include `project` to load CLAUDE.md.",
1837 "element": "json",
1838 "name": "setting_sources",
1839 "type": "list"
1840 },
1841 {
1842 "description": "Skills to make available, or `all`.",
1843 "name": "skills",
1844 "type": "json"
1845 },
1846 {
1847 "description": "Enable adaptive thinking so the model decides when and how much internal reasoning to spend.",
1848 "name": "thinking",
1849 "type": "bool"
1850 },
1851 {
1852 "description": "Stream summaries of the model's reasoning as it thinks.",
1853 "name": "thinking_summaries",
1854 "type": "bool"
1855 },
1856 {
1857 "description": "Overall thinking depth and token spend.",
1858 "name": "effort",
1859 "type": "json"
1860 },
1861 {
1862 "description": "Model to fall back to when the primary is unavailable.",
1863 "name": "fallback_model",
1864 "type": "string"
1865 },
1866 {
1867 "description": "Claude Code session id to continue with the newest supplied interaction. Also read from the newest assistant interaction's metadata when unset.",
1868 "name": "resume",
1869 "type": "string"
1870 },
1871 {
1872 "description": "Branch a resumed session instead of extending it.",
1873 "name": "fork_session",
1874 "type": "bool"
1875 },
1876 {
1877 "description": "Path to the `claude` executable.",
1878 "name": "cli_path",
1879 "type": "string"
1880 },
1881 {
1882 "name": "env",
1883 "type": "object"
1884 },
1885 {
1886 "description": "Per-session Claude Code settings passed to the SDK.",
1887 "name": "settings",
1888 "type": "json"
1889 },
1890 {
1891 "description": "Claude Agent SDK subagent definitions keyed by agent name.",
1892 "name": "agents",
1893 "type": "object"
1894 }
1895 ],
1896 "tag": "a11.sdk.InteractWithClaudeCodeConfig"
1897 },
1898 {
1899 "description": "Parameters for creating a Claude message.",
1900 "fields": [
1901 {
1902 "description": "Opt-in Anthropic API beta headers.",
1903 "element": "string",
1904 "name": "betas",
1905 "type": "list"
1906 },
1907 {
1908 "description": "Caller-selected API context clearing or compaction policy.",
1909 "name": "context_management",
1910 "type": "json"
1911 },
1912 {
1913 "description": "Maximum number of tokens to generate.",
1914 "name": "max_tokens",
1915 "type": "integer"
1916 },
1917 {
1918 "description": "How long Anthropic retains the stable tools and system prefix. One-hour writes cost more and suit prefixes reused after idle periods.",
1919 "name": "stable_cache_ttl",
1920 "type": "json"
1921 },
1922 {
1923 "description": "How long Anthropic retains the growing conversation prefix. Five minutes keeps each moving suffix write inexpensive.",
1924 "name": "conversation_cache_ttl",
1925 "type": "json"
1926 },
1927 {
1928 "description": "Enable adaptive thinking so the model decides when and how much internal reasoning to spend. Unsupported alongside tools and on Haiku models.",
1929 "name": "thinking",
1930 "type": "bool"
1931 },
1932 {
1933 "description": "Stream summaries of the model's reasoning as it thinks.",
1934 "name": "thinking_summaries",
1935 "type": "bool"
1936 },
1937 {
1938 "description": "Overall thinking depth and token spend. Only honoured on models that support the effort parameter.",
1939 "name": "effort",
1940 "type": "json"
1941 },
1942 {
1943 "description": "Enable the built-in web search tool.",
1944 "name": "web_search",
1945 "type": "bool"
1946 },
1947 {
1948 "description": "Enable the built-in web fetch tool.",
1949 "name": "web_fetch",
1950 "type": "bool"
1951 },
1952 {
1953 "description": "Enable the built-in code execution tool.",
1954 "name": "code_execution",
1955 "type": "bool"
1956 }
1957 ],
1958 "tag": "a11.sdk.InteractWithClaudeConfig"
1959 },
1960 {
1961 "description": "Options for a Codex app-server session over stdio.",
1962 "fields": [
1963 {
1964 "description": "Working directory exposed as Codex's primary workspace.",
1965 "name": "cwd",
1966 "type": "string"
1967 },
1968 {
1969 "description": "Additional writable directories.",
1970 "element": "string",
1971 "name": "add_dirs",
1972 "type": "list"
1973 },
1974 {
1975 "description": "Sandbox policy for Codex's built-in tools.",
1976 "name": "sandbox",
1977 "type": "json"
1978 },
1979 {
1980 "description": "Codex configuration profile.",
1981 "name": "profile",
1982 "type": "string"
1983 },
1984 {
1985 "description": "Model reasoning effort.",
1986 "name": "reasoning_effort",
1987 "type": "json"
1988 },
1989 {
1990 "description": "JSON Schema for the final response.",
1991 "name": "output_schema",
1992 "type": "object"
1993 },
1994 {
1995 "description": "Codex thread id to resume. The latest Codex interaction's metadata supplies it when omitted.",
1996 "name": "resume",
1997 "type": "string"
1998 },
1999 {
2000 "description": "Do not persist the Codex thread on disk.",
2001 "name": "ephemeral",
2002 "type": "bool"
2003 },
2004 {
2005 "description": "Allow Codex to run outside a Git repository.",
2006 "name": "skip_git_repo_check",
2007 "type": "bool"
2008 },
2009 {
2010 "description": "Ignore the user's config.toml while retaining authentication.",
2011 "name": "ignore_user_config",
2012 "type": "bool"
2013 },
2014 {
2015 "description": "Do not load user or project execpolicy rule files.",
2016 "name": "ignore_rules",
2017 "type": "bool"
2018 },
2019 {
2020 "description": "Additional Codex `-c key=value` settings.",
2021 "name": "config_overrides",
2022 "type": "object"
2023 },
2024 {
2025 "description": "Path to the Codex CLI executable.",
2026 "name": "cli_path",
2027 "type": "string"
2028 }
2029 ],
2030 "tag": "a11.sdk.InteractWithCodexConfig"
2031 },
2032 {
2033 "description": "Parameters for starting a Gemini interaction.",
2034 "fields": [
2035 {
2036 "description": "Maximum number of tokens to generate per step.",
2037 "name": "max_output_tokens",
2038 "type": "integer"
2039 },
2040 {
2041 "description": "How to carry conversation state across turns: resume by `previous_interaction_id` (`last-id`), replay the whole transcript every turn (`full-history`), or try the former and fall back to the latter (`auto`).",
2042 "name": "state_mode",
2043 "type": "json"
2044 },
2045 {
2046 "description": "How much internal reasoning the model may spend.",
2047 "name": "thinking_level",
2048 "type": "json"
2049 },
2050 {
2051 "description": "Stream summaries of the model's reasoning as it thinks.",
2052 "name": "thinking_summaries",
2053 "type": "bool"
2054 },
2055 {
2056 "description": "Enable the built-in Google Search grounding tool.",
2057 "name": "google_search",
2058 "type": "bool"
2059 },
2060 {
2061 "description": "Enable the built-in code execution tool.",
2062 "name": "code_execution",
2063 "type": "bool"
2064 },
2065 {
2066 "description": "Enable the built-in URL context tool.",
2067 "name": "url_context",
2068 "type": "bool"
2069 }
2070 ],
2071 "tag": "a11.sdk.InteractWithGeminiConfig"
2072 },
2073 {
2074 "description": "Parameters for one OpenAI chat completion.",
2075 "fields": [
2076 {
2077 "description": "Maximum generated tokens, including reasoning tokens.",
2078 "name": "max_completion_tokens",
2079 "type": "integer"
2080 },
2081 {
2082 "description": "Sampling temperature.",
2083 "name": "temperature",
2084 "type": "number"
2085 },
2086 {
2087 "description": "Nucleus-sampling probability.",
2088 "name": "top_p",
2089 "type": "number"
2090 },
2091 {
2092 "description": "Penalty applied when a token already appeared.",
2093 "name": "presence_penalty",
2094 "type": "number"
2095 },
2096 {
2097 "description": "Penalty scaled by a token's prior frequency.",
2098 "name": "frequency_penalty",
2099 "type": "number"
2100 },
2101 {
2102 "description": "Best-effort sampling seed.",
2103 "name": "seed",
2104 "type": "integer"
2105 },
2106 {
2107 "description": "Strings that end generation.",
2108 "element": "string",
2109 "name": "stop",
2110 "type": "list"
2111 },
2112 {
2113 "description": "Reasoning effort for models that support it.",
2114 "name": "reasoning_effort",
2115 "type": "json"
2116 },
2117 {
2118 "description": "Constrain the response to a JSON object.",
2119 "name": "json_output",
2120 "type": "bool"
2121 },
2122 {
2123 "description": "JSON Schema for a structured response.",
2124 "name": "json_schema",
2125 "type": "object"
2126 },
2127 {
2128 "description": "OpenAI processing tier.",
2129 "name": "service_tier",
2130 "type": "json"
2131 },
2132 {
2133 "description": "Additional OpenAI request fields.",
2134 "name": "extra_body",
2135 "type": "object"
2136 }
2137 ],
2138 "tag": "a11.sdk.InteractWithGptConfig"
2139 },
2140 {
2141 "description": "Parameters for a single Ollama chat turn.",
2142 "fields": [
2143 {
2144 "description": "Maximum number of tokens to generate. -1 lets the model run until it stops on its own (Ollama `options.num_predict`).",
2145 "name": "num_predict",
2146 "type": "integer"
2147 },
2148 {
2149 "description": "Enable the model's thinking, optionally at a given effort level. Only honoured by models that support it.",
2150 "name": "think",
2151 "type": "json"
2152 },
2153 {
2154 "description": "Sampling temperature (Ollama `options.temperature`).",
2155 "name": "temperature",
2156 "type": "number"
2157 },
2158 {
2159 "description": "Nucleus-sampling probability (Ollama `options.top_p`).",
2160 "name": "top_p",
2161 "type": "number"
2162 },
2163 {
2164 "description": "Top-k sampling cutoff (Ollama `options.top_k`).",
2165 "name": "top_k",
2166 "type": "integer"
2167 },
2168 {
2169 "description": "Sampling seed for reproducible output (Ollama `options.seed`).",
2170 "name": "seed",
2171 "type": "integer"
2172 },
2173 {
2174 "description": "How long to keep the model loaded in memory after the request so its prompt cache remains available (e.g. `5m`, or seconds as a number). Set null to use the server default.",
2175 "name": "keep_alive",
2176 "type": "json"
2177 },
2178 {
2179 "description": "Constrain the model to emit valid JSON (Ollama `format=\"json\"`).",
2180 "name": "json_output",
2181 "type": "bool"
2182 }
2183 ],
2184 "tag": "a11.sdk.InteractWithOllamaConfig"
2185 },
2186 {
2187 "description": "Parameters for a single vLLM chat completion.",
2188 "fields": [
2189 {
2190 "description": "Maximum number of tokens to generate. -1 lets the model run until it stops on its own or reaches the deployment's context limit.",
2191 "name": "max_tokens",
2192 "type": "integer"
2193 },
2194 {
2195 "description": "Sampling temperature.",
2196 "name": "temperature",
2197 "type": "number"
2198 },
2199 {
2200 "description": "Nucleus-sampling probability.",
2201 "name": "top_p",
2202 "type": "number"
2203 },
2204 {
2205 "description": "Penalty applied to tokens that already appeared.",
2206 "name": "presence_penalty",
2207 "type": "number"
2208 },
2209 {
2210 "description": "Penalty scaled by how often a token already appeared.",
2211 "name": "frequency_penalty",
2212 "type": "number"
2213 },
2214 {
2215 "description": "Sampling seed for reproducible output.",
2216 "name": "seed",
2217 "type": "integer"
2218 },
2219 {
2220 "description": "Strings that end the generation when produced.",
2221 "element": "string",
2222 "name": "stop",
2223 "type": "list"
2224 },
2225 {
2226 "description": "Top-k sampling cutoff (vLLM `extra_body.top_k`).",
2227 "name": "top_k",
2228 "type": "integer"
2229 },
2230 {
2231 "description": "Minimum token probability, relative to the most likely token (vLLM `extra_body.min_p`).",
2232 "name": "min_p",
2233 "type": "number"
2234 },
2235 {
2236 "description": "Penalty applied to tokens from the prompt and the output so far (vLLM `extra_body.repetition_penalty`).",
2237 "name": "repetition_penalty",
2238 "type": "number"
2239 },
2240 {
2241 "description": "Constrain the model to emit valid JSON (`response_format={\"type\": \"json_object\"}`).",
2242 "name": "json_output",
2243 "type": "bool"
2244 },
2245 {
2246 "description": "A JSON Schema the output has to satisfy, enforced by vLLM's structured decoding. Takes precedence over `json_output`.",
2247 "name": "json_schema",
2248 "type": "object"
2249 },
2250 {
2251 "description": "Values passed to the model's chat template, such as `{\"enable_thinking\": true}` on models whose template gates reasoning (vLLM `extra_body.chat_template_kwargs`).",
2252 "name": "chat_template_kwargs",
2253 "type": "object"
2254 },
2255 {
2256 "description": "Stable vLLM prefix-cache namespace. Reuse a value for prompts allowed to share cached prefixes; use distinct values to isolate tenants.",
2257 "name": "cache_salt",
2258 "type": "string"
2259 },
2260 {
2261 "description": "Additional request fields, merged into the request body last. Covers deployment-specific sampling parameters this config does not name.",
2262 "name": "extra_body",
2263 "type": "object"
2264 }
2265 ],
2266 "tag": "a11.sdk.InteractWithVllmConfig"
2267 },
2268 {
2269 "description": "!!! abstract \"Usage Documentation\"",
2270 "fields": [
2271 {
2272 "description": "The completion ID of this interaction",
2273 "name": "id",
2274 "type": "string"
2275 },
2276 {
2277 "description": "The role of the interaction.",
2278 "name": "role",
2279 "type": "json"
2280 },
2281 {
2282 "description": "The millisecond-since-epoch of the interaction.",
2283 "name": "created_at_millis",
2284 "type": "integer"
2285 },
2286 {
2287 "description": "The ID of the previous interaction.",
2288 "name": "previous_interaction_id",
2289 "type": "string"
2290 },
2291 {
2292 "description": "The model that produced the interaction.",
2293 "name": "model",
2294 "type": "string"
2295 },
2296 {
2297 "description": "The status of the interaction.",
2298 "name": "status",
2299 "type": "json"
2300 },
2301 {
2302 "description": "The system instructions of the interaction.",
2303 "element": "json",
2304 "name": "system_instructions",
2305 "type": "list"
2306 },
2307 {
2308 "description": "The action configs of the interaction.",
2309 "name": "action_configs",
2310 "type": "object"
2311 },
2312 {
2313 "description": "The content of the interaction.",
2314 "element": "json",
2315 "name": "content",
2316 "type": "list"
2317 },
2318 {
2319 "description": "The action calls of the interaction.",
2320 "element": "json",
2321 "name": "action_calls",
2322 "type": "list"
2323 },
2324 {
2325 "description": "The inputs of the interaction.",
2326 "name": "action_inputs",
2327 "type": "object"
2328 },
2329 {
2330 "description": "The outputs of the interaction.",
2331 "name": "action_outputs",
2332 "type": "object"
2333 },
2334 {
2335 "description": "The backend-specific metadata of the interaction. For example, Anthropic messages can have `container`, `stop_reason`, etc.",
2336 "name": "backend_specific_metadata",
2337 "type": "object"
2338 },
2339 {
2340 "description": "The usage metadata of the interaction.",
2341 "name": "usage_metadata",
2342 "type": "a11.sdk.UsageMetadata"
2343 }
2344 ],
2345 "tag": "a11.sdk.Interaction"
2346 },
2347 {
2348 "description": "!!! abstract \"Usage Documentation\"",
2349 "fields": [
2350 {
2351 "description": "The protocol to use for the A11 peer.",
2352 "name": "protocol",
2353 "type": "json"
2354 },
2355 {
2356 "description": "The scheme to use for the A11 action party.",
2357 "name": "scheme",
2358 "type": "json"
2359 },
2360 {
2361 "description": "The peer's identity. For MCP, it is empty. For A11 session, it may be $sender, $receiver, or an ID of a stream that is attached to the session. For the `ws` scheme, it is empty. For `rtc`, it is the signalling identity.",
2362 "name": "identity",
2363 "type": "string"
2364 },
2365 {
2366 "description": "The endpoint to use for the peer.",
2367 "name": "endpoint",
2368 "type": "string"
2369 }
2370 ],
2371 "tag": "a11.sdk.Peer"
2372 },
2373 {
2374 "description": "Configuration for whisper.cpp transcription, a cheap energy VAD gate, and optional whisper.cpp Silero neural VAD.",
2375 "fields": [
2376 {
2377 "description": "Use flash attention when supported.",
2378 "name": "flash_attention",
2379 "type": "json"
2380 },
2381 {
2382 "description": "Decoder threads, or zero for the bounded default.",
2383 "name": "inference_threads",
2384 "type": "json"
2385 },
2386 {
2387 "description": "Optional initial decoder prompt.",
2388 "name": "initial_prompt",
2389 "type": "json"
2390 },
2391 {
2392 "description": "Whisper language code, or 'auto'.",
2393 "name": "language",
2394 "type": "json"
2395 },
2396 {
2397 "description": "Maximum utterance duration before splitting.",
2398 "name": "max_speech_seconds",
2399 "type": "json"
2400 },
2401 {
2402 "description": "Silence needed to endpoint speech.",
2403 "name": "min_silence_millis",
2404 "type": "json"
2405 },
2406 {
2407 "description": "Minimum voiced duration accepted.",
2408 "name": "min_speech_millis",
2409 "type": "json"
2410 },
2411 {
2412 "description": "Path to the whisper.cpp model; used by the transcription action (empty is rejected there).",
2413 "name": "model",
2414 "type": "json"
2415 },
2416 {
2417 "description": "Silero speech-probability threshold in (0, 1].",
2418 "name": "silero_threshold",
2419 "type": "json"
2420 },
2421 {
2422 "description": "Audio retained around an utterance.",
2423 "name": "speech_pad_millis",
2424 "type": "json"
2425 },
2426 {
2427 "description": "Duration of internally-created capture buffers.",
2428 "name": "subscription_buffer_millis",
2429 "type": "json"
2430 },
2431 {
2432 "description": "Translate speech to English.",
2433 "name": "translate",
2434 "type": "json"
2435 },
2436 {
2437 "description": "Carry decoder context between utterances.",
2438 "name": "use_context",
2439 "type": "json"
2440 },
2441 {
2442 "description": "Use a compiled GPU backend when available.",
2443 "name": "use_gpu",
2444 "type": "json"
2445 },
2446 {
2447 "description": "Path to a Silero VAD model; empty disables Silero VAD.",
2448 "name": "vad_model",
2449 "type": "json"
2450 },
2451 {
2452 "description": "Speech threshold relative to learned noise.",
2453 "name": "vad_noise_ratio",
2454 "type": "json"
2455 },
2456 {
2457 "description": "Absolute RMS speech threshold.",
2458 "name": "vad_threshold",
2459 "type": "json"
2460 },
2461 {
2462 "description": "RMS analysis window duration.",
2463 "name": "vad_window_millis",
2464 "type": "json"
2465 }
2466 ],
2467 "tag": "a11.sdk.SpeechRecognizerOptions"
2468 },
2469 {
2470 "description": "A capture/inference lifecycle notification from capture_transcription.",
2471 "fields": [
2472 {
2473 "description": "The event kind, e.g. 'inference_started'.",
2474 "name": "kind",
2475 "type": "json"
2476 }
2477 ],
2478 "tag": "a11.sdk.TranscriptionEvent"
2479 },
2480 {
2481 "description": "Provider-independent token usage for a single interaction.",
2482 "fields": [
2483 {
2484 "description": "Stable identity shared by event and interaction usage.",
2485 "name": "usage_id",
2486 "type": "string"
2487 },
2488 {
2489 "description": "Replacement revision for this usage identity.",
2490 "name": "usage_revision",
2491 "type": "integer"
2492 },
2493 {
2494 "description": "Whether the source report is final with known coverage.",
2495 "name": "complete",
2496 "type": "bool"
2497 },
2498 {
2499 "description": "History changed without a replacement context count.",
2500 "name": "context_invalidated",
2501 "type": "bool"
2502 },
2503 {
2504 "description": "A context observation with no consumption contribution.",
2505 "name": "context_only",
2506 "type": "bool"
2507 },
2508 {
2509 "description": "Reported context occupancy or a latest-request estimate.",
2510 "name": "context_source",
2511 "type": "json"
2512 },
2513 {
2514 "description": "Uncached input tokens, excluding separately reported cache writes. Inclusive provider prompt counts have cache reads/writes removed.",
2515 "name": "input_tokens",
2516 "type": "integer"
2517 },
2518 {
2519 "description": "Generated output tokens, including reasoning and tool arguments. Gemini output and thought counts are combined.",
2520 "name": "output_tokens",
2521 "type": "integer"
2522 },
2523 {
2524 "description": "Total tokens attributed to the interaction. Provider-supplied where available (OpenAI `total_tokens`, Gemini `totalTokenCount`); otherwise the sum of the input, output, and cache token counts.",
2525 "name": "total_tokens",
2526 "type": "integer"
2527 },
2528 {
2529 "description": "Input tokens served from a prompt cache (billed at a reduced rate). Anthropic `cache_read_input_tokens`, OpenAI `prompt_tokens_details.cached_tokens`, Gemini `cachedContentTokenCount`.",
2530 "name": "cached_input_tokens",
2531 "type": "integer"
2532 },
2533 {
2534 "description": "Cache-write input tokens, excluded from input_tokens.",
2535 "name": "cache_write_tokens",
2536 "type": "integer"
2537 },
2538 {
2539 "description": "Subset of output_tokens spent on reasoning/thinking. Anthropic `output_tokens_details.thinking_tokens`, OpenAI `completion_tokens_details.reasoning_tokens`, Gemini `thoughtsTokenCount`.",
2540 "name": "reasoning_tokens",
2541 "type": "integer"
2542 },
2543 {
2544 "description": "Whether counters cover one request or one user turn.",
2545 "name": "usage_scope",
2546 "type": "json"
2547 },
2548 {
2549 "description": "Latest model request's input plus output, including cached input. This is a context estimate, distinct from aggregate turn usage.",
2550 "name": "context_tokens",
2551 "type": "integer"
2552 },
2553 {
2554 "description": "Whether provider input usage covers the context or only new input. Incremental usage does not establish context occupancy.",
2555 "name": "input_tokens_scope",
2556 "type": "json"
2557 }
2558 ],
2559 "tag": "a11.sdk.UsageMetadata"
2560 }
2561 ]
2562}
2563)catalogue";
2564
2565} // namespace a11::flow::catalogue
2566
2567#endif // A11_FLOW_CATALOGUE_DATA_H_
Action and type metadata supplied to Flow tooling.
Definition catalogue.cc:29
constexpr std::string_view kCatalogueSnapshot
Definition catalogue_data.h:29