create_lesson
Generate structured lessons by documenting errors, solutions, and verification steps to improve system knowledge and prevent recurrence.
Instructions
Create a new lesson from an error and its solution
Input Schema
Name | Required | Description | Default |
---|---|---|---|
lesson | Yes |
Input Schema (JSON Schema)
{
"properties": {
"lesson": {
"properties": {
"entityType": {
"description": "Must be 'lesson'",
"enum": [
"lesson"
],
"type": "string"
},
"errorPattern": {
"properties": {
"context": {
"description": "Where the error occurred",
"type": "string"
},
"message": {
"description": "The error message",
"type": "string"
},
"stackTrace": {
"description": "Optional stack trace",
"type": "string"
},
"type": {
"description": "Category of the error",
"type": "string"
}
},
"required": [
"type",
"message",
"context"
],
"type": "object"
},
"metadata": {
"properties": {
"environment": {
"properties": {
"dependencies": {
"additionalProperties": {
"type": "string"
},
"type": "object"
},
"nodeVersion": {
"type": "string"
},
"os": {
"type": "string"
}
},
"type": "object"
},
"severity": {
"description": "Severity level of the error",
"enum": [
"low",
"medium",
"high",
"critical"
],
"type": "string"
}
},
"type": "object"
},
"name": {
"description": "Unique identifier for the lesson",
"type": "string"
},
"observations": {
"description": "List of observations about the error and solution",
"items": {
"type": "string"
},
"type": "array"
},
"verificationSteps": {
"items": {
"properties": {
"command": {
"description": "Command to run",
"type": "string"
},
"expectedOutput": {
"description": "Expected output",
"type": "string"
},
"successIndicators": {
"description": "Indicators of success",
"items": {
"type": "string"
},
"type": "array"
}
},
"required": [
"command",
"expectedOutput",
"successIndicators"
],
"type": "object"
},
"type": "array"
}
},
"required": [
"name",
"entityType",
"observations",
"errorPattern",
"verificationSteps"
],
"type": "object"
}
},
"required": [
"lesson"
],
"type": "object"
}