Skip to content

Llama.cpp - confusing and infinitely long answers. #5250

Closed Answered by dosubot bot
pironev asked this question in Q&A
Discussion options

You must be logged in to vote

It sounds like you're encountering an issue with the LlamaCpp model generating infinitely long and confusing responses, especially when using simple prompts like "Hello". This behavior might be related to how the streaming functionality is implemented in the LlamaCpp model within the LangChain JS framework.

The stream method you're using is designed to return a stream of responses in chunks, which should theoretically stop once the model has finished generating its response based on the maxTokens parameter you've set. However, if the stream doesn't terminate as expected, it could lead to the infinite response issue you're experiencing.

Given that you're already specifying a maxTokens lim…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@pironev
Comment options

@dosubot
Comment options

Answer selected by pironev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant