ArcFlow
Company
Managed Services
Markets
  • News
  • LOG IN
  • GET STARTED

OZ brings Visual Intelligence to physical venues, a managed edge layer that lets real-world environments see, understand, and act in real time.

Talk to us

ArcFlow

  • World Models
  • Sensors

Managed Services

  • OZ VI Venue 1
  • Case Studies

Markets

  • Sports
  • Broadcasting
  • Robotics

Company

  • About
  • Technology
  • Careers
  • Contact

Ready to see it live?

Talk to the OZ team about deploying at your venues, from a single pilot match to a full regional rollout.

Schedule a deployment review

© 2026 OZ. All rights reserved.

LinkedIn
ArcFlow Docs
Start
  • Quickstart
  • Installation
  • Bindings
  • Platforms
  • Get Started
  • Cookbook
Concepts
  • World Model
  • Graph Model
  • Evidence Model
  • Observations
  • Confidence & Provenance
  • Proof Artifacts & Gates
  • SQL vs GQL
  • Graph Patterns
  • Parameters
  • Query Results
  • Persistence & WAL
  • Snapshot-Pinned Reads
  • Error Handling
  • Execution Models
  • Causal Edges
  • Adapter Discipline
  • Time Decay
  • Layers
  • 1. World Store
  • 1a. World Store · Smart Reader
  • 2. Perception Lake
  • 3. World Graph
  • 4. Query Engine
  • 5. Live Surface
  • 6. Event Bus
  • 7. Behavior Engine
  • 8. Algorithm Library
  • Virtual Computed Columns
  • Threading Model
  • Typed ID Contract
WorldCypher
  • Overview
  • Execution Options
  • Statements
  • MATCH
  • WHERE
  • RETURN
  • OPTIONAL MATCH
  • CREATE
  • SET
  • MERGE
  • DELETE
  • REMOVE
  • Composition
  • WITH
  • UNION
  • UNWIND
  • CASE
  • Schema
  • Schema Overview
  • Indexes
  • Constraints
  • Functions
  • Built-in Functions
  • Aggregations
  • Procedures
  • Shortest Path
  • EXPLAIN
  • PROFILE
  • Temporal Queriesfacet
  • Spatial Queriesfacet
  • Algorithmsfacet
  • Triggers
Capabilities
  • Live Queries
  • Vector Search
  • Trusted RAG
  • Spatial Knowledge
  • Temporal
  • Behavior Graphs
  • Graph Algorithms
  • Skills
  • CREATE SKILL
  • PROCESS NODE
  • REPROCESS EDGES
  • Sync
  • Programs
  • GPU Acceleration
  • Agent-Native
  • MCP Server
  • Event Sourcing
  • Intent Relay
  • Event Bus
Use Cases
  • Agent Tooling
  • Trusted RAG
  • Knowledge Management
  • Behavior Graphs
  • Autonomous Systems
  • Physical AI
  • Digital Twins
  • Robotics & Perception
  • Sports Analytics
  • Grounded Neural Objects
  • Fraud Detection
Walkthroughs
    Guides
  • Agent Integration
  • Building a World Model
  • Modeling a Social Graph
  • Build a RAG Pipeline
  • Using Skills
  • Behavior Graphs
  • Swarm & Multi-Agent
  • Fleet Coordination
  • Migrate from Cypher / Neo4j
  • From SQL to GQL
  • Filesystem Workspace
  • Data Quality
  • Code Intelligence
  • Scale Patterns
  • v0.7 → v0.8 Lakehouse Fast-Path
  • Tutorials
  • Knowledge Graph
  • Entity Linking
  • Vector Search
  • Graph Algorithms
  • Recipes
  • CRUD
  • Multi-MATCH
  • MERGE (Upsert)
  • Full-Text Search
  • Batch Projection
  • Multi-Source Observation
  • Sports Analytics
Operations
  • CLI
  • REPL Commands
  • Snapshot & Restore
  • Filesystem Projection
  • Plugin Management
  • Agent Governance
  • Server Modes & PG Wire
  • Persistence (ops)
  • Import & Export
  • Deployment
  • Deployment Modes
  • Daemon (UDS)
  • Why not Docker
  • Architecture
  • Engine Architecture
  • Cloud Architecture
  • Sync Protocol (Deep Dive)
  • World Graph Substrate (Preview)
Reference
  • TypeScript API
  • Glossary
  • Naming & Domain Map
  • Data Types
  • Operators
  • Error Codes
  • GQL Reference
  • Known Issues
  • Versioning
  • Licensing
  • Conformance
  • GQL Conformance
  • openCypher TCK
  • Extension Regressions
GQL Reference
    Conformance
  • Conformance Dashboard
  • openCypher TCK Results
  • Extension Regressions
  • Features
  • MATCH Basic
  • CREATE Nodes Edges
  • SET REMOVE Properties
  • DELETE Detach DELETE
  • RETURN WITH WHERE
  • Order BY Limit Skip
  • Order BY Nulls First Last
  • UNWIND
  • Aggregate Functions
  • OPTIONAL MATCH
  • Variable Length Paths
  • Label OR AND NOT Expressions
  • Label Wildcard
  • Quantified Path Sugar
  • Path Modes Walk Trail Simple Acyclic
  • Shortest Path Variants
  • IS Labeled Predicate
  • Element ID Function
  • IS Type Predicate
  • Binary Literals
  • Line Comments Solidus
  • Line Comments Minus
  • GQLSTATUS Result Codes
  • GQL Error Code Mapping
  • Transaction Control Syntax
  • SET Session
  • Conditional Execution WHEN THEN ELSE
  • RETURN NEXT Pipeline
  • Primary Key Constraint
  • Unique Constraint
  • Deterministic MERGE Via PK
  • Undirected Edge MATCH
  • Cast Type Conversion
  • GQL Directories
  • Multiple Labels Per Node
  • GQL Flagger
  • NEXT Linear Composition
  • Cardinality Function
  • INT64 BIGINT Type Names
  • FLOAT64 Double Type Names
  • Log10 Log2 Functions
  • Trim Leading Trailing Both
  • FILTER Clause
  • LET Statement
  • Group BY Explicit
  • EXCEPT SET Operations
  • INTERSECT SET Operations
  • ALL Different Predicate
  • Same Predicate
  • Property Exists Function
  • Path Variable Binding
  • USE Graph Clause
  • FOR IN List
  • Typed Temporal Literals
  • Session SET Value Params
  • Typed List Annotations
  • arcflow.cosine() function
  • arcflow.embed() function
  • arcflow.similar() procedure
  • arcflow.graphrag() procedure
  • ArcFlow Extensions
  • LIVE Queries
  • Triggered Write-Back Views
  • Evidence Algebra
  • Relationship Skills
  • AI Function Namespace
  • Graph Embedding Algorithms
  • ASOF JOIN
  • Durable Workflows
  • Incremental Z-Set Engine
  • GPU GraphBLAS
  • Triggers
  • HNSW Vector Index
  • Extensions Moat

Sync

The full persistent world model — spatial positions, temporal history, confidence scores, observation classes — runs locally and replicates to cloud automatically. Local operations are instant: no round-trip, no network dependency, no blocking. Sync is eventual, conflict-resolved by confidence and temporal precedence, and resumable. The local world model stays authoritative. Cloud stays consistent. Multiple agents can each maintain their own local world model and converge on shared state without central coordination.

Local instance              Cloud
┌──────────────────┐  HTTPS  ┌──────────────────┐
│ Browser (WASM)   │────────→│ ArcFlow Cloud    │
│ Node.js process  │←────────│                  │
│ Edge device      │  sync   │ Persistent graph │
└──────────────────┘         └──────────────────┘

How it works#

Every mutation is captured in a sync WAL (write-ahead log). The sync engine pushes WAL entries to the cloud and pulls remote changes back.

import { openInMemory } from '@ozinc/arcflow'
 
const db = openInMemory()
 
// Mutations are automatically captured in the sync WAL
db.mutate("CREATE (n:Person {name: 'Alice', age: 30})")
db.mutate("CREATE (n:Person {name: 'Bob', age: 25})")
 
// Check how many mutations are pending sync
console.log(db.syncPending())  // 2
 
// Read queries don't enter the WAL
db.query("MATCH (n:Person) RETURN n.name")
console.log(db.syncPending())  // still 2
 
// Graph fingerprint — hash of current state
console.log(db.fingerprint())  // "29553633"

Sync WAL#

The sync WAL captures every mutating query automatically. Read queries are never captured.

OperationEnters WAL?
db.mutate("CREATE ...")Yes
db.mutate("SET ...")Yes
db.mutate("DELETE ...")Yes
db.batchMutate([...])Yes (each query)
db.query("MATCH ...")No
db.query("CALL algo...")No
db.stats()No

Fingerprint#

The graph fingerprint is a hash of the entire graph state — generation, node count, relationship count, mutation sequence. Two instances with the same fingerprint have identical content.

