diff options
Diffstat (limited to 'rag/generator/ollama.py')
-rw-r--r-- | rag/generator/ollama.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rag/generator/ollama.py b/rag/generator/ollama.py index cd8533b..87f9672 100644 --- a/rag/generator/ollama.py +++ b/rag/generator/ollama.py @@ -26,7 +26,7 @@ class Ollama(metaclass=AbstractGenerator): def __context(self, documents: List[Document]) -> str: results = [ - f"Document: {i}\ntitle: {doc.title}\n{doc.text}" + f"Document: {i}\ntitle: {doc.title}\ntext: {doc.text}" for i, doc in enumerate(documents) ] return "\n".join(results) @@ -60,7 +60,7 @@ class Ollama(metaclass=AbstractGenerator): return metaprompt def generate(self, prompt: Prompt) -> Generator[Any, Any, Any]: - log.debug("Generating answer...") + log.debug("Generating answer with ollama...") metaprompt = self.__metaprompt(prompt) for chunk in ollama.generate( model=self.model, prompt=metaprompt, system=SYSTEM_PROMPT, stream=True |