Skip to content

Lucineer/constraint-theory-web

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Constraint Theory Web

A lightweight web visualization tool for observing constraint propagation systems. Built for the Cocapn Fleet, it renders constraint networks in your browser so you can watch relationships resolve in real time.


Why this exists

Constraint logic often operates as an invisible layer within applications. This tool provides a simple, shareable way to see that logic at work—useful for debugging, learning, or explaining how propagation unfolds. It runs entirely in the browser.


Quick Start

  1. Fork this repository – development starts with a fork.
  2. 𝗗𝗲𝗽𝗹𝗼𝘆 to Cloudflare Workers (no build step).
  3. Your visualization will be live at your Worker URL.

What it does

  • Renders an interactive, draggable constraint network.
  • Simulates step-by-step or continuous propagation.
  • Accepts custom constraint systems via a simple object format.
  • Includes several example systems to explore.
  • Registers automatically with the Cocapn Fleet upon deployment.

What it doesn't do

  • It is not a constraint solver. It visualizes propagation logic you provide.
  • Performance degrades with networks exceeding ~50 nodes (it's a visualization tool, not an engine).

Technical notes

  • Zero dependencies. A single Worker file.
  • All state persists in the browser; no data is sent elsewhere.
  • Typical cold starts are fast on Cloudflare's network.
  • Modify styling, layout, and animation in src/.

Live example

A deployed instance is available at:
https://the-fleet.casey-digennaro.workers.dev/constraint-viewer


Bring your own system

Define nodes, edges, and propagation rules using the plain object format in the examples. The renderer handles layout and simulation without requiring core modifications.


Contributing

This is a fork-first open source project. Fork it, adapt it for your needs, and if you build something generally useful, consider opening a pull request.


License

MIT License.

Attribution: Superinstance & Lucineer (DiGennaro et al.)


About

Constraint Theory — web visualization of constraint propagation systems

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors