diff --git a/turnstone/core/memory.py b/turnstone/core/memory.py index 99e43fc6..8c7bd6c2 100644 --- a/turnstone/core/memory.py +++ b/turnstone/core/memory.py @@ -79,15 +79,10 @@ def save_messages_bulk(rows: list[dict[str, Any]]) -> None: log.warning("Failed to bulk-save %d messages", len(rows), exc_info=True) -def load_messages(ws_id: str, *, limit: int | None = None) -> list[dict[str, Any]]: - """Load messages for a workstream and reconstruct OpenAI message format. - - *limit* tail-loads the most recent N rows when set; the storage - backend already accepts the kwarg. Used by callers that don't - need the full transcript (e.g. browsing a long-running coord). - """ +def load_messages(ws_id: str) -> list[dict[str, Any]]: + """Load messages for a workstream and reconstruct OpenAI message format.""" try: - return get_storage().load_messages(ws_id, limit=limit) + return get_storage().load_messages(ws_id) except Exception: log.warning("Failed to load messages for ws=%s", ws_id, exc_info=True) return []