-
Notifications
You must be signed in to change notification settings - Fork 19
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
API endpoint #14
Comments
Same here, hope some kind of reference document can be published |
Same here. What can be understood from the README.md is that the body of the request should be encoded with JSONLand the paypload should be in PCM audio format. We can also see description of some requests, but no real examples. I suggested that https://github.com/rhasspy/wyoming-faster-whisper is run via tcp:// protocol and tried to send a I would really appreciate any help with sending an example request to any Wyoming server. It's a bit hard for me to understand how it works reading the code. |
I've ended up installing wireshark and capturing packages from HA to piper/whisper. It's indeed TCP (mine code had some errors, I didn't send FIN after write), but the packages looks a bit different from what I assumed from the README.md For example synthesize request described as
And from the Format desciption I would assume that I should set type to "synthesize" and put the So, I guess for any request you can try putting the request under |
Wyoming author here. The first line of the TCP message is JSON with the event type and the size of the "additional data" (JSON) plus the size of the binary payload (PCM audio). The "additional data" was needed because Python has a limit to how many characters can be on a single line, so large JSON messages would be cut off. |
Greetings @synesthesiam! Thank you for your work on the protocol and for taking the time to respond to our request. If you have some more time, I would like to ask one more question. Is there somewhere I can read about the API? I mean, I got the idea with line of JSON, line of additional JSON and PCM audio, the real question for me is the spec of the messages. Is there a place where I can see examples of each request? Otherwise I cannot predict if the data should come in the first line under Also, I'm very curious about the limitation you mentioned "Python has a limit on how many characters can be on a single line". Can you tell me more about this? I've never heard of this before. |
I'm looking to find documentation for using Wyoming Whisper/Piper on a curl request but I can't find what endpoint was used and what data to send to it.
I even look in the code but either I don't understand it or I'm really stupid.
The text was updated successfully, but these errors were encountered: