Files
soleprint/cfg/amar/models/schema.json
2025-12-31 09:07:27 -03:00

164 lines
7.0 KiB
JSON

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Pawprint Models",
"description": "Platform-agnostic model definitions. Portable to TypeScript, Pydantic, Django, Prisma.",
"definitions": {
"Status": {
"type": "string",
"enum": ["pending", "planned", "building", "dev", "live", "ready"]
},
"System": {
"type": "string",
"enum": ["artery", "album", "ward"]
},
"Nest": {
"type": "object",
"description": "Runtime environment configuration. Shared across artery, ward.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"config_path": { "type": "string" }
},
"required": ["name", "slug", "title"]
},
"Larder": {
"type": "object",
"description": "Data storage. When generated from Template = 'Book (written)'. Independent in ward/artery.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"source_template": { "type": "string", "description": "Template name if generated" },
"data_path": { "type": "string", "description": "Path to data files" }
},
"required": ["name", "slug", "title"]
},
"Vein": {
"type": "object",
"description": "Connector (artery). Single responsibility.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"system": { "const": "artery" }
},
"required": ["name", "slug", "title"]
},
"Template": {
"type": "object",
"description": "Documentation template (album). Gherkin, BDD patterns.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"template_path": { "type": "string", "description": "Path to template files" },
"system": { "const": "album" }
},
"required": ["name", "slug", "title"]
},
"ToolType": {
"type": "string",
"enum": ["app", "cli"],
"description": "Type of tool: app (web UI) or cli (command line)"
},
"Tool": {
"type": "object",
"description": "Execution tool (ward). Test runners, seeders.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"system": { "const": "ward" },
"type": { "$ref": "#/definitions/ToolType" },
"description": { "type": "string", "description": "Human-readable description" },
"path": { "type": "string", "description": "Path to tool source" },
"url": { "type": "string", "description": "URL path for app tools" },
"cli": { "type": "string", "description": "CLI command for cli tools" }
},
"required": ["name", "slug", "title"]
},
"Monitor": {
"type": "object",
"description": "Service monitor (ward). Health checks, status watchers.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"system": { "const": "ward" }
},
"required": ["name", "slug", "title"]
},
"Cabinet": {
"type": "object",
"description": "Tool cabinet (ward). Contains 0+ tools.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"tools": {
"type": "array",
"items": { "$ref": "#/definitions/Tool" }
},
"system": { "const": "ward" }
},
"required": ["name", "slug", "title"]
},
"Pulse": {
"type": "object",
"description": "Composed data flow (artery). Pulse = Vein + Nest + Larder.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"vein": { "$ref": "#/definitions/Vein" },
"nest": { "$ref": "#/definitions/Nest" },
"larder": { "$ref": "#/definitions/Larder" },
"system": { "const": "artery" }
},
"required": ["name", "slug", "title"]
},
"Book": {
"type": "object",
"description": "Composed documentation (album). Book = Template + Larder.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"template": { "$ref": "#/definitions/Template" },
"larder": { "$ref": "#/definitions/Larder" },
"output_larder": { "$ref": "#/definitions/Larder" },
"system": { "const": "album" }
},
"required": ["name", "slug", "title"]
},
"Table": {
"type": "object",
"description": "Composed execution bundle (ward). Table = Cabinet + Nest + Larders.",
"properties": {
"name": { "type": "string", "description": "Unique identifier" },
"slug": { "type": "string", "description": "URL-friendly identifier" },
"title": { "type": "string", "description": "Display title for UI" },
"status": { "$ref": "#/definitions/Status" },
"cabinet": { "$ref": "#/definitions/Cabinet" },
"nest": { "$ref": "#/definitions/Nest" },
"larders": {
"type": "array",
"items": { "$ref": "#/definitions/Larder" }
},
"system": { "const": "ward" }
},
"required": ["name", "slug", "title"]
}
}
}