OpenClaw Experimental Features and Flags
Learn what experimental flags mean in OpenClaw and which ones are currently documented. This page helps users decide when to use experimental features safely.
Read this when
- You see an `.experimental` config key and want to know whether it is stable
- You want to try preview runtime features without confusing them with normal defaults
- You want one place to find the currently documented experimental flags
Experimental features are preview surfaces that sit behind explicit flags. They require more real-world usage before they earn a stable default or a long-term contract.
- They are off unless a doc spells out a narrow automatic setup rule.
- Their shape and behavior can shift faster than stable config.
- Choose a stable path whenever one is available.
- Only roll out broadly after testing in a smaller environment first.
Currently documented flags
| Surface | Key | Use it when | More |
|---|---|---|---|
| Local model runtime | agents.defaults.experimental.localModelLean, agents.entries.*.experimental.localModelLean | A smaller or stricter local backend chokes on OpenClaw's full default tool surface | Local Models |
| Codex harness | plugins.entries.codex.config.appServer.experimental.sandboxExecServer | You want native Codex app-server 0.143.0 or newer to target an OpenClaw sandbox-backed exec-server instead of disabling Code Mode | Codex harness reference |
| Code Mode | tools.codeMode.enabled | You want compact code-orchestrated access to a hidden OpenClaw tool catalog | Code Mode |
| Cloud workers | cloudWorkers.desktop | You want to watch or control desktop-capable cloud worker environments from the Control UI | Cloud Worker Desktop |
| Swarm | tools.swarm.enabled | You want Code Mode scripts to orchestrate bounded groups of sub-agents in parallel | Swarm |
Control UI Labs
Head to Settings → Agents & Tools → Labs to handle experiments that come with a Control UI switch. Flipping a lab on or off patches the canonical Gateway config right away; the page only shows a restart hint when a feature demands one.
The Labs entries currently shipped are Code Mode, Swarm, Tool Search, Tool-loop detection, Lean tools for local models, Message audit metadata, and Cloud Worker Desktop. Message audit metadata and Cloud Worker Desktop need a Gateway restart; the other switches normally apply to future agent runs with no restart.
Local model lean mode
Each turn, agents.defaults.experimental.localModelLean: true removes heavyweight optional tools from the agent's direct surface: browser, cron, message, image_generate, music_generate, video_generate, tts, and pdf. Tools that are explicitly allowed or needed for delivery stay available, though Tool Search may catalog them rather than exposing them directly. Lean mode also defaults plugin/MCP/client catalogs to structured Tool Search (tool_search, tool_describe, tool_call) when tools.toolSearch is not already set. To scope this to a single agent, use agents.entries.*.experimental.localModelLean.
During onboarding, a verified ollama or lmstudio inference route automatically sets agents.defaults.experimental.localModelLean: true when that value is missing. OpenClaw notes that the setting came from onboarding, so a later verified non-local route lifts only that automatic setting. An explicitly configured true or false is left untouched. Other self-hosted and OpenAI-compatible providers are not inferred from model names or URLs.
If you already tune Tool Search globally, OpenClaw leaves that config alone. Set tools.toolSearch: false to opt out of the lean-mode Tool Search default.
In structured tools mode, lean runs keep exec directly visible beside the Tool Search controls so coding-tuned local models can still pick their familiar shell path. This only alters schema visibility: normal tool policy, sandboxing, and exec approvals still apply. Explicit code and directory modes retain their usual compaction behavior.
Why these tools
These tools carry the biggest descriptions, the broadest parameter shapes, or the highest odds of distracting a small model from the usual coding and conversation path. On a small-context or stricter OpenAI-compatible backend that decides between:
- Tool schemas fitting the prompt vs. pushing out conversation history.
- The model selecting the right tool vs. producing malformed tool calls from too many similar schemas.
- The Chat Completions adapter staying within structured-output limits vs. a 400 on tool-call payload size.
Removing them only shortens the direct tool list. The model still has read, write, edit, exec, apply_patch, image understanding, web search/fetch (when configured), memory, and session/agent tools. Extra catalogs stay reachable through Tool Search unless you set tools.toolSearch: false; explicit tool allows can opt a lean agent back into a trimmed workflow.
When to turn it on
Turn on lean mode once you have confirmed the model can reach the Gateway but full agent turns misbehave:
openclaw infer model run --gateway --model <ref> --prompt "Reply with exactly: pong"succeeds.- A normal agent turn fails with malformed tool calls, oversized prompts, or the model ignoring its tools.
- Toggling
localModelLean: trueclears the failure.
When to leave it off
If your backend handles the full default runtime cleanly, keep this off. It is a workaround for local stacks that need a smaller tool surface, not a default for hosted models or well-resourced local rigs.
Lean mode does not replace tools.profile, tools.allow/tools.deny, or the model compat.supportsTools: false escape hatch. For a permanent narrower tool surface on a specific agent, prefer those stable knobs.
Enable
{
agents: {
defaults: {
experimental: {
localModelLean: true,
},
},
},
}
For one agent only:
{
agents: {
entries: {
local: {
default: true,
model: "lmstudio/gemma-4-e4b-it",
experimental: {
localModelLean: true,
},
},
},
},
}
Restart the Gateway once the flag has been changed. With lean filtering, browser, cron, message, image_generate, music_generate, video_generate, tts, and pdf are removed unless you keep them explicitly using tools.allow or tools.alsoAllow; preserved tools might still be cataloged by Tool Search rather than being directly exposed.
Experimental does not mean hidden
Any experimental feature must be clearly labeled as such in both its documentation and the config path, rather than appearing as a normal, stable-looking option.