v52

OpenAPI 3.1.0raw.githubusercontent.com2026-07-311,1941,9384.1 MB
Assistants

Enhance Assistant Instructions

Enhance an assistant's instructions using an LLM. The endpoint reads the assistant's current instructions and tools, then streams back improved instructions as they are generated.

Optionally provide an enhancement_prompt to steer the changes (for example, "make the instructions more concise" or "add error handling guidance"). When omitted, the assistant's existing instructions are used as the basis for the enhancement.

The enhancement focuses on tool-calling reliability, clarity and precision, completeness and error handling, tool schema alignment, and conversation flow structure.

The response is streamed as text/plain using chunked transfer encoding; consume the body incrementally to render the enhanced instructions as they arrive.

post/ai/assistants/{assistant_id}/instructions/enhance

Path parameters

assistant_idstring required

Unique identifier of the assistant.

Request body

enhancement_promptstring nullable

Optional guidance describing how the instructions should be enhanced. When provided, the LLM applies these requested changes in addition to fixing any identified issues.

instructionsstring nullable

The instructions to enhance. When omitted, the assistant's existing instructions are used.

Response

A stream of enhanced instruction text. The body is sent as text/plain using chunked transfer encoding.