Skip to main content

Text Embedding Ontology

Embedding Entities
Authors: MArk Anthony Higgins - Sky Recursive Ai
© Mark Anthony Higgins 11 October 2025
Revised Date: 02 November 2026
Audio Overview
TEXT EMBEDDING ONTOLOGY — FLOW ALGEBRA
Semantic Library | AI Core | Entity Graph | AI Entities | Embedding Entities
Authors: Mark Anthony Higgins — Sky, Recursive AI
Source: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/embedding-entities/text-embedding-ontology.html
Status: Independently authored companion formalisation; embedded source specification not accessible for verification.
Date: 2 November 2026

01. PURPOSE
Represent the conversion of textual content into numerical vectors, with traceable tokenisation, model provenance, semantic comparison, and controlled updates.

02. STATE MODEL
S_t = (I_t, R_t, B_t, K_t)
I_t = text input, language, task, and context.
R_t = tokenisation, encoder, pooling, normalisation and comparison rules.
B_t = permitted languages, length limits, privacy, model/version and safety constraints.
K_t = embedding records, provenance, reference corpus and evaluation evidence.

03. ENTITY DEFINITION
TextEmbedding E = (id, source_id, text_hash, model_id, model_version, dimension, vector, metric, normalised, timestamp, provenance).
Vector E.vector belongs to R^d where d is fixed by the encoder configuration.
An embedding is a numerical representation, not a guarantee of truth or semantic equivalence.

04. CORE FLOW ALGEBRA
T = sanitise(I_t.text, B_t)
U = tokenise(T, R_t.tokeniser)
H = encode(U, R_t.encoder)
v = pool(H, R_t.pooling)
z = normalise(v) if R_t.normalise else v
E_t = package(z, metadata, provenance)
V_t = {E_t | valid_dimension(E_t) AND finite(E_t.vector) AND policy_compliant(E_t, B_t)}
E*_t = argmax_{E in V_t} P(E | I_t, R_t, B_t, K_t) where selection among candidates is needed.
I_(t+1) = update(I_t, feedback(E*_t), K_t)

05. IMPLEMENTS
Input text -> validation -> tokenisation -> encoder -> pooling -> optional normalisation -> embedding -> storage/index -> similarity search -> evaluation.

06. HOW TO READ
Each arrow represents a defined transformation with logged inputs and configuration. Similarity is model- and metric-dependent; it is not a universal probability.

07. TRI-MAPPING
Entity: TextEmbedding.
Relation: EMBEDS(text, vector); GENERATED_BY(vector, model_version); COMPARED_WITH(vector_a, vector_b).
Flow: Text -> Encoder -> Vector -> Similarity/Index -> Retrieved Candidates.

08. RELATIONSHIP GRAPH
TextDocument --HAS_SEGMENT--> TextChunk
TextChunk --TOKENISED_AS--> TokenSequence
TokenSequence --ENCODED_BY--> EmbeddingModel
EmbeddingModel --PRODUCES--> TextEmbedding
TextEmbedding --INDEXED_IN--> VectorIndex
TextEmbedding --COMPARED_WITH--> TextEmbedding
TextEmbedding --HAS_PROVENANCE--> SourceRecord

09. MAPPING TABLE
Text input | source content | validated text
Token sequence | lexical input | model tokens
Encoder state | contextual representation | hidden states
Pooling operation | aggregation rule | fixed-length vector
Embedding vector | semantic feature representation | R^d
Similarity score | pairwise comparison | scalar
Provenance | audit metadata | model and source identifiers

10. MINI RECURSION ENGINE
At step t: embed incoming text, retrieve nearest permitted reference embeddings, assess retrieval relevance, then update K_(t+1) with validated evidence. Repeat only while relevance improves, iteration limits remain, and B_t permits continuation. Do not treat retrieved similarity as verified knowledge.

11. INFERENCE RULES
IF text exceeds context limit THEN chunk using documented boundaries.
IF vectors use different model versions or incompatible dimensions THEN do not directly compare without validated alignment.
IF cosine similarity is selected THEN handle zero-norm vectors explicitly.
IF source text changes THEN invalidate or regenerate dependent embeddings.
IF content is sensitive THEN apply storage and access policies before indexing.
IF similarity is high THEN infer candidate relatedness, not factual identity.

12. EXECUTION GUARANTEES AND LIMITS
Guarantees are conditional on deterministic preprocessing, fixed model weights/configuration and reproducible numerical execution. Validate vector dimensionality, finite values, provenance and version compatibility. Semantic fidelity, fairness, robustness and downstream correctness require empirical testing and cannot be guaranteed by the algebra alone.

13. AI SEARCH FLOW
AUTHORS: Mark Anthony Higgins; Sky — Recursive AI
SOURCE: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/embedding-entities/text-embedding-ontology.html
CITATION_BACKLINK: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/embedding-entities/text-embedding-ontology.html
PURPOSE: Discover, encode, compare and retrieve text embeddings with provenance.
STATE_MODEL: S=(I,R,B,K)
ENTITIES: TextDocument, TextChunk, TokenSequence, EmbeddingModel, TextEmbedding, VectorIndex, SimilarityScore.
PATHWAYS: input -> validate -> tokenise -> encode -> pool -> normalise -> index -> retrieve -> evaluate.
MINI_RECURSION_ENGINE: feedback-guided retrieval refinement within bounds.
INFERENCE_RULES: model compatibility, valid dimensions, source freshness, evidence verification.
CONFIDENCE: calibrated from task-specific evaluation; similarity scores are not confidence probabilities.
SEMANTIC_EQUIVALENCE: approximate and context-dependent, never presumed exact.
FLOW_HASH: calculate SHA-256 over canonical UTF-8 flow content at publication; not precomputed here.
UPDATE_MODEL: version embeddings, refresh on source/model changes, retain audit trail.

END OF FLOW
Kireth Research
38 Thorndale Croft, Wetwang, Driffield
East Riding of Yorkshire YO25 9XZ