1{
  2  "$schema": "https://json-schema.org/draft/2020-12/schema",
  3  "$defs": {
  4    "Agent": {
  5      "properties": {
  6        "id": {
  7          "type": "string",
  8          "enum": [
  9            "coder",
 10            "task",
 11            "coder",
 12            "task"
 13          ],
 14          "title": "Agent ID",
 15          "description": "Unique identifier for the agent"
 16        },
 17        "name": {
 18          "type": "string",
 19          "title": "Name",
 20          "description": "Display name of the agent"
 21        },
 22        "description": {
 23          "type": "string",
 24          "title": "Description",
 25          "description": "Description of what the agent does"
 26        },
 27        "disabled": {
 28          "type": "boolean",
 29          "title": "Disabled",
 30          "description": "Whether this agent is disabled",
 31          "default": false
 32        },
 33        "model": {
 34          "type": "string",
 35          "enum": [
 36            "large",
 37            "small",
 38            "large",
 39            "small"
 40          ],
 41          "title": "Model Type",
 42          "description": "Type of model to use (large or small)"
 43        },
 44        "allowed_tools": {
 45          "items": {
 46            "type": "string",
 47            "enum": [
 48              "bash",
 49              "edit",
 50              "fetch",
 51              "glob",
 52              "grep",
 53              "ls",
 54              "sourcegraph",
 55              "view",
 56              "write",
 57              "agent"
 58            ]
 59          },
 60          "type": "array",
 61          "title": "Allowed Tools",
 62          "description": "List of tools this agent is allowed to use (if nil all tools are allowed)"
 63        },
 64        "allowed_mcp": {
 65          "additionalProperties": {
 66            "items": {
 67              "type": "string"
 68            },
 69            "type": "array"
 70          },
 71          "type": "object",
 72          "title": "Allowed MCP",
 73          "description": "Map of MCP servers this agent can use and their allowed tools"
 74        },
 75        "allowed_lsp": {
 76          "items": {
 77            "type": "string"
 78          },
 79          "type": "array",
 80          "title": "Allowed LSP",
 81          "description": "List of LSP servers this agent can use (if nil all LSPs are allowed)"
 82        },
 83        "context_paths": {
 84          "items": {
 85            "type": "string"
 86          },
 87          "type": "array",
 88          "title": "Context Paths",
 89          "description": "Custom context paths for this agent (additive to global context paths)"
 90        }
 91      },
 92      "type": "object",
 93      "required": [
 94        "model"
 95      ]
 96    },
 97    "LSPConfig": {
 98      "properties": {
 99        "enabled": {
100          "type": "boolean",
101          "title": "Enabled",
102          "description": "Whether this LSP server is enabled",
103          "default": true
104        },
105        "command": {
106          "type": "string",
107          "title": "Command",
108          "description": "Command to execute for the LSP server"
109        },
110        "args": {
111          "items": {
112            "type": "string"
113          },
114          "type": "array",
115          "title": "Arguments",
116          "description": "Command line arguments for the LSP server"
117        },
118        "options": {
119          "title": "Options",
120          "description": "LSP server specific options"
121        }
122      },
123      "type": "object",
124      "required": [
125        "command"
126      ]
127    },
128    "MCP": {
129      "properties": {
130        "command": {
131          "type": "string",
132          "title": "Command",
133          "description": "Command to execute for stdio MCP servers"
134        },
135        "env": {
136          "items": {
137            "type": "string"
138          },
139          "type": "array",
140          "title": "Environment",
141          "description": "Environment variables for the MCP server"
142        },
143        "args": {
144          "items": {
145            "type": "string"
146          },
147          "type": "array",
148          "title": "Arguments",
149          "description": "Command line arguments for the MCP server"
150        },
151        "type": {
152          "type": "string",
153          "enum": [
154            "stdio",
155            "sse",
156            "stdio",
157            "sse"
158          ],
159          "title": "Type",
160          "description": "Type of MCP connection",
161          "default": "stdio"
162        },
163        "url": {
164          "type": "string",
165          "title": "URL",
166          "description": "URL for SSE MCP servers"
167        },
168        "headers": {
169          "additionalProperties": {
170            "type": "string"
171          },
172          "type": "object",
173          "title": "Headers",
174          "description": "HTTP headers for SSE MCP servers"
175        }
176      },
177      "type": "object",
178      "required": [
179        "command",
180        "type"
181      ]
182    },
183    "Model": {
184      "properties": {
185        "id": {
186          "type": "string",
187          "title": "Model ID",
188          "description": "Unique identifier for the model"
189        },
190        "name": {
191          "type": "string",
192          "title": "Model Name",
193          "description": "Display name of the model"
194        },
195        "cost_per_1m_in": {
196          "type": "number",
197          "minimum": 0,
198          "title": "Input Cost",
199          "description": "Cost per 1 million input tokens"
200        },
201        "cost_per_1m_out": {
202          "type": "number",
203          "minimum": 0,
204          "title": "Output Cost",
205          "description": "Cost per 1 million output tokens"
206        },
207        "cost_per_1m_in_cached": {
208          "type": "number",
209          "minimum": 0,
210          "title": "Cached Input Cost",
211          "description": "Cost per 1 million cached input tokens"
212        },
213        "cost_per_1m_out_cached": {
214          "type": "number",
215          "minimum": 0,
216          "title": "Cached Output Cost",
217          "description": "Cost per 1 million cached output tokens"
218        },
219        "context_window": {
220          "type": "integer",
221          "minimum": 1,
222          "title": "Context Window",
223          "description": "Maximum context window size in tokens"
224        },
225        "default_max_tokens": {
226          "type": "integer",
227          "minimum": 1,
228          "title": "Default Max Tokens",
229          "description": "Default maximum tokens for responses"
230        },
231        "can_reason": {
232          "type": "boolean",
233          "title": "Can Reason",
234          "description": "Whether the model supports reasoning capabilities"
235        },
236        "reasoning_effort": {
237          "type": "string",
238          "title": "Reasoning Effort",
239          "description": "Default reasoning effort level for reasoning models"
240        },
241        "has_reasoning_effort": {
242          "type": "boolean",
243          "title": "Has Reasoning Effort",
244          "description": "Whether the model supports reasoning effort configuration"
245        },
246        "supports_attachments": {
247          "type": "boolean",
248          "title": "Supports Images",
249          "description": "Whether the model supports image attachments"
250        }
251      },
252      "type": "object",
253      "required": [
254        "id",
255        "name",
256        "cost_per_1m_out_cached",
257        "context_window",
258        "default_max_tokens",
259        "can_reason",
260        "reasoning_effort",
261        "has_reasoning_effort",
262        "supports_attachments"
263      ]
264    },
265    "Options": {
266      "properties": {
267        "context_paths": {
268          "items": {
269            "type": "string"
270          },
271          "type": "array",
272          "title": "Context Paths",
273          "description": "List of paths to search for context files",
274          "default": [
275            ".github/copilot-instructions.md",
276            ".cursorrules",
277            ".cursor/rules/",
278            "CLAUDE.md",
279            "CLAUDE.local.md",
280            "GEMINI.md",
281            "gemini.md",
282            "crush.md",
283            "crush.local.md",
284            "Crush.md",
285            "Crush.local.md",
286            "CRUSH.md",
287            "CRUSH.local.md"
288          ]
289        },
290        "tui": {
291          "$ref": "#/$defs/TUIOptions",
292          "title": "TUI Options",
293          "description": "Terminal UI configuration options"
294        },
295        "debug": {
296          "type": "boolean",
297          "title": "Debug",
298          "description": "Enable debug logging",
299          "default": false
300        },
301        "debug_lsp": {
302          "type": "boolean",
303          "title": "Debug LSP",
304          "description": "Enable LSP debug logging",
305          "default": false
306        },
307        "disable_auto_summarize": {
308          "type": "boolean",
309          "title": "Disable Auto Summarize",
310          "description": "Disable automatic conversation summarization",
311          "default": false
312        },
313        "data_directory": {
314          "type": "string",
315          "title": "Data Directory",
316          "description": "Directory for storing application data",
317          "default": ".crush"
318        }
319      },
320      "type": "object"
321    },
322    "PreferredModel": {
323      "properties": {
324        "model_id": {
325          "type": "string",
326          "enum": [
327            "claude-opus-4-20250514",
328            "claude-sonnet-4-20250514",
329            "claude-3-7-sonnet-20250219",
330            "claude-3-5-haiku-20241022",
331            "claude-3-5-sonnet-20240620",
332            "claude-3-5-sonnet-20241022",
333            "codex-mini-latest",
334            "o4-mini",
335            "o3",
336            "o3-pro",
337            "gpt-4.1",
338            "gpt-4.1-mini",
339            "gpt-4.1-nano",
340            "gpt-4.5-preview",
341            "o3-mini",
342            "gpt-4o",
343            "gpt-4o-mini",
344            "gemini-2.5-pro",
345            "gemini-2.5-flash",
346            "codex-mini-latest",
347            "o4-mini",
348            "o3",
349            "o3-pro",
350            "gpt-4.1",
351            "gpt-4.1-mini",
352            "gpt-4.1-nano",
353            "gpt-4.5-preview",
354            "o3-mini",
355            "gpt-4o",
356            "gpt-4o-mini",
357            "anthropic.claude-opus-4-20250514-v1:0",
358            "anthropic.claude-sonnet-4-20250514-v1:0",
359            "anthropic.claude-3-7-sonnet-20250219-v1:0",
360            "anthropic.claude-3-5-haiku-20241022-v1:0",
361            "gemini-2.5-pro",
362            "gemini-2.5-flash",
363            "grok-3-mini",
364            "grok-3",
365            "mistralai/mistral-small-3.2-24b-instruct:free",
366            "mistralai/mistral-small-3.2-24b-instruct",
367            "minimax/minimax-m1:extended",
368            "minimax/minimax-m1",
369            "google/gemini-2.5-flash-lite-preview-06-17",
370            "google/gemini-2.5-flash",
371            "google/gemini-2.5-pro",
372            "openai/o3-pro",
373            "x-ai/grok-3-mini",
374            "x-ai/grok-3",
375            "mistralai/magistral-small-2506",
376            "mistralai/magistral-medium-2506",
377            "mistralai/magistral-medium-2506:thinking",
378            "google/gemini-2.5-pro-preview",
379            "deepseek/deepseek-r1-0528",
380            "anthropic/claude-opus-4",
381            "anthropic/claude-sonnet-4",
382            "mistralai/devstral-small:free",
383            "mistralai/devstral-small",
384            "google/gemini-2.5-flash-preview-05-20",
385            "google/gemini-2.5-flash-preview-05-20:thinking",
386            "openai/codex-mini",
387            "mistralai/mistral-medium-3",
388            "google/gemini-2.5-pro-preview-05-06",
389            "arcee-ai/caller-large",
390            "arcee-ai/virtuoso-large",
391            "arcee-ai/virtuoso-medium-v2",
392            "qwen/qwen3-30b-a3b",
393            "qwen/qwen3-14b",
394            "qwen/qwen3-32b",
395            "qwen/qwen3-235b-a22b",
396            "google/gemini-2.5-flash-preview",
397            "google/gemini-2.5-flash-preview:thinking",
398            "openai/o4-mini-high",
399            "openai/o3",
400            "openai/o4-mini",
401            "openai/gpt-4.1",
402            "openai/gpt-4.1-mini",
403            "openai/gpt-4.1-nano",
404            "x-ai/grok-3-mini-beta",
405            "x-ai/grok-3-beta",
406            "meta-llama/llama-4-maverick",
407            "meta-llama/llama-4-scout",
408            "all-hands/openhands-lm-32b-v0.1",
409            "google/gemini-2.5-pro-exp-03-25",
410            "deepseek/deepseek-chat-v3-0324:free",
411            "deepseek/deepseek-chat-v3-0324",
412            "mistralai/mistral-small-3.1-24b-instruct:free",
413            "mistralai/mistral-small-3.1-24b-instruct",
414            "ai21/jamba-1.6-large",
415            "ai21/jamba-1.6-mini",
416            "openai/gpt-4.5-preview",
417            "google/gemini-2.0-flash-lite-001",
418            "anthropic/claude-3.7-sonnet",
419            "anthropic/claude-3.7-sonnet:beta",
420            "anthropic/claude-3.7-sonnet:thinking",
421            "mistralai/mistral-saba",
422            "openai/o3-mini-high",
423            "google/gemini-2.0-flash-001",
424            "qwen/qwen-turbo",
425            "qwen/qwen-plus",
426            "qwen/qwen-max",
427            "openai/o3-mini",
428            "mistralai/mistral-small-24b-instruct-2501",
429            "deepseek/deepseek-r1-distill-llama-70b",
430            "deepseek/deepseek-r1",
431            "mistralai/codestral-2501",
432            "deepseek/deepseek-chat",
433            "openai/o1",
434            "x-ai/grok-2-1212",
435            "meta-llama/llama-3.3-70b-instruct",
436            "amazon/nova-lite-v1",
437            "amazon/nova-micro-v1",
438            "amazon/nova-pro-v1",
439            "openai/gpt-4o-2024-11-20",
440            "mistralai/mistral-large-2411",
441            "mistralai/mistral-large-2407",
442            "mistralai/pixtral-large-2411",
443            "thedrummer/unslopnemo-12b",
444            "anthropic/claude-3.5-haiku:beta",
445            "anthropic/claude-3.5-haiku",
446            "anthropic/claude-3.5-haiku-20241022:beta",
447            "anthropic/claude-3.5-haiku-20241022",
448            "anthropic/claude-3.5-sonnet:beta",
449            "anthropic/claude-3.5-sonnet",
450            "x-ai/grok-beta",
451            "mistralai/ministral-8b",
452            "mistralai/ministral-3b",
453            "nvidia/llama-3.1-nemotron-70b-instruct",
454            "google/gemini-flash-1.5-8b",
455            "meta-llama/llama-3.2-11b-vision-instruct",
456            "meta-llama/llama-3.2-3b-instruct",
457            "qwen/qwen-2.5-72b-instruct",
458            "mistralai/pixtral-12b",
459            "cohere/command-r-plus-08-2024",
460            "cohere/command-r-08-2024",
461            "microsoft/phi-3.5-mini-128k-instruct",
462            "nousresearch/hermes-3-llama-3.1-70b",
463            "openai/gpt-4o-2024-08-06",
464            "meta-llama/llama-3.1-405b-instruct",
465            "meta-llama/llama-3.1-70b-instruct",
466            "meta-llama/llama-3.1-8b-instruct",
467            "mistralai/mistral-nemo",
468            "openai/gpt-4o-mini",
469            "openai/gpt-4o-mini-2024-07-18",
470            "anthropic/claude-3.5-sonnet-20240620:beta",
471            "anthropic/claude-3.5-sonnet-20240620",
472            "mistralai/mistral-7b-instruct-v0.3",
473            "mistralai/mistral-7b-instruct:free",
474            "mistralai/mistral-7b-instruct",
475            "microsoft/phi-3-mini-128k-instruct",
476            "microsoft/phi-3-medium-128k-instruct",
477            "google/gemini-flash-1.5",
478            "openai/gpt-4o-2024-05-13",
479            "openai/gpt-4o",
480            "openai/gpt-4o:extended",
481            "meta-llama/llama-3-8b-instruct",
482            "meta-llama/llama-3-70b-instruct",
483            "mistralai/mixtral-8x22b-instruct",
484            "openai/gpt-4-turbo",
485            "google/gemini-pro-1.5",
486            "cohere/command-r-plus",
487            "cohere/command-r-plus-04-2024",
488            "cohere/command-r",
489            "anthropic/claude-3-haiku:beta",
490            "anthropic/claude-3-haiku",
491            "anthropic/claude-3-opus:beta",
492            "anthropic/claude-3-opus",
493            "anthropic/claude-3-sonnet:beta",
494            "anthropic/claude-3-sonnet",
495            "cohere/command-r-03-2024",
496            "mistralai/mistral-large",
497            "openai/gpt-3.5-turbo-0613",
498            "openai/gpt-4-turbo-preview",
499            "mistralai/mistral-small",
500            "mistralai/mistral-tiny",
501            "mistralai/mixtral-8x7b-instruct",
502            "openai/gpt-4-1106-preview",
503            "mistralai/mistral-7b-instruct-v0.1",
504            "openai/gpt-3.5-turbo-16k",
505            "openai/gpt-4",
506            "openai/gpt-4-0314"
507          ],
508          "title": "Model ID",
509          "description": "ID of the preferred model"
510        },
511        "provider": {
512          "type": "string",
513          "enum": [
514            "anthropic",
515            "openai",
516            "gemini",
517            "azure",
518            "bedrock",
519            "vertex",
520            "xai",
521            "openrouter"
522          ],
523          "title": "Provider",
524          "description": "Provider for the preferred model"
525        },
526        "reasoning_effort": {
527          "type": "string",
528          "title": "Reasoning Effort",
529          "description": "Override reasoning effort for this model"
530        },
531        "max_tokens": {
532          "type": "integer",
533          "minimum": 1,
534          "title": "Max Tokens",
535          "description": "Override max tokens for this model"
536        },
537        "think": {
538          "type": "boolean",
539          "title": "Think",
540          "description": "Enable thinking for reasoning models",
541          "default": false
542        }
543      },
544      "type": "object",
545      "required": [
546        "model_id",
547        "provider"
548      ]
549    },
550    "PreferredModels": {
551      "properties": {
552        "large": {
553          "$ref": "#/$defs/PreferredModel",
554          "title": "Large Model",
555          "description": "Preferred model configuration for large model type"
556        },
557        "small": {
558          "$ref": "#/$defs/PreferredModel",
559          "title": "Small Model",
560          "description": "Preferred model configuration for small model type"
561        }
562      },
563      "type": "object"
564    },
565    "ProviderConfig": {
566      "properties": {
567        "id": {
568          "type": "string",
569          "enum": [
570            "anthropic",
571            "openai",
572            "gemini",
573            "azure",
574            "bedrock",
575            "vertex",
576            "xai",
577            "openrouter"
578          ],
579          "title": "Provider ID",
580          "description": "Unique identifier for the provider"
581        },
582        "base_url": {
583          "type": "string",
584          "title": "Base URL",
585          "description": "Base URL for the provider API (required for custom providers)"
586        },
587        "provider_type": {
588          "type": "string",
589          "title": "Provider Type",
590          "description": "Type of the provider (openai"
591        },
592        "api_key": {
593          "type": "string",
594          "title": "API Key",
595          "description": "API key for authenticating with the provider"
596        },
597        "disabled": {
598          "type": "boolean",
599          "title": "Disabled",
600          "description": "Whether this provider is disabled",
601          "default": false
602        },
603        "extra_headers": {
604          "additionalProperties": {
605            "type": "string"
606          },
607          "type": "object",
608          "title": "Extra Headers",
609          "description": "Additional HTTP headers to send with requests"
610        },
611        "extra_params": {
612          "additionalProperties": {
613            "type": "string"
614          },
615          "type": "object",
616          "title": "Extra Parameters",
617          "description": "Additional provider-specific parameters"
618        },
619        "default_large_model": {
620          "type": "string",
621          "title": "Default Large Model",
622          "description": "Default model ID for large model type"
623        },
624        "default_small_model": {
625          "type": "string",
626          "title": "Default Small Model",
627          "description": "Default model ID for small model type"
628        },
629        "models": {
630          "items": {
631            "$ref": "#/$defs/Model"
632          },
633          "type": "array",
634          "title": "Models",
635          "description": "List of available models for this provider"
636        }
637      },
638      "type": "object",
639      "required": [
640        "provider_type"
641      ]
642    },
643    "TUIOptions": {
644      "properties": {
645        "compact_mode": {
646          "type": "boolean",
647          "title": "Compact Mode",
648          "description": "Enable compact mode for the TUI",
649          "default": false
650        }
651      },
652      "type": "object",
653      "required": [
654        "compact_mode"
655      ]
656    }
657  },
658  "properties": {
659    "models": {
660      "$ref": "#/$defs/PreferredModels",
661      "title": "Models",
662      "description": "Preferred model configurations for large and small model types"
663    },
664    "providers": {
665      "additionalProperties": {
666        "$ref": "#/$defs/ProviderConfig"
667      },
668      "type": "object",
669      "title": "Providers",
670      "description": "LLM provider configurations"
671    },
672    "agents": {
673      "additionalProperties": {
674        "$ref": "#/$defs/Agent"
675      },
676      "type": "object",
677      "title": "Agents",
678      "description": "Agent configurations for different tasks"
679    },
680    "mcp": {
681      "additionalProperties": {
682        "$ref": "#/$defs/MCP"
683      },
684      "type": "object",
685      "title": "MCP",
686      "description": "Model Control Protocol server configurations"
687    },
688    "lsp": {
689      "additionalProperties": {
690        "$ref": "#/$defs/LSPConfig"
691      },
692      "type": "object",
693      "title": "LSP",
694      "description": "Language Server Protocol configurations"
695    },
696    "options": {
697      "$ref": "#/$defs/Options",
698      "title": "Options",
699      "description": "General application options and settings"
700    }
701  },
702  "type": "object",
703  "title": "Crush Configuration",
704  "description": "Configuration schema for the Crush application"
705}