Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX: handling of very long chat messages #558

Merged
merged 1 commit into from
Nov 20, 2023

Conversation

kodaline
Copy link
Contributor

Description

Handle of very long chat messages

The following files were changed:

  • cheshire_cat.py: input message is split at MAX_TEXT_INPUT tokens saving what exceeds in declarative memory
  • rabbit_hole.py: new method string_to_docs to just convert strings in documents

relates to issue #334

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas

@kodaline
Copy link
Contributor Author

Hi @pieroit , here is a way to handle very long chat messages, splitting them at MAX_TEXT_INPUT and sending the rest to the cat's declarative memory as discussed

- cheshire_cat.py: input message is split at MAX_TEXT_INPUT tokens
saving what exceeds in declarative memory
- rabbit_hole.py: new method string_to_docs to just convert strings
in documents

relates to issue cheshire-cat-ai#334
@kodaline kodaline changed the base branch from main to develop November 11, 2023 09:37
@pieroit
Copy link
Member

pieroit commented Nov 14, 2023

@kodaline we need to revert the develop branch from async/await back to threadpool, because too many things are getting buggy.
As soon as that part is finished I'll review this PR, please leave open ;)

@pieroit
Copy link
Member

pieroit commented Nov 20, 2023

Thanks!!

@pieroit pieroit merged commit dd21f5a into cheshire-cat-ai:develop Nov 20, 2023
1 check passed
kodaline added a commit to kodaline/core that referenced this pull request Nov 24, 2023
- cheshire_cat.py: new method store_long_input_to_declarative
to deal with very long inputs

improvement of issue cheshire-cat-ai#558
@kodaline kodaline deleted the develop_issue_#334 branch January 7, 2024 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants