Skip to main content
Glama

set_backend

Create, update, or remove a custom LLM backend by specifying its name, base URL, model, protocol, and local or cloud flag.

Instructions

Create, update, or remove a custom backend in custom_backends.json.

Args: name: Backend id, e.g. my_local_qwen. Lowercase letters, numbers, _ or -. base_url: OpenAI-compatible or Anthropic-compatible base URL. default_model: Model id. Empty means auto-resolve from /models where possible. local: 1 for local RAM-guarded backend, 0 for cloud backend. api_key_env: Optional environment variable name for the API key. protocol: openai or anthropic. remove: 1 removes the custom backend.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
localNo
removeNo
base_urlNo
protocolNoopenai
api_key_envNo
default_modelNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It explains key behaviors: create/update/remove via the 'remove' parameter, local vs cloud with 'local', and optional API key. However, it omits details about file modification persistence or required permissions, which would enhance transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is moderately concise and well-structured, with a clear opening sentence followed by parameter definitions in a bullet-like format. It is front-loaded and efficient, though slightly verbose with the 'Args:' prefix and multiple lines.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (7 parameters, create/update/delete operations, no annotations, and an output schema), the description covers essential aspects. It explains all parameters and actions, though it could optionally mention the return format or error handling, which is partially mitigated by the output schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It richly describes all 7 parameters, including allowed characters for 'name', auto-resolve for 'default_model', and protocol selection. This adds significant meaning beyond the schema's bare type/default fields.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Create, update, or remove a custom backend in custom_backends.json.' It uses a specific verb ('set') and resource ('backend'), effectively distinguishing from sibling tools like list_backends and refresh_backends which handle listing and refreshing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description lists parameters and actions but does not provide explicit guidance on when to use this tool versus alternatives. It lacks 'when-to-use' or 'when-not-to-use' statements, leaving the agent to infer usage context from the parameter descriptions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/HenryLinyy/local-llm-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server