mirror of https://github.com/openclaw/openclaw.git
76 lines
2.2 KiB
JSON
76 lines
2.2 KiB
JSON
{
|
|
"id": "guardian",
|
|
"configSchema": {
|
|
"type": "object",
|
|
"properties": {
|
|
"model": {
|
|
"type": "string",
|
|
"description": "Guardian model in provider/model format (e.g. 'kimi/moonshot-v1-8k', 'ollama/llama3.1:8b', 'openai/gpt-4o-mini'). If omitted, uses the main agent model."
|
|
},
|
|
"watched_tools": {
|
|
"type": "array",
|
|
"items": { "type": "string" },
|
|
"default": [
|
|
"message_send",
|
|
"message",
|
|
"exec",
|
|
"write_file",
|
|
"Write",
|
|
"edit",
|
|
"gateway",
|
|
"gateway_config",
|
|
"cron",
|
|
"cron_add"
|
|
]
|
|
},
|
|
"timeout_ms": {
|
|
"type": "number",
|
|
"default": 20000,
|
|
"description": "Max wait for guardian API response in milliseconds"
|
|
},
|
|
"fallback_on_error": {
|
|
"type": "string",
|
|
"enum": ["allow", "block"],
|
|
"default": "allow",
|
|
"description": "Action when guardian API fails or times out"
|
|
},
|
|
"log_decisions": {
|
|
"type": "boolean",
|
|
"default": true,
|
|
"description": "Log all ALLOW/BLOCK decisions"
|
|
},
|
|
"mode": {
|
|
"type": "string",
|
|
"enum": ["enforce", "audit"],
|
|
"default": "enforce",
|
|
"description": "enforce = block disallowed calls; audit = log only"
|
|
},
|
|
"max_arg_length": {
|
|
"type": "number",
|
|
"default": 500,
|
|
"description": "Max characters of tool arguments to include (truncated)"
|
|
},
|
|
"max_recent_turns": {
|
|
"type": "number",
|
|
"default": 3,
|
|
"description": "Number of recent raw conversation turns to keep in the guardian prompt alongside the rolling summary"
|
|
},
|
|
"context_tools": {
|
|
"type": "array",
|
|
"items": { "type": "string" },
|
|
"default": [
|
|
"memory_search",
|
|
"memory_get",
|
|
"memory_recall",
|
|
"read",
|
|
"exec",
|
|
"web_fetch",
|
|
"web_search"
|
|
],
|
|
"description": "Tool names whose results are included in the guardian's conversation context. Only results from these tools are fed to the guardian — others are filtered out to save tokens."
|
|
}
|
|
},
|
|
"additionalProperties": false
|
|
}
|
|
}
|