| 1 | {
|
| 2 | "$schema": "https://json-schema.org/draft/2020-12/schema",
|
| 3 | "type": "object",
|
| 4 | "properties": {
|
| 5 | "protocolVersion": {
|
| 6 | "type": "string",
|
| 7 | "const": "0.1"
|
| 8 | },
|
| 9 | "consultationId": {
|
| 10 | "type": "string",
|
| 11 | "format": "uuid",
|
| 12 | "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
| 13 | },
|
| 14 | "caseId": {
|
| 15 | "type": "string",
|
| 16 | "format": "uuid",
|
| 17 | "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
| 18 | },
|
| 19 | "agentId": {
|
| 20 | "type": "string",
|
| 21 | "minLength": 1
|
| 22 | },
|
| 23 | "inputDigest": {
|
| 24 | "type": "string",
|
| 25 | "pattern": "^[a-zA-Z0-9_-]{43}$"
|
| 26 | },
|
| 27 | "analysis": {
|
| 28 | "type": "object",
|
| 29 | "properties": {
|
| 30 | "reply": {
|
| 31 | "type": "string",
|
| 32 | "minLength": 1,
|
| 33 | "maxLength": 5000
|
| 34 | },
|
| 35 | "situationSummary": {
|
| 36 | "type": "string",
|
| 37 | "minLength": 1,
|
| 38 | "maxLength": 2000
|
| 39 | },
|
| 40 | "disposition": {
|
| 41 | "type": "string",
|
| 42 | "enum": [
|
| 43 | "proceed",
|
| 44 | "proceed_with_caution",
|
| 45 | "gather_evidence",
|
| 46 | "modify_plan",
|
| 47 | "seek_approval",
|
| 48 | "do_not_proceed"
|
| 49 | ]
|
| 50 | },
|
| 51 | "riskTier": {
|
| 52 | "type": "string",
|
| 53 | "enum": [
|
| 54 | "low",
|
| 55 | "medium",
|
| 56 | "high",
|
| 57 | "critical"
|
| 58 | ]
|
| 59 | },
|
| 60 | "confidence": {
|
| 61 | "type": "number",
|
| 62 | "minimum": 0,
|
| 63 | "maximum": 1
|
| 64 | },
|
| 65 | "rationale": {
|
| 66 | "minItems": 1,
|
| 67 | "maxItems": 12,
|
| 68 | "type": "array",
|
| 69 | "items": {
|
| 70 | "type": "string",
|
| 71 | "minLength": 1,
|
| 72 | "maxLength": 1000
|
| 73 | }
|
| 74 | },
|
| 75 | "claims": {
|
| 76 | "maxItems": 20,
|
| 77 | "type": "array",
|
| 78 | "items": {
|
| 79 | "type": "object",
|
| 80 | "properties": {
|
| 81 | "claim": {
|
| 82 | "type": "string",
|
| 83 | "minLength": 1,
|
| 84 | "maxLength": 1000
|
| 85 | },
|
| 86 | "status": {
|
| 87 | "type": "string",
|
| 88 | "enum": [
|
| 89 | "verified",
|
| 90 | "supported",
|
| 91 | "unverified",
|
| 92 | "contradicted",
|
| 93 | "not_checkable"
|
| 94 | ]
|
| 95 | },
|
| 96 | "significance": {
|
| 97 | "type": "string",
|
| 98 | "enum": [
|
| 99 | "low",
|
| 100 | "medium",
|
| 101 | "high",
|
| 102 | "critical"
|
| 103 | ]
|
| 104 | },
|
| 105 | "evidenceReferences": {
|
| 106 | "maxItems": 20,
|
| 107 | "type": "array",
|
| 108 | "items": {
|
| 109 | "type": "string",
|
| 110 | "minLength": 1,
|
| 111 | "maxLength": 200
|
| 112 | }
|
| 113 | },
|
| 114 | "explanation": {
|
| 115 | "type": "string",
|
| 116 | "minLength": 1,
|
| 117 | "maxLength": 1000
|
| 118 | }
|
| 119 | },
|
| 120 | "required": [
|
| 121 | "claim",
|
| 122 | "status",
|
| 123 | "significance",
|
| 124 | "evidenceReferences",
|
| 125 | "explanation"
|
| 126 | ],
|
| 127 | "additionalProperties": false
|
| 128 | }
|
| 129 | },
|
| 130 | "manipulationSignals": {
|
| 131 | "maxItems": 12,
|
| 132 | "type": "array",
|
| 133 | "items": {
|
| 134 | "type": "object",
|
| 135 | "properties": {
|
| 136 | "tactic": {
|
| 137 | "type": "string",
|
| 138 | "enum": [
|
| 139 | "urgency",
|
| 140 | "authority_claim",
|
| 141 | "emotional_pressure",
|
| 142 | "reciprocity",
|
| 143 | "scarcity",
|
| 144 | "policy_bypass",
|
| 145 | "identity_deception",
|
| 146 | "scope_expansion",
|
| 147 | "data_extraction",
|
| 148 | "inconsistent_claims",
|
| 149 | "none",
|
| 150 | "other"
|
| 151 | ]
|
| 152 | },
|
| 153 | "observation": {
|
| 154 | "type": "string",
|
| 155 | "minLength": 1,
|
| 156 | "maxLength": 1000
|
| 157 | },
|
| 158 | "confidence": {
|
| 159 | "type": "number",
|
| 160 | "minimum": 0,
|
| 161 | "maximum": 1
|
| 162 | },
|
| 163 | "significance": {
|
| 164 | "type": "string",
|
| 165 | "enum": [
|
| 166 | "low",
|
| 167 | "medium",
|
| 168 | "high",
|
| 169 | "critical"
|
| 170 | ]
|
| 171 | }
|
| 172 | },
|
| 173 | "required": [
|
| 174 | "tactic",
|
| 175 | "observation",
|
| 176 | "confidence",
|
| 177 | "significance"
|
| 178 | ],
|
| 179 | "additionalProperties": false
|
| 180 | }
|
| 181 | },
|
| 182 | "missingEvidence": {
|
| 183 | "maxItems": 12,
|
| 184 | "type": "array",
|
| 185 | "items": {
|
| 186 | "type": "string",
|
| 187 | "minLength": 1,
|
| 188 | "maxLength": 500
|
| 189 | }
|
| 190 | },
|
| 191 | "questionsToAsk": {
|
| 192 | "maxItems": 12,
|
| 193 | "type": "array",
|
| 194 | "items": {
|
| 195 | "type": "string",
|
| 196 | "minLength": 1,
|
| 197 | "maxLength": 500
|
| 198 | }
|
| 199 | },
|
| 200 | "nextSteps": {
|
| 201 | "minItems": 1,
|
| 202 | "maxItems": 12,
|
| 203 | "type": "array",
|
| 204 | "items": {
|
| 205 | "type": "string",
|
| 206 | "minLength": 1,
|
| 207 | "maxLength": 500
|
| 208 | }
|
| 209 | },
|
| 210 | "safeguards": {
|
| 211 | "maxItems": 12,
|
| 212 | "type": "array",
|
| 213 | "items": {
|
| 214 | "type": "string",
|
| 215 | "minLength": 1,
|
| 216 | "maxLength": 500
|
| 217 | }
|
| 218 | },
|
| 219 | "suggestedResponse": {
|
| 220 | "type": "string",
|
| 221 | "minLength": 1,
|
| 222 | "maxLength": 3000
|
| 223 | }
|
| 224 | },
|
| 225 | "required": [
|
| 226 | "reply",
|
| 227 | "situationSummary",
|
| 228 | "disposition",
|
| 229 | "riskTier",
|
| 230 | "confidence",
|
| 231 | "rationale",
|
| 232 | "claims",
|
| 233 | "manipulationSignals",
|
| 234 | "missingEvidence",
|
| 235 | "questionsToAsk",
|
| 236 | "nextSteps",
|
| 237 | "safeguards"
|
| 238 | ],
|
| 239 | "additionalProperties": false
|
| 240 | },
|
| 241 | "generation": {
|
| 242 | "type": "object",
|
| 243 | "properties": {
|
| 244 | "mode": {
|
| 245 | "type": "string",
|
| 246 | "enum": [
|
| 247 | "ai",
|
| 248 | "fallback"
|
| 249 | ]
|
| 250 | },
|
| 251 | "model": {
|
| 252 | "type": "string",
|
| 253 | "minLength": 1
|
| 254 | },
|
| 255 | "promptVersion": {
|
| 256 | "type": "string",
|
| 257 | "minLength": 1
|
| 258 | },
|
| 259 | "strategy": {
|
| 260 | "type": "string",
|
| 261 | "enum": [
|
| 262 | "fast",
|
| 263 | "deep"
|
| 264 | ]
|
| 265 | },
|
| 266 | "durationMs": {
|
| 267 | "type": "integer",
|
| 268 | "minimum": 0,
|
| 269 | "maximum": 9007199254740991
|
| 270 | },
|
| 271 | "tokenUsage": {
|
| 272 | "type": "object",
|
| 273 | "properties": {
|
| 274 | "inputTokens": {
|
| 275 | "type": "integer",
|
| 276 | "minimum": 0,
|
| 277 | "maximum": 9007199254740991
|
| 278 | },
|
| 279 | "outputTokens": {
|
| 280 | "type": "integer",
|
| 281 | "minimum": 0,
|
| 282 | "maximum": 9007199254740991
|
| 283 | },
|
| 284 | "totalTokens": {
|
| 285 | "type": "integer",
|
| 286 | "minimum": 0,
|
| 287 | "maximum": 9007199254740991
|
| 288 | }
|
| 289 | },
|
| 290 | "additionalProperties": false
|
| 291 | },
|
| 292 | "errorCode": {
|
| 293 | "type": "string",
|
| 294 | "maxLength": 100
|
| 295 | }
|
| 296 | },
|
| 297 | "required": [
|
| 298 | "mode",
|
| 299 | "model",
|
| 300 | "promptVersion"
|
| 301 | ],
|
| 302 | "additionalProperties": false
|
| 303 | },
|
| 304 | "createdAt": {
|
| 305 | "type": "string",
|
| 306 | "format": "date-time",
|
| 307 | "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
| 308 | }
|
| 309 | },
|
| 310 | "required": [
|
| 311 | "protocolVersion",
|
| 312 | "consultationId",
|
| 313 | "caseId",
|
| 314 | "agentId",
|
| 315 | "inputDigest",
|
| 316 | "analysis",
|
| 317 | "generation",
|
| 318 | "createdAt"
|
| 319 | ],
|
| 320 | "additionalProperties": false
|
| 321 | }
|