-
Notifications
You must be signed in to change notification settings - Fork 458
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
Seed chat history #132
Comments
use google firebase |
@Dobby89 - I'm currently trying to do the same with Amazon Lex. Did you manage to figure this out? |
@tabrza I ended up making my own chat bot because it had too many custom requirements, so not exactly. But I did use localstorage to persist certain state properties between page refreshes. For the conversation history I'm using a dynamo DB, but obviously any DB would suffice. |
Got it! Would you feel comfortable sharing the code/repo? As you probably saw, I'm trying to get this working with Amazon Lex - just trying to finish the final step of front-end interaction.. |
we can assume that we already have his backend / database part, so we just need to know how we can fill the chat with previous messages with things (like timestamp). |
From this PR #275 we can active a history by messages.forEach(({ who, message, messageId, date }) => {
if(who == 'client')
addUserMessage(message, messageId, date);
else
addResponseMessage(message, messageId, date);
}); |
Is there a way to Seed/save/rehydrate/keep/preserve the chat history from local storage or a cookie or something?
I'm thinking of a use case where the user is browsing from page to page and the chat history has to be preserved across page reloads so the user isn't presented with a clear chat every time.
The text was updated successfully, but these errors were encountered: