Today we publish the Assistant API, our first step in helping developers create agent-like experiences within their own applications. An assistant is a specially designed AI that contains specific instructions, leverages additional knowledge, and can call upon models and tools to complete tasks. The new Assistants API offers new features such as code interpretation and retrieval as well as function calling to handle much of the heavy lifting you previously had to do yourself and allow you to create enterprise applications. High quality AI.
This API is designed for flexibility; use cases range from a natural language-based data analytics app, coding assistant, AI-powered vacation planner, voice-activated DJ, an intelligent visual canvas, the list goes on. The Assistants API is based on the same features that enable our new GPT product: Custom instructions and tools such as code interpreter, recovery and function calling.
A key change introduced by this API is persistent and infinitely long threads, which allow developers to hand over thread state management to OpenAI and bypass popup constraints. With the Assistants API, you simply add each new message to an existing message. thread
.
Assistants also have access to new calling tools as needed, including:
- Code interpreter: Writes and executes Python code in a sandboxed execution environment, and can generate graphs and tables, and process files with various data and formatting. It lets your assistants run code iteratively to solve complex code and math problems, and much more.
- Recovery: Enriches the wizard with knowledge outside of our models, such as proprietary domain data, product information, or documents provided by your users. This means you don’t need to calculate and store embeddings for your documents, or implement segmentation and search algorithms. The Assistants API optimizes which retrieval technique to use based on our experience with knowledge retrieval in ChatGPT.
- Function call: Allows helpers to invoke functions you define and incorporate the function’s response into their messages.
As with the rest of the platform, the data and files transmitted to the OpenAI API are never used to train our models and developers can delete the data whenever they want.
You can try the Assistants API beta without writing code by visiting the page Play area for assistants.