> ## Documentation Index
> Fetch the complete documentation index at: https://www.edenai.co/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# LLMs vs Expert Models

> Eden AI V3 provides two main endpoints. Both share the same base URL (https://api.

export const TechArticleSchema = ({title, description, path, articleSection, about, proficiencyLevel = "Beginner", dependencies, keywords = [], datePublished, dateModified, image, inLanguage = "en"}) => {
  const baseUrl = "https://www.edenai.co/docs";
  const canonicalUrl = `${baseUrl}/${path}`.replace(/\/+$/, "");
  const ogParams = new URLSearchParams({
    division: articleSection || "",
    title: title || "",
    description: description || ""
  });
  const resolvedImage = image || `https://edenai.mintlify.app/_mintlify/api/og?${ogParams.toString()}`;
  const data = {
    "@context": "https://schema.org",
    "@type": "TechArticle",
    "@id": `${canonicalUrl}#techarticle`,
    mainEntityOfPage: {
      "@type": "WebPage",
      "@id": canonicalUrl
    },
    headline: title,
    name: title,
    description: description,
    url: canonicalUrl,
    inLanguage: inLanguage,
    isPartOf: {
      "@type": "WebSite",
      name: "Eden AI Documentation",
      url: baseUrl
    },
    author: [{
      "@type": "Organization",
      name: "Eden AI",
      url: "https://www.edenai.co/"
    }],
    publisher: {
      "@type": "Organization",
      name: "Eden AI",
      url: "https://www.edenai.co/",
      logo: {
        "@type": "ImageObject",
        url: "https://www.edenai.co/assets/logo.png"
      }
    }
  };
  if (articleSection) data.articleSection = articleSection;
  if (about) data.about = {
    "@type": "Thing",
    name: about
  };
  if (proficiencyLevel) data.proficiencyLevel = proficiencyLevel;
  if (dependencies) data.dependencies = dependencies;
  if (keywords && keywords.length) data.keywords = keywords;
  if (datePublished) data.datePublished = datePublished;
  if (dateModified) data.dateModified = dateModified;
  data.image = Array.isArray(resolvedImage) ? resolvedImage : [resolvedImage];
  const json = JSON.stringify(data);
  const schemaId = `techarticle-${canonicalUrl}`;
  React.useEffect(() => {
    if (typeof document === "undefined") return;
    document.querySelectorAll(`script[data-schema-id="${schemaId}"]`).forEach(n => n.remove());
    const script = document.createElement("script");
    script.type = "application/ld+json";
    script.dataset.schemaId = schemaId;
    script.textContent = json;
    document.head.appendChild(script);
    return () => script.remove();
  }, [json, schemaId]);
  return null;
};

<TechArticleSchema title={"LLMs vs Expert Models"} description={"Eden AI V3 provides two main endpoints. Both share the same base URL (https://api."} path="v3/overview/llms-vs-expert-models" articleSection="Overview" about={"AI Gateway"} proficiencyLevel="Beginner" keywords={["Eden AI", "AI API", "AI gateway", "multi-provider"]} datePublished="2026-05-06T00:00:00Z" dateModified="2026-05-07T00:00:00Z" />

Eden AI V3 provides two main endpoints. Both share the same base URL (`https://api.edenai.run/v3`) and authentication (`Authorization: Bearer YOUR_API_KEY`), but they serve different purposes.

## At a Glance

|                           | LLM Endpoint                                | Universal AI Endpoint                                    |
| ------------------------- | ------------------------------------------- | -------------------------------------------------------- |
| **URL**                   | `POST /v3/chat/completions`                 | `POST /v3/universal-ai`                                  |
| **Model Format**          | `provider/model`                            | `feature/subfeature/provider[/model]`                    |
| **Use Cases**             | Chat, text generation, vision, tool calling | OCR, text analysis, image processing, translation, audio |
| **Response Format**       | OpenAI-compatible (choices, usage)          | Unified (status, cost, output)                           |
| **Streaming**             | Yes (SSE)                                   | No                                                       |
| **OpenAI SDK Compatible** | Yes                                         | No                                                       |

## LLM Endpoint

The LLM endpoint follows the **OpenAI chat completions format**, making it a drop-in replacement for any OpenAI-compatible integration.

**Best for:**

* Conversational AI and chatbots
* Text generation and completion
* Vision and multimodal analysis (analyzing images with LLMs)
* Tool/function calling
* Any workflow that uses the OpenAI SDK

**Model format:** `provider/model`

Examples: `openai/gpt-4`, `anthropic/claude-sonnet-4-5`, `google/gemini-2.5-flash`

<CodeGroup>
  ```python Python theme={null}
  import requests

  url = "https://api.edenai.run/v3/chat/completions"
  headers = {
      "Authorization": "Bearer YOUR_API_KEY",
      "Content-Type": "application/json"
  }

  payload = {
      "model": "openai/gpt-4",
      "messages": [
          {"role": "user", "content": "Summarize the benefits of cloud computing."}
      ]
  }

  response = requests.post(url, headers=headers, json=payload)
  result = response.json()
  print(result["choices"][0]["message"]["content"])
  ```

  ```bash cURL theme={null}
  curl -X POST https://api.edenai.run/v3/chat/completions \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "model": "openai/gpt-4",
      "messages": [
        {"role": "user", "content": "Summarize the benefits of cloud computing."}
      ]
    }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch('https://api.edenai.run/v3/chat/completions', {
    method: 'POST',
    headers: {
      'Authorization': 'Bearer YOUR_API_KEY',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      model: 'openai/gpt-4',
      messages: [{role: 'user', content: 'Summarize the benefits of cloud computing.'}]
    })
  });

  const result = await response.json();
  console.log(result.choices[0].message.content);
  ```
</CodeGroup>

## Universal AI Endpoint

The Universal AI endpoint handles **specialized AI tasks** through a single URL. You specify the task, provider, and optionally the model in the model string.

**Best for:**

* Text analysis (moderation, AI detection, NER, sentiment)
* OCR and document parsing (invoices, IDs, resumes)
* Image processing (generation, object detection, face detection)
* Translation
* Audio (speech-to-text, text-to-speech)

**Model format:** `feature/subfeature/provider[/model]`

Examples: `text/moderation/openai`, `ocr/financial_parser/google`, `image/generation/openai/dall-e-3`

<CodeGroup>
  ```python Python theme={null}
  import requests

  url = "https://api.edenai.run/v3/universal-ai"
  headers = {
      "Authorization": "Bearer YOUR_API_KEY",
      "Content-Type": "application/json"
  }

  payload = {
      "model": "text/moderation/openai",
      "input": {
          "text": "Content to analyze for moderation"
      }
  }

  response = requests.post(url, headers=headers, json=payload)
  result = response.json()
  print(f"Status: {result['status']}, Cost: ${result['cost']}")
  ```

  ```bash cURL theme={null}
  curl -X POST https://api.edenai.run/v3/universal-ai \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "model": "text/moderation/openai",
      "input": {
        "text": "Content to analyze for moderation"
      }
    }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch('https://api.edenai.run/v3/universal-ai', {
    method: 'POST',
    headers: {
      'Authorization': 'Bearer YOUR_API_KEY',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      model: 'text/moderation/openai',
      input: { text: 'Content to analyze for moderation' }
    })
  });

  const result = await response.json();
  console.log(`Status: ${result.status}, Cost: $${result.cost}`);
  ```
</CodeGroup>

## When to Use Which

<CardGroup cols={2}>
  <Card title="Use the LLM Endpoint when..." icon="message">
    * You need conversational AI or text generation
    * You want OpenAI SDK compatibility
    * You need streaming responses
    * You are doing vision analysis with an LLM
    * You need tool/function calling
  </Card>

  <Card title="Use Universal AI when..." icon="wand-magic-sparkles">
    * You need OCR or document parsing
    * You need text moderation or analysis
    * You want image generation or detection
    * You need translation
    * You need speech-to-text or text-to-speech
  </Card>
</CardGroup>

<Tip>
  Not sure which endpoint handles your task? Use the [listing models endpoint](/v3/llms/listing-models) to discover all available features and providers.
</Tip>

## Response Format Comparison

**LLM response** (OpenAI-compatible):

```json theme={null}
{
  "id": "chatcmpl-abc123",
  "object": "chat.completion",
  "model": "openai/gpt-4",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "Cloud computing offers..."
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 12,
    "completion_tokens": 85,
    "total_tokens": 97
  }
}
```

**Universal AI response**:

```json theme={null}
{
  "status": "success",
  "cost": 0.0001,
  "provider": "openai",
  "feature": "text",
  "subfeature": "moderation",
  "output": {
    // Feature-specific results
  }
}
```

## Next Steps

<CardGroup cols={2}>
  <Card title="Chat Completions" icon="brain" href="/v3/llms/chat-completions">
    Full guide to the LLM endpoint.
  </Card>

  <Card title="First Expert Model Call" icon="bolt" href="/v3/quickstart/first-expert-model-call">
    Full guide to the Expert Models endpoint.
  </Card>
</CardGroup>
