hyf

Context-aware query service for Radroots
git clone https://radroots.dev/git/hyf.git
Log | Files | Refs | README | LICENSE

buyer_request_match.response.schema.json (7639B)


      1 {
      2   "type": "object",
      3   "properties": {
      4     "version": {
      5       "type": "integer",
      6       "const": 1
      7     },
      8     "request_id": {
      9       "type": "string"
     10     },
     11     "trace_id": {
     12       "type": "string",
     13       "minLength": 1,
     14       "pattern": "\\S"
     15     },
     16     "ok": {
     17       "type": "boolean"
     18     },
     19     "output": {
     20       "type": "object",
     21       "properties": {
     22         "versions": {
     23           "$ref": "common.schema.json#/$defs/versions"
     24         },
     25         "provenance": {
     26           "type": "object",
     27           "properties": {
     28             "need": {
     29               "type": "object",
     30               "properties": {
     31                 "need_id": {
     32                   "type": "string",
     33                   "minLength": 64,
     34                   "maxLength": 64,
     35                   "pattern": "^[0-9a-f]{64}(?![\\s\\S])"
     36                 },
     37                 "revision": {
     38                   "type": "string",
     39                   "minLength": 1,
     40                   "pattern": "\\S"
     41                 }
     42               },
     43               "required": [
     44                 "need_id",
     45                 "revision"
     46               ],
     47               "additionalProperties": false
     48             },
     49             "candidates": {
     50               "type": "array",
     51               "items": {
     52                 "type": "object",
     53                 "properties": {
     54                   "candidate_id": {
     55                     "type": "string",
     56                     "minLength": 64,
     57                     "maxLength": 64,
     58                     "pattern": "^[0-9a-f]{64}(?![\\s\\S])"
     59                   },
     60                   "revision": {
     61                     "type": "string",
     62                     "minLength": 1,
     63                     "pattern": "\\S"
     64                   }
     65                 },
     66                 "required": [
     67                   "candidate_id",
     68                   "revision"
     69                 ],
     70                 "additionalProperties": false
     71               },
     72               "maxItems": 128
     73             }
     74           },
     75           "required": [
     76             "need",
     77             "candidates"
     78           ],
     79           "additionalProperties": false
     80         },
     81         "suggestions": {
     82           "type": "array",
     83           "items": {
     84             "type": "object",
     85             "properties": {
     86               "candidate_id": {
     87                 "type": "string",
     88                 "minLength": 64,
     89                 "maxLength": 64,
     90                 "pattern": "^[0-9a-f]{64}(?![\\s\\S])"
     91               },
     92               "preference": {
     93                 "type": "number",
     94                 "minimum": 0,
     95                 "maximum": 1
     96               },
     97               "checks": {
     98                 "type": "array",
     99                 "items": {
    100                   "type": "object",
    101                   "properties": {
    102                     "kind": {
    103                       "type": "string",
    104                       "minLength": 1,
    105                       "pattern": "\\S"
    106                     },
    107                     "result": {
    108                       "type": "string",
    109                       "enum": [
    110                         "pass",
    111                         "fail",
    112                         "unknown"
    113                       ]
    114                     },
    115                     "reason": {
    116                       "type": "string",
    117                       "minLength": 1,
    118                       "pattern": "\\S"
    119                     },
    120                     "evidence": {
    121                       "type": "array",
    122                       "items": {
    123                         "$ref": "common.schema.json#/$defs/evidence_ref"
    124                       },
    125                       "maxItems": 128
    126                     }
    127                   },
    128                   "required": [
    129                     "kind",
    130                     "result",
    131                     "reason",
    132                     "evidence"
    133                   ],
    134                   "additionalProperties": false
    135                 },
    136                 "maxItems": 128
    137               },
    138               "unresolved": {
    139                 "type": "array",
    140                 "items": {
    141                   "type": "string",
    142                   "minLength": 1,
    143                   "pattern": "\\S"
    144                 },
    145                 "maxItems": 128
    146               },
    147               "evidence": {
    148                 "type": "array",
    149                 "items": {
    150                   "$ref": "common.schema.json#/$defs/evidence_ref"
    151                 },
    152                 "maxItems": 128
    153               },
    154               "commitment": {
    155                 "const": "none"
    156               }
    157             },
    158             "required": [
    159               "candidate_id",
    160               "preference",
    161               "checks",
    162               "unresolved",
    163               "evidence",
    164               "commitment"
    165             ],
    166             "additionalProperties": false
    167           },
    168           "maxItems": 8
    169         },
    170         "limitations": {
    171           "type": "object",
    172           "properties": {
    173             "scope": {
    174               "const": "supplied_only"
    175             },
    176             "truncated": {
    177               "type": "boolean"
    178             },
    179             "unsupported": {
    180               "type": "array",
    181               "items": {
    182                 "type": "string",
    183                 "minLength": 1,
    184                 "pattern": "\\S"
    185               },
    186               "maxItems": 128
    187             },
    188             "commitment": {
    189               "const": "none"
    190             }
    191           },
    192           "required": [
    193             "scope",
    194             "truncated",
    195             "unsupported",
    196             "commitment"
    197           ],
    198           "additionalProperties": false
    199         },
    200         "execution": {
    201           "$ref": "common.schema.json#/$defs/execution"
    202         }
    203       },
    204       "required": [
    205         "versions",
    206         "provenance",
    207         "suggestions",
    208         "limitations",
    209         "execution"
    210       ],
    211       "additionalProperties": false
    212     },
    213     "error": {
    214       "type": "object",
    215       "properties": {
    216         "code": {
    217           "type": "string",
    218           "enum": [
    219             "invalid_request",
    220             "unsupported_capability",
    221             "capability_disabled",
    222             "capability_unavailable",
    223             "internal_error"
    224           ]
    225         },
    226         "message": {
    227           "type": "string"
    228         }
    229       },
    230       "required": [
    231         "code",
    232         "message"
    233       ],
    234       "additionalProperties": false
    235     },
    236     "meta": {
    237       "type": "object",
    238       "properties": {
    239         "schema_version": {
    240           "type": "integer",
    241           "const": 1
    242         }
    243       },
    244       "required": [
    245         "schema_version"
    246       ],
    247       "additionalProperties": false
    248     }
    249   },
    250   "required": [
    251     "version",
    252     "request_id",
    253     "ok"
    254   ],
    255   "additionalProperties": false,
    256   "oneOf": [
    257     {
    258       "properties": {
    259         "ok": {
    260           "const": true
    261         },
    262         "request_id": {
    263           "type": "string",
    264           "minLength": 1,
    265           "pattern": "\\S"
    266         }
    267       },
    268       "required": [
    269         "output"
    270       ],
    271       "not": {
    272         "required": [
    273           "error"
    274         ]
    275       }
    276     },
    277     {
    278       "properties": {
    279         "ok": {
    280           "const": false
    281         }
    282       },
    283       "required": [
    284         "error"
    285       ],
    286       "not": {
    287         "anyOf": [
    288           {
    289             "required": [
    290               "output"
    291             ]
    292           },
    293           {
    294             "required": [
    295               "meta"
    296             ]
    297           }
    298         ]
    299       }
    300     }
    301   ],
    302   "$schema": "https://json-schema.org/draft/2020-12/schema",
    303   "$id": "hyf_ops_v3/buyer_request_match.response.schema.json",
    304   "$comment": "D57 hyf_ops_v3 pre-activation contract. No business write or trusted context can be minted by source/model text. Full semantic input-use and SDK revalidation remain required."
    305 }