-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpolycode.config.example.json
More file actions
66 lines (66 loc) · 3.33 KB
/
Copy pathpolycode.config.example.json
File metadata and controls
66 lines (66 loc) · 3.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
{
"$comment": "Copy to polycode.config.json (cwd) or ~/.config/polycode/config.json. Providers: openai | google | xai | muse | nvidia | qwen | anthropic. Run: poly --models. Contributor/training-tier ids require allowTrainingTiers: true.",
"system": "You are polycode, a terminal coding agent. Be concise. Use tools to inspect and edit the project. Prefer the smallest change that solves the task.",
"tiers": {
"cheap": { "provider": "google", "model": "gemini-2.5-flash" },
"strong": { "provider": "openai", "model": "gpt-5.5" },
"long": { "provider": "google", "model": "gemini-2.5-pro" }
},
"routing": {
"$comment": "strategy 'heuristic' (free) or 'model' (a cheap model picks the tier each turn). classifier defaults to the cheap tier.",
"strategy": "heuristic",
"classifier": { "provider": "google", "model": "gemini-2.5-flash" }
},
"sandbox": {
"$comment": "kind 'local' (host shell) or 'docker' (shell runs in an isolated container; file edits still land in the project). Use 'docker' for untrusted/hosted use.",
"kind": "local",
"image": "node:22-alpine",
"network": false,
"memory": "1g"
},
"session": {
"$comment": "Grok-shaped two-pass compaction. Auto-runs at this % of the model context window. /compact [focus] always runs. Cheap-tier provider writes the prefix summary.",
"autoCompactThresholdPercent": 85,
"keepRecentTurns": 8,
"keepRecentToolResults": 6
},
"profile": "local",
"web": true,
"compat": { "grokSkills": false },
"allowTrainingTiers": false,
"permissions": {
"$comment": "Claude-style patterns. Deny wins. .env / .git / .polycode are always protected outside yolo.",
"allow": ["Bash(npm test*)", "Bash(pnpm test*)"],
"deny": ["Edit(.env)", "Write(.env)"]
},
"hooks": {
"$comment": "Commands run through the sandbox. Nonzero PreToolUse / UserPromptSubmit exit denies. Vars: $TOOL_NAME $FILE $TOOL_INPUT $PROMPT $OUTPUT $SUBAGENT_TYPE. Events: SessionStart UserPromptSubmit PreToolUse PostToolUse SubagentStart SubagentStop Stop SessionEnd.",
"PreToolUse": [],
"UserPromptSubmit": []
},
"hosted": {
"$comment": "poly --serve. mode: plan (local) or acceptEdits (docker). yolo requires --insecure. Rate limit is per client IP.",
"mode": "plan",
"rateLimit": { "windowMs": 60000, "max": 30, "concurrent": 2 },
"maxBodyBytes": 1000000,
"maxMessageChars": 32000,
"trustProxy": false
},
"plugins": {
"$comment": "Discovered from .polycode/plugins/<name>/ and ~/.config/polycode/plugins/. disable skips names.",
"disable": []
},
"mcp": {
"$comment": "deferSchemas (default true): stub MCP JSON schemas until mcp_search or first call. allowRegistrySpawns: never let mcp.json run npx/npm (public registry execute).",
"deferSchemas": true,
"allowRegistrySpawns": false
},
"statusLine": {
"$comment": "Idle TUI status. Tokens: $model $mode $route $sandbox $ctx $ctx_seg $sum $sum_seg $mcp $mcp_seg $cost $cost_seg $cwd. Optional command runs through the sandbox.",
"template": "$model · $mode · route:$route · sandbox:$sandbox$ctx_seg$sum_seg$mcp_seg"
},
"providers": {
"$comment": "allow: omit to permit every catalog id. custom: extra OpenAI-compat endpoints (on-prem NIM, vLLM) with no code change. NVIDIA_BASE_URL / MUSE_BASE_URL / QWEN_BASE_URL override hosted URLs.",
"custom": []
}
}