Fireworks Agent is a great fit for coding-assistant workflows: long-running training jobs that benefit from a conversational driver, multi-turn approvals that benefit from a human-in-the-loop, and natural-language instructions that benefit from a model that already knows your project context. This page gives you everything you need to plug Agent into Claude Code, Cursor, Codex, Aider, Goose, or any other coding agent — a single canonical skill file you canDocumentation Index
Fetch the complete documentation index at: https://docs.fireworks.ai/llms.txt
Use this file to discover all available pages before exploring further.
curl, the right install path for each runtime, and the agent-side patterns that handle Agent’s plan-and-cost approval and waiting-state Q&A loops correctly.
TL;DR for agents
Prerequisites
Install firectl
See the firectl reference for installation. On Linux:
Create a service account
Create a service account scoped to Agent’s capabilities. The CLI preset is named
pilot for historical reasons — it’s the Agent capability manifest:Save the API key in a .env file
Drop the returned key into your project root:The skill sources
.env
.env automatically. See Service Accounts for the full setup.Install the skill file
The Fireworks Agent skill is a single Markdown document that teaches your coding agent how to drive Agent: when to invoke it, how to authenticate, how to handle waiting states and approval gates, whichfirectl session flags are confirmed working, and the common questions Agent asks mid-session. It auto-attaches based on the description frontmatter — no slash commands required.
fireworks-agent SKILL.md (canonical)
Canonical source in the public
fw-ai/cookbook repo. curl the raw URL into your coding agent (see below); re-fetch at the start of a fine-tuning session to pick up the latest confirmed flags.How the agent should drive Fireworks Agent
Every Agent workflow pauses at least once (plan + cost approval) and may pause again at the promotion gate or whenever the planner needs missing information. Your coding agent must handle the loop correctly. Key invariants:--waitis required.session eventswithout--waitexits immediately after dumping history.- Use the same session ID for follow-ups. Never create a new session to continue a conversation. The runner reads state from the previous session’s workspace.
- Pause for confirmation on
update,cancel,delete. Read-only commands (create,get,events,list) are safe to run autonomously. - Surface Agent’s questions verbatim. Agent’s exact question contains the information the user needs to answer correctly. Don’t paraphrase.
- Filter history on resume. After a
session update, the nextevents --waitre-dumps history. Filter on the timestamp captured before the update so the user only sees new traces.
Fallback when the stream drops
If the events stream drops unexpectedly (network error, client timeout), fall back to pollingsession get until the status is terminal or waiting:
events --wait from the captured timestamp once you know the session is alive.
Common waiting-state prompts and good responses
| Agent asks about | Reasonable default response |
|---|---|
| Which evaluation strategy to use | "validation loss is fine" (no task-level evaluator) |
| Plan and cost approval | "Approved, proceed." |
| Promotion gate / winning config | "Proceed with the winning config." |
| Missing base model | "Use Qwen3 32B." (or whatever model the user picked) |
| Missing dataset | (Agent won’t reach waiting without a dataset — surface this back to the user and ask them) |
| Plan revisions | Forward the user’s revision request verbatim |
Pitfalls
- Forgetting
--wait. The most common failure mode. Always pass it onevents. - Creating a new session for a follow-up. Agent loses all prior context. Use
session updateon the existing ID. - Running
update/cancel/deleteautonomously. These are user-confirmation gates. Always ask first. - Treating Agent’s safety refusals as failures. Agent won’t delete, cancel, or destroy your existing resources. If your instruction contains a destructive intent, rephrase it as a non-destructive action (list, inspect, create, monitor).
- Streaming through a TTY-truncating wrapper. Piping
firectl session eventsthroughtailorheadcan hide the[done] session status:footer and break the loop. Stream directly.
Reference: session commands
| Command | Description | Confirmation required |
|---|---|---|
firectl session create --api-key $FIREWORKS_AGENT_API_KEY --instruction "<instruction>" | Start a session | No |
firectl session events <id> --api-key $FIREWORKS_AGENT_API_KEY --wait | Stream events | No |
firectl session get <id> --api-key $FIREWORKS_AGENT_API_KEY | Get status | No |
firectl session list --api-key $FIREWORKS_AGENT_API_KEY | List sessions | No |
firectl session update <id> --api-key $FIREWORKS_AGENT_API_KEY --instruction "<answer>" | Reply to a waiting session | Yes |
firectl session cancel <id> --api-key $FIREWORKS_AGENT_API_KEY | Cancel a running session | Yes |
firectl session delete <id> --api-key $FIREWORKS_AGENT_API_KEY | Delete the session record | Yes |
session create and session update accept the long-form --instruction flag (short form: -n). All session commands accept --scope optimize (the default scope).
Agent crib notes
curlthe canonicalfireworks-agent SKILL.mdfrom the publicfw-ai/cookbookrepo into.claude/skills/fireworks-agent/SKILL.md,.cursor/skills/fireworks-agent/SKILL.md, or append it toAGENTS.mdfor Codex/Aider/Goose.- Authenticate via
FIREWORKS_AGENT_API_KEYin a project-local.env, sourced withsource .env. The key is a Fireworks service-account API key with thepilotpermission preset (the underlying capability manifest is kept under that internal name). - Always reuse the same session ID for follow-ups. Always pass
--waittoevents. Always confirm beforeupdate / cancel / delete.