diff --git a/gramps_webapi/__main__.py b/gramps_webapi/__main__.py index 44e79b78..cc3f5f62 100644 --- a/gramps_webapi/__main__.py +++ b/gramps_webapi/__main__.py @@ -31,7 +31,7 @@ from threading import Thread import click -import waitress +import waitress # type: ignore import webbrowser from .api.search import get_search_indexer, get_semantic_search_indexer diff --git a/gramps_webapi/api/llm/__init__.py b/gramps_webapi/api/llm/__init__.py index 86f89e3e..aa05d929 100644 --- a/gramps_webapi/api/llm/__init__.py +++ b/gramps_webapi/api/llm/__init__.py @@ -54,9 +54,9 @@ def answer_prompt(prompt: str, system_prompt: str, config: dict | None = None) - try: response = client.chat.completions.create( - messages=messages, + messages=messages, # type: ignore model=model, - ) # type: ignore + ) except RateLimitError: abort_with_message(500, "Chat API rate limit exceeded.") except APIError: