Quickstart
Get started in 5 minutes
Fireworks.ai is a lightning-fast inference platform that serves generative AI models. All the models are exposed over completions
and a chat completions
API.
Using the API, you can build on popular open-source models and custom fine-tuned models like FireFunction, Hermes 2 Pro, etc.
Quickstart helps you to get started in minutes. However, if you want to explore more, please refer to the guides section or the API reference.
In this guide, you will:
- Set up your development environment
- Choose an SDK
- Call the Fireworks API with an API Key
Account Creation
Create a Fireworks AI account. Under Account Settings, click on API Keys to generate one. Please keep the API Key in a secure location.
Set up developer environment
Install SDK
Before installing, ensure that you have the right version of Python installed. Optionally you might want to setup a virtual environment too.
pip install --upgrade fireworks-ai
Configure API Key
Step-by-step instructions for setting an environment variable for respective OS platforms:
Sending the first API Request
You can quickly instantiate with the generated API Key and call the Fireworks API.
from fireworks.client import Fireworks
client = Fireworks(api_key="<FIREWORKS_API_KEY>")
response = client.chat.completions.create(
model="accounts/fireworks/models/llama-v3p1-8b-instruct",
messages=[{
"role": "user",
"content": "Say this is a test",
}],
)
print(response.choices[0].message.content)
Dive in further
Build with LangChain
Integrating Fireworks AI using LangChain
Generate a image
Learn Stable Diffusion 3 API
Fine-tune a OSS model
Create a unique model
Bring your own model
Deploy on our blazing-fast inference stack
Have fun!
If you have any questions, please reach out to us on Discord or Twitter.
Was this page helpful?