You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Prompt-Engineering-Guide/pages/introduction/settings.zh.mdx

12 lines
1.2 KiB
Markdown

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# 模型设置
使用提示词时,您会通过 API 或直接与大语言模型进行交互。你可以通过配置一些参数以获得不同的提示结果。
**Temperature**:简单来说,`temperature` 的参数值越小,模型就会返回最确定的一个结果。如果调高该参数值,大语言模型可能会返回更随机的结果,也就是说这可能会带来更多样化或更具创造性的产出。我们目前也在增加其他可能 token 的权重。在实际应用方面对于质量保障QA等任务我们可以设置更低的 `temperature` 值,以促使模型基于事实返回更真实和简洁的结果。 对于诗歌生成或其他创造性任务,你可以适当调高 `temperature` 参数值。
同样,使用 `top_p`(与 `temperature` 一起称为核采样的技术),可以用来控制模型返回结果的真实性。如果你需要准确和事实的答案,就把参数值调低。如果你想要更多样化的答案,就把参数值调高一些。
一般建议是改变其中一个参数就行,不用两个都调整。
在我们开始一些基础示例之前,请记住最终生成的结果可能会和使用的大语言模型的版本而异。