Add Supercomputer category: 12 P2P resource-sharing modules (164 total)

Introduce a new production category for distributed system resource pooling
over Hyperswarm — CPU, RAM, GPU, bandwidth, disk, jobs, cache, and egress.

New modules (supercomputer/):
- hyper-p2p-capacity-registry — gossip CPU/RAM/GPU/disk/bandwidth ads
- hyper-p2p-cpu-share — CPU millisecond credit pool
- hyper-p2p-ram-pool — RAM byte lend/claim/release
- hyper-p2p-gpu-slot — GPU slot register/reserve
- hyper-p2p-bandwidth-share — shared up/down Mbps
- hyper-p2p-disk-stripe — striped block shards
- hyper-p2p-job-dispatcher — submit/claim/complete jobs
- hyper-p2p-thermal-guard — load/temperature throttle signals
- hyper-p2p-cache-farm — distributed LRU cache
- hyper-p2p-net-gateway — peer internet egress routing
- hyper-p2p-cluster-affinity — hardware tag placement scoring
- hyper-p2p-work-stealer — shard queues + work stealing

Each package: index.js, tests, README, api/architecture docs, examples/basic.js.
Shared layering guide: _shared/SUPERCOMPUTER_LAYERS.md.
Registry, module-paths, MODULE_CATEGORIES, and workspace README updated to 164.

Parent workspace also adds docs/supercomputer hub and demo-supercomputer-mesh
(outside this repo).

Co-authored-by: Cursor <[email protected]>
This commit is contained in:
Raven Scott
2026-05-21 00:38:53 -04:00
co-authored by Cursor
parent 70119888cd
commit 693385bd7c
114 changed files with 24378 additions and 6 deletions
@@ -0,0 +1,21 @@
require('bare-process/global')
const test = require('brittle')
const { HyperP2PBandwidthShare } = require('../index.js')
test('bandwidth-share: offer consume', async (t) => {
const b = new HyperP2PBandwidthShare()
b.offer('peer-a', 100, 100)
t.ok(b.consume('peer-a', 1000, 'up'))
await b.close()
})
test('bandwidth-share: validation', async (t) => {
const b = new HyperP2PBandwidthShare()
try {
b.offer('p', -1, 10)
t.fail('expected throw')
} catch (e) {
t.ok(e instanceof Error)
}
await b.close()
})