amfs-adapter-postgres 0.2.1__tar.gz → 0.2.2__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.
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/PKG-INFO +1 -1
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/pyproject.toml +1 -1
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/adapter.py +13 -1
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/.gitignore +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/__init__.py +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/_fts.py +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/async_adapter.py +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/001_initial.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/002_artifact_refs.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/002_search_indexes.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/003_knowledge_graph.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/004_agent_groups.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/005_configurable_embedding_dim.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/006_is_artifact.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/migrations/006_outcome_confidence_semantics.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/schema.sql +0 -0
- {amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/tenant_context.py +0 -0
|
@@ -60,6 +60,7 @@ from amfs_core.models import (
|
|
|
60
60
|
QueryEvent,
|
|
61
61
|
SearchQuery,
|
|
62
62
|
SemanticQuery,
|
|
63
|
+
SessionMetadata,
|
|
63
64
|
Tag,
|
|
64
65
|
ToolCall,
|
|
65
66
|
TraceEntry,
|
|
@@ -2595,7 +2596,18 @@ class PostgresAdapter(AdapterABC):
|
|
|
2595
2596
|
trace.session_duration_ms,
|
|
2596
2597
|
json.dumps([e.model_dump(mode="json") for e in trace.error_events]),
|
|
2597
2598
|
json.dumps(trace.state_diff.model_dump(mode="json")) if trace.state_diff else None,
|
|
2598
|
-
|
|
2599
|
+
# Dumped like every other model field on this row. The
|
|
2600
|
+
# field is typed, so anything arriving over
|
|
2601
|
+
# ``POST /api/v1/traces`` is a ``SessionMetadata`` by the
|
|
2602
|
+
# time it reaches here and ``json.dumps`` cannot encode
|
|
2603
|
+
# it — the trace was lost with a 500. A plain dict still
|
|
2604
|
+
# gets through ``model_copy(update=...)``, which does not
|
|
2605
|
+
# validate, so both shapes are accepted.
|
|
2606
|
+
json.dumps(
|
|
2607
|
+
trace.session_metadata.model_dump(mode="json")
|
|
2608
|
+
if isinstance(trace.session_metadata, SessionMetadata)
|
|
2609
|
+
else trace.session_metadata
|
|
2610
|
+
) if trace.session_metadata else "{}",
|
|
2599
2611
|
trace.created_at,
|
|
2600
2612
|
trace.task_input,
|
|
2601
2613
|
trace.response_text,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/async_adapter.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{amfs_adapter_postgres-0.2.1 → amfs_adapter_postgres-0.2.2}/src/amfs_postgres/tenant_context.py
RENAMED
|
File without changes
|