共用方式為


ToolSet class

表示一組具有其定義和資源的工具。

屬性

toolDefinitions

已新增至工具集的工具定義清單。

toolResources

與工具集中工具相關聯的資源集合。

方法

addAzureAISearchTool(string, string)

將 Azure AI 搜尋工具新增至工具集。

addBingGroundingTool(BingGroundingSearchConfiguration[])

將 Bing 接地搜尋工具添加到工具集中。

addCodeInterpreterTool(string[], VectorStoreDataSource[])

將程式代碼解釋器工具新增至工具集。

addConnectedAgentTool(string, string, string)

將連接的代理工具添加到工具集。

addConnectionTool(connectionToolType, string[])

將連接工具新增至工具集。

addFileSearchTool(string[], VectorStoreConfigurations[], FileSearchToolDefinitionDetails)

將檔案搜尋工具新增至工具集。

addOpenApiTool(OpenApiFunctionDefinition)

將 OpenApi 工具新增至工具集。

屬性詳細資料

toolDefinitions

已新增至工具集的工具定義清單。

toolDefinitions: ToolDefinition[]

屬性值

toolResources

與工具集中工具相關聯的資源集合。

toolResources: ToolResources

屬性值

方法詳細資料

addAzureAISearchTool(string, string)

將 Azure AI 搜尋工具新增至工具集。

function addAzureAISearchTool(indexConnectionId: string, indexName: string): { definition: AzureAISearchToolDefinition, resources: ToolResources }

參數

indexConnectionId

string

Azure AI 搜尋索引的連接標識碼。

indexName

string

Azure AI 搜尋索引的名稱。

傳回

{ definition: AzureAISearchToolDefinition, resources: ToolResources }

物件,其中包含 Azure AI 搜尋工具的定義和資源

addBingGroundingTool(BingGroundingSearchConfiguration[])

將 Bing 接地搜尋工具添加到工具集中。

function addBingGroundingTool(searchConfigurations: BingGroundingSearchConfiguration[]): { definition: BingGroundingToolDefinition }

參數

searchConfigurations

BingGroundingSearchConfiguration[]

傳回

{ definition: BingGroundingToolDefinition }

包含 bing 接地搜尋工具的定義和資源的物件

addCodeInterpreterTool(string[], VectorStoreDataSource[])

將程式代碼解釋器工具新增至工具集。

function addCodeInterpreterTool(fileIds?: string[], dataSources?: VectorStoreDataSource[]): { definition: CodeInterpreterToolDefinition, resources: ToolResources }

參數

fileIds

string[]

可供 code_interpreter 工具使用的檔案識別碼清單。 最多可以有 20 個檔案與工具相關聯。

dataSources

VectorStoreDataSource[]

要使用的數據源。 此選項與 fileIds 互斥。

傳回

{ definition: CodeInterpreterToolDefinition, resources: ToolResources }

物件,其中包含程式代碼解釋器工具的定義和資源

addConnectedAgentTool(string, string, string)

將連接的代理工具添加到工具集。

function addConnectedAgentTool(id: string, name: string, description: string): { definition: ConnectedAgentToolDefinition }

參數

id

string

連接的代理的ID。

name

string

連接的代理的名稱。

description

string

連接的代理的描述。

傳回

{ definition: ConnectedAgentToolDefinition }

包含 connected agent 工具定義的物件

addConnectionTool(connectionToolType, string[])

將連接工具新增至工具集。

function addConnectionTool(toolType: connectionToolType, connectionIds: string[]): { definition: ToolDefinition }

參數

toolType
connectionToolType

連接工具的類型。

connectionIds

string[]

要使用的連線標識碼清單。

傳回

{ definition: ToolDefinition }

物件,包含連接工具的定義

addFileSearchTool(string[], VectorStoreConfigurations[], FileSearchToolDefinitionDetails)

將檔案搜尋工具新增至工具集。

function addFileSearchTool(vectorStoreIds?: string[], vectorStores?: VectorStoreConfigurations[], definitionDetails?: FileSearchToolDefinitionDetails): { definition: FileSearchToolDefinition, resources: ToolResources }

參數

vectorStoreIds

string[]

附加至此代理程式的向量存放區標識符。 最多可以有 1 個向量存放區附加至代理程式。

vectorStores

VectorStoreConfigurations[]

來自 Azure 的向量存放區組態物件清單。 此清單限制為一個專案。 此清單的唯一元素包含搜尋工具所使用的 Azure 資產識別碼清單。

definitionDetails
FileSearchToolDefinitionDetails

用來設定代理程式的檔案搜尋工具輸入定義資訊。

傳回

{ definition: FileSearchToolDefinition, resources: ToolResources }

物件,包含檔案搜尋工具的定義和資源

addOpenApiTool(OpenApiFunctionDefinition)

將 OpenApi 工具新增至工具集。

function addOpenApiTool(openApiFunctionDefinition: OpenApiFunctionDefinition): { definition: OpenApiToolDefinition }

參數

openApiFunctionDefinition
OpenApiFunctionDefinition

要使用的 OpenApi 函式定義。

傳回

{ definition: OpenApiToolDefinition }

物件,包含 OpenApi 工具的定義