An
llmAgent pairs a system prompt with a tool set. You define what the agent knows and what it can do — the LLM figures out how to do it.
This is the simplest way to build a Guild agent. No TypeScript logic required — just a prompt and tools.
Example
Input and output
EveryllmAgent uses the same fixed schemas:
Execution modes
llmAgent supports two modes:
"one-shot"— The agent processes the input, returns a single response, then terminates."multi-turn"— The agent continues interacting with the user until it calls the__submit__tool to signal task completion.
The __submit__ tool
In "multi-turn" mode, the runtime injects a __submit__ tool that the LLM must call to end the session. You do not declare it in your tools set.
- Purpose — Signals that the agent is done. The value the LLM passes to
__submit__becomes the agent’s final output. Earlier turns in the session are not returned to the caller. - Parallel calls —
__submit__must not be called in the same turn as any other tool. The runtime injects this rule into the system prompt; repeat it in your ownsystemPromptif the model tries to submit while still calling tools. - Completion — Until the LLM calls
__submit__, the session stays open for follow-up messages.
Tool recommendations
ui_notifyis included automatically. AdduserInterfaceToolsif the agent needsui_promptorui_ping.- Include
guildToolsif the agent uses tools that require authorization (e.g., GitHub access), so it can request credentials when needed.
Selecting specific tools
Usepick to include only the tools you need. See Selecting specific tools in the SDK reference.
When to use LLM agents
| Situation | Use llmAgent? |
|---|---|
| Task is expressible as a prompt + tools | Yes |
| You need deterministic, repeatable behavior | No — use coded agents |
| You want to minimize LLM token costs | No — use coded agents |