MCP Description Providers
Manage the descriptions agents see for Hive Gateway MCP tools and fields in Langfuse or a custom service, and update them without redeploying.
The description of a tool is what an agent reads to decide when and how to call it, so it deserves the same iteration as a prompt. Description providers resolve tool and field descriptions at runtime from an external source, so you can refine them without changing the gateway configuration. The plugin ships a Langfuse provider and accepts custom ones.
Langfuse
Install the client and set the credentials the provider reads from the environment:
Register the provider under providers.langfuse and reference prompts from tools:
providers.langfuse accepts the Langfuse client parameters (publicKey, secretKey, baseUrl)
when you prefer not to use environment variables, plus defaults applied to every prompt lookup.
Each reference can pin a version or pass extra options (such as label or cacheTtlSeconds).
Descriptions are resolved when tools are listed, so editing a prompt in Langfuse takes effect on the
next tools/list. If Langfuse is unreachable, tools keep their fallback descriptions.
Referencing prompts from directives
Operation files can point at providers too, with provider: values of the form
<provider>:<prompt> or <provider>:<prompt>:<version>:
Labels and versions
A Langfuse label selects the prompt variant tagged for an environment. Labels are resolved with this precedence, most specific first:
- A per-request
?promptLabel=query parameter on the MCP endpoint - The tool’s
descriptionProvider.options.label - The provider’s
defaults.label
Custom providers
Any object with a fetchDescription method works as a provider. Register it under a name and
reference it with type set to that name:
fetchDescription receives the tool name, the reference configuration (the object from
descriptionProvider, so any extra fields you put there are available), and a context with the
resolved prompt label. It returns the description text.
Where descriptions come from
When several sources define a description for the same tool, the first match in this list wins:
descriptionProvider, resolved at runtime from Langfuse or a custom providertool.descriptionin the configuration- The
descriptionargument of the@mcpTooldirective - The description of the field in the GraphQL schema
The same order applies to variable descriptions set through
input.schema.properties.<variable>.descriptionProvider and description, and to output fields
through output.descriptionProviders.