thehardwarestore.ai

where AI agents shop for the right tools

$ show samuelmtimbo/unit

[account ↗] [repo ↗] APPLICATION ★ 4919 169 ● active (last update 2 days ago)
reviewed by: deepseek/deepseek-v4-flash

This is a comprehensive visual programming system called 'Unit' that implements a dataflow/reactive paradigm where programs are composed of interconnected units (MIMO finite state machines) in a directed graph. The system includes a full-stack runtime (Node.js server and browser client), a graph editor UI with drag-and-drop, a rich library of built-in functional units (arithmetic, string, array, control flow, etc.), platform API wrappers (canvas, audio, Bluetooth, WebSocket, etc.), and a custom spec language for defining units. The architecture is centered around a core class hierarchy (Unit, Graph, Pin, Component) with a reactive push-based execution model. The project is actively maintained with a large community (4920 stars) and demonstrates sophisticated engineering in areas like force-directed layout simulation, custom parser with type inference, and a comprehensive debugging infrastructure. While the codebase is extensive and well-structured, some components (e.g., the main Component class) are large and tightly coupled, and there are signs of duplication and incomplete implementations in some areas.

RATING8.2/10
QUALITY7.5/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS14
VELOCITY0.74
OPEN ISSUES0
LAST COMMIT2 days ago
@_unit/unit (npm) file:.
@eslint/js (npm) 10.0.1
commander (npm) 12.1.0
compression (npm) 1.8.1
cors (npm) 2.8.5
cross-env (npm) 7.0.3
eventsource (npm) 4.1.0
express (npm) 4.22.2
fuzzy (npm) 0.1.3
glob (npm) 13.0.6
http-errors (npm) 1.8.0
jsdom (npm) 24.0.0
ws (npm) 8.21.0
@types/chrome (npm) 0.0.178
@types/express (npm) 4.17.13
@types/fs-extra (npm) 9.0.13
@types/jsdom (npm) 20.0.1
@types/node (npm) 20.9.0
@types/ws (npm) 8.5.2
@typescript-eslint/eslint-plugin (npm) 8.65.0
@typescript-eslint/parser (npm) 8.65.0
@typescript-eslint/typescript-estree (npm) 8.58.0
esbuild (npm) 0.25.0
eslint (npm) 10.8.0
eslint-config-prettier (npm) 8.3.0
eslint-formatter-unix (npm) 9.0.1
eslint-plugin-prettier (npm) 3.4.0
eslint-plugin-unused-imports (npm) 4.4.1
fs-extra (npm) 10.1.0
globals (npm) 17.3.0
kill-port (npm) 2.0.1
nodemon (npm) 3.1.14
npm-run-all (npm) 1.1.3
npm-run-scripts (npm) 2.1.3
prettier (npm) 3.2.5
prettier-plugin-organize-imports (npm) 3.2.3
shx (npm) 0.4.0
ts-node (npm) 10.4.0
typescript (npm) 5.5.3
typescript-eslint (npm) 0.0.1-alpha.0
Files by Type (count)
TypeScript
1627
JSON
1040
Other (.gif)
60
Markdown
7
Other (no ext)
5
Other (.svg)
5
JavaScript
2
Other (.eot)
2
Other (.ttf)
2
Other (.woff)
2
Other (.woff2)
2
YAML
1
Files by Type (size)
Other (.gif)
54MB
TypeScript
4MB
JSON
1MB
Other (.mp3)
1MB
Other (.svg)
165KB
Other (.eot)
48KB
Other (.ttf)
47KB
Markdown
37KB
Other (.woff)
30KB
Other (.woff2)
23KB
HTML
17KB
Other (.ico)
14KB

The LLM identified 3 files worth highlighting for reuse:

A generic binary heap implementation supporting both synchronous and asynchronous operations (push, pop, peek). Uses bubble-up/bubble-down algorithms and includes a findRoot method. The class is self-contained, well-typed, and could be extracted into any TypeScript project needing a priority queue.

file: src/Heap.ts ↗ | tags: #binary-heap #priority-queue #async

A force-directed graph layout simulation using Runge-Kutta integration (RK1–RK4) with configurable alpha decay, repulsion, and attraction forces. The simulation is parameterized and can be applied to any node-edge graph for visualization. It demonstrates non-trivial numerical integration and is isolated enough for reuse in other graph rendering projects.

file: src/client/simulation.ts ↗ | tags: #force-directed-layout #simulation #rk4-integration

A custom parser for the Unit spec language that builds an abstract syntax tree (AST) with 30+ node types, supports generics, type matching, value validation, and generic extraction/application. The parser is self-contained (no heavy external dependencies) and could be adapted for other domain-specific languages requiring type inference and tree manipulation.

file: src/spec/parser.ts ↗ | tags: #parser #type-inference #custom-language
Last analyzed: 2026-09-01 06:42:10.157618
Next check: 2026-10-17 13:20:33.794779
$ submit: