diff --git a/src/app/docs/kagent/resources/api-ref/page.mdx b/src/app/docs/kagent/resources/api-ref/page.mdx index 7ae01e27..6ebaf6b1 100644 --- a/src/app/docs/kagent/resources/api-ref/page.mdx +++ b/src/app/docs/kagent/resources/api-ref/page.mdx @@ -285,7 +285,7 @@ _Appears in:_ | `modelConfig` _string_ | The name of the model config to use.
If not specified, the default value is "default-model-config".
Must be in the same namespace as the Agent. | | | | `stream` _boolean_ | Whether to stream the response from the model.
If not specified, the default value is true. | | | | `tools` _[Tool](#tool) array_ | | | MaxItems: 20
| -| `a2aConfig` _[A2AConfig](#a2aconfig)_ | A2AConfig instantiates an A2A server for this agent,
served on the HTTP port of the kagent kubernetes
controller (default 8083).
The A2A server URL will be served at
:8083/api/a2a//
Read more about the A2A protocol here: https://github.com/google/A2A | | | +| `a2aConfig` _[A2AConfig](#a2aconfig)_ | A2AConfig instantiates an A2A server for this agent,
served on the HTTP port of the kagent kubernetes
controller (default 8083).
The A2A server URL will be served at
<kagent-controller-ip>:8083/api/a2a/<agent-namespace>/<agent-name>
Read more about the A2A protocol here: https://github.com/google/A2A | | | | `deployment` _[DeclarativeDeploymentSpec](#declarativedeploymentspec)_ | | | | diff --git a/src/app/docs/kagent/resources/release-notes/page.mdx b/src/app/docs/kagent/resources/release-notes/page.mdx index 404caf56..8580d71c 100644 --- a/src/app/docs/kagent/resources/release-notes/page.mdx +++ b/src/app/docs/kagent/resources/release-notes/page.mdx @@ -396,6 +396,12 @@ spec: The secret name field is renamed from `apiKeySecret` to `apiKeySecret`. +### ModelInfo removed + +The `modelInfo` setting is removed from the ModelConfig API. + +Supported LLM providers are pre-configured by the [kagent-dev/autogen project fork](https://github.com/kagent-dev/autogen/tree/main/python/packages/autogen-ext/src/autogen_ext/models) for you by default. Trying to override these default settings, such as to enable vision for image recognition, could cause unexpected behavior in models that do not support these settings. Therefore, the `modelInfo` field is removed. + ## Memory API The Memory API is not supported in ADK. The [agent development kit](https://google.github.io/adk-docs/) is required to bring your own agents. As such, the Memory docs are removed. diff --git a/src/app/docs/kagent/supported-providers/anthropic/page.mdx b/src/app/docs/kagent/supported-providers/anthropic/page.mdx index 29176e0a..c9db669c 100644 --- a/src/app/docs/kagent/supported-providers/anthropic/page.mdx +++ b/src/app/docs/kagent/supported-providers/anthropic/page.mdx @@ -36,7 +36,7 @@ spec: anthropic: {} ``` -For Anthropic's Claude models, kagent automatically configures the appropriate model capabilities, including vision support for Claude-3 models. You can override these settings using the `modelInfo` field if needed. For more information about model capabilities and configuration, see [Custom Models](/docs/kagent/supported-providers/custom-models). +For Anthropic's Claude models, kagent automatically configures the appropriate model capabilities, including vision support for Claude-3 models. 3. Apply the above resource to the cluster. diff --git a/src/app/docs/kagent/supported-providers/azure-openai/page.mdx b/src/app/docs/kagent/supported-providers/azure-openai/page.mdx index 03cd1a42..ca470bd0 100644 --- a/src/app/docs/kagent/supported-providers/azure-openai/page.mdx +++ b/src/app/docs/kagent/supported-providers/azure-openai/page.mdx @@ -39,7 +39,7 @@ spec: azureAdToken: ``` -For Azure OpenAI's standard models, kagent automatically configures the appropriate model capabilities. However, you can override these settings using the `modelInfo` field if needed. For more information about model capabilities and configuration, see [Custom Models](/docs/kagent/supported-providers/custom-models). +For Azure OpenAI's standard models, kagent automatically configures the appropriate model capabilities. 3. Apply the above resource to the cluster. diff --git a/src/app/docs/kagent/supported-providers/custom-models/page.mdx b/src/app/docs/kagent/supported-providers/custom-models/page.mdx deleted file mode 100644 index 56236b38..00000000 --- a/src/app/docs/kagent/supported-providers/custom-models/page.mdx +++ /dev/null @@ -1,136 +0,0 @@ ---- -title: "Custom Models" -pageOrder: 7 -description: "Learn how to configure custom AI models in kagent." ---- - -export const metadata = { - title: "Configuring custom models in kagent", - description: "Learn how to configure custom AI models in kagent.", - author: "kagent.dev" -}; - -# Custom Models and Model Capabilities - -When using custom models or overriding model capabilities in kagent, you need to specify what features your model supports. This is done through the `modelInfo` configuration. - -## Model Capabilities - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
CapabilityDescription
visionProcess and understand images
functionCallingUse tools and execute actions
jsonOutputGenerate valid JSON responses
familyModel architecture type (e.g., "gpt", "llama")
structuredOutputGenerate formatted responses
multipleSystemMessagesSupport multiple system prompts
- -## Provider Requirements - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ProviderModelInfoNote
OpenAIOptionalPre-configured for standard models
AnthropicOptionalPre-configured for Claude models
OllamaRequiredMust specify all capabilities
CustomRequiredMust specify all capabilities
- -## Configuring Custom Models - -Often you may want to use a custom model with an existing provider, for example if you're using a self-hosted model exposed via the OpenAI API. -Or if you're using a proxy to the OpenAI API. - -The example below will add an API key, but given that this is a custom provider, the key is optional. - -1. Create a Kubernetes Secret that stores the API key, replace `` with an actual API key: - -```shell -export OPENAI_API_KEY= -kubectl create secret generic kagent-openai -n kagent --from-literal OPENAI_API_KEY=$OPENAI_API_KEY -``` - -2. Create a ModelConfig resource that references the secret and key name, and specify the model you want to use: - -```yaml -apiVersion: kagent.dev/v1alpha2 -kind: ModelConfig -metadata: - name: custom-openai-model-config - namespace: kagent -spec: - apiKeySecret: kagent-openai - apiKeySecretKey: OPENAI_API_KEY - model: # This should match the model name passed to the provider. - provider: OpenAI - openAI: - baseUrl: https://your-custom-openai-provider.com - # Required: Specify model capabilities - modelInfo: - vision: false - functionCalling: true - jsonOutput: true - family: "unknown" - structuredOutput: true - multipleSystemMessages: false -``` - -If you don't need an API key you can elide the `apiKeySecret` and `apiKeySecretKey` fields. - -3. Apply the above resource to the cluster. - -Once the resource is applied, you can select the model from the Model dropdown in the UI when creating or updating agents. - -See provider documentation for specific configuration: -- [OpenAI](/docs/kagent/supported-providers/openai) -- [Anthropic](/docs/kagent/supported-providers/anthropic) -- [Ollama](/docs/kagent/supported-providers/ollama) \ No newline at end of file diff --git a/src/app/docs/kagent/supported-providers/ollama/page.mdx b/src/app/docs/kagent/supported-providers/ollama/page.mdx index 833c4ed1..ced64760 100644 --- a/src/app/docs/kagent/supported-providers/ollama/page.mdx +++ b/src/app/docs/kagent/supported-providers/ollama/page.mdx @@ -84,14 +84,4 @@ spec: provider: Ollama ollama: host: http://ollama.ollama.svc.cluster.local - # Required: Specify model capabilities - modelInfo: - vision: false - functionCalling: true - jsonOutput: true - family: "unknown" - structuredOutput: true - multipleSystemMessages: false ``` - -Since Ollama supports various models with different capabilities, you must specify the model's capabilities using the `modelInfo` field. For detailed information about model capabilities and how to configure them, see [Custom Models](/docs/kagent/supported-providers/custom-models). Make sure to set `functionCalling: true` if your model supports it, as this is required for using tools with the agent. diff --git a/src/app/docs/kagent/supported-providers/openai/page.mdx b/src/app/docs/kagent/supported-providers/openai/page.mdx index b2607b78..e2ebdb7c 100644 --- a/src/app/docs/kagent/supported-providers/openai/page.mdx +++ b/src/app/docs/kagent/supported-providers/openai/page.mdx @@ -35,7 +35,7 @@ spec: openAI: {} ``` -For OpenAI's standard models like GPT-4 and GPT-3.5, kagent automatically configures the appropriate model capabilities. However, you can override these settings using the `modelInfo` field if needed. For more information about model capabilities and configuration, see [Custom Models](/docs/kagent/supported-providers/custom-models). +For OpenAI's standard models like GPT-4 and GPT-3.5, kagent automatically configures the appropriate model capabilities. 3. Apply the above resource to the cluster.