You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I get an empty string when calling cat.llm() with Ollama and Llama3.3 as LLM configuration.
Additional infos:
The behavior is normal with Ollama and Llama3
The cat.llm() is called in a custom plugin that use "before_rabbithole_stores_documents" hook
To Reproduce
Steps to reproduce the behavior:
Create a custom plugin using any Rabbit Hole's hooks that use cat.llm()
Try to injest a document
In the console see that the results of calling cat.llm() (with any prompt) is empty
Expected behavior
Have any filled string as response of LLM to the prompt passed to cat.llm()
Additional context
Here the code snippet where the call.llm() is called:
@hook # default priority = 1
def before_rabbithole_stores_documents(docs, cat):
# summarize group of 5 documents and add them along original ones
entire_doc = "\n".join([doc.page_content for doc in docs])
author = cat.llm(f"""Chi è l'autore o l'organizzazione che ha emesso il seguente documento?
Rispondi in maniera concisa, se non riesci a capirlo non rispondere nulla.
Non includere date ma solo il nome della persona o dell'organizzazione: {entire_doc}
""")
summary = cat.llm(f"Fai un riassunto breve e conciso del seguente testo: {entire_doc}")
Here the console in debug mode with Ollama and Llama3.3:
==================== before_rabbithole_stores_documents prompt ====================
cheshire_cat_core | SystemMessage
cheshire_cat_core | Chi è l'autore o l'organizzazione che ha emesso il seguente documento?
cheshire_cat_core | Rispondi in maniera concisa, se non riesci a capirlo non rispondere nulla.
cheshire_cat_core | Non includere date ma solo il nome della persona o dell'organizzazione: Come puoi
[...]
========================================
cheshire_cat_core |
cheshire_cat_core |
cheshire_cat_core | ==================== before_rabbithole_stores_documents prompt output ====================
cheshire_cat_core |
cheshire_cat_core | ========================================
Here the console in debug mode with Ollama and Llama3:
==================== before_rabbithole_stores_documents prompt ====================
cheshire_cat_core | SystemMessage
cheshire_cat_core | Chi è l'autore o l'organizzazione che ha emesso il seguente documento?
cheshire_cat_core | Rispondi in maniera concisa, se non riesci a capirlo non rispondere nulla.
cheshire_cat_core | Non includere date ma solo il nome della persona o dell'organizzazione: Come puoi
[...]
========================================
cheshire_cat_core |
cheshire_cat_core |
cheshire_cat_core | ==================== before_rabbithole_stores_documents prompt output ====================
cheshire_cat_core | L'autore del documento è [...]
cheshire_cat_core | ========================================
The text was updated successfully, but these errors were encountered:
Below is the solution I propose. It works but needs to be tested more widely: in llm() method of stray_cat replace SystemMessage with HumanMessage. (Ref. line 296 of core/cat/looking_glass/stray_cat.py)
Describe the bug
I get an empty string when calling cat.llm() with Ollama and Llama3.3 as LLM configuration.
Additional infos:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Have any filled string as response of LLM to the prompt passed to cat.llm()
Additional context
Here the code snippet where the call.llm() is called:
Here the console in debug mode with Ollama and Llama3.3:
Here the console in debug mode with Ollama and Llama3:
The text was updated successfully, but these errors were encountered: