How to implement a predefined prompt button creating a new threadId, with useAssistant hook? #4489
Unanswered
ozanyusufoglu
asked this question in
Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm confused how to use useAssistant() for a predefined prompt button.
I first tried only using append() but it requires and already existing threadID.
What I want is to start a thread with a button click and send the query with the click.
I tried using a form instead to imitate an input like the code below, but I always get the error at the bottom, on my terminal. What am I missing here? Isn't it enough to setInput to create a proper Message object on submitMessage?
The error on the terminal:
Beta Was this translation helpful? Give feedback.
All reactions