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

# Anthropic

[Updated in 2026.22](https://docs-classic.cognigy.com/release-notes/2026.22.md)

> [!WARNING]
>
> As of Cognigy 2026.6.0, the support for the Completions API for custom LLMs is deprecated. The full removal is planned for Cognigy 2026.24.0. Switch to the Messages API instead before the removal date.

> [!WARNING]
>
> Anthropic's `claude-sonnet-4-6` model doesn't support [assistant message
> prefilling](https://platform.claude.com/docs/en/about-claude/models/migration-guide#breaking-changes-3). If your AI Agent uses this model and a conversation ends with an assistant message, for example,
> after a [Say Node](https://docs-classic.cognigy.com/ai/agents/develop/node-reference/basic/say.md), requests can
> fail with the error `The conversation must end with a user message`.
>
> To keep your Flows compatible, ensure that the last transcript step before the
> LLM call is a user message. For example, add an [Add Transcript Step
> Node](https://docs-classic.cognigy.com/ai/agents/develop/node-reference/service/add-transcript-step.md) before
> the LLM call and set the role to `user`.

> [!NOTE]
>
> The `claude-sonnet-5`, `claude-sonnet-5-5`, `claude-haiku-5-5`, `claude-opus-4-7`, `claude-opus-4-8`, `claude-opus-5`, and `claude-opus-5-5` models don't support token-sampling parameters such as `temperature`, `top_p`, or `top_k`. If you set these parameters at the Node level or in **Custom Model Options**, Cognigy automatically removes them before sending the request. Instead, set Anthropic's `thinking.type` and `thinking.effort` parameters in **Custom Model Options** to control model behavior.

To start using an Anthropic model with Cognigy features, follow these steps:

1. [Add a Model](#add-models)
2. [Apply the Model](#apply-the-model)

## Add Models

You can add a model using one of the following interfaces:

* [GUI](#add-models-via-gui)
* [API](#add-models-via-the-api)

### Add Models via GUI

You can add a model provided by Anthropic to Cognigy in **Build > LLM**. To add the model, you will need the following parameters:

> [tab] Standard Model
>
> > [!NOTE]
> >
> > The `*-latest` suffix indicates that the model you select points to the latest version of the model. For more information, read the [Anthropic's models](https://docs.anthropic.com/en/docs/about-claude/models/overview) documentation.
>
> | Parameter | Description |
> | - | - |
> | apiKey | Add an API Key that you generated via [Account Settings](https://platform.claude.com/docs/en/get-started) in Anthropic. |

> [tab] Custom Model
>
> | Parameter | Description |
> | - | - |
> | Model Type | Select **Chat** for models that support the Messages API and **Completion** for the Completions API. For more information, refer to the [Anthropic Model Comparison (API format)](https://docs.anthropic.com/claude/docs/models-overview) documentation. |
> | Model Name | Enter the name of the model that you want to use as a custom model. To find model names, refer to the [Anthropic](https://docs.anthropic.com/claude/docs/models-overview) documentation. |
> | apiKey | Add an API Key that you generated via [Account Settings](https://platform.claude.com/docs/en/get-started) in Anthropic. |

Apply changes. Check if the connection was set up by clicking **Test**. You can switch generative models at any time using the **Model** list without setting up a new connection. For embedding models, the selection is locked because different embedding models can generate incompatible embeddings for [Knowledge AI](https://docs-classic.cognigy.com/ai/agents/develop/knowledge-ai/overview#embedding-model). To switch an embedding, delete the connection and create a new one.

### Add Models via the API

You can add either a standard or custom model using the [Cognigy API POST /v2.0/largelanguagemodels](https://api-trial.cognigy.ai/openapi#post-/v2.0/largelanguagemodels) request.
Then, test your connection for the created model via the [Cognigy API POST /v2.0/largelanguagemodels//test](https://api-trial.cognigy.ai/openapi#post-/v2.0/largelanguagemodels/-largeLanguageModelId-/test).

## Apply the Model

To apply a model, follow these steps:

1. In the left-side menu of the Project, go to **Manage > Settings**.
2. Go to the section based on your use case for using a model:
   * **Generative AI Settings**. In the **Generative AI Settings** section, activate **Enable Generative AI Features**. This setting is toggled on by default if you have previously set up the Generative AI credentials.
   * **Knowledge AI Settings**. Use this section if you need to add a model for Knowledge AI. Select a model for the **Knowledge Search** and **Answer Extraction** features. Refer to the [list of standard models](https://docs-classic.cognigy.com/ai/agents/develop/gen-ai-and-llms/model-support-by-feature.md) and find the models that support these features.
3. Navigate to the desired feature and select a model from the list. If there are no models available for the selected feature, the system will automatically select **None**. Save changes.

## More Information

* [Other LLM Operations](https://docs-classic.cognigy.com/ai/agents/develop/gen-ai-and-llms/other-operations.md)
* [Overview](https://docs-classic.cognigy.com/ai/agents/develop/gen-ai-and-llms/llms.md)
* [All LLM Providers](https://docs-classic.cognigy.com/ai/agents/develop/gen-ai-and-llms/providers/all-providers.md)
* [Model support by feature](https://docs-classic.cognigy.com/ai/agents/develop/gen-ai-and-llms/model-support-by-feature.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.