cheshire-cat-ai/docs

Fix `before_rabbithole_splits_text` input argument description

Closed this issue · 7 comments

The before_rabbithole_splits_text hook in the hook table describes the input as a Langchain doc.
However, the correct input is a list with inside a Langchain doc.

Hello @nicola-corbellini ,

In rabbithole.py we have a single Langchain doc as input.

Should we change also the core?

Hi @Tudor44, good question. Let's ask @pieroit. Should we align the doc to the core or change the core and pass the doc instead instead of the List[doc]?

@pieroit tagging you again in case you missed this

Hi @nicola-corbellini @Tudor44 looks to me the hook receives a Document and returns a Document (no lists, because that is the whole content of the file/URL)

actually the hook receives what the parser returns, that is indeed a list of Document.
I can open an issue in the core repo to fix this or we can fix the documentation accordingly

@nicola-corbellini oh ok got it sorry
Push a commit to core directly when you get the chance ;)

Sure, I'll do asap! :) I'll close this issue then