Cohesive 0.1.0-alpha.80

This is a prerelease version of Cohesive.
dotnet add package Cohesive --version 0.1.0-alpha.80
                    
NuGet\Install-Package Cohesive -Version 0.1.0-alpha.80
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Cohesive" Version="0.1.0-alpha.80" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Cohesive" Version="0.1.0-alpha.80" />
                    
Directory.Packages.props
<PackageReference Include="Cohesive" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Cohesive --version 0.1.0-alpha.80
                    
#r "nuget: Cohesive, 0.1.0-alpha.80"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Cohesive@0.1.0-alpha.80
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Cohesive&version=0.1.0-alpha.80&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Cohesive&version=0.1.0-alpha.80&prerelease
                    
Install as a Cake Tool

Cohesive

Cohesive contains the portable values, shape model, expression IR, execution contracts, and provenance primitives shared by every Cohesive block and adapter.

Install

dotnet add package Cohesive

Start with a shape

Ordinary CLR types can produce a deterministic shape graph without hand-authoring fields or node identities:

using Cohesive.Model;

[ShapeDefinition("shape.shipment", ShapeRoles.Transport)]
public sealed record Shipment(string Id, IReadOnlyList<Stop> Stops);

[ShapeType("type.stop")]
public sealed record Stop(string City, string State);

var graph = new ClrShapeGraphBuilder()
    .AddShape<Shipment>()
    .Build(new("shipping"));

The graph records the semantic types, fields, cardinalities, roles, and CLR provenance used by higher-level blocks. It can be persisted, validated, generated into another host language, or interpreted by a target adapter.

What this package provides

  • Graph-qualified shapes, fields, paths, scalar types, cardinality, and nullability.
  • Immutable ObservationValue and Observation values with exact shape evidence.
  • Explicit EntityObservationSnapshot values when identity and version apply.
  • Portable Expr definitions and expression-site analysis shared by compilers and interpreters.
  • Canonical execution-definition, interaction, control, trace, explain, provenance, and compatibility contracts.
  • Common typed quantities, identifiers, codes, paths, diagnostics, and deterministic serialization helpers.

The package does not define Relations, Transitions, Processes, APIs, presentation, storage, or provider behavior. Those blocks depend on these shared semantic contracts.

Observations and snapshots

An Observation describes an immutable shaped value. Entity identity and version remain explicit rather than being silently attached to every value:

Shipment shipment = observation.Materialize<Shipment>();

var snapshot = new EntityObservationSnapshot(
    new EntityId("shipment-42"),
    version: 3,
    observation);

Physical layouts, source placement, relation occurrences, and storage concurrency tokens belong to the interpreting block or adapter.

Go deeper

Related application blocks include Cohesive.Relations, Cohesive.Transitions, and Cohesive.Processes.

Ordinal observation construction

Observation.Create(shape, layout, immutableValues) retains an ImmutableArray<ObservationValue> in a shared ObservationLayout; the span overload snapshots caller-owned values. Layouts belong to the exact graph instance and shape from which they were compiled. Each slot is one canonical field: Undefined means absent, while Null remains present. Full shape validation still runs. Name-based Fields is an immutable view over the same vector, and canonical serialization, equality, and fingerprints are independent of physical field order. The field view also implements IOrdinalObservationFieldReader, allowing a materializer compiled against that layout to read directly by ordinal.

Default CLR materialization converts native byte observations directly to an independently owned byte[], including inside conventional nested records and arrays. This copies mutable output once; it does not route bytes through JSON text. Explicit serializer customizations retain their chosen conversion contract. Durable detached observation values can opt into PortableValueJsonConverter.TaggedObservationValues, which reuses the PortableValue node encoding to preserve byte, temporal, numeric, and undefined kinds. Opting in changes the wire format and requires a versioned profile; ordinary observation JSON remains unchanged. Entity receipts use the explicit EntityStorageJson profile in Storage.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (24)

Showing the top 5 NuGet packages that depend on Cohesive:

Package Downloads
Cohesive.Relations

Cohesive semantic system definition and orchestration building blocks.

Cohesive.Transitions

Cohesive semantic system definition and orchestration building blocks.

Cohesive.Processes

Cohesive semantic system definition and orchestration building blocks.

Cohesive.Api

Cohesive semantic system definition and orchestration building blocks.

Cohesive.Storage

Cohesive semantic system definition and orchestration building blocks.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.0-alpha.80 133 9/8/2026
0.1.0-alpha.79 187 9/7/2026
0.1.0-alpha.78 166 9/7/2026
0.1.0-alpha.77 166 9/7/2026
0.1.0-alpha.76 220 9/6/2026
0.1.0-alpha.75 243 9/6/2026
0.1.0-alpha.74 225 9/6/2026
0.1.0-alpha.73 285 9/5/2026
0.1.0-alpha.72 221 9/5/2026
0.1.0-alpha.71 217 9/4/2026
0.1.0-alpha.70 226 9/4/2026
0.1.0-alpha.69 233 9/2/2026
0.1.0-alpha.68 205 8/30/2026
0.1.0-alpha.67 393 8/26/2026
0.1.0-alpha.66.5 238 9/6/2026
0.1.0-alpha.66.4 291 8/30/2026
0.1.0-alpha.66.3 204 8/29/2026
0.1.0-alpha.66.2 203 8/27/2026
0.1.0-alpha.66.1 207 8/26/2026
0.1.0-alpha.66 274 8/25/2026
Loading failed