Does Azure Assistant API code_ interpreter takes other form of data input apart from file_ids?

Karishma Nanda 155 Reputation points
2024-04-30T09:01:52.08+00:00

I am using Azure Assistants API as code_interpreter and wanted to know about what are other options/parameters I could use to pass data to Azure Assiatants API, does it always need to be file_ids? The data I want to pass to Assitants is stored in SQL Server, what are the steps I should take to ingest data from SQL Server to Azure Assistants API, apart from creating file_ids?
I am following this doc doc

Azure OpenAI Service
Azure OpenAI Service
An Azure service that provides access to OpenAI’s GPT-3 models with enterprise capabilities.
2,271 questions
{count} votes

Accepted answer
  1. dupammi 7,225 Reputation points Microsoft Vendor
    2024-04-30T10:45:30.9533333+00:00

    Hi @Karishma Nanda

    Thank you for using the Microsoft Q&A platform.

    The file_ids parameter is required to give tools like code_interpreter access to files. When using the File upload endpoint, you must have the purpose set to assistants to be used with the Assistants API.

    Files can be uploaded via Studio or programmatically using the File upload endpoint. When using the File upload endpoint, you must have the purpose parameter set to assistants to be used with the Assistants API.

    If you have data stored in SQL Server, you can ingest it into Azure Assistants API. To ingest data from SQL Server into Azure Assistants API, begin by retrieving the desired data through SQL queries. Optionally, transform the data to fit the API's requirements and its supported file types. Then, pass the prepared data to the API using suitable parameters, including direct Rest API requests. Finally, invoke the Azure Assistants API with the prepared data to execute desired tasks like generating visualizations or responding to queries.

    I hope the provided details help you in your particular use case. Thank you.

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful