jenkins d3cb6e9045 hermes(hux): add contract-only foundation for the chat UX program
Schemas, examples and a flag registry for the twelve HUX cards, a dependency-free
validator, the governance rules (memory ledger, autonomy matrix, friendly modes
mapped to real Switchyard routes, privacy defaults, suggestion gating, release
state machine) and the contract doc UI work codes against.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RNPhwu2bsaRNg3DETSAZoM
2026-08-23 22:30:41 -03:00

62 lines
2.7 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://hermes.bstein.dev/contracts/hux/v1/mode.schema.json",
"title": "HUX friendly mode intent",
"description": "Stable intent contract for Fast/Thoughtful/Research/Create/Private (HUX-06). A mode never names a vendor model; it names constraints that Switchyard resolves. The advanced drawer may pin an exact route id, which must exist in the Switchyard catalog.",
"type": "object",
"additionalProperties": false,
"required": ["schema", "mode", "label", "intent", "constraints", "switchyard"],
"properties": {
"schema": {"const": "hux.mode.v1"},
"mode": {"type": "string", "enum": ["fast", "thoughtful", "research", "create", "private"]},
"label": {"type": "string", "minLength": 1, "maxLength": 40},
"intent": {"type": "string", "minLength": 1, "maxLength": 400},
"constraints": {
"type": "object",
"additionalProperties": false,
"required": ["providers", "local_only", "effort", "tools", "memory", "citations_required", "retention"],
"properties": {
"providers": {"type": "array", "minItems": 1, "uniqueItems": true, "items": {"$ref": "common.schema.json#/$defs/provider"}},
"local_only": {"type": "boolean"},
"effort": {
"type": "object",
"additionalProperties": false,
"required": ["min", "max"],
"properties": {
"min": {"$ref": "common.schema.json#/$defs/effort"},
"max": {"$ref": "common.schema.json#/$defs/effort"}
}
},
"tools": {
"type": "object",
"additionalProperties": false,
"required": ["web", "shell", "artifacts", "delegate"],
"properties": {
"web": {"type": "string", "enum": ["required", "allowed", "denied"]},
"shell": {"type": "string", "enum": ["allowed", "denied"]},
"artifacts": {"type": "string", "enum": ["encouraged", "allowed", "denied"]},
"delegate": {"type": "string", "enum": ["allowed", "denied"]}
}
},
"memory": {
"type": "object",
"additionalProperties": false,
"required": ["read", "write"],
"properties": {"read": {"type": "boolean"}, "write": {"type": "boolean"}}
},
"citations_required": {"type": "boolean"},
"retention": {"type": "string", "enum": ["default", "ephemeral"]}
}
},
"switchyard": {
"type": "object",
"additionalProperties": false,
"required": ["route_id"],
"properties": {
"route_id": {"type": "string", "pattern": "^atlas/(auto|manual|fallback|worker)/[a-z0-9/-]+$"},
"override_route_id": {"type": "string", "pattern": "^atlas/(auto|manual)/[a-z0-9/-]+$"}
}
}
}
}