minmal example with a server client architecture
This commit is contained in:
@@ -5,6 +5,7 @@ import soundfile as sf
|
||||
from voice_models.request_models import SynthesizeRequest
|
||||
|
||||
|
||||
API_URL = "http://127.0.0.1:8099/synthesize/"
|
||||
|
||||
def request_synthesis(request_data: SynthesizeRequest):
|
||||
response = requests.post(API_URL, json=request_data.model_dump())
|
||||
@@ -27,7 +28,6 @@ def request_synthesis(request_data: SynthesizeRequest):
|
||||
print(f"Error: {response.status_code}, {response.text}")
|
||||
|
||||
if __name__ == "__main__":
|
||||
API_URL = "http://127.0.0.1:8099/synthesize/"
|
||||
|
||||
target_rate=16000
|
||||
|
||||
Reference in New Issue
Block a user