voqalize-agent-sdk 0.0.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (122) hide show
  1. voqalize_agent_sdk-0.0.1/.gitignore +35 -0
  2. voqalize_agent_sdk-0.0.1/CHANGELOG.md +225 -0
  3. voqalize_agent_sdk-0.0.1/LICENSE +201 -0
  4. voqalize_agent_sdk-0.0.1/PKG-INFO +252 -0
  5. voqalize_agent_sdk-0.0.1/README.md +217 -0
  6. voqalize_agent_sdk-0.0.1/RELEASING.md +105 -0
  7. voqalize_agent_sdk-0.0.1/docs/architecture.md +189 -0
  8. voqalize_agent_sdk-0.0.1/docs/decisions.md +212 -0
  9. voqalize_agent_sdk-0.0.1/docs/wire-protocol.md +73 -0
  10. voqalize_agent_sdk-0.0.1/examples/echo/README.md +56 -0
  11. voqalize_agent_sdk-0.0.1/examples/echo/brain.py +37 -0
  12. voqalize_agent_sdk-0.0.1/examples/echo/run_direct.py +39 -0
  13. voqalize_agent_sdk-0.0.1/examples/fastapi_inbound/Dockerfile +22 -0
  14. voqalize_agent_sdk-0.0.1/examples/fastapi_inbound/README.md +97 -0
  15. voqalize_agent_sdk-0.0.1/examples/fastapi_inbound/app.py +112 -0
  16. voqalize_agent_sdk-0.0.1/examples/fastapi_inbound/requirements.txt +7 -0
  17. voqalize_agent_sdk-0.0.1/examples/travel/brain.py +435 -0
  18. voqalize_agent_sdk-0.0.1/examples/travel/run.py +31 -0
  19. voqalize_agent_sdk-0.0.1/examples/travel/run_direct.py +44 -0
  20. voqalize_agent_sdk-0.0.1/examples/travel/run_local.py +65 -0
  21. voqalize_agent_sdk-0.0.1/examples/travel_adk/agent.py +89 -0
  22. voqalize_agent_sdk-0.0.1/examples/travel_adk/run_conformance.py +115 -0
  23. voqalize_agent_sdk-0.0.1/pyproject.toml +89 -0
  24. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/__init__.py +18 -0
  25. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/brain.py +216 -0
  26. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/coerce.py +221 -0
  27. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/context.py +145 -0
  28. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/heard.py +73 -0
  29. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/resume.py +44 -0
  30. voqalize_agent_sdk-0.0.1/src/voqalize/_framework/turn.py +141 -0
  31. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/__init__.py +64 -0
  32. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/__main__.py +125 -0
  33. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/checks.py +255 -0
  34. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/driver.py +694 -0
  35. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/reference.py +243 -0
  36. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/report.py +235 -0
  37. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/scenarios.py +597 -0
  38. voqalize_agent_sdk-0.0.1/src/voqalize/conformance/wire_pygato.py +274 -0
  39. voqalize_agent_sdk-0.0.1/src/voqalize/google_adk/__init__.py +23 -0
  40. voqalize_agent_sdk-0.0.1/src/voqalize/google_adk/_context.py +19 -0
  41. voqalize_agent_sdk-0.0.1/src/voqalize/google_adk/brain.py +950 -0
  42. voqalize_agent_sdk-0.0.1/src/voqalize/google_adk/testing.py +239 -0
  43. voqalize_agent_sdk-0.0.1/src/voqalize/py.typed +0 -0
  44. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/__init__.py +74 -0
  45. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/_logging.py +132 -0
  46. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/_platform_keys.py +38 -0
  47. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/actions.py +156 -0
  48. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/brain.py +1236 -0
  49. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/engine.py +358 -0
  50. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/inbound.py +206 -0
  51. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/outbound.py +279 -0
  52. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/py.typed +0 -0
  53. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/session.py +362 -0
  54. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/wire/__init__.py +91 -0
  55. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/wire/_frames_pb2.py +80 -0
  56. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/wire/frames.py +328 -0
  57. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/wire/serializer.py +527 -0
  58. voqalize_agent_sdk-0.0.1/src/voqalize/sdk/wire/transport.py +279 -0
  59. voqalize_agent_sdk-0.0.1/tests/__init__.py +0 -0
  60. voqalize_agent_sdk-0.0.1/tests/conformance/__init__.py +0 -0
  61. voqalize_agent_sdk-0.0.1/tests/conformance/test_conformance_suite.py +182 -0
  62. voqalize_agent_sdk-0.0.1/tests/cortex/__init__.py +0 -0
  63. voqalize_agent_sdk-0.0.1/tests/cortex/conftest.py +55 -0
  64. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_endframe_teardown.py +112 -0
  65. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_factory_crash_surfaces.py +58 -0
  66. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_interruption_preempts_worker.py +79 -0
  67. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_outbound_drop.py +130 -0
  68. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_permanent_close_raises.py +32 -0
  69. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_reconnect_clears_queue.py +102 -0
  70. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_serial_dispatch.py +91 -0
  71. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_session_isolation.py +129 -0
  72. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_slow_handler_isolation.py +169 -0
  73. voqalize_agent_sdk-0.0.1/tests/cortex/test_agent_system_lane_priority.py +107 -0
  74. voqalize_agent_sdk-0.0.1/tests/direct/__init__.py +0 -0
  75. voqalize_agent_sdk-0.0.1/tests/direct/test_declared_voice.py +172 -0
  76. voqalize_agent_sdk-0.0.1/tests/direct/test_direct_end_to_end.py +326 -0
  77. voqalize_agent_sdk-0.0.1/tests/direct/test_run_session_handoff.py +207 -0
  78. voqalize_agent_sdk-0.0.1/tests/direct/test_session_end.py +95 -0
  79. voqalize_agent_sdk-0.0.1/tests/direct/test_session_logging.py +211 -0
  80. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/__init__.py +0 -0
  81. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/conftest.py +116 -0
  82. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_agent_leg_reconnect.py +56 -0
  83. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_interruption_cancels_in_flight.py +83 -0
  84. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_pygato_leg_reconnect.py +65 -0
  85. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_round_trip_every_frame.py +82 -0
  86. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_serial_guarantee.py +75 -0
  87. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_session_action.py +195 -0
  88. voqalize_agent_sdk-0.0.1/tests/e2e_cortex/test_e2e_start_frame_lifecycle.py +59 -0
  89. voqalize_agent_sdk-0.0.1/tests/fakes/__init__.py +4 -0
  90. voqalize_agent_sdk-0.0.1/tests/fakes/cortex.py +380 -0
  91. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_canaries.py +132 -0
  92. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_errors.py +148 -0
  93. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_grounding.py +277 -0
  94. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_interruption.py +540 -0
  95. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_lazy_agent.py +143 -0
  96. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_memory.py +164 -0
  97. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_multitool.py +149 -0
  98. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_real_model.py +235 -0
  99. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_resume.py +127 -0
  100. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_runner.py +97 -0
  101. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_seams.py +154 -0
  102. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_session_source_of_truth.py +189 -0
  103. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_subagents.py +145 -0
  104. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_testing_helpers.py +52 -0
  105. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_thought_gating.py +91 -0
  106. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_timeouts.py +105 -0
  107. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_tool_args.py +209 -0
  108. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_tool_guard.py +74 -0
  109. voqalize_agent_sdk-0.0.1/tests/google_adk/test_adk_tool_results.py +187 -0
  110. voqalize_agent_sdk-0.0.1/tests/google_adk/test_travel_adk.py +213 -0
  111. voqalize_agent_sdk-0.0.1/tests/unit/__init__.py +0 -0
  112. voqalize_agent_sdk-0.0.1/tests/unit/test_actions.py +199 -0
  113. voqalize_agent_sdk-0.0.1/tests/unit/test_engine.py +227 -0
  114. voqalize_agent_sdk-0.0.1/tests/wire/__init__.py +0 -0
  115. voqalize_agent_sdk-0.0.1/tests/wire/test_client_message_wire_compat.py +263 -0
  116. voqalize_agent_sdk-0.0.1/tests/wire/test_dispatch_completeness.py +28 -0
  117. voqalize_agent_sdk-0.0.1/tests/wire/test_malformed_bytes.py +25 -0
  118. voqalize_agent_sdk-0.0.1/tests/wire/test_payload_json_roundtrip.py +52 -0
  119. voqalize_agent_sdk-0.0.1/tests/wire/test_serialize_roundtrip.py +160 -0
  120. voqalize_agent_sdk-0.0.1/tests/wire/test_unknown_frame_raises.py +18 -0
  121. voqalize_agent_sdk-0.0.1/tests/wire/test_wire_prefix.py +76 -0
  122. voqalize_agent_sdk-0.0.1/tests/wire/test_wire_reconnect.py +130 -0
