File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 1616from dataclasses import dataclass
1717from datetime import datetime , timezone
1818from pathlib import Path
19- from typing import Annotated , Self
19+ from typing import Annotated , Self , TypeVar
2020
2121import asyncpg
2222import numpy as np
3535DEFAULT_LLM_MODEL = "openai:gpt-4o"
3636DEFAULT_EMBEDDING_MODEL = "text-embedding-3-small"
3737
38+ T = TypeVar ("T" )
39+
3840mcp = FastMCP (
3941 "memory" ,
4042 dependencies = [
@@ -57,7 +59,7 @@ def cosine_similarity(a: list[float], b: list[float]) -> float:
5759 return np .dot (a_array , b_array ) / (np .linalg .norm (a_array ) * np .linalg .norm (b_array ))
5860
5961
60- async def do_ai [ T ] (
62+ async def do_ai (
6163 user_prompt : str ,
6264 system_prompt : str ,
6365 result_type : type [T ] | Annotated ,
You can’t perform that action at this time.
0 commit comments