📦 deps(thirdparty): update snapshots
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://cangjie-skill.org/schemas/contracts/chunk.schema.json",
|
||||
"title": "Chunk Contract v1",
|
||||
"description": "结构感知块(chunks.jsonl 每行一条)。块必须尊重章节边界并可回溯到 elements。",
|
||||
"type": "object",
|
||||
"required": ["chunk_id", "source_id", "version_id", "heading_path", "element_ids", "text", "content_hash"],
|
||||
"properties": {
|
||||
"chunk_id": { "type": "string", "pattern": "^ck-[0-9a-f]{12}$" },
|
||||
"source_id": { "type": "string" },
|
||||
"version_id": { "type": "string" },
|
||||
"heading_path": { "type": "array", "items": { "type": "string" } },
|
||||
"element_ids": { "type": "array", "minItems": 1, "items": { "type": "string" } },
|
||||
"text": { "type": "string" },
|
||||
"char_count": { "type": "integer" },
|
||||
"keywords": { "type": "array", "items": { "type": "string" }, "description": "确定性预筛关键词(供 FTS5 检索)" },
|
||||
"content_hash": { "type": "string", "pattern": "^sha256:[0-9a-f]+$" }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://cangjie-skill.org/schemas/contracts/source-document.schema.json",
|
||||
"title": "SourceDocument Contract v1",
|
||||
"description": "核心共享契约(ADR-003):外部预处理仓库必须遵守。核心自身首版只处理原生 Markdown/TXT。",
|
||||
"type": "object",
|
||||
"required": ["schema_version", "source_id", "version_id", "title", "media_type", "elements"],
|
||||
"properties": {
|
||||
"schema_version": { "const": 1 },
|
||||
"source_id": { "type": "string", "description": "稳定 ID,文件改名不得自动变成新来源" },
|
||||
"version_id": { "type": "string", "pattern": "^sha256:[0-9a-f]+$", "description": "由规范化字节确定性计算" },
|
||||
"title": { "type": "string" },
|
||||
"media_type": { "enum": ["markdown", "txt", "pdf", "html", "epub", "docx", "pptx", "xlsx", "subtitle", "audio", "video"] },
|
||||
"language": { "type": "array", "items": { "type": "string" } },
|
||||
"parser": { "type": "string", "description": "解析器名称@版本" },
|
||||
"elements": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"required": ["element_id", "type", "content_hash"],
|
||||
"properties": {
|
||||
"element_id": { "type": "string", "pattern": "^el-[0-9]{6}$" },
|
||||
"type": { "enum": ["heading", "paragraph", "list", "table", "image", "formula", "transcript", "frame", "code"] },
|
||||
"text": { "type": "string" },
|
||||
"heading_path": { "type": "array", "items": { "type": "string" } },
|
||||
"page": { "type": ["integer", "null"] },
|
||||
"time_start_ms": { "type": ["integer", "null"] },
|
||||
"time_end_ms": { "type": ["integer", "null"] },
|
||||
"bbox": { "type": ["array", "null"], "items": { "type": "number" }, "minItems": 4, "maxItems": 4 },
|
||||
"asset_ref": { "type": ["string", "null"] },
|
||||
"confidence": { "type": ["number", "null"], "minimum": 0, "maximum": 1 },
|
||||
"content_hash": { "type": "string", "pattern": "^sha256:[0-9a-f]+$" }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user