Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ v0.51.0 - ADK 2.0 clean-break store contract
``get_metadata``, and ``set_metadata``.
* ``append_event_and_update_state()`` accepts optional ``app_state`` and
``user_state`` deltas and applies them atomically with the session and event
write, returning the updated ``SessionRecord``.
write, returning the updated ``StoredSession``.

**Fixed:**

Expand Down Expand Up @@ -750,7 +750,7 @@ v0.47.0 - Persistent listeners, schema builders, and performance polish
Pydantic, dataclasses, and attrs. Pass ``wire_format=True`` to keep
wire-aligned names.
* Third-party ADK stores implementing ``append_event_and_update_state()`` must
return the updated ``SessionRecord``.
return the updated ``StoredSession``.
* Data dictionary metadata/version helpers now live under
``sqlspec.data_dictionary``. ``ColumnMetadata``, ``ForeignKeyMetadata``,
``IndexMetadata``, ``TableMetadata``, ``VersionInfo``, and
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/extensions/adk/memory_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import pytest

if TYPE_CHECKING:
from sqlspec.extensions.adk import EventRecord
from sqlspec.extensions.adk import StoredEvent

__all__ = ("test_adk_memory_store",)

Expand All @@ -16,7 +16,7 @@ def test_adk_memory_store() -> None:
pytest.importorskip("aiosqlite")
pytest.importorskip("google.adk")

async def _run() -> list[EventRecord]:
async def _run() -> list[StoredEvent]:
# start-example
from google.adk.events.event import Event
from google.genai import types
Expand Down
8 changes: 4 additions & 4 deletions docs/extensions/adk/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -79,22 +79,22 @@ Artifact Stores
Record Types
============

.. autoclass:: SessionRecord
.. autoclass:: StoredSession
:members:
:show-inheritance:
:no-index:

.. autoclass:: EventRecord
.. autoclass:: StoredEvent
:members:
:show-inheritance:
:no-index:

.. autoclass:: MemoryRecord
.. autoclass:: StoredMemory
:members:
:show-inheritance:
:no-index:

.. autoclass:: ArtifactRecord
.. autoclass:: StoredArtifact
:members:
:show-inheritance:
:no-index:
Expand Down
4 changes: 2 additions & 2 deletions docs/extensions/adk/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Key capabilities:

- **Session and event storage** with atomic ``append_event_and_update_state()``
ensuring events and state are always consistent.
- **Full-event JSON storage** (EventRecord) that captures the entire ADK Event
- **Full-event JSON storage** (StoredEvent) that captures the entire ADK Event
in a single column, eliminating schema drift with upstream ADK releases.
- **Scoped state semantics** (``app:``, ``user:``, ``temp:``) for controlling
state visibility and persistence across sessions.
Expand Down Expand Up @@ -56,7 +56,7 @@ Choose a guide
:link: schema
:link-type: doc

Table layouts, EventRecord, scoped state, and artifact metadata.
Table layouts, StoredEvent, scoped state, and artifact metadata.

.. grid-item-card:: API Reference
:link: api
Expand Down
2 changes: 1 addition & 1 deletion docs/extensions/adk/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ The ``adk`` extra includes the Google ADK SDK (``google-genai``). SQLSpec provid
for context retrieval across conversations.
- **Artifact Service contracts** -- Compose a concrete metadata store with
pluggable object storage backends when your deployment needs ADK artifacts.
- **Event Storage** -- Full-event JSON storage (EventRecord) that captures the
- **Event Storage** -- Full-event JSON storage (StoredEvent) that captures the
entire ADK Event without schema drift.

Next Steps
Expand Down
2 changes: 1 addition & 1 deletion docs/extensions/adk/quickstart.rst
Original file line number Diff line number Diff line change
Expand Up @@ -117,5 +117,5 @@ Next Steps
==========

- :doc:`backends` for the full support matrix and backend-specific details.
- :doc:`schema` for table layouts, EventRecord format, and scoped state semantics.
- :doc:`schema` for table layouts, StoredEvent format, and scoped state semantics.
- :doc:`api` for the complete API reference.
6 changes: 3 additions & 3 deletions docs/extensions/adk/schema.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ config for multi-tenant deployments.

.. _event-record:

Events Table (EventRecord)
Events Table (StoredEvent)
==========================

The events table uses **full-event JSON storage**: the entire ADK ``Event`` is
Expand Down Expand Up @@ -107,15 +107,15 @@ via ``Event.model_validate()``.

from sqlspec.extensions.adk.converters import event_to_record, record_to_event

# Serialize: Event -> EventRecord
# Serialize: Event -> StoredEvent
record = event_to_record(
event=adk_event,
app_name="my_agent",
user_id="user_123",
session_id="sess_123",
)

# Reconstruct: EventRecord -> Event
# Reconstruct: StoredEvent -> Event
restored_event = record_to_event(record)

.. _scoped-state:
Expand Down
8 changes: 4 additions & 4 deletions docs/reference/extensions/adk.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,19 +67,19 @@ Artifact Store Base Classes
Record Types
============

.. autoclass:: sqlspec.extensions.adk.SessionRecord
.. autoclass:: sqlspec.extensions.adk.StoredSession
:members:
:show-inheritance:

.. autoclass:: sqlspec.extensions.adk.EventRecord
.. autoclass:: sqlspec.extensions.adk.StoredEvent
:members:
:show-inheritance:

.. autoclass:: sqlspec.extensions.adk.MemoryRecord
.. autoclass:: sqlspec.extensions.adk.StoredMemory
:members:
:show-inheritance:

.. autoclass:: sqlspec.extensions.adk.ArtifactRecord
.. autoclass:: sqlspec.extensions.adk.StoredArtifact
:members:
:show-inheritance:

Expand Down
Loading
Loading