@@ -0,0 +1,35 @@
1
+ # Python
2
+ __pycache__/
3
+ *.py[cod]
4
+ .venv/
5
+ .uv/
6
+ uv.lock.*
7
+ dist/
8
+ build/
9
+ *.egg-info/
10
+ .pytest_cache/
11
+ .ruff_cache/
12
+
13
+ # JS / TS
14
+ node_modules/
15
+ .pnpm-store/
16
+ *.tsbuildinfo
17
+ .astro/
18
+ # sdk/react is a pnpm workspace member — the root lockfile is authoritative. This
19
+ # transient lockfile is only written when demos/build.mjs builds it standalone
20
+ # (--ignore-workspace) and must not be committed.
21
+ sdk/react/pnpm-lock.yaml
22
+
23
+ # Generated protobuf stubs (regenerated via `make proto`)
24
+ proto/gen/
25
+
26
+ # Env / secrets
27
+ .env
28
+ .env.*
29
+ !.env.example
30
+
31
+ # OS / editor
32
+ .DS_Store
33
+ *.swp
34
+ .idea/
35
+ .vscode/
@@ -0,0 +1,225 @@
1
+ # Changelog
2
+
3
+ All notable changes to `voqalize-agent-sdk`. This project is pre-1.0 and still
4
+ alpha: the package API can break on a minor version, the **wire** does not.
5
+
6
+ **The numbering restarts at `0.0.1`.** Everything below it — `0.1.0` through the
7
+ work that would have been `0.4.0` — was never published: the one host that used
8
+ the SDK installed it from a path in a sibling checkout. `0.0.1` is the first
9
+ version anyone can `pip install`, and starting the public series at the bottom
10
+ says plainly that nothing here is promised yet. Those older entries stay,
11
+ because the API they describe is the API `0.0.1` ships.
12
+
13
+ ## 0.0.1
14
+
15
+ First release published to PyPI: `pip install voqalize-agent-sdk`.
16
+
17
+ **No wire change.** Every change below is package-API or packaging only; the
18
+ frames a brain emits are byte-identical to what the previous release emitted.
19
+
20
+ ### Added
21
+
22
+ - **Session-scoped logging — your brain's logs join the rest of the call.** Every
23
+ session now runs inside a context that tags each log line with `session_id`,
24
+ and with `tenant_id`/`agent_id` when the connection's verified token carries
25
+ them. A bare `from loguru import logger` anywhere in your brain — including in
26
+ tasks it spawns — picks that up with nothing threaded through your signatures.
27
+
28
+ The SDK **only adds fields**; it never touches your logging setup. If you
29
+ already configure loguru, add `{extra}` to your format. If you don't, call
30
+ `voqalize.sdk.configure_logging()` from your entrypoint — `json_logs=True`
31
+ writes one JSON object per line with the identity fields at top level, which is
32
+ the shape a log shipper indexes on.
33
+
34
+ `session_context(...)` is exported too, for tagging work you do outside a
35
+ session (a warm-up, a background reconciler).
36
+
37
+ - **`voqalize.sdk.Action` — typed UI commands.** Declare a command as a pydantic
38
+ model that carries its own wire name and pass an instance where you used to pass
39
+ `(name, args)`:
40
+
41
+ ```python
42
+ class AddToCart(Action): # wire name: "add_to_cart"
43
+ sku: str
44
+ qty: int = 1
45
+
46
+ interaction.action(AddToCart(sku="oat-milk", qty=2))
47
+ ```
48
+
49
+ The name is `snake_case`d from the class name unless pinned
50
+ (`class AddToCart(Action, name="add_to_cart")`). Serialization is
51
+ `model_dump(by_alias=True, mode="json")`: aliases apply (a `from_` field goes out
52
+ as `from`), `date`/`Enum`/`Decimal`/`UUID` become JSON scalars, nested models and
53
+ lists compose, unknown kwargs are rejected, and **every declared field is emitted
54
+ including `None`** — no `exclude_none`, so the wire shape is a function of the
55
+ class and the browser can declare one total TypeScript interface. A field that
56
+ would serialize to `type`, `action` or `action_id` raises at class definition.
57
+ Accepted by `session.action`, `interaction.action` and `voice().action`, with
58
+ `callback=` unchanged. **The `(name, args)` dict form is unchanged and remains
59
+ first-class** — convert one command at a time. `pydantic` is now a core
60
+ dependency (it was already a transitive one for ADK users).
61
+ - **Tools may return pydantic models.** The ADK adapter's new `after_tool_callback`
62
+ dumps a returned model — and models nested in a returned dict/list — with the
63
+ same `by_alias`/JSON-mode rules before the result reaches the model, so the field
64
+ names a tool declares are the field names the model reads, instead of ADK's
65
+ `str()` of a `BaseModel`. A non-dict dump is wrapped as `{"result": ...}`,
66
+ matching ADK's own handling; a result containing no model passes through
67
+ untouched. This is the mirror of the 0.3.0 tool-*argument* coercion.
68
+ - **`useUiCommand`** in `@voqalize/client-react` is the browser half — see
69
+ [the React client docs](https://voqalize.com/docs/client/react/).
70
+
71
+ ### Changed
72
+
73
+ - **`protobuf>=5.29.3,<7`** (was `>=6.30,<7`) — **the SDK no longer drags a host
74
+ application onto protobuf 6.** The old floor came from the committed wire stubs,
75
+ which were generated with protoc v32 and therefore assert a 6.32 runtime at
76
+ import. A protobuf runtime accepts gencode from its own major or an older one,
77
+ so the stubs are now generated with protoc **v29.3**: they run unchanged on
78
+ protobuf 5.29+ *and* on 6.x, and an application already resolved on 5.29 keeps
79
+ its resolution when it adds this SDK. The `.proto` contract is untouched and the
80
+ wire bytes are identical — this is a gencode-target change, not a wire change.
81
+ We test against both majors.
82
+
83
+ The generator pin lives in `proto/buf.gen.yaml` and now tracks the **oldest**
84
+ runtime we support, not the newest; raise it only together with the floor here.
85
+ - **The `adk` extra now requires `google-adk>=2.3,<3`** (was `>=1.33,<2`). The old
86
+ ceiling held installs on the 1.x line, and 1.x caps two things a host
87
+ application is likely to be ahead of: `starlette<1` (lifted in ADK 2.2) and
88
+ `opentelemetry-*<=1.41.1` (lifted in ADK 2.3). Installing `[adk]` next to a
89
+ modern FastAPI or OTel stack therefore walked those backwards, and dragged in
90
+ the 1.x-only `google-cloud-aiplatform` subtree with them. 2.3 is the first
91
+ release that pins neither. The adapter itself is unchanged — the ADK surfaces
92
+ it uses (`Runner`, `InvocationContext`, callbacks, `types`) are identical
93
+ across the two lines, and the drift canaries pass on 2.3.0 and 2.6.2 alike.
94
+
95
+ ## 0.3.0
96
+
97
+ The ADK adapter grows the seams a real screen-driving agent needed. **No wire
98
+ change** — `proto/voqalize/frames/frames.proto` is untouched, so this is a pure
99
+ package-API release and any 0.2.0 runtime pairing keeps working.
100
+
101
+ ### Added
102
+
103
+ - **`AdkBrain.grounding() -> str | None`** — override it to append live context to
104
+ the **fully assembled** system instruction on *every* model call (the root
105
+ agent's and every sub-agent's). Appending after ADK assembles is what makes it
106
+ compose instead of clobber: a plain-string `instruction` keeps ADK's `{state}`
107
+ templating, a client's own `InstructionProvider` still runs, and one
108
+ registration covers the whole agent tree. `None` appends nothing, turn by turn.
109
+ This replaces reaching for an `InstructionProvider` just to re-read state.
110
+ - **The `state_sync` browser-snapshot convention.** `on_client_message` now
111
+ handles the `state_sync` message type by default and parks the payload on
112
+ **`self.browser_state`**. It **takes no floor** — a screen change never makes
113
+ the agent talk — and it **replaces** rather than merges (the browser sends a
114
+ complete picture; merging would resurrect rows the user just deleted). Pair it
115
+ with `grounding()`. A subclass that overrides `on_client_message` keeps the
116
+ default by calling `super()`. Convention, not protocol: the wire still carries
117
+ an opaque client message.
118
+ - **Tool arguments arrive as the models you annotated.** A parameter typed `Leg`
119
+ or `list[Leg]` (also `Model | None`, `Sequence`/`tuple`/`set` of a model) is
120
+ constructed from the model's raw JSON before the tool runs; every other
121
+ annotation is passed through untouched. `Field(alias=...)` validates **both
122
+ ways** — from the wire's `from` *and* from the schema's `from_` — so a wire key
123
+ that is a Python keyword needs no rename in the body. An argument the model
124
+ shaped wrong comes back to it as a **tool error result** it can retry, not an
125
+ exception that kills the turn. (`voqalize._framework.coerce`, wired at
126
+ `before_tool_callback`.)
127
+ - **The sync-tool guard.** A non-`async` tool is rejected when the agent is
128
+ built, with a `ValueError` naming it — ADK dispatches a sync tool on a thread
129
+ pool, where `voice()` is unset and `voice().action(...)` would raise mid-call,
130
+ after the model already spoke. **`allow_sync_tools=True`** opts out for tools
131
+ that never call `voice()`.
132
+ - **`AdkBrain.agent`** — the ADK `LlmAgent` this brain drives, for inspection in
133
+ tests.
134
+
135
+ ### Changed
136
+
137
+ - **The ADK agent is built lazily**, on first need (session start, or the `agent`
138
+ property) and exactly once — never in `__init__`. A subclass can therefore
139
+ assign its per-session state *after* `super().__init__(...)` and still have the
140
+ factory, the instruction and the tools see it. The "build your state before
141
+ `super().__init__`" ordering trap is gone.
142
+ - **`ScriptedLlm`** records `captured_system_instructions` (each call's assembled
143
+ system instruction, in call order) alongside `captured_contents`.
144
+ - **`call(name, /, ...)` / `reply_and_call(text, name, /, ...)`** take the
145
+ helper's own parameters **positional-only**, so every keyword is unambiguously
146
+ a tool argument — a tool taking `name=` or `text=` no longer collides — plus an
147
+ explicit `args={...}` form for an argument literally named `args`. Mixing the
148
+ two forms raises `TypeError`.
149
+
150
+ ## 0.2.0
151
+
152
+ Breaking changes to the package API. The wire protocol is fully backward
153
+ compatible — every change to `proto/voqalize/frames/frames.proto` in this release
154
+ is an addition, so a 0.1.0 brain keeps working against the current runtime and a
155
+ 0.2.0 brain keeps working against an older one (it just never sees the new
156
+ frames).
157
+
158
+ ### Breaking (package API)
159
+
160
+ - **`on_app_event(session, event)` → `on_client_message(session, message)`.**
161
+ `event.name` → `message.type`, `event.data` → `message.data`. The `AppEvent`
162
+ type is gone; `ClientMessage` replaces it and adds `.id` (the browser-supplied
163
+ message id) and `.interaction_id` (minted by Voice for this message).
164
+ Replying is now explicit: touch `message.interaction` to take the floor and
165
+ respond on the pre-minted id, or read the data and return to ingest it
166
+ silently. Messages from an older runtime arrive unstamped
167
+ (`interaction_id == 0`) and degrade to an agent-initiated turn.
168
+ - **`inference()` → `say()`.** `session.inference()` → `session.say()` and
169
+ `interaction.inference()` → `interaction.say()`. The bracket is otherwise
170
+ unchanged (`async with … as speech: await speech.speak(text)`), still 1:1 with
171
+ one model call.
172
+
173
+ ### Added
174
+
175
+ - **`on_user_idle(interaction)`** — the user went silent past the idle timeout
176
+ and the brain holds the floor to re-engage. `interaction.idle` is an
177
+ `IdleInfo(level, idle_ms)`; `level` escalates while the silence persists and
178
+ resets on user speech. Default is a no-op, so the silence just rides.
179
+ - **`session.configure_idle(timeout_ms=…)`** — set the silence window mid-call;
180
+ `0` disables idle detection entirely.
181
+ - **`InteractionSource`** (`USER` / `IDLE` / `CLIENT_MESSAGE`), readable as
182
+ `interaction.source`.
183
+ - **`voqalize.google_adk`** — hand the SDK a native Google ADK agent
184
+ (`AdkBrain` / `adk_brain(...)`) and let it drive the run loop, including the
185
+ heard-truth corrector that reconciles what the user actually heard back into
186
+ ADK's session history. Optional extra: `pip install voqalize-agent-sdk[adk]`.
187
+ - **`voqalize.conformance`** — a wire-level driver plus a scenario catalog and
188
+ MUST checks that any brain can be run against
189
+ (`python -m voqalize.conformance`), so protocol compatibility is testable
190
+ without the voice runtime.
191
+ - **`voqalize._framework`** — the internal framework-brain machinery the ADK
192
+ adapter is built on (heard-truth readers, greeting resolution, the no-dead-air
193
+ turn runner). Private; not part of the public API.
194
+
195
+ ### Wire (all additive)
196
+
197
+ - `VqlUserIdle` (`Envelope` body 12) — `interaction_id`, `level`, `idle_ms`.
198
+ - `IdleUpdateSettings` (`Envelope` body 38) — JSON idle policy.
199
+ - `RTVIClientMessage.interaction_id` (field 4) — the Voice-minted stamp; `0` or
200
+ absent means an older, unstamped sender.
201
+
202
+ ### Migration
203
+
204
+ ```diff
205
+ -async with session.inference() as inf:
206
+ - await inf.speak("Hi!")
207
+ +async with session.say() as speech:
208
+ + await speech.speak("Hi!")
209
+
210
+ -async def on_app_event(self, session, event) -> None:
211
+ - if event.name == "state_sync":
212
+ - self.screen = event.data
213
+ +async def on_client_message(self, session, message) -> None:
214
+ + if message.type == "state_sync":
215
+ + self.screen = message.data # silent: no floor taken
216
+ + elif message.type == "photo_upload":
217
+ + async with message.interaction.say() as speech:
218
+ + await speech.speak("Let me look at that.")
219
+ ```
220
+
221
+ ## 0.1.0
222
+
223
+ Initial release: the pipecat-free `Brain` surface, the inbound (direct) server
224
+ and the Cortex agent, the `Vql*` wire vocabulary, and the framework-owned
225
+ heard-text conversation record.
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or Derivative
95
+ Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2026 Voqalize
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.