Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9d7ce399c8 |
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [1.3.2] - 2025-12-14
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- **Memory**: Fix biographer tool type hints for Ollama compatibility (remove `| None` union types)
|
||||||
|
|
||||||
## [1.3.1] - 2025-12-14
|
## [1.3.1] - 2025-12-14
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|||||||
@@ -432,7 +432,7 @@ For LLM agent development guidelines and architectural decisions, see [AGENTS.md
|
|||||||
|
|
||||||
## Version
|
## Version
|
||||||
|
|
||||||
Current version: **1.3.1** - Biographer delegation fix
|
Current version: **1.3.2** - Biographer tool type hints fix
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "tatlock"
|
name = "tatlock"
|
||||||
version = "1.3.1"
|
version = "1.3.2"
|
||||||
description = "OpenAI-compatible API with Ollama backend"
|
description = "OpenAI-compatible API with Ollama backend"
|
||||||
requires-python = ">=3.12"
|
requires-python = ">=3.12"
|
||||||
dependencies = []
|
dependencies = []
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ logger = get_logger(__name__)
|
|||||||
|
|
||||||
async def recall_semantic(
|
async def recall_semantic(
|
||||||
query: str,
|
query: str,
|
||||||
memory_type: str | None = None,
|
memory_type: str = "",
|
||||||
limit: int = 5,
|
limit: int = 5,
|
||||||
) -> str:
|
) -> str:
|
||||||
"""
|
"""
|
||||||
@@ -64,7 +64,7 @@ async def recall_semantic(
|
|||||||
user=user,
|
user=user,
|
||||||
query_vector=query_vector,
|
query_vector=query_vector,
|
||||||
limit=limit,
|
limit=limit,
|
||||||
memory_type=memory_type,
|
memory_type=memory_type if memory_type else None,
|
||||||
)
|
)
|
||||||
|
|
||||||
if not results:
|
if not results:
|
||||||
@@ -111,7 +111,6 @@ async def recall_semantic(
|
|||||||
async def store_insight(
|
async def store_insight(
|
||||||
key: str,
|
key: str,
|
||||||
value: str,
|
value: str,
|
||||||
keywords: list[str] | None = None,
|
|
||||||
importance: float = 0.5,
|
importance: float = 0.5,
|
||||||
) -> str:
|
) -> str:
|
||||||
"""
|
"""
|
||||||
@@ -128,7 +127,6 @@ async def store_insight(
|
|||||||
Args:
|
Args:
|
||||||
key: Short identifier for the memory (e.g., "car", "employer", "pet")
|
key: Short identifier for the memory (e.g., "car", "employer", "pet")
|
||||||
value: The actual information to remember
|
value: The actual information to remember
|
||||||
keywords: Optional keywords for better search (auto-extracted if not provided)
|
|
||||||
importance: How important is this? 0.0 (trivial) to 1.0 (critical)
|
importance: How important is this? 0.0 (trivial) to 1.0 (critical)
|
||||||
|
|
||||||
Returns:
|
Returns:
|
||||||
@@ -137,13 +135,10 @@ async def store_insight(
|
|||||||
Examples:
|
Examples:
|
||||||
store_insight("car", "User drives a Tesla Model 3")
|
store_insight("car", "User drives a Tesla Model 3")
|
||||||
store_insight("employer", "Works at Acme Corp as software engineer", importance=0.8)
|
store_insight("employer", "Works at Acme Corp as software engineer", importance=0.8)
|
||||||
store_insight("coffee", "Prefers oat milk lattes", keywords=["coffee", "drink", "preference"])
|
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
# Auto-generate keywords if not provided
|
# Auto-generate keywords from key and value
|
||||||
if not keywords:
|
|
||||||
keywords = [key]
|
keywords = [key]
|
||||||
# Extract simple keywords from value
|
|
||||||
words = value.lower().split()
|
words = value.lower().split()
|
||||||
keywords.extend([w for w in words if len(w) > 4][:5])
|
keywords.extend([w for w in words if len(w) > 4][:5])
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user