Skip to main content

Workflow Execution Ontology

Workflow Entities
Authors: MArk Anthony Higgins - Sky Recursive Ai
© Mark Anthony Higgins 11 October 2025
Revised Date: 02 November 2026
Audio Overview
WORKFLOW EXECUTION ONTOLOGY — FLOW ALGEBRA
Semantic Library | AI Core | Entity Graph | Workflow Entities

SOURCE: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/workflow-entities/workflow-execution-ontology.html
SOURCE AUTHORS: Mark Anthony Higgins — Sky Recursive AI
SOURCE COPYRIGHT: © Mark Anthony Higgins, 11 October 2025
SOURCE REVISION: 01 August 2026
COMPANION FORMALISATION: 02 November 2026
STATUS: Original companion formalisation. The public page identifies the ontology and its authors but does not expose the full embedded specification in the accessible page text. The formal rules below are therefore proposed, not a verbatim transcription.

1. PURPOSE
Represent workflow execution as a sequence of authorised, dependency-satisfied, constraint-valid state transitions, with explicit provenance, outputs, failure handling and termination.

2. ENTITY MODEL
WorkflowExecution E = (W, Q, C, D, G, T, X, H, O, Z)
W : workflow definition and version
Q : execution status and current step
C : execution context and inputs
D : dependency graph
G : guards, conditions and constraints
T : transition relation
X : execution trace
H : retry, timeout and error-handling policy
O : emitted outputs and effects
Z : terminal outcome

Statuses = {created, ready, running, waiting, succeeded, failed, cancelled, timed_out}.
Terminal = {succeeded, failed, cancelled, timed_out}.

3. FORMAL STATE MODEL
S_t = (I_t, R_t, B_t, K_t)
I_t : observed workflow inputs and execution events
R_t : transition, scheduling, safety and validation rules
B_t : permitted actions, resource limits and boundaries
K_t : known state, trace, dependencies and results

Candidate transitions:
E_t = expand(I_t, R_t)
V_t = {a in E_t | dependencies_met(a,K_t) AND guard_true(a,K_t)
                   AND constraints_hold(a,B_t) AND authorised(a,B_t)}

Decision:
a*_t = argmax_{a in V_t} P(a | I_t,R_t,B_t,K_t)

State update:
K_{t+1} = update(K_t, execute(a*_t), observations_t)

NOTE: Probability-based selection is optional. Where execution must be deterministic, replace argmax with a declared priority or stable ordering. An empty V_t must never imply permission to execute an invalid action.

4. WORKFLOW TRANSITION ALGEBRA
Ready(s,t) := Pending(s,t) AND AllRequiredPredecessorsSucceeded(s,t)
              AND Guard(s,t) AND WithinBounds(s,t)

Start(s): ready -> running
Complete(s,r): running -> succeeded, output(s)=r
Reject(s,e): running -> failed, error(s)=e
Wait(s,d): ready -> waiting if unresolved dependency d
Resume(s): waiting -> ready only after revalidation
Cancel(s): nonterminal -> cancelled under authorised cancellation
Timeout(s): running or waiting -> timed_out when deadline exceeded

A transition is valid iff its preconditions, guard and policy hold at commit time.

5. EXECUTION RULES
R1. A step MUST NOT start before all mandatory dependencies are satisfied.
R2. Guards and constraints MUST be evaluated against the applicable current state.
R3. An execution MUST preserve its workflow version and input provenance.
R4. Every attempted transition MUST append an ordered trace record.
R5. A retry MUST obey bounded attempt limits, backoff and idempotency policy.
R6. External side effects MUST use deduplication, transactional or compensation mechanisms as appropriate.
R7. A terminal execution MUST NOT silently resume; a new run or explicit recovery process is required.
R8. Missing permissions, invalid inputs or violated safety constraints block execution.
R9. Parallel steps MAY execute only when their dependencies and shared-resource constraints permit it.
R10. A result MUST distinguish observed success from merely scheduled or attempted work.

6. EXECUTION INVARIANTS
INV1: terminal(E) => no ordinary outgoing execution transitions.
INV2: succeeded(s) => completed_at(s) exists AND result_validated(s).
INV3: running(s) => previously authorised(s) AND dependencies_met_at_start(s).
INV4: attempts(s) <= max_attempts(s), when a finite bound is configured.
INV5: each recorded output links to the producing step and execution run.
INV6: a committed transition has one consistent trace sequence number.

