Skip to content
Archee Docs

Search and execute

The two tools Archee MCP exposes, their inputs and what a result contains.

Archee MCP has two tools. Instead of one tool per function, the agent finds functions with search and composes them in one Python program with execute. That means fewer round trips, and the agent can loop, branch and combine results like any program.

search: Search the Archee SDK for functions, calculations and standards. Returns Python stubs with signatures, units, examples and credit prices. Free. Call this first, then send one program to execute.

Inputs:

  • query (string): a function name, a calculation or a standard, in English or Vietnamese.
  • limit (integer, 1 to 20): how many entries to return. The default is 5.
  • kind (optional): restrict to one kind of entry.
search(query="bearing life", limit=3)

execute

execute: Run a Python program in an isolated sandbox with the archee SDK (import archee). The last expression or return value is the result. Compose many SDK calls in one program and return only what you need. Metered in credits per sandbox second and priced SDK calls.

Inputs:

  • code (string, up to 50 KB): the program. Its last expression, or an explicit return, is the result.
  • project (optional string): a project slug or id. Omit it to use your scratch project.
  • timeout_s (integer, 1 to 120): the wall-clock limit in seconds. The default is 30.
import archee

key = archee.standards.lookup("key", d=40)
bearing = archee.standards.lookup("bearing", d=40, type="deep_groove", series="light")
{"key": key, "bearing": bearing}

The result

  • ok says whether the program finished without an error.
  • result is the value of the last expression, as JSON.
  • stdout is what the program printed.
  • error holds the error code, message, hint and retryable when ok is false.
  • timed_out is true when the time limit stopped the program, and absent otherwise.
  • files_changed lists the files the program wrote in the project.
  • evidence_ids are the citations behind the values.
  • credits is what the call cost.
  • duration_ms is how long it ran.
  • call_id is what to quote when you ask for help.

:::note Long output is cut in the middle. The head and the tail are kept with a marker between them. Return less, or write large data to a file and return its link. :::

The sandbox

Each program runs in its own isolated sandbox; Security and privacy explains what that means. When the time limit passes the program is stopped. For longer work, use archee.agent.run and poll archee.runs.get in a later call.