Skip to content

🤖 Explain with AI

LLM Models

4Geeks AI Agents leverages a multi-model architecture through the Private AI Gateway, dynamically selecting the optimal Large Language Model for each interaction. This document provides a detailed breakdown of the models available today, how they are used, and how the platform decides which model to use for a given task.

Multi-Model Orchestration

The 4Geeks Private AI Gateway does not rely on a single LLM provider. Instead, it orchestrates across multiple providers to ensure the best combination of quality, speed, and cost for each interaction.

graph LR
    subgraph Request["Incoming Request"]
        MSG[User Message]
        CTX[Context Type]
        CFG[Agent Config]
    end

    subgraph Router["Gateway Router"]
        AN[Analyzer]
        SEL[Model Selector]
        LB[Load Balancer]
        FB[Fallback Handler]
    end

    subgraph Providers["LLM Providers"]
        OA[OpenAI]
        ANTH[Anthropic]
        GOOG[Google]
        XAI[xAI]
        DS[DeepSeek]
    end

    MSG --> AN
    CTX --> AN
    CFG --> AN
    AN --> SEL
    SEL --> LB
    LB --> OA
    LB --> ANTH
    LB --> GOOG
    LB --> XAI
    LB --> DS
    OA --> FB
    ANTH --> FB
    GOOG --> FB
    XAI --> FB
    DS --> FB

How Model Selection Works

For every request, the Gateway evaluates several factors:

Factor Description
Task Type Text conversation, voice response, website analysis, embedding, or tool execution
Latency Requirement Voice interactions require ultra-low latency; text can tolerate slightly longer processing
Complexity Simple FAQs use lightweight models; complex reasoning tasks use frontier models
Agent Configuration Each agent can specify preferred models or allow dynamic selection
Cost Optimization The gateway prefers cost-effective models when quality requirements are met
Provider Health If a provider is experiencing issues, traffic is automatically rerouted
Rate Limits Requests are distributed across API keys to avoid hitting provider rate limits

Automatic Fallbacks

If the primary model or provider is unavailable, the Gateway automatically falls back to an equivalent model:

graph TD
    A[Primary Model Request] --> B{Success?}
    B -->|Yes| C[Return Response]
    B -->|No - Timeout| D[Try Secondary Model]
    B -->|No - Error| E[Try Alternate Provider]
    D --> F{Success?}
    F -->|Yes| C
    F -->|No| G[Try Tertiary Model]
    E --> H{Success?}
    H -->|Yes| C
    H -->|No| G
    G --> I{Success?}
    I -->|Yes| C
    I -->|No| J[Return Graceful Error]

Fallback chain example for a text agent:

  1. Primary: OpenAI GPT-6 Luna (fast, low-cost)
  2. Secondary: DeepSeek V4.1 Flash (similar capability at a similar price)
  3. Tertiary: Anthropic Claude Haiku 5.5 or Google Gemini 4 Argon (alternate provider)
  4. Final: Return a graceful error message to the user

Available Models

OpenAI Models

OpenAI provides the primary family of models used across the platform for text and voice interactions.

Model Context Window Best For Latency Relative Cost
GPT-6 Luna 272K tokens General-purpose text agents, WhatsApp, FAQs, lead qualification, voice reasoning Very Low Very Low
text-embedding-3-small 8,191 tokens Knowledge base embeddings, semantic search Very Low Very Low
text-embedding-3-large 8,191 tokens High-precision embeddings for critical knowledge bases Very Low Low

GPT-6 Luna

The default model for most agent interactions, used for tasks that combine speed, cost, and reliable instruction following:

  • Use Cases: Standard text conversations, WhatsApp messaging, lead qualification, FAQ answering, appointment scheduling, knowledge base answers, and the reasoning tier behind voice interactions
  • Strengths: Very low cost, fast response times, strong tool calling, reliable structured output, extended context window
  • Limitations: Less capable than DeepSeek V4 Pro or Grok 4.7 on the hardest multi-step reasoning tasks
  • Default Temperature: 0.7

text-embedding-3-small

The default embedding model for the Knowledge Base (RAG) system:

  • Dimensions: 1,536
  • Use Cases: Converting knowledge base documents into vector embeddings for semantic search
  • Strengths: Excellent balance of quality and speed, cost-effective for large document collections
  • Limitations: Lower precision than the large variant for highly specialized domains

Anthropic Claude Models

Anthropic’s Claude models are used for tasks requiring strong safety guardrails and careful instruction following.

Model Context Window Best For Latency Relative Cost
Claude Haiku 5.5 200K tokens Safety-sensitive conversations, compliance workflows, fallback when OpenAI is degraded Low Very Low

Claude Haiku 5.5

A fast, safety-focused model used as both a primary and a critical fallback:

  • Use Cases: Compliance-related conversations, general-purpose support, fallback when another provider is degraded, tasks requiring strong safety properties
  • Strengths: Very fast, strong safety guardrails, large context window, very low cost, careful instruction following
  • Limitations: Less capable than the frontier reasoning models on complex analysis
  • Default Temperature: 0.7

