grok-code-fast-1

Display Name: Grok Code Fast 1
X-AI
X-AI
Released on Oct 13 12:00 AM

a speedy and economical reasoning model that excels at agentic coding.

Specifications

Context256,000
Inputtext
Outputtext, json

Performance (7-day Average)

Uptime
TPS

Pricing

Input$0.22/MTokens
Cached Input$0.02/MTokens
Output$1.65/MTokens

Usage Statistics

No usage data available for this model during the selected period
View your usage statistics for this model

Code Examples

Use the OpenAI Python SDK to call this model. Replace your-api-key with your API key.

python
from openai import OpenAI

client = OpenAI(
    base_url="https://api.ohmygpt.com/v1",
    api_key="your-api-key",  # Replace with your API key
)

response = client.chat.completions.create(
    model="grok-code-fast-1",
    messages=[
        {"role": "user", "content": "Hello!"}
    ],
)

print(response.choices[0].message.content)