Skip to content
Snippets Groups Projects
Unverified Commit ce94beb7 authored by James Briggs's avatar James Briggs
Browse files

lint

parent 9575e7fe
Branches
Tags
No related merge requests found
...@@ -2,7 +2,7 @@ from contextlib import contextmanager ...@@ -2,7 +2,7 @@ from contextlib import contextmanager
from pathlib import Path from pathlib import Path
from typing import Any, Optional from typing import Any, Optional
from llama_cpp import Llama, LlamaGrammar, CreateChatCompletionResponse from llama_cpp import Llama, LlamaGrammar
from semantic_router.llms.base import BaseLLM from semantic_router.llms.base import BaseLLM
from semantic_router.schema import Message from semantic_router.schema import Message
...@@ -57,7 +57,7 @@ class LlamaCppLLM(BaseLLM): ...@@ -57,7 +57,7 @@ class LlamaCppLLM(BaseLLM):
grammar=self.grammar, grammar=self.grammar,
stream=False, stream=False,
) )
assert type(completion) is CreateChatCompletionResponse assert isinstance(completion, dict) # keep mypy happy
output = completion["choices"][0]["message"]["content"] output = completion["choices"][0]["message"]["content"]
if not output: if not output:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment