-
Notifications
You must be signed in to change notification settings - Fork 645
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
add an openai compatible api #60
Conversation
Great job! I'm excited to set up the environment, but I encountered an issue with Python 3.8. Could you please confirm if PR is compatible with Python 3.8, as it's the recommended version to run with EmotiVoice? |
OK,I will test it on Python 3.8. |
Hi, I used FastAPI to implement the openai compatible API for emoti-voice. And Python 3.10+ has the best and simplest syntax for type hints. I will change to Python 3.8+ type hints to run with EmotiVoice. |
Thank you for the information. Yeah, I agree 3.10+ might be better. |
I have tried Python 3.10 and it works fine. I have two suggestions:
|
Great! it's amazing to see that you have already finished the changes so quickly. I'm sorry that I didn't have time today to modify and support Python 3.8. log-config.yml is unnecessary and can be deleted. I agree that you keep 'frontend_cn.py' unchanged. |
Thank you for confirming that. Could you please make the necessary updates as we discussed, so that I can easily merge the PR?
|
ok. |
Hi, the PR has been updated. |
Thank you and all the best! |
Hi, this is good, but if there is no-stream support, we can not say supported openai API now. At least 2 things not done:
|
Can give a demo? |
curl -X POST -H "Content-Type: application/json" -d '{"voice":"8051","input":"这里有一个改进的版本,使用了一个简单的轮询机制来等待文件生成。"}' http://192.168.21.133:8000/v1/audio/speech > o.mp3 还有其他参数,我最想知道的是prompt的用处。 |
def openai_audio(text: str, outPath: str): |
this is a test API cpde and it works,you can copy and paste it: def openai_audio(text: str, outPath: str):
主程序调用部分if name == "main": |
No description provided.