91 lines
2.9 KiB
JSON
91 lines
2.9 KiB
JSON
{
|
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
"title": "mindnet_chunk",
|
|
"type": "object",
|
|
"description": "Chunk-Payload (Qdrant). Kompatibel mit Alt-Feldern und neuen Feldern für Export/Roundtrip.",
|
|
"required": ["id", "note_id", "chunk_index", "path"],
|
|
"properties": {
|
|
"id": { "type": "string" },
|
|
"scope": { "type": "string", "enum": ["chunk"] },
|
|
"note_id": { "type": "string" },
|
|
"note_title": { "type": "string" },
|
|
"note_type": { "type": "string" },
|
|
"note_status": { "type": "string" },
|
|
"type": { "type": "string", "description": "Legacy: früherer Chunk-Typ; kann dem Note-Typ entsprechen" },
|
|
"area": { "type": "string" },
|
|
"project": { "type": "string" },
|
|
"tags": { "type": "array", "items": { "type": "string" } },
|
|
|
|
"note_path": { "type": "string" },
|
|
"path": { "type": "string" },
|
|
|
|
"chunk_index": { "type": "integer" },
|
|
"section_title":{ "type": ["string","null"] },
|
|
"section_path": { "type": ["string","null"] },
|
|
|
|
"char_start": { "type": ["integer","null"] },
|
|
"char_end": { "type": ["integer","null"] },
|
|
"char_len": { "type": "integer" },
|
|
|
|
"token_count": { "type": "integer", "description": "Legacy: frühere Token-Zahl" },
|
|
"token_est": { "type": "integer", "description": "Neue grobe Token-Schätzung (≈ len(text)/4)" },
|
|
|
|
"neighbors": {
|
|
"type": "object",
|
|
"properties": {
|
|
"prev": { "type": ["string","null"] },
|
|
"next": { "type": ["string","null"] }
|
|
},
|
|
"additionalProperties": false
|
|
},
|
|
|
|
"text": { "type": "string" },
|
|
"text_sha256": { "type": "string", "pattern": "^sha256:[0-9a-fA-F]{64}$" },
|
|
"lang": { "type": "string" },
|
|
|
|
"wikilinks": { "type": "array", "items": { "type": "string" } },
|
|
"external_links": {
|
|
"type": "array",
|
|
"items": {
|
|
"anyOf": [
|
|
{ "type": "string" },
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"href": { "type": "string" },
|
|
"label": { "type": ["string","null"] }
|
|
},
|
|
"required": ["href"],
|
|
"additionalProperties": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"references": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"properties": {
|
|
"target_id": { "type": "string" },
|
|
"kind": { "type": "string" }
|
|
},
|
|
"required": ["target_id","kind"],
|
|
"additionalProperties": true
|
|
}
|
|
},
|
|
|
|
"embed_model": { "type": "string" },
|
|
"embed_dim": { "type": "integer" },
|
|
"embed_version": { "type": "integer" },
|
|
|
|
"created_at": { "type": "string" }
|
|
},
|
|
|
|
"allOf": [
|
|
{ "anyOf": [ { "required": ["token_count"] }, { "required": ["token_est"] } ] },
|
|
{ "anyOf": [ { "required": ["type"] }, { "required": ["note_type"] } ] }
|
|
],
|
|
|
|
"additionalProperties": true
|
|
}
|