PROVIDER MODELS
xAI Grok models
xAI positions Grok 4.6 as its flagship model for coding, chat, configurable reasoning, and tool-using AI agents.
Model guides
Open current model pages and retained retirement notices
Grok 4.6
xAI's flagship model for coding, AI agent workflows, knowledge work, long-running tool use, and visual interaction.
500K context · $2 input / $6 outputxAI modelGrok 4.5
xAI's Grok 4.5 model for reasoning, coding, tool use, and text-and-image workflows.
500,000 context · Exact API ID grok-4.5Choosing and integrating
Choose the right model in the family
Start with the smallest model likely to meet the workload. Compare it with one higher-capability candidate on the same tasks, then choose by accepted-result quality, latency, reliability, and total cost.
- Choose Grok 4.6 for coding, knowledge work and tool-using agents that benefit from a large context window.
- Use low or medium reasoning for interactive work; evaluate high or xhigh only where the quality gain justifies latency and output cost.
- Prefer a smaller route for simple classification or extraction when your evaluation shows no benefit from the flagship model.
Inputs, outputs, context and tools
- Text and image input with text output through Responses and Chat Completions APIs.
- A 500K context window supports large codebases, long documents and extended agent history.
- Published tools include function calling, web search, X search and code execution.
- Reasoning effort supports low, medium, high and xhigh; high is the documented default.
Where this family fits
These are strong starting points—not universal recommendations. Test them with your own prompts, tools and acceptance criteria.
- Multi-file coding, debugging and repository analysis.
- Research agents combining web and X search with structured tools.
- Long-form knowledge work across large source collections.
- Multi-step workflows that need code execution and function calls.
Reasoning, context and cost controls
Do not compare only the headline input rate. Include output, cache reads and writes, long-context tiers, reasoning tokens, tool calls, retries, and the amount of history resent on every turn.
- Use prompt_cache_key or the Chat Completions conversation header to improve cache affinity on long agent loops.
- Compact or summarize context before the 500K limit instead of repeatedly sending an ever-growing transcript.
- Fresh internet or X information requires the corresponding search tool; the base model alone is not a realtime feed.
Send a minimal request
This example uses the first provider model ID in the table. If Model Plaza shows a different ID for your API key, copy the Model Plaza value exactly.
curl https://app.llmfly.ai/v1/chat/completions \
-H "Authorization: Bearer $LLMFLY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "grok-4.6",
"messages": [{"role": "user", "content": "Explain this request in three bullets."}],
"stream": false
}'Limits and compatibility notes
- Vendor pricing doubles for requests whose context reaches the published long-context threshold; confirm how the selected route bills it.
- Image input is limited to supported formats and size constraints; validate preprocessing before production.
- Newer Grok models do not support every legacy sampling option, including log probabilities.
Production evaluation checklist
- Run 20–50 representative tasks and define pass criteria before testing.
- Measure time to first token, total latency, input and output tokens, tool retries, and cost per successful task.
- Test the endpoint, streaming mode, tool schemas, and structured output used by the application.
- Verify 400, 401, 404, 429, and temporary 5xx handling with bounded retries.
- Keep the model ID in configuration and validate a fallback before moving production requests.
What to confirm in Model Plaza
Model Plaza shows which model IDs your API key can use, their billing multipliers, availability, supported endpoints, and compatibility notes. Confirm these details with a small request before deployment.
- Grok 4.6 uses a 500K context window.
- Reasoning effort can be configured for the workload.
- The LLMFly AI group must support the exact model name; unsupported names return 404.
Move from model research to a usable model ID
Open a model page above, note its provider model ID, and then use Model Plaza to confirm the ID available to your API key. Store that ID in configuration so it can be reviewed and changed without rewriting the application.
Frequently asked questions
Can I send these provider model IDs directly to LLMFly AI?
Not always. Use the model ID shown for your API key in Model Plaza.
Are these LLMFly AI prices?
No. They are provider reference prices. Check Model Plaza and the usage record for the amount charged by LLMFly AI.
Does the largest context window always produce a better answer?
No. Curated context usually improves relevance, latency, and cost. Treat the published window as a limit, not a target.
How should I choose a reasoning level?
Start with the documented default, then change it only when your evaluation shows a measurable quality or latency benefit.
What should a production fallback cover?
It should accept the same request format, tools, and safety checks, and your application should define when switching is allowed.
Which Grok API model should I use?
Start with the smallest candidate whose published capabilities match the task, then compare it with one stronger model on a representative evaluation set.
How much does the Grok API cost?
Pricing belongs to a specific model. Open its page for provider pricing, then confirm the LLMFly AI price in Model Plaza.
What is the Grok context window?
Context limits vary by model. Use the specific model page and catalog instead of inferring a limit from the family name.
Can I use Grok through an OpenAI-compatible client?
Use a model marked compatible in Model Plaza and test the endpoint, streaming, tools, structured outputs, and error behavior your application needs.
Why keep the model ID in configuration?
It lets you test, roll back, and change models without scattering provider-specific IDs throughout the codebase.
Confirm the model available to your API key
Open Model Plaza before adding a model ID to production configuration.