From 9217ac5ee929d5c6dbde07075ec52ddc023a6cea Mon Sep 17 00:00:00 2001 From: Ftps <63702646+Tps-F@users.noreply.github.com> Date: Sun, 21 Jan 2024 14:48:31 +0900 Subject: [PATCH] Add api docs --- README.md | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index d5af2af..fec8d17 100644 --- a/README.md +++ b/README.md @@ -80,4 +80,25 @@ rvc infer -m {model.pth} -i {input.wav} -o {output.wav} | filter_radius | -fr | int | 3 | If >=3: apply median filtering to the harvested pitch results. The value represents the filter radius and can reduce breathiness | | resample_sr | -rsr | int | 0 | Resample the output audio in post-processing to the final sample rate. Set to 0 for no resampling | | rms_mix_rate | -rmr | float | 0.25 | Adjust the volume envelope scaling. Closer to 0, the more it mimicks the volume of the original vocals. Can help mask noise and make volume sound more natural when set relatively low. Closer to 1 will be more of a consistently loud volume | -| protect | -p | float | 0.33 | Protect voiceless consonants and breath sounds to prevent artifacts such as tearing in electronic music. Set to 0.5 to disable. Decrease the value to increase protection, but it may reduce indexing accuracy | \ No newline at end of file +| protect | -p | float | 0.33 | Protect voiceless consonants and breath sounds to prevent artifacts such as tearing in electronic music. Set to 0.5 to disable. Decrease the value to increase protection, but it may reduce indexing accuracy | + +### API Usage +First, start up the server. +```sh +rvc-api +``` +or +```sh +poetry run poe rvc-api +``` + +#### Inference Audio +```sh +curl -X 'POST' \ + 'http://127.0.0.1:8000/inference' \ + -H 'accept: application/json' \ + -H 'Content-Type: multipart/form-data' \ + -F 'modelpath={model.pth}' \ + -F 'input={input audio path}' \ + -o {output audio path} +```