docs(types): 添加prompt类型的注释

This commit is contained in:
icarus 2025-09-04 13:02:58 +08:00
parent b8cefb8e85
commit 10301a1f79

View File

@ -1317,7 +1317,8 @@ type MessagesParams = BaseParams & {
type PromptParams = BaseParams & {
messages?: never
// prompt: StreamTextParams['prompt']
// prompt: Just use string for convinience. Native prompt type unite more types, including messages type.
// we craete a non-intersecting prompt type to discriminate them.
// see https://github.com/vercel/ai/issues/8363
prompt: string
}