This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 2f21a257bc72 CAMEL-23832: camel-ai-prompt - improve the component and
option descriptions (#30933)
2f21a257bc72 is described below
commit 2f21a257bc723629df0d7c2ffc3f8544e4b296d3
Author: Claus Ibsen <[email protected]>
AuthorDate: Fri Nov 27 15:03:57 2026 +0100
CAMEL-23832: camel-ai-prompt - improve the component and option
descriptions (#30933)
This commit rewrites the component description and the texts of 6 options
of ai-prompt (5 shared by the component and
the endpoint, plus the component configuration), 11 texts in the component
JSON. The new texts say where MCP clients see
each value (prompts/list, prompts/get), how arguments reach the route as
headers, which argument names are reserved,
and that a prompt without tags is never exposed by the MCP server. The
component has no headers.
Documentation only, no behavior change. The component JSON, the catalog
copy, the doc page header and the DSL are
regenerated. camel-ai-prompt is marked as done in
tasks/component-descriptions.md.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Claus Ibsen <[email protected]>
---
.../apache/camel/catalog/components/ai-prompt.json | 22 ++++----
.../camel/catalog/docs/ai-prompt-component.adoc | 2 +-
.../camel/component/ai/prompt/ai-prompt.json | 22 ++++----
.../src/main/docs/ai-prompt-component.adoc | 2 +-
.../component/ai/prompt/AiPromptComponent.java | 3 +-
.../component/ai/prompt/AiPromptConfiguration.java | 21 +++++---
.../component/ai/prompt/AiPromptEndpoint.java | 6 ++-
.../component/ComponentsBuilderFactory.java | 3 +-
.../dsl/AiPromptComponentBuilderFactory.java | 38 +++++++++-----
.../builder/endpoint/StaticEndpointBuilders.java | 16 ++++--
.../dsl/AiPromptEndpointBuilderFactory.java | 60 ++++++++++++++--------
tasks/component-descriptions.md | 2 +-
12 files changed, 122 insertions(+), 75 deletions(-)
diff --git
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/ai-prompt.json
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/ai-prompt.json
index 926c218250bd..8a5d80e8fe7d 100644
---
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/ai-prompt.json
+++
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/ai-prompt.json
@@ -3,7 +3,7 @@
"kind": "component",
"name": "ai-prompt",
"title": "AI Prompt",
- "description": "Consumer endpoint that registers a Camel route as an MCP
prompt.",
+ "description": "Expose a Camel route as a prompt that MCP clients list and
get through the Camel MCP server.",
"deprecated": false,
"firstVersion": "4.24.0",
"label": "ai",
@@ -24,12 +24,12 @@
"remote": false
},
"componentProperties": {
- "arguments": { "index": 0, "kind": "property", "displayName": "Arguments",
"group": "consumer", "label": "consumer", "required": false, "type": "object",
"javaType": "java.util.Map<java.lang.String, java.lang.String>", "prefix":
"argument.", "multiValue": true, "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Prompt arguments.
Configure e [...]
+ "arguments": { "index": 0, "kind": "property", "displayName": "Arguments",
"group": "consumer", "label": "consumer", "required": false, "type": "object",
"javaType": "java.util.Map<java.lang.String, java.lang.String>", "prefix":
"argument.", "multiValue": true, "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The arguments of the
prompt, [...]
"bridgeErrorHandler": { "index": 1, "kind": "property", "displayName":
"Bridge Error Handler", "group": "consumer", "label": "consumer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Allows for bridging the consumer to the Camel routing Error Handler, which
mean any exceptions (if possible) occurred while the Camel consumer is trying
to pickup incoming messages, or the like [...]
- "configuration": { "index": 2, "kind": "property", "displayName":
"Configuration", "group": "consumer", "label": "", "required": false, "type":
"object", "javaType":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration", "deprecated":
false, "autowired": false, "secret": false, "description": "The component
configuration" },
- "description": { "index": 3, "kind": "property", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Human-readable
description of what this prompt provides. When omitted, defaults to the prompt
name." },
- "tags": { "index": 4, "kind": "property", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Comma-separated list of
tags used to group prompts. MCP servers select which prompts to expose using
these tags. Wh [...]
- "title": { "index": 5, "kind": "property", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Optional display title
for MCP prompt listings." },
+ "configuration": { "index": 2, "kind": "property", "displayName":
"Configuration", "group": "consumer", "label": "", "required": false, "type":
"object", "javaType":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration", "deprecated":
false, "autowired": false, "secret": false, "description": "The configuration
that every endpoint starts from. The endpoint copies it, and the options of the
endpoint URI replace its values." },
+ "description": { "index": 3, "kind": "property", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The description of what
the prompt provides, which MCP clients see in prompts\/list and receive in th
[...]
+ "tags": { "index": 4, "kind": "property", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "A comma-separated list
of tags to register the prompt under. The MCP server exposes the prompts whose
tags match it [...]
+ "title": { "index": 5, "kind": "property", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The human-readable title
of the prompt, which MCP clients can show in prompts\/list instead of the name.
If not s [...]
"autowiredEnabled": { "index": 6, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching t [...]
},
"bodyTypes": {
@@ -37,11 +37,11 @@
"consumerReply": { "carriers": [ "text", "list", "bytes", "stream", "file"
], "description": "A String, byte array, stream or file is converted to one
user message. A List may contain Strings or Maps with role (user or assistant)
and content. Content may be a String or an MCP content block." }
},
"properties": {
- "promptName": { "index": 0, "kind": "path", "displayName": "Prompt Name",
"group": "consumer", "label": "", "required": true, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "description": "The prompt name advertised to MCP clients." },
- "arguments": { "index": 1, "kind": "parameter", "displayName":
"Arguments", "group": "consumer", "label": "consumer", "required": false,
"type": "object", "javaType": "java.util.Map<java.lang.String,
java.lang.String>", "prefix": "argument.", "multiValue": true, "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Prompt arguments.
Configure [...]
- "description": { "index": 2, "kind": "parameter", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Human-readable
description of what this prompt provides. When omitted, defaults to the prompt
name." },
- "tags": { "index": 3, "kind": "parameter", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Comma-separated list of
tags used to group prompts. MCP servers select which prompts to expose using
these tags. W [...]
- "title": { "index": 4, "kind": "parameter", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Optional display title
for MCP prompt listings." },
+ "promptName": { "index": 0, "kind": "path", "displayName": "Prompt Name",
"group": "consumer", "label": "", "required": true, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "description": "The name of the prompt, which MCP clients see
in prompts\/list and pass to prompts\/get. It must not contain a slash. A route
whose prompt name is already registered under one of its tags, or in the pool
of prompts without tags, fails to [...]
+ "arguments": { "index": 1, "kind": "parameter", "displayName":
"Arguments", "group": "consumer", "label": "consumer", "required": false,
"type": "object", "javaType": "java.util.Map<java.lang.String,
java.lang.String>", "prefix": "argument.", "multiValue": true, "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The arguments of the
prompt, [...]
+ "description": { "index": 2, "kind": "parameter", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The description of what
the prompt provides, which MCP clients see in prompts\/list and receive in t
[...]
+ "tags": { "index": 3, "kind": "parameter", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "A comma-separated list
of tags to register the prompt under. The MCP server exposes the prompts whose
tags match i [...]
+ "title": { "index": 4, "kind": "parameter", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The human-readable title
of the prompt, which MCP clients can show in prompts\/list instead of the name.
If not [...]
"bridgeErrorHandler": { "index": 5, "kind": "parameter", "displayName":
"Bridge Error Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Allows for bridging the consumer to the
Camel routing Error Handler, which mean any exceptions (if possible) occurred
while the Camel consumer is trying to pickup incoming [...]
"exceptionHandler": { "index": 6, "kind": "parameter", "displayName":
"Exception Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "object", "javaType":
"org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.",
"deprecated": false, "autowired": false, "secret": false, "description": "To
let the consumer use a custom ExceptionHandler. Notice if the option
bridgeErrorHandler is enabled then this option is not in use. By def [...]
"exchangePattern": { "index": 7, "kind": "parameter", "displayName":
"Exchange Pattern", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "enum", "javaType":
"org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut" ],
"deprecated": false, "autowired": false, "secret": false, "description": "Sets
the exchange pattern when the consumer creates an exchange." }
diff --git
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/ai-prompt-component.adoc
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/ai-prompt-component.adoc
index 946dacc6914d..8ac05e0bd568 100644
---
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/ai-prompt-component.adoc
+++
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/ai-prompt-component.adoc
@@ -2,7 +2,7 @@
:doctitle: AI Prompt
:shortname: ai-prompt
:artifactid: camel-ai-prompt
-:description: Consumer endpoint that registers a Camel route as an MCP prompt.
+:description: Expose a Camel route as a prompt that MCP clients list and get
through the Camel MCP server.
:since: 4.24
:supportlevel: Preview
:tabs-sync-option:
diff --git
a/components/camel-ai/camel-ai-prompt/src/generated/resources/META-INF/org/apache/camel/component/ai/prompt/ai-prompt.json
b/components/camel-ai/camel-ai-prompt/src/generated/resources/META-INF/org/apache/camel/component/ai/prompt/ai-prompt.json
index 926c218250bd..8a5d80e8fe7d 100644
---
a/components/camel-ai/camel-ai-prompt/src/generated/resources/META-INF/org/apache/camel/component/ai/prompt/ai-prompt.json
+++
b/components/camel-ai/camel-ai-prompt/src/generated/resources/META-INF/org/apache/camel/component/ai/prompt/ai-prompt.json
@@ -3,7 +3,7 @@
"kind": "component",
"name": "ai-prompt",
"title": "AI Prompt",
- "description": "Consumer endpoint that registers a Camel route as an MCP
prompt.",
+ "description": "Expose a Camel route as a prompt that MCP clients list and
get through the Camel MCP server.",
"deprecated": false,
"firstVersion": "4.24.0",
"label": "ai",
@@ -24,12 +24,12 @@
"remote": false
},
"componentProperties": {
- "arguments": { "index": 0, "kind": "property", "displayName": "Arguments",
"group": "consumer", "label": "consumer", "required": false, "type": "object",
"javaType": "java.util.Map<java.lang.String, java.lang.String>", "prefix":
"argument.", "multiValue": true, "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Prompt arguments.
Configure e [...]
+ "arguments": { "index": 0, "kind": "property", "displayName": "Arguments",
"group": "consumer", "label": "consumer", "required": false, "type": "object",
"javaType": "java.util.Map<java.lang.String, java.lang.String>", "prefix":
"argument.", "multiValue": true, "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The arguments of the
prompt, [...]
"bridgeErrorHandler": { "index": 1, "kind": "property", "displayName":
"Bridge Error Handler", "group": "consumer", "label": "consumer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Allows for bridging the consumer to the Camel routing Error Handler, which
mean any exceptions (if possible) occurred while the Camel consumer is trying
to pickup incoming messages, or the like [...]
- "configuration": { "index": 2, "kind": "property", "displayName":
"Configuration", "group": "consumer", "label": "", "required": false, "type":
"object", "javaType":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration", "deprecated":
false, "autowired": false, "secret": false, "description": "The component
configuration" },
- "description": { "index": 3, "kind": "property", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Human-readable
description of what this prompt provides. When omitted, defaults to the prompt
name." },
- "tags": { "index": 4, "kind": "property", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Comma-separated list of
tags used to group prompts. MCP servers select which prompts to expose using
these tags. Wh [...]
- "title": { "index": 5, "kind": "property", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Optional display title
for MCP prompt listings." },
+ "configuration": { "index": 2, "kind": "property", "displayName":
"Configuration", "group": "consumer", "label": "", "required": false, "type":
"object", "javaType":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration", "deprecated":
false, "autowired": false, "secret": false, "description": "The configuration
that every endpoint starts from. The endpoint copies it, and the options of the
endpoint URI replace its values." },
+ "description": { "index": 3, "kind": "property", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The description of what
the prompt provides, which MCP clients see in prompts\/list and receive in th
[...]
+ "tags": { "index": 4, "kind": "property", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "A comma-separated list
of tags to register the prompt under. The MCP server exposes the prompts whose
tags match it [...]
+ "title": { "index": 5, "kind": "property", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The human-readable title
of the prompt, which MCP clients can show in prompts\/list instead of the name.
If not s [...]
"autowiredEnabled": { "index": 6, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching t [...]
},
"bodyTypes": {
@@ -37,11 +37,11 @@
"consumerReply": { "carriers": [ "text", "list", "bytes", "stream", "file"
], "description": "A String, byte array, stream or file is converted to one
user message. A List may contain Strings or Maps with role (user or assistant)
and content. Content may be a String or an MCP content block." }
},
"properties": {
- "promptName": { "index": 0, "kind": "path", "displayName": "Prompt Name",
"group": "consumer", "label": "", "required": true, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "description": "The prompt name advertised to MCP clients." },
- "arguments": { "index": 1, "kind": "parameter", "displayName":
"Arguments", "group": "consumer", "label": "consumer", "required": false,
"type": "object", "javaType": "java.util.Map<java.lang.String,
java.lang.String>", "prefix": "argument.", "multiValue": true, "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Prompt arguments.
Configure [...]
- "description": { "index": 2, "kind": "parameter", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Human-readable
description of what this prompt provides. When omitted, defaults to the prompt
name." },
- "tags": { "index": 3, "kind": "parameter", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Comma-separated list of
tags used to group prompts. MCP servers select which prompts to expose using
these tags. W [...]
- "title": { "index": 4, "kind": "parameter", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "Optional display title
for MCP prompt listings." },
+ "promptName": { "index": 0, "kind": "path", "displayName": "Prompt Name",
"group": "consumer", "label": "", "required": true, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "description": "The name of the prompt, which MCP clients see
in prompts\/list and pass to prompts\/get. It must not contain a slash. A route
whose prompt name is already registered under one of its tags, or in the pool
of prompts without tags, fails to [...]
+ "arguments": { "index": 1, "kind": "parameter", "displayName":
"Arguments", "group": "consumer", "label": "consumer", "required": false,
"type": "object", "javaType": "java.util.Map<java.lang.String,
java.lang.String>", "prefix": "argument.", "multiValue": true, "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The arguments of the
prompt, [...]
+ "description": { "index": 2, "kind": "parameter", "displayName":
"Description", "group": "consumer", "label": "consumer", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The description of what
the prompt provides, which MCP clients see in prompts\/list and receive in t
[...]
+ "tags": { "index": 3, "kind": "parameter", "displayName": "Tags", "group":
"consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "A comma-separated list
of tags to register the prompt under. The MCP server exposes the prompts whose
tags match i [...]
+ "title": { "index": 4, "kind": "parameter", "displayName": "Title",
"group": "consumer", "label": "consumer", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.ai.prompt.AiPromptConfiguration",
"configurationField": "configuration", "description": "The human-readable title
of the prompt, which MCP clients can show in prompts\/list instead of the name.
If not [...]
"bridgeErrorHandler": { "index": 5, "kind": "parameter", "displayName":
"Bridge Error Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Allows for bridging the consumer to the
Camel routing Error Handler, which mean any exceptions (if possible) occurred
while the Camel consumer is trying to pickup incoming [...]
"exceptionHandler": { "index": 6, "kind": "parameter", "displayName":
"Exception Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "object", "javaType":
"org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.",
"deprecated": false, "autowired": false, "secret": false, "description": "To
let the consumer use a custom ExceptionHandler. Notice if the option
bridgeErrorHandler is enabled then this option is not in use. By def [...]
"exchangePattern": { "index": 7, "kind": "parameter", "displayName":
"Exchange Pattern", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "enum", "javaType":
"org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut" ],
"deprecated": false, "autowired": false, "secret": false, "description": "Sets
the exchange pattern when the consumer creates an exchange." }
diff --git
a/components/camel-ai/camel-ai-prompt/src/main/docs/ai-prompt-component.adoc
b/components/camel-ai/camel-ai-prompt/src/main/docs/ai-prompt-component.adoc
index 946dacc6914d..8ac05e0bd568 100644
--- a/components/camel-ai/camel-ai-prompt/src/main/docs/ai-prompt-component.adoc
+++ b/components/camel-ai/camel-ai-prompt/src/main/docs/ai-prompt-component.adoc
@@ -2,7 +2,7 @@
:doctitle: AI Prompt
:shortname: ai-prompt
:artifactid: camel-ai-prompt
-:description: Consumer endpoint that registers a Camel route as an MCP prompt.
+:description: Expose a Camel route as a prompt that MCP clients list and get
through the Camel MCP server.
:since: 4.24
:supportlevel: Preview
:tabs-sync-option:
diff --git
a/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptComponent.java
b/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptComponent.java
index b53c537c99b6..f4b919f3f245 100644
---
a/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptComponent.java
+++
b/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptComponent.java
@@ -40,7 +40,8 @@ import static
org.apache.camel.component.ai.prompt.AiPrompt.SCHEME;
@Component(SCHEME)
public class AiPromptComponent extends DefaultComponent {
- @Metadata(description = "The component configuration")
+ @Metadata(description = "The configuration that every endpoint starts
from. The endpoint copies it, and the"
+ + " options of the endpoint URI replace its
values.")
private AiPromptConfiguration configuration;
public AiPromptComponent() {
diff --git
a/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptConfiguration.java
b/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptConfiguration.java
index 0a36dd229909..3c9583e5a4de 100644
---
a/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptConfiguration.java
+++
b/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptConfiguration.java
@@ -35,23 +35,28 @@ import org.apache.camel.spi.UriParams;
public class AiPromptConfiguration implements Cloneable {
@Metadata(label = "consumer")
- @UriParam(description = "Comma-separated list of tags used to group
prompts. MCP servers select which prompts to "
- + "expose using these tags. When omitted, the
prompt goes into a default pool that is not "
- + "exposed to remote clients.")
+ @UriParam(description = "A comma-separated list of tags to register the
prompt under. The MCP server exposes the"
+ + " prompts whose tags match its tag patterns.
Without tags, the prompt goes into a default"
+ + " pool that the MCP server never exposes.")
private String tags;
@Metadata(label = "consumer")
- @UriParam(description = "Human-readable description of what this prompt
provides. When omitted, defaults to the "
- + "prompt name.")
+ @UriParam(description = "The description of what the prompt provides,
which MCP clients see in prompts/list and"
+ + " receive in the prompts/get result. If not set
or blank, the prompt name is used.")
private String description;
@Metadata(label = "consumer")
- @UriParam(description = "Optional display title for MCP prompt listings.")
+ @UriParam(description = "The human-readable title of the prompt, which MCP
clients can show in prompts/list instead"
+ + " of the name. If not set, the prompt has no
title.")
private String title;
@Metadata(label = "consumer")
- @UriParam(description = "Prompt arguments. Configure each argument with
argument.NAME.description=TEXT and/or "
- + "argument.NAME.required=true or false. An
argument is declared by either option.",
+ @UriParam(description = "The arguments of the prompt, set as
argument.NAME.description=TEXT and"
+ + " argument.NAME.required=true or false, where
either option declares the argument NAME and an"
+ + " argument is optional by default. The route
receives each argument as a String header named"
+ + " NAME; undeclared arguments of a request are
ignored, and a request without a required"
+ + " argument is rejected before the route runs. A
NAME that starts with camel or"
+ + " org.apache.camel. in any case is not allowed.",
prefix = "argument.", multiValue = true)
private Map<String, String> arguments;
diff --git
a/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptEndpoint.java
b/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptEndpoint.java
index aea26e4bc3ad..6c566ffde75c 100644
---
a/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptEndpoint.java
+++
b/components/camel-ai/camel-ai-prompt/src/main/java/org/apache/camel/component/ai/prompt/AiPromptEndpoint.java
@@ -32,7 +32,7 @@ import org.apache.camel.support.DefaultEndpoint;
import static org.apache.camel.component.ai.prompt.AiPrompt.SCHEME;
/**
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through the
Camel MCP server.
*
* @since 4.24
*/
@@ -56,7 +56,9 @@ import static
org.apache.camel.component.ai.prompt.AiPrompt.SCHEME;
public class AiPromptEndpoint extends DefaultEndpoint {
@Metadata(required = true)
- @UriPath(description = "The prompt name advertised to MCP clients.")
+ @UriPath(description = "The name of the prompt, which MCP clients see in
prompts/list and pass to prompts/get. It"
+ + " must not contain a slash. A route whose prompt
name is already registered under one of"
+ + " its tags, or in the pool of prompts without
tags, fails to start.")
private final String promptName;
@UriParam(description = "Prompt configuration including tags, description,
title and argument definitions.")
diff --git
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
index 005baf27a8d6..d581e1ba0d4f 100644
---
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
+++
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
@@ -88,7 +88,8 @@ public interface ComponentsBuilderFactory {
}
/**
* AI Prompt (camel-ai-prompt)
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through
+ * the Camel MCP server.
*
* Category: ai
* Since: 4.24
diff --git
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AiPromptComponentBuilderFactory.java
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AiPromptComponentBuilderFactory.java
index f7b39d0e4c3c..84a7b10a8dcd 100644
---
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AiPromptComponentBuilderFactory.java
+++
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AiPromptComponentBuilderFactory.java
@@ -24,7 +24,8 @@ import org.apache.camel.builder.component.ComponentBuilder;
import org.apache.camel.component.ai.prompt.AiPromptComponent;
/**
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through the
+ * Camel MCP server.
*
* Generated by camel build tools - do NOT edit this file!
*/
@@ -33,7 +34,8 @@ public interface AiPromptComponentBuilderFactory {
/**
* AI Prompt (camel-ai-prompt)
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through
+ * the Camel MCP server.
*
* Category: ai
* Since: 4.24
@@ -51,10 +53,14 @@ public interface AiPromptComponentBuilderFactory {
interface AiPromptComponentBuilder extends
ComponentBuilder<AiPromptComponent> {
/**
- * Prompt arguments. Configure each argument with
- * argument.NAME.description=TEXT and/or argument.NAME.required=true or
- * false. An argument is declared by either option. This is a
- * multi-value option with prefix: argument.
+ * The arguments of the prompt, set as argument.NAME.description=TEXT
+ * and argument.NAME.required=true or false, where either option
+ * declares the argument NAME and an argument is optional by default.
+ * The route receives each argument as a String header named NAME;
+ * undeclared arguments of a request are ignored, and a request without
+ * a required argument is rejected before the route runs. A NAME that
+ * starts with camel or org.apache.camel. in any case is not allowed.
+ * This is a multi-value option with prefix: argument.
*
* The option is a: <code>java.util.Map&lt;java.lang.String,
* java.lang.String&gt;</code> type.
@@ -98,7 +104,8 @@ public interface AiPromptComponentBuilderFactory {
}
/**
- * The component configuration.
+ * The configuration that every endpoint starts from. The endpoint
+ * copies it, and the options of the endpoint URI replace its values.
*
* The option is a:
*
<code>org.apache.camel.component.ai.prompt.AiPromptConfiguration</code>
type.
@@ -114,8 +121,9 @@ public interface AiPromptComponentBuilderFactory {
}
/**
- * Human-readable description of what this prompt provides. When
- * omitted, defaults to the prompt name.
+ * The description of what the prompt provides, which MCP clients see
in
+ * prompts/list and receive in the prompts/get result. If not set or
+ * blank, the prompt name is used.
*
* The option is a: <code>java.lang.String</code> type.
*
@@ -130,10 +138,10 @@ public interface AiPromptComponentBuilderFactory {
}
/**
- * Comma-separated list of tags used to group prompts. MCP servers
- * select which prompts to expose using these tags. When omitted, the
- * prompt goes into a default pool that is not exposed to remote
- * clients.
+ * A comma-separated list of tags to register the prompt under. The MCP
+ * server exposes the prompts whose tags match its tag patterns.
Without
+ * tags, the prompt goes into a default pool that the MCP server never
+ * exposes.
*
* The option is a: <code>java.lang.String</code> type.
*
@@ -148,7 +156,9 @@ public interface AiPromptComponentBuilderFactory {
}
/**
- * Optional display title for MCP prompt listings.
+ * The human-readable title of the prompt, which MCP clients can show
in
+ * prompts/list instead of the name. If not set, the prompt has no
+ * title.
*
* The option is a: <code>java.lang.String</code> type.
*
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
index 9fd8b041cdb2..c4fc645d286a 100644
---
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
@@ -178,7 +178,8 @@ public class StaticEndpointBuilders {
}
/**
* AI Prompt (camel-ai-prompt)
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through
+ * the Camel MCP server.
*
* Category: ai
* Since: 4.24
@@ -187,7 +188,10 @@ public class StaticEndpointBuilders {
* Syntax: <code>ai-prompt:promptName</code>
*
* Path parameter: promptName (required)
- * The prompt name advertised to MCP clients.
+ * The name of the prompt, which MCP clients see in prompts/list and pass
to
+ * prompts/get. It must not contain a slash. A route whose prompt name is
+ * already registered under one of its tags, or in the pool of prompts
+ * without tags, fails to start.
*
* @param path promptName
* @return the dsl builder
@@ -197,7 +201,8 @@ public class StaticEndpointBuilders {
}
/**
* AI Prompt (camel-ai-prompt)
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through
+ * the Camel MCP server.
*
* Category: ai
* Since: 4.24
@@ -206,7 +211,10 @@ public class StaticEndpointBuilders {
* Syntax: <code>ai-prompt:promptName</code>
*
* Path parameter: promptName (required)
- * The prompt name advertised to MCP clients.
+ * The name of the prompt, which MCP clients see in prompts/list and pass
to
+ * prompts/get. It must not contain a slash. A route whose prompt name is
+ * already registered under one of its tags, or in the pool of prompts
+ * without tags, fails to start.
*
* @param componentName to use a custom component name for the endpoint
* instead of the default name
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AiPromptEndpointBuilderFactory.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AiPromptEndpointBuilderFactory.java
index bc64810a3eef..7b02b90b1e3e 100644
---
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AiPromptEndpointBuilderFactory.java
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AiPromptEndpointBuilderFactory.java
@@ -27,7 +27,8 @@ import org.apache.camel.builder.EndpointProducerBuilder;
import org.apache.camel.builder.endpoint.AbstractEndpointBuilder;
/**
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get through the
+ * Camel MCP server.
*
* Generated by camel build tools - do NOT edit this file!
*/
@@ -45,10 +46,14 @@ public interface AiPromptEndpointBuilderFactory {
}
/**
- * Prompt arguments. Configure each argument with
- * argument.NAME.description=TEXT and/or argument.NAME.required=true or
- * false. An argument is declared by either option. This is a
- * multi-value option with prefix: argument.
+ * The arguments of the prompt, set as argument.NAME.description=TEXT
+ * and argument.NAME.required=true or false, where either option
+ * declares the argument NAME and an argument is optional by default.
+ * The route receives each argument as a String header named NAME;
+ * undeclared arguments of a request are ignored, and a request without
+ * a required argument is rejected before the route runs. A NAME that
+ * starts with camel or org.apache.camel. in any case is not allowed.
+ * This is a multi-value option with prefix: argument.
*
* The option is a: <code>java.util.Map<java.lang.String,
* java.lang.String></code> type.
@@ -67,10 +72,14 @@ public interface AiPromptEndpointBuilderFactory {
return this;
}
/**
- * Prompt arguments. Configure each argument with
- * argument.NAME.description=TEXT and/or argument.NAME.required=true or
- * false. An argument is declared by either option. This is a
- * multi-value option with prefix: argument.
+ * The arguments of the prompt, set as argument.NAME.description=TEXT
+ * and argument.NAME.required=true or false, where either option
+ * declares the argument NAME and an argument is optional by default.
+ * The route receives each argument as a String header named NAME;
+ * undeclared arguments of a request are ignored, and a request without
+ * a required argument is rejected before the route runs. A NAME that
+ * starts with camel or org.apache.camel. in any case is not allowed.
+ * This is a multi-value option with prefix: argument.
*
* The option is a: <code>java.util.Map<java.lang.String,
* java.lang.String></code> type.
@@ -88,8 +97,9 @@ public interface AiPromptEndpointBuilderFactory {
return this;
}
/**
- * Human-readable description of what this prompt provides. When
- * omitted, defaults to the prompt name.
+ * The description of what the prompt provides, which MCP clients see
in
+ * prompts/list and receive in the prompts/get result. If not set or
+ * blank, the prompt name is used.
*
* The option is a: <code>java.lang.String</code> type.
*
@@ -103,10 +113,10 @@ public interface AiPromptEndpointBuilderFactory {
return this;
}
/**
- * Comma-separated list of tags used to group prompts. MCP servers
- * select which prompts to expose using these tags. When omitted, the
- * prompt goes into a default pool that is not exposed to remote
- * clients.
+ * A comma-separated list of tags to register the prompt under. The MCP
+ * server exposes the prompts whose tags match its tag patterns.
Without
+ * tags, the prompt goes into a default pool that the MCP server never
+ * exposes.
*
* The option is a: <code>java.lang.String</code> type.
*
@@ -120,7 +130,9 @@ public interface AiPromptEndpointBuilderFactory {
return this;
}
/**
- * Optional display title for MCP prompt listings.
+ * The human-readable title of the prompt, which MCP clients can show
in
+ * prompts/list instead of the name. If not set, the prompt has no
+ * title.
*
* The option is a: <code>java.lang.String</code> type.
*
@@ -267,7 +279,8 @@ public interface AiPromptEndpointBuilderFactory {
public interface AiPromptBuilders {
/**
* AI Prompt (camel-ai-prompt)
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get
+ * through the Camel MCP server.
*
* Category: ai
* Since: 4.24
@@ -276,7 +289,10 @@ public interface AiPromptEndpointBuilderFactory {
* Syntax: <code>ai-prompt:promptName</code>
*
* Path parameter: promptName (required)
- * The prompt name advertised to MCP clients.
+ * The name of the prompt, which MCP clients see in prompts/list and
+ * pass to prompts/get. It must not contain a slash. A route whose
+ * prompt name is already registered under one of its tags, or in the
+ * pool of prompts without tags, fails to start.
*
* @param path promptName
* @return the dsl builder
@@ -286,7 +302,8 @@ public interface AiPromptEndpointBuilderFactory {
}
/**
* AI Prompt (camel-ai-prompt)
- * Consumer endpoint that registers a Camel route as an MCP prompt.
+ * Expose a Camel route as a prompt that MCP clients list and get
+ * through the Camel MCP server.
*
* Category: ai
* Since: 4.24
@@ -295,7 +312,10 @@ public interface AiPromptEndpointBuilderFactory {
* Syntax: <code>ai-prompt:promptName</code>
*
* Path parameter: promptName (required)
- * The prompt name advertised to MCP clients.
+ * The name of the prompt, which MCP clients see in prompts/list and
+ * pass to prompts/get. It must not contain a slash. A route whose
+ * prompt name is already registered under one of its tags, or in the
+ * pool of prompts without tags, fails to start.
*
* @param componentName to use a custom component name for the endpoint
* instead of the default name
diff --git a/tasks/component-descriptions.md b/tasks/component-descriptions.md
index 0baba6513b3d..e134a4910e6d 100644
--- a/tasks/component-descriptions.md
+++ b/tasks/component-descriptions.md
@@ -55,7 +55,7 @@ or removes its row.
| camel-a2a | a2a | |
| camel-activemq | activemq | |
| camel-activemq6 | activemq6 | |
-| camel-ai-prompt | ai-prompt | |
+| camel-ai-prompt | ai-prompt | yes |
| camel-ai-resource | ai-resource | |
| camel-ai-tool | ai-tool | |
| camel-alibaba-eventbridge | alibaba-eventbridge | yes |