Skip to content

ToolInputStartStreamPart

Namespace: Vercel.AI.Provider

public sealed class ToolInputStartStreamPart : LanguageModelStreamPart

Marks the start of streamed tool input.

Inheritance: object → LanguageModelStreamPart

View source

ToolInputStartStreamPart(string, string, JsonElement?, bool?, bool?, string?, ToolInputEncoding?)

Section titled “ToolInputStartStreamPart(string, string, JsonElement?, bool?, bool?, string?, ToolInputEncoding?)”
public ToolInputStartStreamPart(string id, string toolName, JsonElement? providerMetadata = null, bool? providerExecuted = null, bool? dynamic = null, string? title = null, ToolInputEncoding? inputEncoding = null)

Creates a tool-input-start part.

Parameters

Name Type Description
id string
toolName string
providerMetadata JsonElement?
providerExecuted bool?
dynamic bool?
title string
inputEncoding ToolInputEncoding?

View source

public bool? Dynamic { get; }

True for a tool the caller did not declare.

Value: bool?

View source

public string Id { get; }

Tool call id.

Value: string

View source

public ToolInputEncoding? InputEncoding { get; }

Encoding of the input deltas. Defaults to JSON when <a href=“https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null"&gt;null&lt;/a>. Text deltas concatenate to a raw string. The final tool call input must still be JSON-encoded, whatever the delta encoding.

Value: ToolInputEncoding?

View source

public bool? ProviderExecuted { get; }

True when the provider executes the tool.

Value: bool?

View source

public JsonElement? ProviderMetadata { get; }

Provider metadata for this tool input.

Value: JsonElement?

View source

public string? Title { get; }

Optional tool title.

Value: string

View source

public string ToolName { get; }

Tool name.

Value: string

View source

Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product