Chat History Component

The Chat History component in FlowHunt allows chatbots to remember previous messages, ensuring coherent conversations and improved customer experience. It limits memory use to save costs and can be configured for message count, type, and token usage.

Categories:
Chat History Component

Imagine a customer chatting with your chatbot about their order. They have further questions, but the bot immediately forgets which order they’re talking about, creating a frustrating customer experience. To prevent this, you will want the chatbot to remember the message history, and that’s exactly what this component does.

However, having AI hold on to previous messages costs tokens. Moreover, many uses of Flows do not require memory. That’s why this component is optional and allows you to limit the memory according to your needs while not breaking the bank.

What is the Chat History component?

The Chat history component ensures the chatbot remembers a set number of previous messages. It allows the chatbot to hold a coherent conversation while limiting the number of remembered messages and token usage.

Chat history can be found in the Memory category of components and is optional:

Flowhunt Chat history feature

Last Messages Count

It controls how many previous messages the chatbot should remember. The default value is 5, which should cover the conversation around any basic query. If your use case requires the bot to hold a coherent conversation for longer, feel free to increase the limit, but don’t forget to increase the Max Tokens setting, too.

Max Tokens

Each past message is tokenized into smaller units of text, which the model processes to generate relevant and context-aware responses. The Max Tokens setting limits the number of tokens used to remember previous messages. Token usage varies with models, and a single token can be anything from words or subwords to a single character.

Message Type

This drop-down setting allows you to filter which messages to remember: only human messages, only AI messages, or all.

How to connect the Chat History component to your flow

The history must be connected to the LLM and the user input to function properly. However, you’ll notice that the component doesn’t have the incoming handle, only the outgoing one.

The Chat History component’s output type is chat history, and it connects to the components asking for history, which are Prompts and Splitters.

For example, in the Follow-up questions component, the answer is provided by connecting an LLM generator, the context by chat history, and the Input text by human Chat Input.

Discover FlowHunt's History Feature to track and analyze chatbot interactions, manage tags, and troubleshoot efficiently. Get started for free!

History Feature

Discover FlowHunt's History Feature to track and analyze chatbot interactions, manage tags, and troubleshoot efficiently. Get started for free!

Explore FlowHunt's expanding components collection—your building blocks for enhancing AI capabilities. Dive in and elevate your workflows today!

Components

Explore FlowHunt's expanding components collection—your building blocks for enhancing AI capabilities. Dive in and elevate your workflows today!

Create and integrate custom AI chatbots effortlessly with FlowHunt. Enhance customer service and automate tasks 24/7. Try it for free today!

Chatbots

Create and integrate custom AI chatbots effortlessly with FlowHunt. Enhance customer service and automate tasks 24/7. Try it for free today!

Discover FlowHunt's modular AI tools and chatbot features for seamless automation and integration with top customer service platforms.

Features

Discover FlowHunt's modular AI tools and chatbot features for seamless automation and integration with top customer service platforms.

Our website uses cookies. By continuing we assume your permission to deploy cookies as detailed in our privacy and cookies policy.