graphiti/core/prompts/models.py
Daniel Chalef 73ec0146ff
ruff action (#17)
* ruff action

* chore: Update Python version to 3.10 in lint.yml workflow

* fix lint and formatting

* cleanup
2024-08-22 13:06:42 -07:00

15 lines
284 B
Python

from typing import Callable, Protocol
from pydantic import BaseModel
class Message(BaseModel):
role: str
content: str
class PromptVersion(Protocol):
def __call__(self, context: dict[str, any]) -> list[Message]: ...
PromptFunction = Callable[[dict[str, any]], list[Message]]