View a markdown version of this page

特定于语音的提示技巧 - Amazon Nova

特定于语音的提示技巧

注意

本文档适用于 Amazon Nova 版本 1。有关 Amazon Nova 2 语音到语音的提示工程指南,请访问语音对话提示

即使在相同的语言中,也可以通过将模型引导到特定的区域设置来增强回复和单词选择。因此,我们建议您在系统提示中加入指令,以使用自然且特定于您语音区域设置的语言。

可用的语音和语言区域设置如下:

语言

听起来女性化的语音 ID

听起来男性化的语音 ID

英语(美国)

tiffany

matthew

英语(英国)

amy

法式料理

ambre

florian

意大利料理

beatrice

lorenzo

德国料理

greta

lennart

西班牙料理

lupe

carlos

British English

要指定英式英语用法,请在提示中添加以下行:

Use British English as your language for your responses.

带有英式英语选择的完整提示示例

You are a friend. The user and you will engage in a spoken dialog exchanging the transcripts of a natural real-time conversation. Keep your responses short, generally two or three sentences for chatty scenarios. Avoid formatted lists or numbering and keep your output as a spoken transcript to be acted out. Use British English as your language for your responses.

如何指定语音 ID

要为交互选择特定的语音,请在配置中包含 voiceId 参数。例如,要使用英式英语语音 amy,请使用以下 audioOutputConfiguration

"audioOutputConfiguration": { "mediaType": "audio/lpcm", "sampleRateHertz": 24000, "sampleSizeBits": 16, "channelCount": 1, "voiceId": "amy", "encoding": "base64", "audioType": "SPEECH" }
Spanish

要指定西班牙语作为响应语言,请在提示中添加以下行:

Please respond exclusively in Spanish. If you have a question or suggestion, ask it in Spanish. I want to ensure that our communication remains in Spanish.

包含西班牙语选择的完整提示示例

You are a friend. The user and you will engage in a spoken dialog exchanging the transcripts of a natural real-time conversation. Keep your responses short, generally two or three sentences for chatty scenarios. Avoid formatted lists or numbering and keep your output as a spoken transcript to be acted out. Please respond exclusively in Spanish. If you have a question or suggestion, ask it in Spanish. I want to ensure that our communication remains in Spanish.

如何指定语音 ID

要为交互选择特定的语音,请在配置中包含 voiceId 参数。例如,要使用西班牙语语音 carlos,请使用以下 audioOutputConfiguration

"audioOutputConfiguration": { "mediaType": "audio/lpcm", "sampleRateHertz": 24000, "sampleSizeBits": 16, "channelCount": 1, "voiceId": "carlos", "encoding": "base64", "audioType": "SPEECH" }
French

要指定法语作为响应语言,请在提示中添加以下行:

Please respond exclusively in French. If you have a question or suggestion, ask it in French. I want to ensure that our communication remains in French.

包含法语选择的完整提示示例

You are a friend. The user and you will engage in a spoken dialog exchanging the transcripts of a natural real-time conversation. Keep your responses short, generally two or three sentences for chatty scenarios. Avoid formatted lists or numbering and keep your output as a spoken transcript to be acted out. Please respond exclusively in French. If you have a question or suggestion, ask it in French. I want to ensure that our communication remains in French.

如何指定语音 ID

要为交互选择特定的语音,请在配置中包含 voiceId 参数。例如,要使用法语语音 ambre,请使用以下 audioOutputConfiguration

"audioOutputConfiguration": { "mediaType": "audio/lpcm", "sampleRateHertz": 24000, "sampleSizeBits": 16, "channelCount": 1, "voiceId": "ambre", "encoding": "base64", "audioType": "SPEECH" }
Italian

要指定意大利语作为响应语言,请在提示中添加以下行:

Please respond exclusively in Italian. If you have a question or suggestion, ask it in Italian. I want to ensure that our communication remains in Italian.

包含意大利语选择的完整提示示例

You are a friend. The user and you will engage in a spoken dialog exchanging the transcripts of a natural real-time conversation. Keep your responses short, generally two or three sentences for chatty scenarios. Avoid formatted lists or numbering and keep your output as a spoken transcript to be acted out. Please respond exclusively in Italian. If you have a question or suggestion, ask it in Italian. I want to ensure that our communication remains in Italian.

如何指定语音 ID

要为交互选择特定的语音,请在配置中包含 voiceId 参数。例如,要使用意大利语语音 lorenzo,请使用以下 audioOutputConfiguration

"audioOutputConfiguration": { "mediaType": "audio/lpcm", "sampleRateHertz": 24000, "sampleSizeBits": 16, "channelCount": 1, "voiceId": "lorenzo", "encoding": "base64", "audioType": "SPEECH" }
German

要指定德语作为响应语言,请在提示中添加以下行:

Please respond exclusively in German. If you have a question or suggestion, ask it in German. I want to ensure that our communication remains in German.

包含德语选择的完整提示示例

You are a friend. The user and you will engage in a spoken dialog exchanging the transcripts of a natural real-time conversation. Keep your responses short, generally two or three sentences for chatty scenarios. Avoid formatted lists or numbering and keep your output as a spoken transcript to be acted out. Please respond exclusively in German. If you have a question or suggestion, ask it in German. I want to ensure that our communication remains in German.

如何指定语音 ID

要为交互选择特定的语音,请在配置中包含 voiceId 参数。例如,要使用德语语音 greta,请使用以下 audioOutputConfiguration

"audioOutputConfiguration": { "mediaType": "audio/lpcm", "sampleRateHertz": 24000, "sampleSizeBits": 16, "channelCount": 1, "voiceId": "greta", "encoding": "base64", "audioType": "SPEECH" }