feat: add kwargs to other adapters
This commit is contained in:
parent
aa8afefe8a
commit
af8c5bedcc
5 changed files with 7 additions and 7 deletions
|
|
@ -51,7 +51,7 @@ class AnthropicAdapter(LLMInterface):
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def acreate_structured_output(
|
async def acreate_structured_output(
|
||||||
self, text_input: str, system_prompt: str, response_model: Type[BaseModel]
|
self, text_input: str, system_prompt: str, response_model: Type[BaseModel], **kwargs
|
||||||
) -> BaseModel:
|
) -> BaseModel:
|
||||||
"""
|
"""
|
||||||
Generate a response from a user query.
|
Generate a response from a user query.
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ class GeminiAdapter(LLMInterface):
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def acreate_structured_output(
|
async def acreate_structured_output(
|
||||||
self, text_input: str, system_prompt: str, response_model: Type[BaseModel]
|
self, text_input: str, system_prompt: str, response_model: Type[BaseModel], **kwargs
|
||||||
) -> BaseModel:
|
) -> BaseModel:
|
||||||
"""
|
"""
|
||||||
Generate a response from a user query.
|
Generate a response from a user query.
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ class GenericAPIAdapter(LLMInterface):
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def acreate_structured_output(
|
async def acreate_structured_output(
|
||||||
self, text_input: str, system_prompt: str, response_model: Type[BaseModel]
|
self, text_input: str, system_prompt: str, response_model: Type[BaseModel], **kwargs
|
||||||
) -> BaseModel:
|
) -> BaseModel:
|
||||||
"""
|
"""
|
||||||
Generate a response from a user query.
|
Generate a response from a user query.
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@ class MistralAdapter(LLMInterface):
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def acreate_structured_output(
|
async def acreate_structured_output(
|
||||||
self, text_input: str, system_prompt: str, response_model: Type[BaseModel]
|
self, text_input: str, system_prompt: str, response_model: Type[BaseModel], **kwargs
|
||||||
) -> BaseModel:
|
) -> BaseModel:
|
||||||
"""
|
"""
|
||||||
Generate a response from the user query.
|
Generate a response from the user query.
|
||||||
|
|
|
||||||
|
|
@ -74,7 +74,7 @@ class OllamaAPIAdapter(LLMInterface):
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def acreate_structured_output(
|
async def acreate_structured_output(
|
||||||
self, text_input: str, system_prompt: str, response_model: Type[BaseModel]
|
self, text_input: str, system_prompt: str, response_model: Type[BaseModel], **kwargs
|
||||||
) -> BaseModel:
|
) -> BaseModel:
|
||||||
"""
|
"""
|
||||||
Generate a structured output from the LLM using the provided text and system prompt.
|
Generate a structured output from the LLM using the provided text and system prompt.
|
||||||
|
|
@ -121,7 +121,7 @@ class OllamaAPIAdapter(LLMInterface):
|
||||||
before_sleep=before_sleep_log(logger, logging.DEBUG),
|
before_sleep=before_sleep_log(logger, logging.DEBUG),
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def create_transcript(self, input_file: str) -> str:
|
async def create_transcript(self, input_file: str, **kwargs) -> str:
|
||||||
"""
|
"""
|
||||||
Generate an audio transcript from a user query.
|
Generate an audio transcript from a user query.
|
||||||
|
|
||||||
|
|
@ -160,7 +160,7 @@ class OllamaAPIAdapter(LLMInterface):
|
||||||
before_sleep=before_sleep_log(logger, logging.DEBUG),
|
before_sleep=before_sleep_log(logger, logging.DEBUG),
|
||||||
reraise=True,
|
reraise=True,
|
||||||
)
|
)
|
||||||
async def transcribe_image(self, input_file: str) -> str:
|
async def transcribe_image(self, input_file: str, **kwargs) -> str:
|
||||||
"""
|
"""
|
||||||
Transcribe content from an image using base64 encoding.
|
Transcribe content from an image using base64 encoding.
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue