Skip to content

ollamaAPI.chatStreaming does not seem to concatenate tokens #115

@jesuino

Description

@jesuino

Hello,

It seems that when using OllamaAPI::chatStreaming the received token in OllamaTokenHandler does not concatenate the response as mentioned in Javadocs: callback handler to handle the last token from stream (caution: all previous messages from stream will be concatenated)

ollamaAPI.chatStreaming(chatRequest, token ->   System.out.println(token.getMessage().getContent()));

When I use the code above it seems to print token by token, so I have been concatenating them manually.

Kindly let me know if this is a known issue or if I am misunderstanding the documentation.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions