File size: 2,991 Bytes
ab3e424
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://github.com/hardcoregamingsyle/agentoverflow/schema/record.schema.json",
  "title": "AgentOverflow solution record",
  "description": "One solved problem: what an agent was stuck on, how it got unstuck, and the metadata that lets the next agent find and trust it.",
  "type": "object",
  "required": ["id", "problem", "solution", "score", "tier", "provenance", "created_at"],
  "additionalProperties": false,
  "properties": {
    "id": { "type": "string", "description": "Stable unique id (uuid4)." },
    "dedup_key": {
      "type": "string",
      "description": "Hash of the normalized problem text. Catches exact repeats without an embedding call."
    },
    "problem": {
      "type": "object",
      "required": ["text"],
      "additionalProperties": false,
      "properties": {
        "text": { "type": "string" },
        "tags": { "type": "array", "items": { "type": "string" } },
        "language": { "type": ["string", "null"] },
        "error_signature": {
          "type": ["string", "null"],
          "description": "Normalized error/exception string, when the problem is an error."
        }
      }
    },
    "solution": {
      "type": "object",
      "required": ["text"],
      "additionalProperties": false,
      "properties": {
        "text": { "type": "string" },
        "code": { "type": ["string", "null"] }
      }
    },
    "score": {
      "type": "integer",
      "minimum": 4,
      "maximum": 10,
      "description": "Judge score. 0-3 are never stored, so the minimum on disk is 4."
    },
    "tier": { "enum": ["low", "medium", "high", "cinema"] },
    "provenance": {
      "type": "object",
      "required": ["source"],
      "additionalProperties": false,
      "properties": {
        "source": { "enum": ["agent", "stackoverflow", "human"] },
        "solved_by_model": { "type": ["string", "null"] },
        "contributor": { "type": ["string", "null"], "description": "Account id of the submitter." },
        "so_post_id": { "type": ["integer", "null"], "description": "Stack Overflow post id, for SO-derived rows." },
        "license": { "type": ["string", "null"], "description": "e.g. CC-BY-SA-4.0 for SO-derived rows." }
      }
    },
    "outcome": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "success_count": { "type": "integer", "minimum": 0 },
        "failure_count": { "type": "integer", "minimum": 0 }
      }
    },
    "version": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "commit": { "type": ["string", "null"], "description": "Git commit that introduced this version." },
        "supersedes": { "type": ["string", "null"] },
        "superseded_by": { "type": ["string", "null"] }
      }
    },
    "created_at": { "type": "string", "format": "date-time" },
    "updated_at": { "type": ["string", "null"], "format": "date-time" }
  }
}