openai assistant swarm

Report Abuse

Basic Information

This repository provides a Node.js library that extends the OpenAI Node SDK to orchestrate and delegate work across multiple OpenAI assistants. It exposes a swarm API under beta.assistants.swarm and installs via an EnableSwarmAbilities call that registers a manager assistant tied to your OpenAI account. The manager assistant can accept a single prompt and decide which registered assistants should handle subtasks, spawn parallel subruns, and return structured parent and child run objects. The library also simplifies pagination and retrieval of many assistant definitions, enables configuration of the manager assistant options such as name, model and instructions, and targets server-side JavaScript workflows where developers need to turn individual assistants into a coordinated multi-assistant system.

Links

App Details

Features
The project adds a swarm extension to the OpenAI Node SDK with functions and tools useful for multi-assistant orchestration. Main features include EnableSwarmAbilities to extend the client, initialization via swarm.init, delegation via delegateWithPrompt, and selective delegation to a subset of assistant IDs. It provides helper methods allAssistants and getAssistants to handle pagination and batch fetching of assistants. An event emitter surfaces lifecycle events including parent_assistant_complete, child_assistants_complete, and poll_event. Responses surface parentRun and subRuns including run objects and playground links for debugging. Configuration options include debug and managerAssistantOptions for name, model and instructions. The library is designed to run sub-assistants in parallel and to surface required_action tool_calls for handling externally.
Use Cases
The swarm manager reduces developer overhead when building autonomous agent systems by centralizing delegation logic and automating which assistant handles which part of a request. Developers can send one prompt and let the manager split work across specialized assistants, receive an early parent response while child runs continue, and handle child tool_calls via provided events. Batch fetching and pagination helpers make discovery and management of large assistant registries easier. The emitter lets applications react to parent or child completion events asynchronously and debug with playground links. Overall it simplifies orchestration, parallel execution, and result aggregation for teams building multi-assistant workflows on top of the OpenAI platform.

Please fill the required fields*