Building Blocks
Cohesive. Core
Cohesive.Core is the foundational semantic block for shapes, observations, values, expressions, annotations, and the shared vocabulary that the rest of Cohesive builds on.
Define meaning once, then attach many interpretations. Core gives higher-level blocks a stable way to describe structure, facts, and computation without binding those definitions to a transport, framework, database, or UI runtime.
Semantic Substrate
Cohesive.Core is the common language used by the other Cohesive blocks. Relations use it to describe projections, transitions use it to describe legal state changes, processes use it to coordinate work over time, presentation uses it to bind UI surfaces, and adapters use it to project the model into infrastructure.
At the center are three ideas:
- Shapes define structured meaning.
- Observations capture concrete facts against shapes.
- Expressions describe portable computation over fields, parameters, constants, functions, predicates, and derived values.
Shapes And Graphs
A Shape identifies a kind of value or entity state. It declares fields, constraints, canonical names, annotations, and role metadata that interpreters can preserve.
A shape graph collects related shapes so tooling can reason over type references, validation, evolution, generated contracts, relation targets, transition state, and presentation bindings.
This keeps domain structure more semantic than raw JSON schema and more portable than a single CLR or TypeScript type.
Observations And Values
An Observation is a shaped fact. It carries a shape id, stable observation identity, version, field values, indexed field layout, and optional lineage metadata.
ObservationValue is the shared value representation for scalar, temporal, binary, array, object, null, and undefined values. That shared representation lets facts move through validation, relation execution, transition updates, presentation projection, and serialization without repeated loose conversions.
Expressions
The Cohesive expression model is a portable computation IR. An Expr can represent field references, parameters, constants, operators, conditionals, function calls, aggregates, joins, grouping, and related-field access.
Expressions are used for mapping assignments, transition preconditions, state updates, effect payloads, action enablement, visibility, metrics, data-source parameters, and labels.
The important part is not only execution. Expressions preserve dependencies, read sets, write sets, return hints, lineage, validation context, and future projection opportunities.
Why It Matters
Most systems scatter meaning across DTOs, database rows, workflow code, form schemas, validators, generated clients, and adapter-specific configuration. Core gives those pieces a shared source of meaning.
That enables teams to:
- Keep structure separate from transport and framework details.
- Reuse shape definitions across backend, frontend, relations, and generated artifacts.
- Validate observations against declared shapes.
- Preserve field dependencies and lineage.
- Infer read and write sets from expressions.
- Build higher-level tools such as Ari on a stable semantic foundation.
