extended-salmon•2y ago
"yarn dev" leads to myriad of errors
using node v20 in the examples/live-agent repo and getting the following:
37 Replies
To resolve the errors you're encountering when running
yarn dev in the examples/live-agent repo using Node v20, follow these steps:
1. Check Node Version Compatibility:
- Ensure the project is compatible with Node v20. Some projects may require a specific Node version. You can check the engines field in the package.json file for the required Node version.
2. Install Dependencies:
- Run yarn install to ensure all dependencies are correctly installed. This can resolve many issues related to missing or incompatible packages.
3. Clear Cache:
- Sometimes, clearing the yarn cache can help. Run yarn cache clean and then yarn install again.
4. Update Dependencies:
- If the project dependencies are outdated, you might need to update them. Run yarn upgrade to update all dependencies to their latest versions.
5. Check for Known Issues:
- Look for any known issues in the repository's issue tracker on GitHub. There might be specific fixes or workarounds for Node v20.
6. Run the Development Server:
- After ensuring all dependencies are correctly installed and updated, run yarn dev again.
If the errors persist, you might need to provide more specific error messages for further assistance.
For more detailed instructions, you can refer to the Voiceflow demo-react-chat repository.extended-salmonOP•2y ago
"yarn upgrade" does not work, yarn up does though. still identical errors on v20 + yarn dev
extended-salmonOP•2y ago

extended-salmonOP•2y ago
got it working with the demo-react-chat app
extended-salmonOP•2y ago

extended-salmonOP•2y ago
it "works" but the typing thing dissapears instantly
and i get no response back
how can i get this working? @SuperZooper ty
@Deleted User on the repo for react chat demo it states:

so might be that it messes up due to it just not being supported anymore?
extended-salmonOP•2y ago
its the react-chat repo
https://github.com/voiceflow/react-chat/tree/master/examples/live-agent
trying
d15bb6d1c44ccaa3d4d743bbae02d2675a03146aextended-salmonOP•2y ago

extended-salmonOP•2y ago
How can I fix this @MikeG ?
for the react-chat/examples/live-chat
deep-jade•2y ago
did you put your API key, project ID and project versoin like it says in the .env?
extended-salmonOP•2y ago
it doesnt ask for an API key
only a project ID
there is nowhere to put an API key
deep-jade•2y ago
huh
extended-salmonOP•2y ago

extended-salmonOP•2y ago
react-chat repo, examples/live-agent folder
only asks for VF_PROJECT_ID
deep-jade•2y ago
i see, have you published your agent?
extended-salmonOP•2y ago
no, im not sure what that means or how to do it
i imported the .vf file
deep-jade•2y ago
top right

deep-jade•2y ago
click publish
and then get the project ID after that
extended-salmonOP•2y ago
ok one sec
deep-jade•2y ago
it opens it up to public connections
i need to do something else rn so if you're sitll sturgging, i'll try to get back later
extended-salmonOP•2y ago
thanks man
OK now im getting 200's
ok it works
how can i get streaming working now? so that answers are sent word-by-word/character-by-character?
Thats not natively supported, you'd need to program that yourself
extended-salmonOP•2y ago
ok great
deep-jade•2y ago
@Deleted User work off this https://github.com/voiceflow/streaming-wizard
extended-salmonOP•2y ago
yup thats what im doing! using the components from react-chat
Just a random question: why are you trying to use the react-chat?
extended-salmonOP•2y ago
what do you mean @W. Williams (SFT) ?
it contains components to create a custom chatbot UI which is what im using it for
and then using streaming-wizard as an example of how to do streaming
let me know if im on the right path
vicious-gold•2y ago
Had the same issues. What worked for me is to first do
yarn install and right after that do yarn build. Also publishing the agent and setting the versionID to "production" in the config.ts is what made it finally work.
My goal is to host the webchat client, live handoff server + websocket on a separate server that connects to my admin dashboard where my clients their live agent employees can send/receive messages in case when there's an handoff.
How do I embed my customised webchat widget on my clients their websites? The only example on GitHub shows a more local approach where it assumes you have the website built in React to import the react-chat package? https://github.com/voiceflow/react-chat?tab=readme-ov-file#browser-usage
My goal is to point it to a remote server with my customised webchat widget but have it in a similar fashion like the JS snippet so I can use verify: {{ projectID: 'XXX' }} for all my different clients.extended-salmonOP•2y ago
pls start your own thread thanks
FYI: You can do all this using extensions now and not have to run your own server.
extended-salmonOP•2y ago
what do you mean? can you clarify
voiceflow extensions
they allow you to run custom code within VF
extended-salmonOP•2y ago
great
im just trying to get the live agent chat demo working, but with streaming
a little difficult because theres no turn indicators
ah i see the extensions page. very cool. will be using this eventually
GitHub
GitHub - voiceflow-gallagan/vf-extensions-demo at c7a5eda8116dc915f...
Contribute to voiceflow-gallagan/vf-extensions-demo development by creating an account on GitHub.
repo above
plus video too 🙂