Skip to main content
The official Python SDK for the Fireworks AI API is available on GitHub and PyPI.

Fireworks vs. OpenAI SDK

Fireworks is OpenAI-compatible, so you can use the OpenAI SDK with Fireworks. The Fireworks SDK offers additional benefits:
  • Better concurrency defaults — Optimized connection pooling for high-throughput workloads
  • Fireworks-exclusive features — Access parameters and response fields not available in the OpenAI API
  • Platform automation — Manage datasets, evals, fine-tuning, and deployments programmatically

Installation

Requires Python 3.9+ and an API key. See Getting your API key for instructions.
The SDK is currently in alpha. Use the --pre flag when installing to get the latest version.
pip install --pre fireworks-ai
For detailed usage instructions, see the README.md. To quickly get started with serverless, see our Serverless Quickstart.