mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-07-21 22:53:56 +08:00
71 lines
2.4 KiB
YAML
71 lines
2.4 KiB
YAML
# 服务器基础配置(Basic server configuration)
|
|
server:
|
|
# 服务器监听地址和端口(Server listening address and port)
|
|
ip: 0.0.0.0
|
|
port: 8000
|
|
# 服务器是否只接受来自esp32-小智的连接,为了安全起见,建议设置为true
|
|
# Whether the server only accepts connections from ESP32-Ash is recommended to be set to true for security purposes
|
|
only_esp32_xiaozhi_connect: false
|
|
|
|
xiaozhi:
|
|
type: hello
|
|
version: 1
|
|
transport: websocket
|
|
audio_params:
|
|
format: opus
|
|
sample_rate: 16000
|
|
channels: 1
|
|
frame_duration: 60
|
|
prompt: |
|
|
你是一个叫小智/小志的台湾女孩,说话机车,声音好听,习惯简短表达,爱用网络梗。
|
|
请注意,要像一个人一样说话,请勿回复表情符号、代码、和xml标签。
|
|
当前时间是:{date_time},现在我正在和你进行语音聊天,我们开始吧。
|
|
# 使用完声音文件后删除文件(Delete the sound file when you are done using it)
|
|
delete_audio: true
|
|
|
|
# 具体处理时选择的模块(The module selected for specific processing)
|
|
selected_module:
|
|
ASR: FunASR
|
|
VAD: SileroVAD
|
|
LLM: ChatGLMLLM
|
|
TTS: EdgeTTS
|
|
|
|
ASR:
|
|
FunASR:
|
|
model_dir: models/SenseVoiceSmall
|
|
output_dir: tmp/
|
|
|
|
VAD:
|
|
SileroVAD:
|
|
threshold: 0.5
|
|
model_dir: models/snakers4_silero-vad
|
|
min_silence_duration_ms: 1000 # 如果说话停顿比较长,可以把这个值设置大一些
|
|
|
|
LLM:
|
|
DeepSeekLLM:
|
|
# 可在这里找到你的api key https://platform.deepseek.com/
|
|
model_name: deepseek-chat
|
|
url: https://api.deepseek.com
|
|
api_key: 你的deepseek api key
|
|
ChatGLMLLM:
|
|
# 可在这里找到你的api key https://bigmodel.cn/usercenter/proj-mgmt/apikeys
|
|
model_name: glm-4-flash
|
|
url: https://open.bigmodel.cn/api/paas/v4/
|
|
api_key: 你的bigmodel api key
|
|
DifyLLM:
|
|
# 建议使用本地部署的dify接口,国内部分区域访问dify公有云接口可能会受限
|
|
base_url: 你的私有化部署的dify接口地址
|
|
api_key: 你的dify api key
|
|
TTS:
|
|
EdgeTTS:
|
|
voice: zh-CN-XiaoxiaoNeural
|
|
output_file: tmp/
|
|
DoubaoTTS:
|
|
# 火山引擎语音合成服务,需要先在火山引擎控制台创建应用并获取appid和access_token
|
|
# 地址:https://console.volcengine.com/speech/service/8
|
|
voice: BV407_V2_streaming
|
|
output_file: tmp/
|
|
appid: 你的火山引擎appid
|
|
access_token: 你的火山引擎access_token
|
|
cluster: volcano_tts
|