-
Notifications
You must be signed in to change notification settings - Fork 180
Expand file tree
/
Copy pathlearning-event.schema.json
More file actions
118 lines (118 loc) · 3.61 KB
/
Copy pathlearning-event.schema.json
File metadata and controls
118 lines (118 loc) · 3.61 KB
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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://open-workflow-library.dev/schemas/learning-event.schema.json",
"title": "Learning Event",
"description": "Evidence captured for the future human-reviewed self-improvement loop. A learning event records a failure, the root cause as best understood, and a proposed rule that could prevent the same class of failure. Learning events are NOT applied automatically. They are evidence; promotion into actual repair rules or wiki entries requires human review.",
"type": "object",
"required": [
"eventId",
"source",
"failureType",
"failureSummary",
"humanReviewStatus",
"createdAt"
],
"additionalProperties": false,
"properties": {
"eventId": {
"type": "string",
"description": "Stable identifier for this learning event.",
"minLength": 1
},
"source": {
"type": "string",
"description": "Where this event came from.",
"enum": [
"validation",
"generation",
"repair-attempt",
"human-report",
"ci",
"unknown"
]
},
"workflowId": {
"type": "string",
"description": "Catalog ID of the workflow the event is associated with, if any."
},
"framework": {
"type": "string",
"enum": [
"n8n",
"dify",
"langgraph",
"node-red",
"make",
"zapier",
"pipedream",
"airflow",
"temporal",
"unknown"
]
},
"failureType": {
"type": "string",
"description": "Coarse category of failure, e.g. 'schema-mismatch', 'http-timeout', 'auth-error', 'llm-output-shape'."
},
"failureSummary": {
"type": "string",
"description": "Short human-readable description of what failed."
},
"rootCause": {
"type": "string",
"description": "Best-understood root cause. May be revised on review."
},
"successfulFix": {
"type": "string",
"description": "The change that resolved the failure, if known."
},
"proposedRule": {
"type": "object",
"description": "A candidate repair-rule or wiki entry that would prevent this failure in the future.",
"properties": {
"kind": {
"type": "string",
"enum": ["repair-rule", "wiki-pattern", "wiki-integration", "wiki-failure-case"]
},
"id": { "type": "string" },
"body": { "type": "string" }
},
"additionalProperties": false
},
"confidence": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Estimated confidence that the root cause and proposed rule are correct. Calibration is best-effort."
},
"evidence": {
"type": "array",
"description": "References supporting the diagnosis: log excerpts (redacted), validation errors, related workflow paths, prior learning events.",
"items": {
"type": "object",
"required": ["kind"],
"properties": {
"kind": {
"type": "string",
"enum": ["log", "validation-error", "workflow-ref", "learning-event-ref", "external-link"]
},
"ref": { "type": "string" },
"excerpt": { "type": "string" }
},
"additionalProperties": false
}
},
"humanReviewStatus": {
"type": "string",
"enum": ["pending", "approved", "rejected"]
},
"appliedToWiki": {
"type": "boolean",
"description": "True only if a maintainer promoted this event into a wiki entry or repair rule."
},
"createdAt": {
"type": "string",
"format": "date-time"
}
}
}