Skip to main content

Large Language Model Ontology

AI Model Entities
Authors: MArk Anthony Higgins - Sky Recursive Ai
© Mark Anthony Higgins 11 October 2025
Revised Date: 28 October 2026
Audio Overview
FLOW ALGEBRA — LARGE LANGUAGE MODEL ONTOLOGY
Version: 1.0 | 28 October 2026 | Language: en-GB
Authors: Mark Anthony Higgins — Sky, Recursive AI
Source: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/ai-model-entities/large-language-model-ontology-2.html
Status: Original companion formalisation. The page heading and attribution were accessible; the complete embedded ontology specification was not available for verification.

1. PURPOSE
Represent a large language model (LLM) as an identifiable model entity with tokenisation, parameters, context, inference, training provenance, constraints and auditable output pathways. Distinguish probabilistic generation from verified knowledge or guaranteed correctness.

2. ENTITY MODEL
LLM := (ID, A, T, Theta, C, D, P, G, S, V)
ID: stable model identifier and version.
A: architecture and computation graph.
T: tokenizer and vocabulary.
Theta: learned parameter state.
C: context and token budget.
D: training and adaptation provenance where known.
P: inference and decoding policy.
G: permitted tools, retrieval and grounding interfaces.
S: safety and operational constraints.
V: validation, evaluation and revision metadata.

Relations:
instance_of(LLM, LanguageModel)
implements(LLM, ConditionalTokenDistribution)
uses(LLM, Tokenizer)
parameterised_by(LLM, Theta)
conditioned_on(LLM, Context)
subject_to(LLM, SafetyPolicy)
may_use(LLM, RetrievalOrTools)

3. FORMAL STATE
S_t = (I_t, R_t, B_t, K_t)
I_t: input tokens, task and conversation context.
R_t: inference, retrieval and tool-use rules.
B_t: budget, permissions, latency and safety boundaries.
K_t: model parameters plus permitted working knowledge and evidence.
E_t = expand(I_t, R_t)
V_t = {x in E_t | satisfies(x, B_t) and supported(x, K_t)}
x*_t = argmax_{x in V_t} P(x | I_t, R_t, B_t, K_t)
I_(t+1) = update(I_t, x*_t, observations_t)
Note: argmax is a formal selection abstraction; actual decoding can sample, beam-search or use other policies. 'supported' means compliant with the configured evidence policy, not necessarily factually true.

4. TOKEN GENERATION
x = T.encode(prompt)
h_t = A_Theta(x_<=t, cache_t)
p_t(v) = softmax(logits_Theta(h_t) / tau)_v
x_(t+1) ~ Decode(p_t, P)
y = T.decode(x_generated)
Constraints: token_budget(x, y) <= C; tau > 0 when temperature scaling is used.
Autoregressive factorisation: P(y_1:n | x) = product_{i=1..n} P(y_i | x, y_<i).
This is a common architecture pattern, not a claim that all LLMs share identical architectures.

5. TRAINING AND ADAPTATION
Pretraining objective (illustrative): L_pre = -sum_i log P_Theta(y_i | y_<i).
Theta' = Optimise(Theta, L_pre, training_data, configuration).
Adaptation may use supervised fine-tuning, preference optimisation, adapters or retrieval without weight updates.
Separate: model_weight_change != context_update != external_memory_update.
Training provenance must be labelled unknown where evidence is absent.

6. FLOW IMPLEMENTATION
flow "LargeLanguageModelEntity" v1.0
  input: prompt, context, policy, optional_evidence
  validate: permissions, size, schema, source_provenance
  encode: tokenizer(prompt + allowed_context)
  infer: model(tokens, parameters, inference_policy)
  constrain: safety_policy + output_contract + resource_limits
  ground: cite_or_flag_unverified(optional_evidence)
  decode: output_tokens -> response
  evaluate: format, consistency, provenance, uncertainty
  emit: response, trace_metadata, validation_status
end

7. INFERENCE RULES
R1: if input_exceeds_context then reject_or_truncate_with_disclosure.
R2: if external_fact_required and no verified_evidence then label_as_unverified.
R3: if tool_result_used then preserve provenance and trust boundaries.
R4: if unsafe_or_unauthorised_action then do_not_execute.
R5: if output_schema_requested then validate before acceptance.
R6: if model_version_changes then invalidate version-dependent guarantees.
R7: if model_weights_unchanged then in-context adaptation is not parameter training.
R8: if probability_high then do_not_infer_truth_without_independent_evidence.
R9: if recursive_refinement then enforce iteration, time and token bounds.
R10: if sensitive_input then apply data minimisation and authorised handling.

8. TRI-MAPPING
Entity layer: LLM, Tokenizer, Parameters, Context, Decoder, Tool, Evidence.
Relationship layer: uses, conditioned_on, generates, retrieves, validates, governed_by.
Flow layer: input -> tokenise -> infer -> constrain -> ground -> decode -> validate -> output.
Mapping:
LLM -> implements -> conditional generation
Tokenizer -> transforms -> text/token sequence
Context -> conditions -> inference state
Decoder -> selects -> next-token sequence
Evidence -> supports_or_disputes -> output claims
SafetyPolicy -> restricts -> actions and outputs
Validator -> checks -> output contract

9. SYSTEM DIAGRAM (TEXT)
[User/task] -> [Input validation] -> [Tokenizer] -> [LLM inference]
                                           |              |
                                      [Context]     [Policy checks]
                                                          |
                                  [Optional retrieval/tool evidence]
                                                          |
                                             [Decode and validation]
                                                          |
                                          [Output + provenance]

10. HOW TO READ
The ontology identifies the model as an entity, defines its relations, and maps an input through bounded probabilistic inference to a validated response. The algebra specifies an analysis framework rather than executable source code or a proof of model reliability.

11. EXECUTION GUARANTEE (CONDITIONAL)
If all required components are available, inputs are valid, boundaries are enforced, and validation passes, the flow returns a schema-conforming output or an explicit failure state.
No guarantee is made of factual truth, deterministic repeatability, universal safety, or task success.
Failures: invalid_input, context_overflow, policy_block, tool_failure, insufficient_evidence, validation_failure, resource_exhaustion.

12. AI SEARCH FLOW
flow "AISearch_LargeLanguageModelOntology" v1.0
  intent: identify, classify and reason about LLM entities
  match_terms: [large language model, LLM, tokenizer, transformer, parameters, decoding, context window, inference]
  canonical_source: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/ai-model-entities/large-language-model-ontology-2.html
  entity: LargeLanguageModel
  parent: AIModelEntities > LanguageModel
  expand: architecture, training, adaptation, evaluation, safety, provenance
  filter: relevance, source_quality, permission, temporal_validity
  rank: semantic_match + verified_evidence + provenance_quality
  return: ontology_definition, relations, flow, limitations, citation
end

13. CITATION AND REUSE
Credit: Mark Anthony Higgins and Sky — Recursive AI.
Source URL above. This companion Flow Algebra is a newly authored interpretation and must not be mistaken for a verbatim copy of the site's hidden AI Search specification.
Kireth Research
38 Thorndale Croft, Wetwang, Driffield
East Riding of Yorkshire YO25 9XZ