diff --git a/wasmedge-chatTTS/.gitignore b/wasmedge-chatTTS/.gitignore index de665f5..8207d82 100644 --- a/wasmedge-chatTTS/.gitignore +++ b/wasmedge-chatTTS/.gitignore @@ -1,3 +1,2 @@ asset -config -*.wav \ No newline at end of file +config \ No newline at end of file diff --git a/wasmedge-chatTTS/README.md b/wasmedge-chatTTS/README.md index 133d5ed..a457314 100644 --- a/wasmedge-chatTTS/README.md +++ b/wasmedge-chatTTS/README.md @@ -57,4 +57,12 @@ let config_data = serde_json::to_string(&json!({"prompt": "[oral_2][laugh_0][bre .unwrap() .as_bytes() .to_vec(); -``` \ No newline at end of file +``` +### Demo speaker + + +
+ +[demo](https://github.com/user-attachments/assets/53b6b5f0-8568-4309-9a91-735459156b07) + +
\ No newline at end of file diff --git a/wasmedge-chatTTS/assets/demo.mp4 b/wasmedge-chatTTS/assets/demo.mp4 new file mode 100644 index 0000000..9355dfd Binary files /dev/null and b/wasmedge-chatTTS/assets/demo.mp4 differ diff --git a/wasmedge-chatTTS/assets/demo.wav b/wasmedge-chatTTS/assets/demo.wav new file mode 100644 index 0000000..f9b38d1 Binary files /dev/null and b/wasmedge-chatTTS/assets/demo.wav differ diff --git a/wasmedge-chatTTS/src/main.rs b/wasmedge-chatTTS/src/main.rs index 60ed8ec..8e01d35 100644 --- a/wasmedge-chatTTS/src/main.rs +++ b/wasmedge-chatTTS/src/main.rs @@ -15,7 +15,7 @@ fn get_data_from_context(context: &GraphExecutionContext, index: usize, limit: u } fn main() { - let prompt = "It is [uv_break] test sentence [laugh] for chat T T S"; + let prompt = "It is test sentence [uv_break] for chat T T S."; let tensor_data = prompt.as_bytes().to_vec(); let config_data = serde_json::to_string(&json!({"prompt": "[oral_2][laugh_0][break_6]", "spk_emb": "random", "temperature": 0.5, "top_k": 0, "top_p": 0.9})) .unwrap() @@ -37,7 +37,6 @@ fn main() { context.compute().expect("Failed to compute"); let bytes_written = get_data_from_context(&context, 1, 4); let bytes_written = usize::from_le_bytes(bytes_written.as_slice().try_into().unwrap()); - println!("Byte: {}", bytes_written); let output_bytes = get_data_from_context(&context, 0, bytes_written); let spec = hound::WavSpec { channels: 1,