fix: mypy

This commit is contained in:
Javier Martinez 2024-09-24 17:40:13 +02:00
parent 7c99878576
commit dbbe5bcf07
No known key found for this signature in database
10 changed files with 35 additions and 24 deletions

View file

@ -40,7 +40,8 @@ class AbstractPromptStyle(abc.ABC):
logger.debug("Got for messages='%s' the prompt='%s'", messages, prompt)
return prompt
def completion_to_prompt(self, completion: str) -> str:
def completion_to_prompt(self, prompt: str) -> str:
completion = prompt # Fix: Llama-index parameter has to be named as prompt
prompt = self._completion_to_prompt(completion)
logger.debug("Got for completion='%s' the prompt='%s'", completion, prompt)
return prompt