Sign in
Docs
0%

Agents and automation

Models and sandbox tools for assistants (MCP)

The 6 tools an assistant can call for Models and sandbox over MCP: what each one does, the scopes it needs, its arguments and an example call.

Ask the platform's models for an answer or an embedding, see which models are up and the tokens left today, and which languages the code sandbox runs. An assistant calls these tools over MCP; they have no HTTP operation. Tools for assistants lists every product, and MCP shows how to connect an assistant.

llm_embed

Embed one or more texts with the tier's embedding model, for the tiers whose engine declares one (ModelInfo.embeds); FAILED_PRECONDITION otherwise.

Scopes: mcp:generate · reads only

ArgumentTypeWhat it is
inputslist of string
tierTIER_UNSPECIFIED or TIER_FAST or TIER_DEEP
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "llm_embed",
    "arguments": {
      "inputs": [
        "Failed deliveries are not retried."
      ]
    }
  }
}

llm_generate

Generate a completion for a conversation, streamed one chunk at a time. The last chunk has done set and carries the usage. Over REST this is server-sent events; on the multiplexed socket it is the same RPC by name. A tier runs a bounded number of generations at once with a bounded line behind them; beyond that, or after waiting too long in it, the answer is RESOURCE_EXHAUSTED starting "busy:", at once rather than after a minute. An agent with tools may call them before it answers: each call is a chunk with step set, run as the caller, bounded in number, in tokens (the same daily budget) and by the tier's deadline. Streams on the wire; this tool collects the stream into one answer (text joined, reasoning apart), up to the server's cap.

Scopes: mcp:generate · changes something · reaches outside the platform · collects a stream

ArgumentTypeWhat it is
agentstringTalk to this agent (an id from ListAgents): the service puts its instructions and knowledge in front of messages, which may then carry no system message of their own. Its tier and bounds apply where this request is silent. Empty: the bare model.
langstringThe language the visitor reads the site in ("en" or "hr"). With an agent, the service answers in it unless the visitor asks for another language or clearly writes in one; empty: English, until they do.
max_tokensintegerLongest completion, in tokens; clamped to the service's cap.
messageslist of object
pagestringThe page the visitor is reading (a path such as "/about/"): with an agent, that page's text is added when the agent's knowledge has it.
reasoningbooleanWhether the model may reason before it answers, for models that can. Unset leaves the engine's default. Reasoning spends the token budget before any answer appears; a short max_tokens with reasoning on can end with no answer at all.
session_idstringA session of the caller's to continue; empty starts a new one. Sessions are a record, not a memory: the request carries the whole conversation.
temperaturenumber
tierTIER_UNSPECIFIED or TIER_FAST or TIER_DEEPUnspecified: the service's default tier.
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "llm_generate",
    "arguments": {
      "messages": [
        {
          "content": "Summarise the open incidents in two sentences.",
          "role": "user"
        }
      ]
    }
  }
}

llm_get_budget

The caller's token budget for today.

Scopes: mcp:read · reads only

No arguments.

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "llm_get_budget",
    "arguments": {}
  }
}

llm_list_agents

The agents the service speaks as: who each is and whether the caller may talk to it. Never an agent's instructions.

Scopes: mcp:read · reads only

ArgumentTypeWhat it is
page_sizeintegerAt most 1000 (larger is coerced down); 0 means 1000.
page_tokenstringFrom the previous answer's next_page_token; "" for the first page.
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "llm_list_agents",
    "arguments": {
      "page_size": 20
    }
  }
}

llm_list_models

The tiers this service routes to, the model each serves, and whether the engine answered its last probe.

Scopes: mcp:read · reads only

ArgumentTypeWhat it is
page_sizeintegerAt most 1000 (larger is coerced down); 0 means 1000.
page_tokenstringFrom the previous answer's next_page_token; "" for the first page.
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "llm_list_models",
    "arguments": {
      "page_size": 20
    }
  }
}

runner_list_languages

The languages the runner runs, and the caller's runs left today.

Scopes: mcp:read · reads only

ArgumentTypeWhat it is
page_sizeintegerAt most 1000 (larger is coerced down); 0 means 1000.
page_tokenstringFrom the previous answer's next_page_token; "" for the first page.
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "runner_list_languages",
    "arguments": {
      "page_size": 20
    }
  }
}