@gmickel/gno 1.25.1 → 1.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -5
- package/assets/skill/SKILL.md +37 -17
- package/browser-extension/artifacts/{gno-browser-clipper-v1.25.1.zip → gno-browser-clipper-v1.27.0.zip} +0 -0
- package/browser-extension/artifacts/gno-browser-clipper-v1.27.0.zip.sha256 +1 -0
- package/browser-extension/dist/manifest.json +1 -1
- package/package.json +1 -1
- package/spec/cli.md +161 -6
- package/spec/db/schema.sql +1 -1
- package/spec/evals-agentic.md +17 -0
- package/spec/mcp.md +25 -6
- package/spec/output-schemas/ask.schema.json +3 -0
- package/spec/output-schemas/project-profile-apply.schema.json +209 -0
- package/spec/output-schemas/project-profile-command.schema.json +160 -0
- package/spec/output-schemas/query-diagnose.schema.json +68 -5
- package/spec/output-schemas/search-results.schema.json +87 -1
- package/spec/output-schemas/setup-profile-result.schema.json +87 -0
- package/spec/output-schemas/status.schema.json +24 -0
- package/spec/project-profile.schema.json +303 -0
- package/src/app/context-runtime-contract.ts +4 -1
- package/src/app/context-runtime-types.ts +2 -0
- package/src/app/context-runtime.ts +26 -0
- package/src/app/verified-ask.ts +6 -1
- package/src/cli/commands/ask.ts +8 -1
- package/src/cli/commands/collection/add.ts +39 -45
- package/src/cli/commands/collection/remove.ts +28 -28
- package/src/cli/commands/collection/rename.ts +55 -73
- package/src/cli/commands/context/add.ts +37 -26
- package/src/cli/commands/context/rm.ts +47 -20
- package/src/cli/commands/init.ts +55 -125
- package/src/cli/commands/models/use.ts +43 -38
- package/src/cli/commands/profile-apply.ts +334 -0
- package/src/cli/commands/profile.ts +409 -0
- package/src/cli/commands/query.ts +6 -3
- package/src/cli/commands/search.ts +6 -1
- package/src/cli/commands/setup-activation.ts +205 -54
- package/src/cli/commands/setup-profile.ts +223 -0
- package/src/cli/commands/setup.ts +3 -0
- package/src/cli/commands/status.ts +43 -7
- package/src/cli/program.ts +112 -9
- package/src/config/content-types.ts +82 -0
- package/src/config/index.ts +11 -0
- package/src/config/project-profile.ts +374 -0
- package/src/config/saver.ts +16 -7
- package/src/config/types.ts +53 -2
- package/src/core/config-mutation.ts +138 -76
- package/src/core/config-write-lock.ts +89 -0
- package/src/core/context-compiler.ts +38 -1
- package/src/core/context-identity.ts +16 -0
- package/src/core/context-resolver.ts +2 -12
- package/src/core/folder-setup-planning.ts +6 -21
- package/src/core/folder-setup.ts +30 -2
- package/src/core/path-rules.ts +53 -0
- package/src/core/project-affinity-surface.ts +102 -7
- package/src/core/project-profile-apply-state.ts +268 -0
- package/src/core/project-profile-apply-validation.ts +95 -0
- package/src/core/project-profile-apply.ts +408 -0
- package/src/core/project-profile-canonical.ts +71 -0
- package/src/core/project-profile-diff.ts +302 -0
- package/src/core/project-profile-discovery.ts +519 -0
- package/src/core/project-profile-file.ts +37 -0
- package/src/core/project-profile-parser.ts +98 -0
- package/src/core/project-profile.ts +490 -0
- package/src/core/retrieval-replay-candidate.ts +6 -1
- package/src/ingestion/sync-options.ts +6 -2
- package/src/ingestion/sync.ts +21 -29
- package/src/ingestion/types.ts +1 -1
- package/src/ingestion/walker.ts +85 -44
- package/src/llm/cache.ts +21 -0
- package/src/mcp/tools/ask.ts +1 -0
- package/src/mcp/tools/index.ts +4 -0
- package/src/mcp/tools/query.ts +4 -2
- package/src/mcp/tools/search.ts +3 -0
- package/src/mcp/tools/status.ts +4 -0
- package/src/pipeline/content-type-boost.ts +264 -0
- package/src/pipeline/diagnose.ts +46 -19
- package/src/pipeline/explain.ts +15 -2
- package/src/pipeline/hybrid.ts +170 -74
- package/src/pipeline/rerank.ts +45 -15
- package/src/pipeline/search.ts +29 -11
- package/src/pipeline/types.ts +13 -4
- package/src/pipeline/vsearch.ts +30 -10
- package/src/sdk/client.ts +19 -3
- package/src/sdk/index.ts +1 -0
- package/src/sdk/types.ts +21 -5
- package/src/serve/config-sync.ts +2 -2
- package/src/serve/resident-runtime.ts +1 -0
- package/src/serve/routes/api.ts +18 -3
- package/src/serve/status-model.ts +2 -0
- package/src/serve/status.ts +4 -0
- package/src/store/migrations/021-multi-context-identity.ts +37 -0
- package/src/store/migrations/index.ts +2 -0
- package/src/store/sqlite/adapter.ts +86 -0
- package/src/store/types.ts +3 -2
- package/browser-extension/artifacts/gno-browser-clipper-v1.25.1.zip.sha256 +0 -1
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "gno://schemas/project-profile-apply@1.0",
|
|
4
|
+
"title": "GNO Project Profile Apply Result",
|
|
5
|
+
"description": "Deterministic, path-redacted receipt for create/update-only project profile application.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": [
|
|
9
|
+
"schemaVersion",
|
|
10
|
+
"command",
|
|
11
|
+
"status",
|
|
12
|
+
"applied",
|
|
13
|
+
"discovery",
|
|
14
|
+
"receipt",
|
|
15
|
+
"diagnostics"
|
|
16
|
+
],
|
|
17
|
+
"properties": {
|
|
18
|
+
"schemaVersion": { "const": "1.0" },
|
|
19
|
+
"command": { "const": "apply" },
|
|
20
|
+
"status": {
|
|
21
|
+
"enum": [
|
|
22
|
+
"applied",
|
|
23
|
+
"unchanged",
|
|
24
|
+
"invalid",
|
|
25
|
+
"not_found",
|
|
26
|
+
"disabled",
|
|
27
|
+
"failed"
|
|
28
|
+
]
|
|
29
|
+
},
|
|
30
|
+
"applied": { "type": "boolean" },
|
|
31
|
+
"discovery": { "$ref": "#/definitions/discovery" },
|
|
32
|
+
"receipt": {
|
|
33
|
+
"oneOf": [{ "$ref": "#/definitions/receipt" }, { "type": "null" }]
|
|
34
|
+
},
|
|
35
|
+
"diagnostics": {
|
|
36
|
+
"type": "array",
|
|
37
|
+
"items": { "$ref": "#/definitions/diagnostic" }
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"definitions": {
|
|
41
|
+
"diagnostic": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"additionalProperties": false,
|
|
44
|
+
"required": ["code", "severity", "path", "message", "remediation"],
|
|
45
|
+
"properties": {
|
|
46
|
+
"code": { "type": "string", "pattern": "^[A-Z][A-Z0-9_]*$" },
|
|
47
|
+
"severity": { "enum": ["error", "warning"] },
|
|
48
|
+
"path": { "type": "string" },
|
|
49
|
+
"message": { "type": "string", "minLength": 1 },
|
|
50
|
+
"remediation": { "type": "string", "minLength": 1 }
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
"discovery": {
|
|
54
|
+
"type": "object",
|
|
55
|
+
"additionalProperties": false,
|
|
56
|
+
"required": [
|
|
57
|
+
"status",
|
|
58
|
+
"source",
|
|
59
|
+
"boundary",
|
|
60
|
+
"profile",
|
|
61
|
+
"ambiguous",
|
|
62
|
+
"shadowedProfiles"
|
|
63
|
+
],
|
|
64
|
+
"properties": {
|
|
65
|
+
"status": { "enum": ["found", "not_found", "disabled", "error"] },
|
|
66
|
+
"source": { "enum": ["cwd", "override", "remote"] },
|
|
67
|
+
"boundary": {
|
|
68
|
+
"enum": ["repository", "filesystem", "explicit", "remote"]
|
|
69
|
+
},
|
|
70
|
+
"profile": {
|
|
71
|
+
"type": ["string", "null"],
|
|
72
|
+
"enum": [".gno/index.yml", null]
|
|
73
|
+
},
|
|
74
|
+
"ambiguous": { "type": "boolean" },
|
|
75
|
+
"shadowedProfiles": { "type": "integer", "minimum": 0 }
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"change": {
|
|
79
|
+
"type": "object",
|
|
80
|
+
"additionalProperties": false,
|
|
81
|
+
"required": ["action", "field", "destructive", "summary"],
|
|
82
|
+
"properties": {
|
|
83
|
+
"action": { "enum": ["add", "update", "repair", "review"] },
|
|
84
|
+
"field": { "type": "string", "minLength": 1 },
|
|
85
|
+
"destructive": { "const": false },
|
|
86
|
+
"summary": { "type": "string", "minLength": 1 }
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
"staleMapping": {
|
|
90
|
+
"type": "object",
|
|
91
|
+
"additionalProperties": false,
|
|
92
|
+
"required": ["collection", "reason", "choices"],
|
|
93
|
+
"properties": {
|
|
94
|
+
"collection": { "type": "string", "minLength": 1 },
|
|
95
|
+
"reason": { "enum": ["name_changed", "root_changed"] },
|
|
96
|
+
"choices": {
|
|
97
|
+
"type": "array",
|
|
98
|
+
"minItems": 2,
|
|
99
|
+
"maxItems": 2,
|
|
100
|
+
"items": { "enum": ["repair", "remove_explicitly"] }
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"diff": {
|
|
105
|
+
"type": "object",
|
|
106
|
+
"additionalProperties": false,
|
|
107
|
+
"required": ["status", "changes", "staleMappings"],
|
|
108
|
+
"properties": {
|
|
109
|
+
"status": { "enum": ["in_sync", "changes_required"] },
|
|
110
|
+
"changes": {
|
|
111
|
+
"type": "array",
|
|
112
|
+
"items": { "$ref": "#/definitions/change" }
|
|
113
|
+
},
|
|
114
|
+
"staleMappings": {
|
|
115
|
+
"type": "array",
|
|
116
|
+
"items": { "$ref": "#/definitions/staleMapping" }
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
"resource": {
|
|
121
|
+
"type": "object",
|
|
122
|
+
"additionalProperties": false,
|
|
123
|
+
"required": ["kind", "id", "disposition", "pendingIndexing"],
|
|
124
|
+
"properties": {
|
|
125
|
+
"kind": {
|
|
126
|
+
"enum": [
|
|
127
|
+
"capability",
|
|
128
|
+
"collection",
|
|
129
|
+
"content_type",
|
|
130
|
+
"contexts",
|
|
131
|
+
"profile_binding",
|
|
132
|
+
"project_affinity",
|
|
133
|
+
"stale_mapping"
|
|
134
|
+
]
|
|
135
|
+
},
|
|
136
|
+
"id": { "type": "string", "minLength": 1 },
|
|
137
|
+
"disposition": {
|
|
138
|
+
"enum": ["created", "reused", "updated", "skipped"]
|
|
139
|
+
},
|
|
140
|
+
"pendingIndexing": { "type": "boolean" }
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
"receipt": {
|
|
144
|
+
"type": "object",
|
|
145
|
+
"additionalProperties": false,
|
|
146
|
+
"required": [
|
|
147
|
+
"schemaVersion",
|
|
148
|
+
"command",
|
|
149
|
+
"status",
|
|
150
|
+
"profile",
|
|
151
|
+
"diff",
|
|
152
|
+
"resources",
|
|
153
|
+
"pendingIndexing",
|
|
154
|
+
"diagnostics"
|
|
155
|
+
],
|
|
156
|
+
"properties": {
|
|
157
|
+
"schemaVersion": { "const": "1.0" },
|
|
158
|
+
"command": { "const": "apply" },
|
|
159
|
+
"status": { "enum": ["applied", "unchanged"] },
|
|
160
|
+
"profile": {
|
|
161
|
+
"type": "object",
|
|
162
|
+
"additionalProperties": false,
|
|
163
|
+
"required": ["fingerprint"],
|
|
164
|
+
"properties": {
|
|
165
|
+
"fingerprint": {
|
|
166
|
+
"type": "string",
|
|
167
|
+
"pattern": "^[a-f0-9]{64}$"
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
},
|
|
171
|
+
"diff": { "$ref": "#/definitions/diff" },
|
|
172
|
+
"resources": {
|
|
173
|
+
"type": "array",
|
|
174
|
+
"items": { "$ref": "#/definitions/resource" }
|
|
175
|
+
},
|
|
176
|
+
"pendingIndexing": {
|
|
177
|
+
"type": "array",
|
|
178
|
+
"uniqueItems": true,
|
|
179
|
+
"items": { "type": "string", "minLength": 1 }
|
|
180
|
+
},
|
|
181
|
+
"diagnostics": {
|
|
182
|
+
"type": "array",
|
|
183
|
+
"items": { "$ref": "#/definitions/diagnostic" }
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
},
|
|
188
|
+
"allOf": [
|
|
189
|
+
{
|
|
190
|
+
"if": {
|
|
191
|
+
"properties": {
|
|
192
|
+
"status": { "enum": ["applied", "unchanged"] }
|
|
193
|
+
},
|
|
194
|
+
"required": ["status"]
|
|
195
|
+
},
|
|
196
|
+
"then": {
|
|
197
|
+
"properties": {
|
|
198
|
+
"receipt": { "$ref": "#/definitions/receipt" }
|
|
199
|
+
}
|
|
200
|
+
},
|
|
201
|
+
"else": {
|
|
202
|
+
"properties": {
|
|
203
|
+
"receipt": { "type": "null" },
|
|
204
|
+
"applied": { "const": false }
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
]
|
|
209
|
+
}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "gno://schemas/project-profile-command@1.0",
|
|
4
|
+
"title": "GNO Project Profile Read Command",
|
|
5
|
+
"description": "Deterministic, path-redacted result shared by profile check, show, and diff.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": [
|
|
9
|
+
"schemaVersion",
|
|
10
|
+
"command",
|
|
11
|
+
"status",
|
|
12
|
+
"valid",
|
|
13
|
+
"discovery",
|
|
14
|
+
"profile",
|
|
15
|
+
"diff",
|
|
16
|
+
"diagnostics"
|
|
17
|
+
],
|
|
18
|
+
"properties": {
|
|
19
|
+
"schemaVersion": { "const": "1.0" },
|
|
20
|
+
"command": { "enum": ["check", "show", "diff"] },
|
|
21
|
+
"status": { "enum": ["valid", "invalid", "not_found", "disabled"] },
|
|
22
|
+
"valid": { "type": "boolean" },
|
|
23
|
+
"discovery": { "$ref": "#/definitions/discovery" },
|
|
24
|
+
"profile": {
|
|
25
|
+
"oneOf": [{ "$ref": "#/definitions/profile" }, { "type": "null" }]
|
|
26
|
+
},
|
|
27
|
+
"diff": {
|
|
28
|
+
"oneOf": [{ "$ref": "#/definitions/diff" }, { "type": "null" }]
|
|
29
|
+
},
|
|
30
|
+
"diagnostics": {
|
|
31
|
+
"type": "array",
|
|
32
|
+
"items": { "$ref": "#/definitions/diagnostic" }
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"definitions": {
|
|
36
|
+
"diagnostic": {
|
|
37
|
+
"type": "object",
|
|
38
|
+
"additionalProperties": false,
|
|
39
|
+
"required": ["code", "severity", "path", "message", "remediation"],
|
|
40
|
+
"properties": {
|
|
41
|
+
"code": { "type": "string", "pattern": "^[A-Z][A-Z0-9_]*$" },
|
|
42
|
+
"severity": { "enum": ["error", "warning"] },
|
|
43
|
+
"path": { "type": "string" },
|
|
44
|
+
"message": { "type": "string", "minLength": 1 },
|
|
45
|
+
"remediation": { "type": "string", "minLength": 1 }
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"discovery": {
|
|
49
|
+
"type": "object",
|
|
50
|
+
"additionalProperties": false,
|
|
51
|
+
"required": [
|
|
52
|
+
"status",
|
|
53
|
+
"source",
|
|
54
|
+
"boundary",
|
|
55
|
+
"profile",
|
|
56
|
+
"ambiguous",
|
|
57
|
+
"shadowedProfiles"
|
|
58
|
+
],
|
|
59
|
+
"properties": {
|
|
60
|
+
"status": { "enum": ["found", "not_found", "disabled", "error"] },
|
|
61
|
+
"source": { "enum": ["cwd", "override", "remote"] },
|
|
62
|
+
"boundary": {
|
|
63
|
+
"enum": ["repository", "filesystem", "explicit", "remote"]
|
|
64
|
+
},
|
|
65
|
+
"profile": {
|
|
66
|
+
"type": ["string", "null"],
|
|
67
|
+
"enum": [".gno/index.yml", null]
|
|
68
|
+
},
|
|
69
|
+
"ambiguous": { "type": "boolean" },
|
|
70
|
+
"shadowedProfiles": { "type": "integer", "minimum": 0 }
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
"profile": {
|
|
74
|
+
"type": "object",
|
|
75
|
+
"additionalProperties": false,
|
|
76
|
+
"required": ["fingerprint", "desiredState"],
|
|
77
|
+
"properties": {
|
|
78
|
+
"fingerprint": {
|
|
79
|
+
"type": "string",
|
|
80
|
+
"pattern": "^[a-f0-9]{64}$"
|
|
81
|
+
},
|
|
82
|
+
"desiredState": {
|
|
83
|
+
"oneOf": [{ "type": "object" }, { "type": "null" }]
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"change": {
|
|
88
|
+
"type": "object",
|
|
89
|
+
"additionalProperties": false,
|
|
90
|
+
"required": ["action", "field", "destructive", "summary"],
|
|
91
|
+
"properties": {
|
|
92
|
+
"action": { "enum": ["add", "update", "repair", "review"] },
|
|
93
|
+
"field": { "type": "string", "minLength": 1 },
|
|
94
|
+
"destructive": { "type": "boolean" },
|
|
95
|
+
"summary": { "type": "string", "minLength": 1 }
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
"staleMapping": {
|
|
99
|
+
"type": "object",
|
|
100
|
+
"additionalProperties": false,
|
|
101
|
+
"required": ["collection", "reason", "choices"],
|
|
102
|
+
"properties": {
|
|
103
|
+
"collection": { "type": "string", "minLength": 1 },
|
|
104
|
+
"reason": { "enum": ["name_changed", "root_changed"] },
|
|
105
|
+
"choices": {
|
|
106
|
+
"type": "array",
|
|
107
|
+
"minItems": 2,
|
|
108
|
+
"maxItems": 2,
|
|
109
|
+
"items": { "enum": ["repair", "remove_explicitly"] }
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
"diff": {
|
|
114
|
+
"type": "object",
|
|
115
|
+
"additionalProperties": false,
|
|
116
|
+
"required": ["status", "changes", "staleMappings"],
|
|
117
|
+
"properties": {
|
|
118
|
+
"status": { "enum": ["in_sync", "changes_required"] },
|
|
119
|
+
"changes": {
|
|
120
|
+
"type": "array",
|
|
121
|
+
"items": { "$ref": "#/definitions/change" }
|
|
122
|
+
},
|
|
123
|
+
"staleMappings": {
|
|
124
|
+
"type": "array",
|
|
125
|
+
"items": { "$ref": "#/definitions/staleMapping" }
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
"allOf": [
|
|
131
|
+
{
|
|
132
|
+
"if": {
|
|
133
|
+
"properties": { "valid": { "const": true } },
|
|
134
|
+
"required": ["valid"]
|
|
135
|
+
},
|
|
136
|
+
"then": {
|
|
137
|
+
"properties": {
|
|
138
|
+
"status": { "const": "valid" },
|
|
139
|
+
"profile": { "$ref": "#/definitions/profile" }
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
"if": {
|
|
145
|
+
"properties": { "command": { "const": "diff" } },
|
|
146
|
+
"required": ["command"]
|
|
147
|
+
},
|
|
148
|
+
"then": {
|
|
149
|
+
"properties": {
|
|
150
|
+
"diff": {
|
|
151
|
+
"oneOf": [{ "$ref": "#/definitions/diff" }, { "type": "null" }]
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
"else": {
|
|
156
|
+
"properties": { "diff": { "type": "null" } }
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
]
|
|
160
|
+
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "gno://schemas/query-diagnose@1.
|
|
3
|
+
"$id": "gno://schemas/query-diagnose@1.2",
|
|
4
4
|
"title": "GNO Query Diagnose",
|
|
5
5
|
"type": "object",
|
|
6
6
|
"required": ["schemaVersion", "query", "target", "stages", "chunk", "meta"],
|
|
7
7
|
"properties": {
|
|
8
|
-
"schemaVersion": { "type": "string", "enum": ["1.0", "1.1"] },
|
|
8
|
+
"schemaVersion": { "type": "string", "enum": ["1.0", "1.1", "1.2"] },
|
|
9
9
|
"query": { "type": "string" },
|
|
10
10
|
"target": {
|
|
11
11
|
"type": "object",
|
|
@@ -149,11 +149,62 @@
|
|
|
149
149
|
},
|
|
150
150
|
"source": {
|
|
151
151
|
"type": ["string", "null"],
|
|
152
|
-
"enum": [
|
|
152
|
+
"enum": [
|
|
153
|
+
"cli_cwd",
|
|
154
|
+
"cli_explicit",
|
|
155
|
+
"cli_worktree",
|
|
156
|
+
"project_profile",
|
|
157
|
+
null
|
|
158
|
+
]
|
|
153
159
|
}
|
|
154
160
|
},
|
|
155
161
|
"additionalProperties": false
|
|
156
162
|
},
|
|
163
|
+
"contentTypeBoost": {
|
|
164
|
+
"type": "object",
|
|
165
|
+
"required": [
|
|
166
|
+
"baseScore",
|
|
167
|
+
"cappedContribution",
|
|
168
|
+
"combinedAuxiliaryApplied",
|
|
169
|
+
"combinedAuxiliaryCap",
|
|
170
|
+
"combinedAuxiliaryRequested",
|
|
171
|
+
"configuredFactor",
|
|
172
|
+
"contentType",
|
|
173
|
+
"finalScore",
|
|
174
|
+
"rawContribution",
|
|
175
|
+
"rawScore",
|
|
176
|
+
"rawScoreKind",
|
|
177
|
+
"ruleSource",
|
|
178
|
+
"rulesFingerprint"
|
|
179
|
+
],
|
|
180
|
+
"properties": {
|
|
181
|
+
"baseScore": { "type": "number", "minimum": 0, "maximum": 1 },
|
|
182
|
+
"cappedContribution": {
|
|
183
|
+
"type": "number",
|
|
184
|
+
"minimum": -0.05,
|
|
185
|
+
"maximum": 0.05
|
|
186
|
+
},
|
|
187
|
+
"combinedAuxiliaryApplied": {
|
|
188
|
+
"type": "number",
|
|
189
|
+
"minimum": -0.08,
|
|
190
|
+
"maximum": 0.08
|
|
191
|
+
},
|
|
192
|
+
"combinedAuxiliaryCap": { "type": "number", "const": 0.08 },
|
|
193
|
+
"combinedAuxiliaryRequested": { "type": "number" },
|
|
194
|
+
"configuredFactor": { "type": "number", "minimum": 0.5, "maximum": 2 },
|
|
195
|
+
"contentType": { "type": "string" },
|
|
196
|
+
"finalScore": { "type": "number", "minimum": 0, "maximum": 1 },
|
|
197
|
+
"rawContribution": { "type": "number" },
|
|
198
|
+
"rawScore": { "type": "number" },
|
|
199
|
+
"rawScoreKind": {
|
|
200
|
+
"type": "string",
|
|
201
|
+
"enum": ["bm25", "hybrid_blended", "normalized", "vector_distance"]
|
|
202
|
+
},
|
|
203
|
+
"ruleSource": { "type": "string", "enum": ["configured-id", "prefix"] },
|
|
204
|
+
"rulesFingerprint": { "type": "string", "pattern": "^[a-f0-9]{64}$" }
|
|
205
|
+
},
|
|
206
|
+
"additionalProperties": false
|
|
207
|
+
},
|
|
157
208
|
"chunk": {
|
|
158
209
|
"type": "object",
|
|
159
210
|
"required": ["seq", "startLine", "endLine", "language"],
|
|
@@ -193,7 +244,9 @@
|
|
|
193
244
|
"properties": { "schemaVersion": { "const": "1.0" } },
|
|
194
245
|
"required": ["schemaVersion"]
|
|
195
246
|
},
|
|
196
|
-
"then": {
|
|
247
|
+
"then": {
|
|
248
|
+
"properties": { "affinity": false, "contentTypeBoost": false }
|
|
249
|
+
}
|
|
197
250
|
},
|
|
198
251
|
{
|
|
199
252
|
"if": {
|
|
@@ -201,9 +254,19 @@
|
|
|
201
254
|
"required": ["schemaVersion"]
|
|
202
255
|
},
|
|
203
256
|
"then": {
|
|
204
|
-
"properties": { "affinity": {} },
|
|
257
|
+
"properties": { "affinity": {}, "contentTypeBoost": false },
|
|
205
258
|
"required": ["affinity"]
|
|
206
259
|
}
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
"if": {
|
|
263
|
+
"properties": { "schemaVersion": { "const": "1.2" } },
|
|
264
|
+
"required": ["schemaVersion"]
|
|
265
|
+
},
|
|
266
|
+
"then": {
|
|
267
|
+
"properties": { "contentTypeBoost": {} },
|
|
268
|
+
"required": ["contentTypeBoost"]
|
|
269
|
+
}
|
|
207
270
|
}
|
|
208
271
|
],
|
|
209
272
|
"additionalProperties": false
|
|
@@ -166,7 +166,78 @@
|
|
|
166
166
|
"type": "string"
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
|
-
}
|
|
169
|
+
},
|
|
170
|
+
"additionalProperties": false
|
|
171
|
+
},
|
|
172
|
+
"contentTypeBoost": {
|
|
173
|
+
"type": "object",
|
|
174
|
+
"required": [
|
|
175
|
+
"baseScore",
|
|
176
|
+
"cappedContribution",
|
|
177
|
+
"combinedAuxiliaryApplied",
|
|
178
|
+
"combinedAuxiliaryCap",
|
|
179
|
+
"combinedAuxiliaryRequested",
|
|
180
|
+
"configuredFactor",
|
|
181
|
+
"contentType",
|
|
182
|
+
"finalScore",
|
|
183
|
+
"rawContribution",
|
|
184
|
+
"rawScore",
|
|
185
|
+
"rawScoreKind",
|
|
186
|
+
"ruleSource",
|
|
187
|
+
"rulesFingerprint"
|
|
188
|
+
],
|
|
189
|
+
"properties": {
|
|
190
|
+
"baseScore": { "type": "number", "minimum": 0, "maximum": 1 },
|
|
191
|
+
"cappedContribution": {
|
|
192
|
+
"type": "number",
|
|
193
|
+
"minimum": -0.05,
|
|
194
|
+
"maximum": 0.05
|
|
195
|
+
},
|
|
196
|
+
"combinedAuxiliaryApplied": {
|
|
197
|
+
"type": "number",
|
|
198
|
+
"minimum": -0.08,
|
|
199
|
+
"maximum": 0.08
|
|
200
|
+
},
|
|
201
|
+
"combinedAuxiliaryCap": { "type": "number", "const": 0.08 },
|
|
202
|
+
"combinedAuxiliaryRequested": { "type": "number" },
|
|
203
|
+
"configuredFactor": { "type": "number", "minimum": 0.5, "maximum": 2 },
|
|
204
|
+
"contentType": { "type": "string" },
|
|
205
|
+
"finalScore": { "type": "number", "minimum": 0, "maximum": 1 },
|
|
206
|
+
"rawContribution": { "type": "number" },
|
|
207
|
+
"rawScore": { "type": "number" },
|
|
208
|
+
"rawScoreKind": {
|
|
209
|
+
"type": "string",
|
|
210
|
+
"enum": ["bm25", "hybrid_blended", "normalized", "vector_distance"]
|
|
211
|
+
},
|
|
212
|
+
"ruleSource": { "type": "string", "enum": ["configured-id", "prefix"] },
|
|
213
|
+
"rulesFingerprint": { "type": "string", "pattern": "^[a-f0-9]{64}$" }
|
|
214
|
+
},
|
|
215
|
+
"additionalProperties": false
|
|
216
|
+
},
|
|
217
|
+
"explainLine": {
|
|
218
|
+
"type": "object",
|
|
219
|
+
"required": ["stage", "message"],
|
|
220
|
+
"properties": {
|
|
221
|
+
"stage": { "type": "string" },
|
|
222
|
+
"message": { "type": "string" }
|
|
223
|
+
},
|
|
224
|
+
"additionalProperties": false
|
|
225
|
+
},
|
|
226
|
+
"explainResult": {
|
|
227
|
+
"type": "object",
|
|
228
|
+
"required": ["rank", "docid", "score"],
|
|
229
|
+
"properties": {
|
|
230
|
+
"rank": { "type": "integer", "minimum": 1 },
|
|
231
|
+
"docid": { "type": "string", "pattern": "^#[a-f0-9]{6,8}$" },
|
|
232
|
+
"score": { "type": "number" },
|
|
233
|
+
"fusionScore": { "type": "number" },
|
|
234
|
+
"bm25Score": { "type": "number" },
|
|
235
|
+
"vecScore": { "type": "number" },
|
|
236
|
+
"rerankScore": { "type": "number" },
|
|
237
|
+
"projectAffinity": { "type": "object" },
|
|
238
|
+
"contentTypeBoost": { "$ref": "#/$defs/contentTypeBoost" }
|
|
239
|
+
},
|
|
240
|
+
"additionalProperties": false
|
|
170
241
|
}
|
|
171
242
|
},
|
|
172
243
|
"properties": {
|
|
@@ -331,6 +402,21 @@
|
|
|
331
402
|
"type": "array",
|
|
332
403
|
"items": { "type": "string" },
|
|
333
404
|
"description": "Tags ANY filter applied (if any)"
|
|
405
|
+
},
|
|
406
|
+
"explain": {
|
|
407
|
+
"type": "object",
|
|
408
|
+
"required": ["lines", "results"],
|
|
409
|
+
"properties": {
|
|
410
|
+
"lines": {
|
|
411
|
+
"type": "array",
|
|
412
|
+
"items": { "$ref": "#/$defs/explainLine" }
|
|
413
|
+
},
|
|
414
|
+
"results": {
|
|
415
|
+
"type": "array",
|
|
416
|
+
"items": { "$ref": "#/$defs/explainResult" }
|
|
417
|
+
}
|
|
418
|
+
},
|
|
419
|
+
"additionalProperties": false
|
|
334
420
|
}
|
|
335
421
|
}
|
|
336
422
|
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "gno://schemas/setup-profile-result@1.0",
|
|
4
|
+
"title": "GNO Setup Profile Result",
|
|
5
|
+
"description": "Closed opt-in project-profile apply composition around verified setup and optional connectors.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": ["schemaVersion", "status", "profile", "setup", "connectors"],
|
|
9
|
+
"properties": {
|
|
10
|
+
"schemaVersion": { "const": "1.0" },
|
|
11
|
+
"status": {
|
|
12
|
+
"enum": ["completed", "completed_with_actions", "failed"]
|
|
13
|
+
},
|
|
14
|
+
"profile": {
|
|
15
|
+
"type": "object",
|
|
16
|
+
"additionalProperties": false,
|
|
17
|
+
"required": ["check", "apply"],
|
|
18
|
+
"properties": {
|
|
19
|
+
"check": {
|
|
20
|
+
"allOf": [
|
|
21
|
+
{ "$ref": "gno://schemas/project-profile-command@1.0" },
|
|
22
|
+
{
|
|
23
|
+
"type": "object",
|
|
24
|
+
"properties": { "command": { "const": "check" } },
|
|
25
|
+
"required": ["command"]
|
|
26
|
+
}
|
|
27
|
+
]
|
|
28
|
+
},
|
|
29
|
+
"apply": {
|
|
30
|
+
"oneOf": [
|
|
31
|
+
{ "$ref": "gno://schemas/project-profile-apply@1.0" },
|
|
32
|
+
{ "type": "null" }
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"setup": { "$ref": "gno://schemas/setup-command-result@1.0" },
|
|
38
|
+
"connectors": {
|
|
39
|
+
"$ref": "gno://schemas/setup-activation-result@1.0#/properties/connectors"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"allOf": [
|
|
43
|
+
{
|
|
44
|
+
"if": {
|
|
45
|
+
"properties": { "status": { "const": "completed" } },
|
|
46
|
+
"required": ["status"]
|
|
47
|
+
},
|
|
48
|
+
"then": {
|
|
49
|
+
"properties": {
|
|
50
|
+
"profile": {
|
|
51
|
+
"type": "object",
|
|
52
|
+
"properties": {
|
|
53
|
+
"check": {
|
|
54
|
+
"type": "object",
|
|
55
|
+
"properties": { "status": { "const": "valid" } }
|
|
56
|
+
},
|
|
57
|
+
"apply": {
|
|
58
|
+
"type": "object",
|
|
59
|
+
"properties": {
|
|
60
|
+
"status": { "enum": ["applied", "unchanged"] }
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
"setup": {
|
|
66
|
+
"type": "object",
|
|
67
|
+
"properties": { "status": { "const": "completed" } }
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"if": {
|
|
74
|
+
"properties": { "status": { "const": "failed" } },
|
|
75
|
+
"required": ["status"]
|
|
76
|
+
},
|
|
77
|
+
"then": {
|
|
78
|
+
"properties": {
|
|
79
|
+
"setup": {
|
|
80
|
+
"type": "object",
|
|
81
|
+
"properties": { "status": { "const": "failed" } }
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
]
|
|
87
|
+
}
|