7. INFERENCE RULES
IF dependencies_met(s) AND guard_true(s) AND constraints_hold(s)
THEN eligible(s).

IF eligible(s) AND scheduler_selects(s) AND authorised(s)
THEN may_start(s).

IF running(s) AND validated_success_event(s,r)
THEN succeeded(s) AND output(s,r).

IF running(s) AND recoverable_error(s) AND attempts_remaining(s)
THEN retry_candidate(s), subject to policy.

IF any mandatory step permanently fails AND no recovery branch exists
THEN workflow_failed(E).

IF every required terminal goal is satisfied AND no mandatory work remains
THEN workflow_succeeded(E).

8. TRI-MAPPING
Entity graph: WorkflowExecution --executes--> Workflow
              WorkflowExecution --runs--> WorkflowStage
              WorkflowStage --depends_on--> WorkflowStage
              WorkflowExecution --produces--> WorkflowOutput

Relationship graph: depends_on, enables, blocks, retries, produces,
                    validates, cancels, records, terminates.

Flow algebra: eligibility -> selection -> authorised transition ->
              observation -> validation -> state update -> repeat/terminate.

9. EXECUTION DIAGRAM
[Inputs + Workflow Definition]
             |
             v
[Validate schema / policy / version]
             |
             v
[Evaluate dependencies + guards + bounds]
       | eligible            | blocked
       v                     v
[Select authorised step]  [Wait / reject / fail]
       |
       v
[Execute + record trace]
       |
       v
[Validate result and side effects]
       | success       | recoverable error       | terminal error
       v               v                         v
[Update state]     [Bounded retry]             [Fail / compensate]
       |
       v
[Goals complete?] -- no --> [Re-evaluate next step]
       |
      yes
       v
[Emit validated outputs + terminal status]

10. MAPPING TABLE
Workflow definition  -> W -> immutable run reference/version
Workflow state       -> Q -> current lifecycle status
Workflow input       -> C -> validated input binding
Workflow dependency  -> D -> prerequisite satisfaction
Workflow condition   -> G -> Boolean/three-valued guard
Workflow constraint  -> G,B -> admissibility boundary
Workflow trigger     -> I -> event enabling evaluation
Workflow branch      -> T -> conditional successor choice
Workflow loop        -> T,H -> bounded repeated transitions
Workflow output      -> O -> validated produced artefact
Workflow execution   -> E,X,Z -> run, trace and terminal outcome

11. VALIDATION AND EXECUTION GUARANTEE
Guarantee (conditional): IF all transitions obey the declared preconditions,
resource constraints, atomicity assumptions and trace rules, THEN every
committed transition is policy-admissible under the state snapshot checked.

This is NOT a guarantee of eventual termination, availability, correctness of
external services, absence of races or successful real-world side effects.
Those properties require separately stated assumptions and verification.

12. AI SEARCH FLOW
FLOW_ID: workflow-execution-ontology
FLOW_VERSION: 1.0
ENTITY_TYPE: WorkflowExecution
PURPOSE: Determine which workflow step may run, how it changes state, and
         how to validate and record its outcome.
INPUTS: workflow, version, context, dependency state, guards, constraints,
        scheduler policy, permissions, events, resource limits.
OUTPUTS: eligible steps, selected transition, updated execution state,
         validated artefacts, ordered trace, terminal status or error.
PATHWAY: parse -> validate -> resolve dependencies -> evaluate guards ->
         select -> authorise -> execute -> observe -> validate -> commit.
MINI_RECURSION_ENGINE: repeat pathway while nonterminal and eligible work
                       exists; apply bounded retries and timeout policies.
CONFIDENCE: evidence-based, not a substitute for validation.
SEMANTIC_EQUIVALENCE: workflow run; workflow enactment; execution instance.
UPDATE_MODEL: append trace event and recompute affected eligibility.
SOURCE: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/workflow-entities/workflow-execution-ontology.html
CITATION_BACKLINK: https://kirethresearch.org/booksai-core/entity-graph/ai-entities/workflow-entities/workflow-execution-ontology.html
AUTHORS: Mark Anthony Higgins — Sky Recursive AI

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