From fc1ea82cb1a0478a4a40e8f15ad21206ebe0f3af Mon Sep 17 00:00:00 2001 From: Yiorgis Gozadinos Date: Wed, 14 Jan 2026 18:14:53 +0200 Subject: [PATCH] Display on info pydantic-ai and docling-document schema version --- CHANGELOG.md | 1 + haiku_rag_slim/haiku/rag/app.py | 10 ++++++++++ tests/test_info.py | 2 ++ 3 files changed, 13 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a5eb3e84..79fb7dda 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ ### Added +- **Enhanced Database Info**: `haiku-rag info` now displays `pydantic-ai` version and `docling-document schema` version - **Keyed State Emission for Chat Agent**: New `state_key` parameter in `ChatDeps` for namespaced AG-UI state snapshots - When set, tools emit `{state_key: snapshot}` instead of bare state, enabling state merging when multiple agents share state - Default `None` preserves backwards compatibility (bare state emission) diff --git a/haiku_rag_slim/haiku/rag/app.py b/haiku_rag_slim/haiku/rag/app.py index e570028a..73467351 100644 --- a/haiku_rag_slim/haiku/rag/app.py +++ b/haiku_rag_slim/haiku/rag/app.py @@ -98,6 +98,10 @@ class HaikuRAGApp: docling_version = pkg_version("docling") except Exception: docling_version = "unknown" + pydantic_ai_version = pkg_version("pydantic-ai-slim") + from docling_core.types.doc.document import DoclingDocument + + docling_document_version = DoclingDocument.model_construct().version # Get comprehensive table statistics (this also runs migrations) from haiku.rag.store.engine import Store @@ -219,6 +223,12 @@ class HaikuRAGApp: self.console.print( f" [repr.attrib_name]docling[/repr.attrib_name]: {docling_version}" ) + self.console.print( + f" [repr.attrib_name]pydantic-ai[/repr.attrib_name]: {pydantic_ai_version}" + ) + self.console.print( + f" [repr.attrib_name]docling-document schema[/repr.attrib_name]: {docling_document_version}" + ) async def history(self, table: str | None = None, limit: int | None = None): """Display version history for database tables. diff --git a/tests/test_info.py b/tests/test_info.py index 11f4fa25..cd24bac4 100644 --- a/tests/test_info.py +++ b/tests/test_info.py @@ -81,6 +81,8 @@ async def test_app_info_outputs(temp_db_path, capsys): # Package versions section assert "lancedb:" in out assert "haiku.rag:" in out + assert "docling-document schema:" in out + assert "pydantic-ai:" in out @pytest.mark.asyncio