You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Windows批处理脚本无法读取文本中的!字符的问题求助

Windows批处理脚本无法读取文本中的!字符的问题求助

各位大佬好,我最近遇到了一个棘手的小问题:我写了一段批处理脚本,用来把processed_speech.txt里的内容逐行读取并合并成一段连续的文本,但运行后发现输出里所有的感叹号(!)都凭空消失了,试了好几种调整都没解决,有没有懂行的朋友帮忙看看?

先给大家贴一下我的批处理脚本:

set "PROCESSED_TEXT="

REM Read the contents of processed_speech.txt line by line

for /F "usebackq delims=" %%A in ("processed_speech.txt") do (

set "LINE=%%A"

if not "!PROCESSED_TEXT!"=="" set "PROCESSED_TEXT=!PROCESSED_TEXT! "

set "PROCESSED_TEXT=!PROCESSED_TEXT!%%A"

)

echo Processed text: !PROCESSED_TEXT!

这是我的processed_speech.txt文件内容:

Hello and welcome, one and all! Today, we are embarking on an exciting journey through the most intuitive and comprehensive deep voice cloning tutorial you will find anywhere. Our mission?

To show you how to train your voice and generate hours of speech in just a single click.

This tutorial is built on open source projects, meaning it is entirely free and runs directly on your own computer.

You may have heard of pricey services like Eleven Labs that offer voice training and speech synthesis.

But why break the bank when you can achieve stunning results without any prior technical knowledge? That is right, all you need to do is follow along with me.

Interestingly, the voice you are hearing now is a deep clone! Drop a comment to let me know what you think, and who it reminds you of.

We will switch to my natural voice after this introduction, so stay tuned!

Every step of this tutorial is meticulously detailed, both in this video and in the accompanying GitHub introduction file.

This file is your one stop shop, packed with all the information you will need. You will find the link in the description and the pinned comment, so don't forget to check it out.

Are you wondering why this tutorial stands out from the rest? It is because, with a simple drag and drop, your speech file can be transformed into your complete training data.

Thanks to our chosen user friendly graphical user interface, you can set up all training parameters and launch your training with just a single click.

Once the training is complete, my specially developed scripts will enable you to convert an entire text file into speech, again, just by dragging and dropping.

What is more, each step is clearly documented and demonstrated in this tutorial video, making it incredibly easy for you to follow along.

This tutorial offers a seamless and convenient process unlike any other. So, are you ready to jump into the world of voice cloning? Let's get started!

然后是脚本运行后的输出结果:

Hello and welcome, one and all Today, we are embarking on an exciting journey through the most intuitive and comprehensive deep voice cloning tutorial you will find anywhere. Our mission? To show you how to train your voice and generate hours of speech in just a single click. This tutorial is built on open source projects, meaning it is entirely free and runs directly on your own computer. You may have heard of pricey services like Eleven Labs that offer voice training and speech synthesis. But why break the bank when you can achieve stunning results without any prior technical knowledge? That is right, all you need to do is follow along with me. Interestingly, the voice you are hearing now is a deep clone Drop a comment to let me know what you think, and who it reminds you of. We will switch to my natural voice after this introduction, so stay tuned Every step of this tutorial is meticulously detailed, both in this video and in the accompanying GitHub introduction file. This file is your one stop shop, packed with all the information you will need. You will find the link in the description and the pinned comment, so don't forget to check it out. Are you wondering why this tutorial stands out from the rest? It is because, with a simple drag and drop, your speech file can be transformed into your complete training data. Thanks to our chosen user friendly graphical user interface, you can set up all training parameters and launch your training with just a single click. Once the training is complete, my specially developed scripts will enable you to convert an entire text file into speech, again, just by dragging and dropping. What is more, each step is clearly documented and demonstrated in this tutorial video, making it incredibly easy for you to follow along. This tutorial offers a seamless and convenient process unlike any other. So, are you ready to jump into the world of voice cloning? Let's get started

能明显看到,原文本里的所有!都消失了——比如开头的“Hello and welcome, one and all!”变成了“Hello and welcome, one and all”,结尾的“Let's get started!”变成了“Let's get started”。我实在找不到问题出在哪,有没有大佬能给点思路?

备注:内容来源于stack exchange,提问作者Furkan Gözükara

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.22 12:03:03