on main help sign in
Merge pull request #623 from charmbracelet/schema

fix: add $schema to jsonschema

commitecbb93e0314083c40511fe0b94f438636293f90e authorKujtim Hoxha <kujtimii.h@gmail.com> dateThu 7 Aug 2025, 16:28 (1 year ago) parent6f60a98b0b85e6
2 files changed+5−1
internal/config/config.go+2−1 schema.json+3
internal/config/config.go+2−1
@@ -20,7 +20,6 @@ import (
2020const (
2121 appName = "crush"
2222 defaultDataDirectory = ".crush"
23− defaultLogLevel = "info"
2423)
2524
2625var defaultContextPaths = []string{
@@ -244,6 +243,8 @@ type Agent struct {
244243
245244// Config holds the configuration for crush.
246245type Config struct {
246+ Schema string `json:"$schema,omitempty"`
247+
247248 // We currently only support large/small as values here.
248249 Models map[SelectedModelType]SelectedModel `json:"models,omitempty" jsonschema:"description=Model configurations for different model types,example={\"large\":{\"model\":\"gpt-4o\",\"provider\":\"openai\"}}"`
249250
schema.json+3
@@ -5,6 +5,9 @@
55 "$defs": {
66 "Config": {
77 "properties": {
8+ "$schema": {
9+ "type": "string"
10+ },
811 "models": {
912 "additionalProperties": {
1013 "$ref": "#/$defs/SelectedModel"