Files
aitbc/docs/agent-training/training_schema.json
aitbc c25f0dc1ca Phase 6: Add testing improvements to training schema and stages
- Add integration_tests field to validation section
- Add coverage_target field for test coverage percentage
- Add coverage_report field for coverage reporting
- Add mock_data section with wallets, addresses, transactions
- Add integration test example to stage1_foundation.json
- Add coverage target and report to stage1_foundation.json
- Add mock data example to stage1_foundation.json
2026-05-07 09:48:19 +02:00

290 lines
9.0 KiB
JSON

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Agent Training Data Schema",
"description": "Schema for OpenClaw agent training data on AITBC operations",
"type": "object",
"required": ["stage", "agent_type", "training_data", "validation"],
"properties": {
"stage": {
"type": "string",
"description": "Training stage identifier",
"enum": [
"stage1_foundation",
"stage2_operations_mastery",
"stage3_ai_operations",
"stage4_marketplace_economics",
"stage5_expert_operations",
"stage6_agent_identity_sdk",
"stage7_cross_node_training",
"stage8_advanced_agent_specialization",
"stage9_multi_chain_architecture"
]
},
"agent_type": {
"type": "string",
"description": "Type of agent being trained",
"enum": ["coordinator", "genesis", "follower", "wallet", "general"]
},
"scenarios": {
"type": "array",
"description": "Scenarios covered by this training stage",
"items": {
"type": "string"
}
},
"depends_on": {
"type": "array",
"description": "Stages that must be completed before this stage",
"items": {
"type": "string"
}
},
"difficulty": {
"type": "string",
"description": "Difficulty level of this training stage",
"enum": ["beginner", "intermediate", "advanced", "expert"]
},
"estimated_time_minutes": {
"type": "number",
"description": "Estimated time to complete this stage in minutes"
},
"training_data": {
"type": "object",
"required": ["operations"],
"properties": {
"prerequisites": {
"type": "object",
"description": "Environment setup prerequisites for this training stage",
"properties": {
"description": {
"type": "string",
"description": "Description of required environment setup"
},
"setup_method": {
"type": "string",
"description": "Path to setup script for this stage"
},
"requirements": {
"type": "array",
"items": {"type": "string"},
"description": "List of required environment conditions"
}
}
},
"operations": {
"type": "array",
"items": {
"type": "object",
"required": ["operation", "parameters", "expected_result", "success_criteria"],
"properties": {
"operation": {
"type": "string",
"description": "AITBC operation name"
},
"parameters": {
"type": "object",
"description": "Operation parameters"
},
"expected_result": {
"type": "object",
"description": "Expected operation result"
},
"success_criteria": {
"type": "object",
"description": "Criteria for operation success",
"properties": {
"status": {
"type": "string",
"enum": ["success", "error"]
},
"response_fields": {
"type": "array",
"items": {"type": "string"},
"description": "Required fields in response"
},
"performance": {
"type": "object",
"properties": {
"max_duration_ms": {"type": "number"},
"min_success_rate": {"type": "number"},
"max_memory_mb": {"type": "number"}
}
}
}
},
"idempotent": {
"type": "boolean",
"description": "Whether operation can be safely retried",
"default": false
},
"check_exists": {
"type": "string",
"description": "Operation to check if resource already exists"
},
"verify_on_chain": {
"type": "boolean",
"description": "Whether to verify transaction on-chain",
"default": false
},
"confirmations_required": {
"type": "number",
"description": "Number of block confirmations required"
},
"timeout_seconds": {
"type": "number",
"description": "Timeout for on-chain verification"
},
"retry": {
"type": "object",
"properties": {
"max_attempts": {"type": "number"},
"backoff_seconds": {"type": "number"},
"retryable_errors": {
"type": "array",
"items": {"type": "string"}
}
}
},
"examples": {
"type": "array",
"items": {
"type": "object",
"properties": {
"command": {"type": "string"},
"description": {"type": "string"}
}
}
},
"errors": {
"type": "array",
"items": {
"type": "object",
"properties": {
"error": {"type": "string"},
"message": {"type": "string"},
"resolution": {"type": "string"}
}
}
},
"verify": {
"type": "object",
"properties": {
"command": {"type": "string"},
"expected_pattern": {"type": "string"}
}
},
"resources": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {"type": "string"},
"url": {"type": "string"}
}
}
}
}
}
}
}
},
"validation": {
"type": "object",
"required": ["exam_tests", "passing_score"],
"properties": {
"exam_tests": {
"type": "array",
"items": {
"type": "object",
"required": ["test_name", "operation", "test_case", "expected_output"],
"properties": {
"test_name": {
"type": "string",
"description": "Test name"
},
"operation": {
"type": "string",
"description": "Operation to test"
},
"test_case": {
"type": "object",
"description": "Test input parameters"
},
"expected_output": {
"type": "object",
"description": "Expected test output"
},
"weight": {
"type": "number",
"description": "Test weight for scoring",
"default": 1
}
}
}
},
"integration_tests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "Integration test name"
},
"operations": {
"type": "array",
"items": {"type": "string"},
"description": "Operations to execute in sequence"
},
"cleanup": {
"type": "boolean",
"description": "Whether to cleanup after test",
"default": true
}
}
}
},
"coverage_target": {
"type": "number",
"description": "Target test coverage percentage",
"minimum": 0,
"maximum": 100
},
"coverage_report": {
"type": "boolean",
"description": "Whether to generate coverage report",
"default": false
},
"passing_score": {
"type": "number",
"description": "Minimum score percentage to pass",
"minimum": 0,
"maximum": 100,
"default": 80
}
}
},
"mock_data": {
"type": "object",
"description": "Mock data for testing",
"properties": {
"wallets": {
"type": "array",
"items": {"type": "string"},
"description": "Mock wallet names"
},
"addresses": {
"type": "array",
"items": {"type": "string"},
"description": "Mock wallet addresses"
},
"transactions": {
"type": "array",
"items": {"type": "string"},
"description": "Mock transaction IDs"
}
}
}
}
}