Google Gemini Models

Google’s Gemini models provide additional diversity and are particularly strong in multimodal and long-context tasks.

Model Context Window Best For Latency Relative Cost
Gemini 4 Argon 1M tokens Very long context tasks, multimodal analysis, multilingual conversations Medium High

Gemini 4 Argon

Selected for tasks requiring extremely large context windows and multimodal understanding:

  • Use Cases: Processing very long documents, contract and policy analysis, multilingual conversations, image and document understanding
  • Strengths: Massive context window, strong multilingual capability, multimodal input, good at code understanding
  • Limitations: Higher cost and latency than the default model for simple conversational tasks
  • Default Temperature: 0.7

xAI Grok Models

xAI’s Grok models are strong at agentic tool use and reasoning with up-to-date knowledge.

Model Context Window Best For Latency Relative Cost
Grok 4.7 200K tokens Agentic workflows, complex reasoning, real-time knowledge, multi-step tool calling Low Medium

Grok 4.7

Used for high-value interactions that need current context and reliable tool use:

  • Use Cases: Multi-step research, complex sales conversations, agentic workflows that chain several tools, tasks that benefit from recent world knowledge
  • Strengths: Strong reasoning, excellent tool calling, up-to-date knowledge, good performance on long agentic tasks
  • Limitations: Higher cost than the default workhorse model
  • Default Temperature: 0.7

DeepSeek Models

DeepSeek models provide frontier-level reasoning at low cost and are the main alternative to the default model for analytical workloads.

Model Context Window Best For Latency Relative Cost
DeepSeek V4.1 Flash 128K tokens High-volume agents, cost-sensitive workflows that still need solid reasoning Very Low Very Low
DeepSeek V4 Pro 128K tokens Deep reasoning, complex multi-step workflows, tool-heavy automation Medium Low

DeepSeek V4.1 Flash

The high-volume reasoning model:

  • Use Cases: Bulk message processing, high-traffic campaigns, structured workflows, retrieval-heavy conversations where cost is critical
  • Strengths: Low cost, fast inference, strong reasoning for its price, efficient caching
  • Limitations: Smaller context window than Gemini 4 Argon or GPT-6 Luna
  • Default Temperature: 0.7

DeepSeek V4 Pro

The deep-reasoning variant:

  • Use Cases: Complex multi-step tasks, analytical workflows, data-heavy tool calls, cases where answer quality matters more than cost
  • Strengths: Strong analytical reasoning, reliable structured output, good performance on long tool chains
  • Limitations: Slower and more expensive than DeepSeek V4.1 Flash
  • Default Temperature: 0.7

Model Usage by Feature

The following table shows which models are used for each platform feature:

Feature Primary Model Fallback Model(s) Reason
Text Agents (WhatsApp) GPT-6 Luna DeepSeek V4.1 Flash, Claude Haiku 5.5 Best balance of quality, speed, and cost for conversational text
Voice Agents (Phone) 4Geeks Voice Engine (GPT-6 Luna) DeepSeek V4.1 Flash Ultra-low latency required for natural voice conversations
Complex Reasoning DeepSeek V4 Pro Grok 4.7, Gemini 4 Argon Deep reasoning for complex multi-step tasks
Website Analysis Managed compound pipeline N/A (specialized) Purpose-built pipeline for web analysis and prompt generation
Knowledge Base Embeddings text-embedding-3-small text-embedding-3-large High-quality embeddings at scale
Knowledge Base Retrieval GPT-6 Luna DeepSeek V4.1 Flash Fast synthesis of retrieved context into responses
Workflow Automation DeepSeek V4.1 Flash GPT-6 Luna Cost-effective processing of structured workflows
Campaign Scripts GPT-6 Luna Grok 4.7 Good quality for outbound call scripts

Model Configuration

Default Settings

Each agent type has optimized default model settings:

Setting Text Agents Voice Agents Custom Agents
Model GPT-6 Luna 4Geeks Voice Engine (GPT-6 Luna) Configurable
Temperature 0.7 0.7 Configurable
Max Tokens 1,024 256 Configurable
Top-P 1.0 1.0 Configurable
Frequency Penalty 0.0 0.0 Configurable
Presence Penalty 0.0 0.0 Configurable

Temperature Guide

The temperature parameter controls the randomness of the model’s output:

Temperature Behavior Best For
0.0 - 0.2 Deterministic, consistent responses Factual Q&A, data lookup, compliance responses
0.3 - 0.5 Mostly consistent with some variation Customer support, appointment scheduling, collections
0.5 - 0.7 Balanced creativity and consistency Sales conversations, marketing content, general chat
0.7 - 0.9 Creative and varied responses Content generation, brainstorming, creative marketing
0.9 - 1.0 Highly creative, unpredictable Creative writing, ideation (not recommended for customer-facing)

Context Window Management

Different models have different context windows. The platform manages context efficiently:

