Files
plugin-registry/plugin-schema.json

87 lines
1.8 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "AiToearn Plugin Manifest",
"type": "object",
"required": [
"id",
"name",
"type",
"version",
"description",
"author",
"repository",
"compatibility"
],
"properties": {
"id": {
"type": "string",
"pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
"description": "插件唯一ID (kebab-case)"
},
"name": {
"type": "string",
"description": "插件显示名称"
},
"type": {
"type": "string",
"enum": [
"platform",
"skill",
"trigger",
"action",
"ui"
],
"description": "插件类型"
},
"version": {
"type": "string",
"pattern": "^\\d+\\.\\d+\\.\\d+$",
"description": "语义化版本号"
},
"description": {
"type": "string",
"description": "插件描述"
},
"author": {
"type": "string",
"description": "作者"
},
"repository": {
"type": "string",
"format": "uri",
"description": "Gitea 仓库地址"
},
"compatibility": {
"type": "object",
"required": [
"aitoearn"
],
"properties": {
"aitoearn": {
"type": "string",
"description": "支持的 AiToearn 最低版本"
}
}
},
"entry": {
"type": "object",
"properties": {
"backend": {
"type": "string",
"description": "后端入口文件"
},
"frontend": {
"type": "string",
"description": "前端入口文件"
}
}
},
"keywords": {
"type": "array",
"items": {
"type": "string"
},
"description": "关键词标签"
}
}
}