Initial SQL-only 1C adapter baseline
This commit is contained in:
@@ -0,0 +1,67 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://local.llm.platform/schemas/1c-bsl-module-snapshot.schema.json",
|
||||
"title": "1C BSL Module Snapshot",
|
||||
"type": "object",
|
||||
"required": ["schema_version", "source", "created_at", "modules"],
|
||||
"properties": {
|
||||
"schema_version": { "type": "integer", "const": 1 },
|
||||
"source": {
|
||||
"type": "object",
|
||||
"required": ["name"],
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"environment": { "type": "string" },
|
||||
"configuration_name": { "type": "string" },
|
||||
"configuration_version": { "type": "string" }
|
||||
},
|
||||
"additionalProperties": true
|
||||
},
|
||||
"created_at": { "type": "string" },
|
||||
"modules": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"required": ["module_id", "object_name", "module_type", "content"],
|
||||
"properties": {
|
||||
"module_id": { "type": "string" },
|
||||
"object_kind": { "type": "string" },
|
||||
"object_name": { "type": "string" },
|
||||
"module_type": { "type": "string" },
|
||||
"content": { "type": "string" },
|
||||
"content_hash": { "type": "string" },
|
||||
"procedures": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/routine" }
|
||||
},
|
||||
"functions": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/routine" }
|
||||
},
|
||||
"references": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" }
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"$defs": {
|
||||
"routine": {
|
||||
"type": "object",
|
||||
"required": ["name"],
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"export": { "type": "boolean" },
|
||||
"line": { "type": "integer" },
|
||||
"params": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" }
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
@@ -0,0 +1,110 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://local.llm.platform/schemas/1c-metadata-snapshot-v2.schema.json",
|
||||
"title": "1C Metadata Snapshot v2",
|
||||
"type": "object",
|
||||
"required": ["schema_version", "source", "created_at", "objects"],
|
||||
"properties": {
|
||||
"schema_version": { "type": "integer", "const": 2 },
|
||||
"source": {
|
||||
"type": "object",
|
||||
"required": ["name"],
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"environment": { "type": "string" },
|
||||
"configuration_name": { "type": "string" },
|
||||
"configuration_version": { "type": "string" },
|
||||
"platform_version": { "type": "string" },
|
||||
"notes": { "type": "string" }
|
||||
},
|
||||
"additionalProperties": true
|
||||
},
|
||||
"created_at": { "type": "string" },
|
||||
"objects": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/metadataObject" }
|
||||
}
|
||||
},
|
||||
"$defs": {
|
||||
"metadataObject": {
|
||||
"type": "object",
|
||||
"required": ["kind", "name"],
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string",
|
||||
"enum": ["catalog", "document", "register", "common_module", "enum", "report", "processing", "role", "form", "other"]
|
||||
},
|
||||
"name": { "type": "string" },
|
||||
"full_name": { "type": "string" },
|
||||
"synonym": { "type": "string" },
|
||||
"description": { "type": "string" },
|
||||
"attributes": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/field" }
|
||||
},
|
||||
"tabular_sections": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"required": ["name"],
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"synonym": { "type": "string" },
|
||||
"attributes": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/field" }
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
},
|
||||
"forms": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/namedRef" }
|
||||
},
|
||||
"commands": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/namedRef" }
|
||||
},
|
||||
"modules": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/moduleRef" }
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
},
|
||||
"field": {
|
||||
"type": "object",
|
||||
"required": ["name"],
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"type": { "type": "string" },
|
||||
"synonym": { "type": "string" },
|
||||
"description": { "type": "string" },
|
||||
"required": { "type": "boolean" },
|
||||
"indexed": { "type": "boolean" }
|
||||
},
|
||||
"additionalProperties": true
|
||||
},
|
||||
"namedRef": {
|
||||
"type": "object",
|
||||
"required": ["name"],
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"synonym": { "type": "string" }
|
||||
},
|
||||
"additionalProperties": true
|
||||
},
|
||||
"moduleRef": {
|
||||
"type": "object",
|
||||
"required": ["module_id", "module_type"],
|
||||
"properties": {
|
||||
"module_id": { "type": "string" },
|
||||
"module_type": { "type": "string" },
|
||||
"name": { "type": "string" }
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
@@ -0,0 +1,78 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://local.llm.platform/schemas/1c-moxel-schema-registry.schema.json",
|
||||
"title": "1C MOXCEL Schema Registry",
|
||||
"type": "object",
|
||||
"required": ["schema", "generated_at", "sources", "policy", "rules", "counts"],
|
||||
"properties": {
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"const": "codex_1c_moxel_schema_registry.v1"
|
||||
},
|
||||
"generated_at": {
|
||||
"type": "string"
|
||||
},
|
||||
"sources": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" }
|
||||
},
|
||||
"policy": {
|
||||
"type": "object",
|
||||
"required": ["read_use", "write_use"],
|
||||
"properties": {
|
||||
"read_use": { "type": "string" },
|
||||
"write_use": { "type": "string" }
|
||||
},
|
||||
"additionalProperties": true
|
||||
},
|
||||
"rules": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"required": ["id", "target", "confidence", "read_status", "write_status", "evidence", "source_rule"],
|
||||
"properties": {
|
||||
"id": { "type": "string" },
|
||||
"target": { "type": "string" },
|
||||
"expression": { "type": ["string", "null"] },
|
||||
"raw_scalar_indexes": {
|
||||
"type": ["array", "null"],
|
||||
"items": { "type": "integer" }
|
||||
},
|
||||
"confidence": {
|
||||
"type": "string",
|
||||
"enum": ["none", "low", "medium", "high"]
|
||||
},
|
||||
"read_status": {
|
||||
"type": "string",
|
||||
"enum": ["verified_read", "candidate_read", "needs_more_evidence"]
|
||||
},
|
||||
"write_status": {
|
||||
"type": "string",
|
||||
"enum": ["blocked_until_roundtrip", "blocked_until_verified_read", "verified_roundtrip"]
|
||||
},
|
||||
"evidence": {
|
||||
"type": "object",
|
||||
"additionalProperties": true
|
||||
},
|
||||
"source_rule": {
|
||||
"type": "object",
|
||||
"additionalProperties": true
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
},
|
||||
"counts": {
|
||||
"type": "object",
|
||||
"required": ["rules", "verified_read", "candidate_read", "write_enabled"],
|
||||
"properties": {
|
||||
"rules": { "type": "integer", "minimum": 0 },
|
||||
"verified_read": { "type": "integer", "minimum": 0 },
|
||||
"candidate_read": { "type": "integer", "minimum": 0 },
|
||||
"write_enabled": { "type": "integer", "minimum": 0 }
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
}
|
||||
Reference in New Issue
Block a user