const fp1 = db.fingerprint()
db.mutate("CREATE (n:Change {v: 1})")
const fp2 = db.fingerprint()
// fp1 !== fp2 — fingerprint changes after mutation

Use fingerprints to verify sync consistency: after a sync cycle, both client and cloud should have the same fingerprint.

Sync protocol#

The sync engine uses a push/pull protocol with resume via high-water marks:

  1. Push: local WAL entries batched into a sync request and POST'd to cloud
  2. Ack: cloud responds with acked_seq + fingerprint
  3. Pull: client requests changes since its remote_hwm
  4. Apply: remote queries replayed locally
  5. Verify: fingerprints compared — match = consistent

Sync request format#

{
  "peer_id": "node-1",
  "seq_start": 1,
  "seq_end": 3,
  "queries": [
    "CREATE (n:Person {name: 'Alice'})",
    "CREATE (n:Person {name: 'Bob'})",
    "CREATE (a:Person {name: 'Alice'})-[:KNOWS]->(b:Person {name: 'Bob'})"
  ],
  "fingerprint": 29553633
}

Queries are replayed on the receiving end — MERGE for idempotent operations, CREATE for new data.

Conflict resolution#

When two clients mutate concurrently, conflicts are resolved using vector clocks:

StrategyRuleDefault
Last-writer-winsHigher vector clock winsYes
First-writer-winsEarlier clock winsOptional
Evidence-weightedHigher confidence winsFor observation data

LAN Discovery#

ArcFlow instances on the same network discover each other automatically via UDP multicast. No configuration needed — peers announce themselves and sync propagates across the mesh.

Group:    239.255.0.1:7947
Announce: every 5 seconds
Stale:    60 seconds (peer removed if no heartbeat)
Protocol: {"op":"announce","peer_id":"af-abc123","data_port":7948}

CLI commands for mesh status:

arcflow sync health   # Show discovered peers
arcflow sync scopes   # List registered sync scopes
arcflow sync announce # Print this node's announcement JSON

Supported transports#

TransportHow
HTTP push/pullarcflow sync push/pull
Background auto-syncarcflow sync start daemon
LAN peer discoveryUDP multicast announce
WebSocket delta-pushLive delta stream over WS
ArcFlow WAL StreamHigh-throughput WAL streaming to read replicas
Object-store fan-outWAL segments written to S3/GCS/Azure for durable replication
WASM (browser)Not yet supported

Replication (SWMR)#

ArcFlow supports a Single-Writer-Multiple-Reader replication model via ArcFlow WAL Stream. The primary node streams WAL entries directly to read replicas, which apply them in order.

-- Check SWMR contract and replication configuration
CALL arcflow.replication.contract()
  YIELD mode, writes_enabled, replication_factor, description
 
-- ArcFlow WAL Stream parameters
CALL arcflow.replication.walTailing()
  YIELD field, value, description
 
-- Object-store fan-out configuration (S3/GCS/Azure)
CALL arcflow.replication.objectStoreFanout()
  YIELD field, value, description
 
-- Live replication health
CALL db.replicationStatus()

The mode from arcflow.replication.contract() is one of "primary", "replica", or "standalone". writes_enabled is false on read replicas.

API reference#

interface ArcflowDB {
  // ... existing methods ...
 
  /** Number of mutations pending sync push (0 if sync not configured). */
  syncPending(): number
 
  /** Graph fingerprint for sync verification. */
  fingerprint(): string
}

Sync subsystem#

ComponentWhat it provides
WAL delta captureMutating queries recorded with sequence numbers
Batched transportQueries batched for efficient push/pull
Push/pull orchestrationCoordinator for outbound and inbound sync
Pluggable transportMemory mock, HTTP, WASM fetch — same protocol
Causal orderingVector clock across peers for consistent ordering
Conflict detectionEntity-level detection and resolution
Fingerprint verificationState hash ensures sync consistency
Remote replayApply remote mutation queries locally

Architecture deep dive#

See Sync Architecture for the full protocol specification, implementation waves, and engine primitive mapping.

See Also#

  • Sync Architecture — full protocol specification, vector clocks, and engine primitives
  • Event Sourcing — WAL replay and temporal audit trail built on the same mutation log
  • Live Queries — live views that sync across nodes as CDC
  • Cloud Architecture — distributed mesh, ArcFlow WAL Stream, multi-region
Try it
Open ↗⌘↵ to run
Loading engine…
← PreviousREPROCESS EDGESNext →Programs