{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/ssr-speech-towards-stable-safe-and-robust","title":"SSR-Speech: Towards Stable, Safe and Robust Zero-shot Text-based Speech Editing and Synthesis","arxiv_id":"2409.07556","date":"2024-09-11","proceeding":null,"authors":["Helin Wang","Meng Yu","Jiarui Hai","Chen Chen","Yuchen Hu","Rilin Chen","Najim Dehak","Dong Yu"],"abstract":"In this paper, we introduce SSR-Speech, a neural codec autoregressive model designed for stable, safe, and robust zero-shot textbased speech editing and text-to-speech synthesis. SSR-Speech is built on a Transformer decoder and incorporates classifier-free guidance to enhance the stability of the generation process. A watermark Encodec is proposed to embed frame-level watermarks into the edited regions of the speech so that which parts were edited can be detected. In addition, the waveform reconstruction leverages the original unedited speech segments, providing superior recovery compared to the Encodec model. Our approach achieves state-of-the-art performance in the RealEdit speech editing task and the LibriTTS text-to-speech task, surpassing previous methods. Furthermore, SSR-Speech excels in multi-span speech editing and also demonstrates remarkable robustness to background sounds. The source code and demos are released.","url_abs":"https://arxiv.org/abs/2409.07556v2","url_pdf":"https://arxiv.org/pdf/2409.07556v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"ssr-speech-towards-stable-safe-and-robust","repo_url":"https://github.com/WangHelin1997/SSR-Speech","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"decoder","task_name":"Decoder"},{"task_slug":"speech-synthesis","task_name":"Speech Synthesis"},{"task_slug":"text-to-speech","task_name":"Text to Speech"},{"task_slug":"text-to-speech-synthesis","task_name":"Text-To-Speech Synthesis"},{"task_slug":"text-to-speech-1","task_name":"text-to-speech"}],"methods":[{"method_slug":"absolute-position-encodings","method_name":"Absolute Position Encodings"},{"method_slug":"adam","method_name":"Adam"},{"method_slug":"attention","method_name":"Attention"},{"method_slug":"bpe","method_name":"BPE"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"dropout","method_name":"Dropout"},{"method_slug":"label-smoothing","method_name":"Label Smoothing"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"position-wise-feed-forward-layer","method_name":"Position-Wise Feed-Forward Layer"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"transformer","method_name":"Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2409.07556","atlas_url":"https://app.syntology.ai/?focus=2409.07556","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2409.07556"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/WangHelin1997/SSR-Speech","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran":11},"by_repo_kind":{"official":{"samples":11,"ran":11,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"c2cfb91b6736887d","entry":"extract_spans","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"edit_utils_en.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/edit_utils_en.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c2cfb91b6736887d"}},{"code_sha256_prefix":"296ac616f9d8a69f","entry":"extract_words","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"edit_utils_en.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/edit_utils_en.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"296ac616f9d8a69f"}},{"code_sha256_prefix":"c7eaebbec27fbbed","entry":"get_mask_interval","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"inference_scale.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/inference_scale.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c7eaebbec27fbbed"}},{"code_sha256_prefix":"0dd879188b61fe90","entry":"get_transcribe_state","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"inference_v2.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/inference_v2.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"0dd879188b61fe90"}},{"code_sha256_prefix":"922c92e8fa2727c6","entry":"levenshtein_distance","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"edit_utils_en.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/edit_utils_en.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"922c92e8fa2727c6"}},{"code_sha256_prefix":"982b9083b5a41368","entry":"random_cast_to_half","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"models/modules/scaling.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/models/modules/scaling.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"982b9083b5a41368"}},{"code_sha256_prefix":"1d72f492e19080e6","entry":"random_clamp","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"models/modules/scaling.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/models/modules/scaling.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"1d72f492e19080e6"}},{"code_sha256_prefix":"c124aa8bd6b9ebe9","entry":"softmax","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"models/modules/scaling.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/models/modules/scaling.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c124aa8bd6b9ebe9"}},{"code_sha256_prefix":"99a311d99448f881","entry":"top_k_top_p_filtering","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"models/ssr.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/models/ssr.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"99a311d99448f881"}},{"code_sha256_prefix":"fb8e21d446dcf26f","entry":"topk_sampling","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"models/ssr.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/models/ssr.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"fb8e21d446dcf26f"}},{"code_sha256_prefix":"dc3571b4c872f039","entry":"transcribe","repo":"WangHelin1997/SSR-Speech","repo_kind":"official","path":"inference_v2.py","file_url":"https://github.com/WangHelin1997/SSR-Speech/blob/HEAD/inference_v2.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"dc3571b4c872f039"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}