graph LR
    subgraph Context["Model Context Window"]
        SP[System Prompt<br/>~500-2,000 tokens]
        KC[Knowledge Base Context<br/>~1,500-3,000 tokens]
        CH[Conversation History<br/>~2,000-20,000 tokens]
        UM[User Message<br/>~50-500 tokens]
        RS[Response Space<br/>~256-1,024 tokens]
    end

Context allocation strategy:

  1. System Prompt — Fixed allocation based on agent type (500-2,000 tokens)
  2. Knowledge Base Context — Up to 3,000 tokens from RAG retrieval (configurable)
  3. Conversation History — Dynamically sized; older messages are truncated as the window fills
  4. User Message — The current incoming message
  5. Response Space — Reserved for the model’s output (256 tokens for voice, up to 1,024 for text)

Conversation Memory

The platform maintains conversation history within the context window:

Setting Default Description
Max History Messages 20 Maximum number of previous messages included in context
Max History Tokens 10,000 Maximum total tokens allocated to conversation history
Truncation Strategy Sliding Window Oldest messages are dropped first when limits are reached
Summary Injection Disabled When enabled, older messages are summarized instead of dropped

Cost Comparison

Per-Token Pricing (Approximate)

Model Input (per 1M tokens) Output (per 1M tokens) Notes
GPT-6 Luna $0.10 $0.50 Default workhorse model
DeepSeek V4.1 Flash $0.15 $0.60 High-volume reasoning at low cost
DeepSeek V4 Pro $0.66 $1.98 Deep reasoning for complex tasks
Claude Haiku 5.5 $0.10 $0.50 Fast and safety-focused fallback
Grok 4.7 $2.00 $6.00 Agentic reasoning and current knowledge
Gemini 4 Argon $2.00 $10.00 Long context and multimodal analysis
text-embedding-3-small $0.02 N/A Embeddings (input only)

How This Maps to Credits

4Geeks abstracts raw token pricing into a simplified credit system:

Interaction Type Credits Consumed Approximate Token Equivalent
Text Message ~40 credits ~1,000-2,000 total tokens (input + output)
Voice Minute ~400 credits Includes STT, LLM, TTS, and telephony costs
Knowledge Base Query Included in message cost Retrieval is bundled with the text message
Website Analysis ~200 credits One-time cost per analysis
Embedding (per document) ~10 credits per 100 pages One-time cost during document processing

Note

Credit consumption is an estimation. Actual costs vary based on the model selected, conversation complexity, knowledge base retrieval depth, and the number of tool calls executed during an interaction.

Model Selection Best Practices

For Agent Creators

When configuring a custom agent, consider these guidelines:

Scenario Recommended Model Why
High-volume WhatsApp support GPT-6 Luna (default) Best quality-to-cost ratio for conversational text
Premium customer experience DeepSeek V4 Pro or Grok 4.7 Stronger reasoning for complex, high-value interactions
Voice agent (phone) 4Geeks Voice Engine (GPT-6 Luna) Optimized for low-latency voice conversations
Multilingual (Spanish/Portuguese) GPT-6 Luna or Gemini 4 Argon Both have strong multilingual capabilities
Long document analysis Gemini 4 Argon Largest context window (1M tokens)
Cost-sensitive campaigns DeepSeek V4.1 Flash Lowest cost with solid reasoning
Agentic workflows and tool use Grok 4.7 Most reliable multi-step tool calling
Safety-sensitive conversations Claude Haiku 5.5 Strongest guardrails and instruction following

For Developers

When building custom integrations via the API:

{
  "model": "gpt-6-luna",
  "messages": [
    {"role": "system", "content": "You are a helpful assistant..."},
    {"role": "user", "content": "What are your business hours?"}
  ],
  "temperature": 0.7,
  "max_tokens": 1024,
  "tools": [
    {
      "type": "function",
      "function": {
        "name": "check_availability",
        "description": "Check business availability"
      }
    }
  ]
}

The API is fully compatible with the OpenAI API format, making it easy to switch between models without changing your integration code.

Extended Model Catalog

The models listed on this page are the default tiers the Gateway routes to. The Gateway also operates a broader catalog of frontier and specialist models, and additional models can be enabled for an agent through the same OpenAI-compatible API. If you need a specific model for a workload, your account team can confirm availability, pricing, and data-processing terms.

Model Updates & Versioning

The 4Geeks platform continuously evaluates and updates its model lineup:

  • Seamless Upgrades — When a new model version is released (e.g., GPT-6 Luna (2026-09) → GPT-6 Luna), the Gateway automatically routes to the latest version
  • Backward Compatibility — The OpenAI-compatible API format ensures that model upgrades do not break existing integrations
  • A/B Testing — New models are tested against current models using A/B testing before full rollout
  • Regression Testing — Every model update is validated against a benchmark suite of agent interactions to ensure quality does not decrease
  • Changelog — Significant model changes are documented in the platform changelog

What’s Next


Still have questions? Ask on Discord or explore the tutorials.