LLM task
기준일: 2026-07-26
난이도: 중급
공식 기준: LLM task
개요
이 페이지는 OpenClaw LLM task 도구(파라미터, 권한, 설정, CLI)를 공식 문서 기준으로 정리합니다.
공식 요약: JSON-only LLM tasks for workflows (optional plugin tool)
도구 가시성은 profile / allow·deny policy / sandbox / channel 권한에 따라 달라집니다. 최신 스키마는 항상 공식 문서를 우선합니다.
공식 문서 기반 상세
아래는 공식 tools/llm-task 문서를 정리한 내용입니다. 코드 블록, 파라미터 이름, 기본값은 원문 그대로입니다.
llm-task is a bundled optional plugin tool that runs a single JSON-only
LLM call and returns structured output, optionally validated against a JSON
Schema. It gives workflow engines like Lobster an LLM step without custom
OpenClaw code per workflow.
Enable
- Enable the plugin:
{
"plugins": {
"entries": {
"llm-task": { "enabled": true }
}
}
}
- Allow the tool:
{
"tools": {
"alsoAllow": ["llm-task"]
}
}
alsoAllow adds llm-task on top of the active tool profile without
restricting other core tools. Use tools.allow only if you want a restrictive
allowlist mode instead.
Config (optional)
{
"plugins": {
"entries": {
"llm-task": {
"enabled": true,
"config": {
"defaultProvider": "openai",
"defaultModel": "gpt-5.6-sol",
"defaultAuthProfileId": "main",
"allowedModels": ["openai/gpt-5.6-sol"],
"maxTokens": 800,
"timeoutMs": 30000
}
}
}
}
}
allowedModels is an allowlist of provider/model strings; a request for any
other model is rejected. All other keys are per-call fallbacks used when the
tool call omits that parameter.
Tool parameters
| Parameter | Type | Notes |
|---|---|---|
prompt |
string | Required. Task instruction for the LLM. |
input |
any | Optional payload; serialized to JSON and appended to the prompt. |
schema |
object | Optional JSON Schema the parsed output must validate against. |
provider |
string | Overrides defaultProvider / the agent's default provider. |
model |
string | Overrides defaultModel; accepts bare model ids, aliases, or a provider/model ref (a duplicate provider prefix is stripped automatically). |
thinking |
string | Reasoning level (e.g. low, medium); must be one supported by the resolved model. |
authProfileId |
string | Overrides defaultAuthProfileId. |
temperature |
number | Best-effort; not all providers honor it. |
maxTokens |
number | Best-effort cap on output tokens. |
timeoutMs |
number | Run timeout; default 30000. |
Output
Returns details.json (the parsed, schema-validated JSON) plus details.provider
and details.model naming what actually ran.
Example: Lobster workflow step
Important limitation
The example below assumes the standalone Lobster CLI is running where
openclaw.invoke already has the correct gateway URL/auth context.
For the bundled embedded Lobster runner inside OpenClaw, this nested CLI pattern is not currently reliable:
openclaw.invoke --tool llm-task --action json --args-json '{ ... }'
Until embedded Lobster has a supported bridge for this flow, prefer either:
- direct
llm-tasktool calls outside Lobster, or - Lobster steps that do not rely on nested
openclaw.invokecalls.
Standalone Lobster CLI example:
openclaw.invoke --tool llm-task --action json --args-json '{
"prompt": "Given the input email, return intent and draft.",
"thinking": "low",
"input": {
"subject": "Hello",
"body": "Can you help?"
},
"schema": {
"type": "object",
"properties": {
"intent": { "type": "string" },
"draft": { "type": "string" }
},
"required": ["intent", "draft"],
"additionalProperties": false
}
}'
Safety notes
- JSON-only: the model is instructed to return only a JSON value, no code fences, no commentary.
- No tools: the underlying run has tools disabled, so the model cannot call out mid-task.
- Treat output as untrusted unless you validate it with
schema. - Put approvals before any side-effecting step (send, post, exec) that consumes this output.
관련 문서
검증 체크리스트
- 해당 tool이 활성 profile/policy에서 허용되는지 확인
- sandbox / elevated / host 실행 경로 정책을 이해했는지 확인
- 채널·에이전트 권한과 충돌하지 않는지 확인
- 공식 CLI/
--help와 문서 옵션이 버전과 맞는지 확인