Comments (2)
This is amazing. Thank you so much for the pointers and an overview. Enough to get me on my way. Thanks again!
from smooch-bot-example.
Can all this (full screen, let the bot initiate the conversation and show a typing indicator) be achieved with this framework?
In short, yes, but much of the onboarding UI was heavily customized and is not reusable, so you would have to do much of it yourself.
The conversation script of the Smooch onboarding uses this state machine model, so that part would be easy to do. However, from your questions it sounds like you're interested in the UI as well. The onboarding chat UI was derived from our web widget, smooch/smooch-js, but it was very heavily modified, things like setting up a Smooch app using your company name and automatically detecting when certain steps were completed, all of that was custom built front and back for the specific onboarding experience we wanted.
The goal of smooch/smooch-bot however is to be a offer a more generic framework, without any assumptions made about the UI.
With that said, I can give you some pointers.
-
Without any code changes you can run the smooch/smooch-js widget in full screen by running it in embedded mode.
-
Simulating the bot's typing indicators requires a little more work. The way we did this was very hackish to be honest. We set a kind of "bot will respond" flag in each bot message's metadata and assuming that flag was there we rendered a fake typing indicator client side as soon as the user sent a message.
-
The bot response delay is also simulated. We compute the delay based on the length of the bot's message. You can do this easily in your bot's
say()
implmementation by simply delaying the promise resolution with Q.delay, or your own favorite promise implementation. -
Finally, the immediate first message you see in the onboarding experience is actually implemented as a Smooch whisper, which we trigger with a track call.
I hope that gives you something useful to work off of :)
from smooch-bot-example.
Related Issues (20)
- Reply button in web embedded widget opens new browser tab on click HOT 4
- Restarting the bot conversation HOT 2
- smooch-bot-example not switching to another block
- Simulating typing status HOT 1
- Bot states inconsistent with multiple user messages. HOT 3
- smooch Bot /help menu implementation HOT 4
- Smooch Webhook - Bad Request HOT 1
- Deploy to AWS Lambda HOT 4
- Passing a param from heroku/index.js to a certain state in script.js HOT 1
- how to get last bot state HOT 3
- Get message from slack/frontApp and do some processing! HOT 5
- How to deploy this to existing heroku app. HOT 1
- App crash on PROD heroku HOT 3
- Reset bot state to => 'start' after 15 minutes of idle chat
- [REQUEST] HOT 1
- Cannot send message to our customer when customer did not write first. :( HOT 5
- Changing Script
- how to move bot receive step in script.js
- How to send sms to chatbot user using twilio with smooch API
- Uncaught (in promise) Error at o (shallowEqual.js:18) HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from smooch-bot-example.