@reicek/neataptic-ts 0.1.21 → 0.1.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/agents/boundary-mapper.agent.md +29 -0
- package/.github/agents/docs-scout.agent.md +29 -0
- package/.github/agents/plan-scout.agent.md +29 -0
- package/.github/agents/solid-split.agent.md +138 -0
- package/.github/copilot-instructions.md +103 -0
- package/package.json +6 -3
- package/plans/ES2023 migration +13 -8
- package/plans/Evolution_Training_Interoperability_Contracts.md +1 -1
- package/plans/Interactive_Examples_and_Learning_Path.md +10 -2
- package/plans/Memory_Optimization.md +3 -3
- package/plans/README.md +63 -0
- package/plans/Roadmap.md +15 -3
- package/plans/asciiMaze_SOLID_split.done.md +130 -0
- package/plans/flappy_bird_SOLID_split.done.md +67 -0
- package/scripts/assets/theme.css +221 -34
- package/scripts/copy-examples.mjs +9 -5
- package/scripts/export-onnx.mjs +3 -3
- package/scripts/generate-bench-tables.mjs +10 -10
- package/scripts/generate-bench-tables.ts +10 -10
- package/scripts/generate-docs.ts +1415 -449
- package/scripts/render-docs-html.ts +15 -8
- package/src/README.md +101 -223
- package/src/architecture/README.md +57 -185
- package/src/architecture/layer/README.md +38 -38
- package/src/architecture/network/README.md +33 -31
- package/src/architecture/network/activate/README.md +77 -77
- package/src/architecture/network/connect/README.md +15 -13
- package/src/architecture/network/deterministic/README.md +7 -7
- package/src/architecture/network/evolve/README.md +44 -44
- package/src/architecture/network/gating/README.md +20 -20
- package/src/architecture/network/genetic/README.md +51 -51
- package/src/architecture/network/mutate/README.md +97 -97
- package/src/architecture/network/onnx/README.md +264 -264
- package/src/architecture/network/prune/README.md +39 -39
- package/src/architecture/network/remove/README.md +26 -26
- package/src/architecture/network/serialize/README.md +56 -56
- package/src/architecture/network/slab/README.md +61 -61
- package/src/architecture/network/standalone/README.md +24 -24
- package/src/architecture/network/stats/README.md +9 -9
- package/src/architecture/network/topology/README.md +46 -46
- package/src/architecture/network/training/README.md +21 -21
- package/src/methods/README.md +9 -87
- package/src/multithreading/README.md +8 -77
- package/src/multithreading/workers/README.md +2 -2
- package/src/multithreading/workers/browser/README.md +0 -6
- package/src/multithreading/workers/node/README.md +0 -3
- package/src/neat/README.md +562 -568
- package/src/utils/README.md +18 -18
- package/test/examples/asciiMaze/README.md +59 -59
- package/test/examples/asciiMaze/asciiMaze.e2e.test.ts +14 -9
- package/test/examples/asciiMaze/browser-entry/README.md +196 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.abort.services.ts +95 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.constants.ts +23 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.curriculum.services.ts +115 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.globals.services.ts +106 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.host.services.ts +157 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.services.ts +14 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.ts +129 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.types.ts +120 -0
- package/test/examples/asciiMaze/browser-entry/browser-entry.utils.ts +98 -0
- package/test/examples/asciiMaze/browser-entry.ts +10 -576
- package/test/examples/asciiMaze/dashboardManager/README.md +276 -0
- package/test/examples/asciiMaze/dashboardManager/archive/README.md +16 -0
- package/test/examples/asciiMaze/dashboardManager/archive/dashboardManager.archive.services.ts +267 -0
- package/test/examples/asciiMaze/dashboardManager/dashboardManager.constants.ts +35 -0
- package/test/examples/asciiMaze/dashboardManager/dashboardManager.services.ts +103 -0
- package/test/examples/asciiMaze/dashboardManager/dashboardManager.ts +181 -0
- package/test/examples/asciiMaze/dashboardManager/dashboardManager.types.ts +267 -0
- package/test/examples/asciiMaze/dashboardManager/dashboardManager.utils.ts +254 -0
- package/test/examples/asciiMaze/dashboardManager/live/README.md +14 -0
- package/test/examples/asciiMaze/dashboardManager/live/dashboardManager.live.services.ts +264 -0
- package/test/examples/asciiMaze/dashboardManager/telemetry/README.md +47 -0
- package/test/examples/asciiMaze/dashboardManager/telemetry/dashboardManager.telemetry.services.ts +513 -0
- package/test/examples/asciiMaze/dashboardManager.ts +13 -2335
- package/test/examples/asciiMaze/evolutionEngine/README.md +1058 -0
- package/test/examples/asciiMaze/evolutionEngine/curriculumPhase.ts +90 -0
- package/test/examples/asciiMaze/evolutionEngine/engineState.constants.ts +36 -0
- package/test/examples/asciiMaze/evolutionEngine/engineState.ts +58 -513
- package/test/examples/asciiMaze/evolutionEngine/engineState.types.ts +212 -0
- package/test/examples/asciiMaze/evolutionEngine/engineState.utils.ts +301 -0
- package/test/examples/asciiMaze/evolutionEngine/evolutionEngine.types.ts +445 -0
- package/test/examples/asciiMaze/evolutionEngine/evolutionLoop.ts +81 -50
- package/test/examples/asciiMaze/evolutionEngine/optionsAndSetup.ts +2 -4
- package/test/examples/asciiMaze/evolutionEngine/populationDynamics.ts +17 -33
- package/test/examples/asciiMaze/evolutionEngine/populationPruning.ts +1 -1
- package/test/examples/asciiMaze/evolutionEngine/rngAndTiming.ts +1 -2
- package/test/examples/asciiMaze/evolutionEngine/sampling.ts +1 -1
- package/test/examples/asciiMaze/evolutionEngine/scratchPools.ts +2 -5
- package/test/examples/asciiMaze/evolutionEngine/setupHelpers.ts +30 -37
- package/test/examples/asciiMaze/evolutionEngine/telemetryMetrics.ts +16 -58
- package/test/examples/asciiMaze/evolutionEngine/trainingWarmStart.ts +2 -2
- package/test/examples/asciiMaze/evolutionEngine.ts +55 -55
- package/test/examples/asciiMaze/fitness.ts +2 -2
- package/test/examples/asciiMaze/fitness.types.ts +65 -0
- package/test/examples/asciiMaze/interfaces.ts +64 -1352
- package/test/examples/asciiMaze/mazeMovement/README.md +356 -0
- package/test/examples/asciiMaze/mazeMovement/finalization/README.md +49 -0
- package/test/examples/asciiMaze/mazeMovement/finalization/mazeMovement.finalization.ts +138 -0
- package/test/examples/asciiMaze/mazeMovement/mazeMovement.constants.ts +101 -0
- package/test/examples/asciiMaze/mazeMovement/mazeMovement.services.ts +230 -0
- package/test/examples/asciiMaze/mazeMovement/mazeMovement.ts +299 -0
- package/test/examples/asciiMaze/mazeMovement/mazeMovement.types.ts +185 -0
- package/test/examples/asciiMaze/mazeMovement/mazeMovement.utils.ts +153 -0
- package/test/examples/asciiMaze/mazeMovement/policy/README.md +91 -0
- package/test/examples/asciiMaze/mazeMovement/policy/mazeMovement.policy.ts +467 -0
- package/test/examples/asciiMaze/mazeMovement/runtime/README.md +95 -0
- package/test/examples/asciiMaze/mazeMovement/runtime/mazeMovement.runtime.ts +354 -0
- package/test/examples/asciiMaze/mazeMovement/shaping/README.md +124 -0
- package/test/examples/asciiMaze/mazeMovement/shaping/mazeMovement.shaping.ts +459 -0
- package/test/examples/asciiMaze/mazeMovement.ts +12 -2978
- package/test/examples/flappy_bird/Trace-20260309T191949.json +24124 -0
- package/test/examples/flappy_bird/browser-entry/README.md +1129 -0
- package/test/examples/flappy_bird/browser-entry/browser-entry.host.utils.ts +4 -324
- package/test/examples/flappy_bird/browser-entry/browser-entry.network-view.utils.ts +6 -399
- package/test/examples/flappy_bird/browser-entry/browser-entry.playback.utils.ts +1 -717
- package/test/examples/flappy_bird/browser-entry/browser-entry.spawn.utils.ts +11 -31
- package/test/examples/flappy_bird/browser-entry/browser-entry.visualization.utils.ts +15 -893
- package/test/examples/flappy_bird/browser-entry/host/README.md +307 -0
- package/test/examples/flappy_bird/browser-entry/host/host.resize.service.ts +1 -295
- package/test/examples/flappy_bird/browser-entry/host/host.ts +562 -6
- package/test/examples/flappy_bird/browser-entry/host/resize/README.md +274 -0
- package/test/examples/flappy_bird/browser-entry/host/resize/host.resize.service.constants.ts +31 -0
- package/test/examples/flappy_bird/browser-entry/host/resize/host.resize.service.services.ts +360 -0
- package/test/examples/flappy_bird/browser-entry/host/resize/host.resize.service.ts +117 -0
- package/test/examples/flappy_bird/browser-entry/host/resize/host.resize.service.types.ts +63 -0
- package/test/examples/flappy_bird/browser-entry/host/resize/host.resize.service.utils.ts +250 -0
- package/test/examples/flappy_bird/browser-entry/network-view/README.md +399 -0
- package/test/examples/flappy_bird/browser-entry/network-view/network-view.topology.utils.ts +255 -0
- package/test/examples/flappy_bird/browser-entry/network-view/network-view.ts +802 -7
- package/test/examples/flappy_bird/browser-entry/playback/README.md +684 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/README.md +277 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/README.md +770 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.cache.services.ts +178 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.constants.ts +107 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.geometry.utils.ts +518 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.math.utils.ts +117 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.pulse.utils.ts +233 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.services.ts +211 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.ts +48 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.types.ts +212 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/playback.background.ground-grid.utils.ts +81 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/playback.background.cache.services.ts +96 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/playback.background.constants.ts +62 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/playback.background.services.ts +244 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/playback.background.ts +53 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/playback.background.types.ts +68 -0
- package/test/examples/flappy_bird/browser-entry/playback/background/playback.background.utils.ts +100 -0
- package/test/examples/flappy_bird/browser-entry/playback/frame-render/README.md +310 -0
- package/test/examples/flappy_bird/browser-entry/playback/frame-render/playback.frame-render.service.ts +92 -0
- package/test/examples/flappy_bird/browser-entry/playback/frame-render/playback.frame-render.services.ts +272 -0
- package/test/examples/flappy_bird/browser-entry/playback/frame-render/playback.frame-render.types.ts +39 -0
- package/test/examples/flappy_bird/browser-entry/playback/frame-render/playback.frame-render.utils.ts +493 -0
- package/test/examples/flappy_bird/browser-entry/playback/playback.constants.ts +1 -1
- package/test/examples/flappy_bird/browser-entry/playback/playback.frame-render.service.ts +4 -0
- package/test/examples/flappy_bird/browser-entry/playback/playback.snapshot.utils.ts +44 -0
- package/test/examples/flappy_bird/browser-entry/playback/playback.starfield.service.ts +39 -122
- package/test/examples/flappy_bird/browser-entry/playback/playback.starfield.services.ts +272 -0
- package/test/examples/flappy_bird/browser-entry/playback/playback.starfield.types.ts +62 -0
- package/test/examples/flappy_bird/browser-entry/playback/playback.starfield.utils.ts +11 -4
- package/test/examples/flappy_bird/browser-entry/playback/playback.ts +409 -8
- package/test/examples/flappy_bird/browser-entry/playback/playback.types.ts +4 -12
- package/test/examples/flappy_bird/browser-entry/runtime/README.md +235 -0
- package/test/examples/flappy_bird/browser-entry/runtime/runtime.evolution-launch.service.ts +45 -0
- package/test/examples/flappy_bird/browser-entry/runtime/runtime.lifecycle.service.ts +81 -0
- package/test/examples/flappy_bird/browser-entry/runtime/runtime.startup.service.ts +74 -0
- package/test/examples/flappy_bird/browser-entry/runtime/runtime.ts +31 -121
- package/test/examples/flappy_bird/browser-entry/runtime/runtime.types.ts +36 -0
- package/test/examples/flappy_bird/browser-entry/visualization/README.md +557 -0
- package/test/examples/flappy_bird/browser-entry/visualization/visualization.constants.ts +110 -0
- package/test/examples/flappy_bird/browser-entry/visualization/visualization.draw.service.ts +957 -19
- package/test/examples/flappy_bird/browser-entry/visualization/visualization.legend.utils.ts +138 -3
- package/test/examples/flappy_bird/browser-entry/visualization/visualization.topology.utils.ts +3 -27
- package/test/examples/flappy_bird/browser-entry/visualization/visualization.ts +1 -23
- package/test/examples/flappy_bird/browser-entry/worker-channel/README.md +156 -0
- package/test/examples/flappy_bird/constants/README.md +1179 -0
- package/test/examples/flappy_bird/constants/constants.network-view.ts +24 -0
- package/test/examples/flappy_bird/constants/constants.palette.ts +7 -0
- package/test/examples/flappy_bird/constants/constants.starfield.ts +78 -3
- package/test/examples/flappy_bird/environment/README.md +143 -0
- package/test/examples/flappy_bird/environment/environment.observation.utils.ts +1 -19
- package/test/examples/flappy_bird/environment/environment.step.service.ts +3 -66
- package/test/examples/flappy_bird/evaluation/README.md +130 -0
- package/test/examples/flappy_bird/evaluation/evaluation.fitness.utils.ts +1 -1
- package/test/examples/flappy_bird/evaluation/evaluation.rollout.service.ts +5 -375
- package/test/examples/flappy_bird/evaluation/rollout/README.md +291 -0
- package/test/examples/flappy_bird/evaluation/rollout/evaluation.rollout.constants.ts +30 -0
- package/test/examples/flappy_bird/evaluation/rollout/evaluation.rollout.service.ts +58 -0
- package/test/examples/flappy_bird/evaluation/rollout/evaluation.rollout.services.ts +310 -0
- package/test/examples/flappy_bird/evaluation/rollout/evaluation.rollout.types.ts +56 -0
- package/test/examples/flappy_bird/evaluation/rollout/evaluation.rollout.utils.ts +368 -0
- package/test/examples/flappy_bird/flappy-evolution-worker/README.md +618 -0
- package/test/examples/flappy_bird/flappy-evolution-worker/flappy-evolution-worker.playback.service.ts +7 -7
- package/test/examples/flappy_bird/flappy-evolution-worker/flappy-evolution-worker.simulation.frame.service.ts +364 -0
- package/test/examples/flappy_bird/flappy-evolution-worker/flappy-evolution-worker.simulation.types.ts +14 -0
- package/test/examples/flappy_bird/flappy-evolution-worker/flappy-evolution-worker.simulation.utils.ts +4 -201
- package/test/examples/flappy_bird/flappy-evolution-worker/flappy-evolution-worker.ts +184 -345
- package/test/examples/flappy_bird/flappy-evolution-worker/flappy-evolution-worker.warm-start.service.ts +291 -0
- package/test/examples/flappy_bird/flappy.simulation.shared.utils.ts +5 -0
- package/test/examples/flappy_bird/simulation-shared/README.md +417 -0
- package/test/examples/flappy_bird/simulation-shared/observation/README.md +183 -0
- package/test/examples/flappy_bird/simulation-shared/observation/observation.features.utils.ts +301 -0
- package/test/examples/flappy_bird/simulation-shared/observation/observation.ts +9 -0
- package/test/examples/flappy_bird/simulation-shared/observation/observation.vector.utils.ts +59 -0
- package/test/examples/flappy_bird/simulation-shared/simulation-shared.observation.utils.ts +5 -403
- package/test/examples/flappy_bird/simulation-shared/simulation-shared.spawn.utils.ts +20 -6
- package/test/examples/flappy_bird/{evaluation/evaluation.statistics.utils.ts → simulation-shared/simulation-shared.statistics.utils.ts} +23 -8
- package/test/examples/flappy_bird/trainer/README.md +563 -0
- package/test/examples/flappy_bird/trainer/evaluation/README.md +199 -0
- package/test/examples/flappy_bird/trainer/evaluation/trainer.evaluation.service.constants.ts +9 -0
- package/test/examples/flappy_bird/trainer/evaluation/trainer.evaluation.service.services.ts +73 -0
- package/test/examples/flappy_bird/trainer/evaluation/trainer.evaluation.service.ts +165 -0
- package/test/examples/flappy_bird/trainer/evaluation/trainer.evaluation.service.types.ts +25 -0
- package/test/examples/flappy_bird/trainer/evaluation/trainer.evaluation.service.utils.ts +161 -0
- package/test/examples/flappy_bird/trainer/trainer.evaluation.service.ts +13 -0
- package/test/examples/flappy_bird/trainer/trainer.report.service.services.ts +181 -0
- package/test/examples/flappy_bird/trainer/trainer.report.service.ts +126 -0
- package/test/examples/flappy_bird/trainer/trainer.selection.utils.ts +89 -0
- package/test/examples/flappy_bird/trainer/trainer.ts +11 -553
- package/test/examples/flappy_bird/browser-entry/browser-entry.utils.ts +0 -12
- package/test/examples/flappy_bird/environment/environment.ts +0 -7
- package/test/examples/flappy_bird/evaluation/evaluation.ts +0 -7
- package/test/examples/flappy_bird/simulation-shared/simulation-shared.ts +0 -15
- package/test/examples/flappy_bird/trainer/trainer.statistics.utils.ts +0 -78
package/src/utils/README.md
CHANGED
|
@@ -20,7 +20,7 @@ Design principles:
|
|
|
20
20
|
|
|
21
21
|
### memoryStats
|
|
22
22
|
|
|
23
|
-
`(targetNetworks: import("
|
|
23
|
+
`(targetNetworks: import("src/utils/memory").NetworkView | import("src/utils/memory").NetworkView[] | undefined) => import("src/utils/memory").MemoryStats`
|
|
24
24
|
|
|
25
25
|
### MemoryStats
|
|
26
26
|
|
|
@@ -41,7 +41,7 @@ enabling typed local variables instead of `any` everywhere.
|
|
|
41
41
|
|
|
42
42
|
### registerTrackedNetwork
|
|
43
43
|
|
|
44
|
-
`(network: import("
|
|
44
|
+
`(network: import("src/utils/memory").NetworkView | null | undefined) => void`
|
|
45
45
|
|
|
46
46
|
### resetMemoryTracking
|
|
47
47
|
|
|
@@ -54,13 +54,13 @@ include additional fields; we only rely on fresh/pooled counts.
|
|
|
54
54
|
|
|
55
55
|
### unregisterTrackedNetwork
|
|
56
56
|
|
|
57
|
-
`(network: import("
|
|
57
|
+
`(network: import("src/utils/memory").NetworkView) => void`
|
|
58
58
|
|
|
59
59
|
## utils/memory.utils.ts
|
|
60
60
|
|
|
61
61
|
### accumulateCapacitySlices
|
|
62
62
|
|
|
63
|
-
`(accumulators: import("
|
|
63
|
+
`(accumulators: import("src/utils/memory.utils").Accumulators, network: import("src/utils/memory").NetworkView, heuristics: import("src/utils/memory.utils").HeuristicBytes) => void`
|
|
64
64
|
|
|
65
65
|
Track reserved vs used bytes based on connection capacity slices.
|
|
66
66
|
|
|
@@ -71,7 +71,7 @@ Parameters:
|
|
|
71
71
|
|
|
72
72
|
### accumulateSlabArrays
|
|
73
73
|
|
|
74
|
-
`(accumulators: import("
|
|
74
|
+
`(accumulators: import("src/utils/memory.utils").Accumulators, typedArrays: (Float32Array<ArrayBufferLike> | Float64Array<ArrayBufferLike> | Uint32Array<ArrayBufferLike> | Uint8Array<ArrayBufferLike> | Int32Array<ArrayBufferLike>)[]) => void`
|
|
75
75
|
|
|
76
76
|
Sum slab-backed array counts and byte sizes into the accumulator.
|
|
77
77
|
|
|
@@ -86,7 +86,7 @@ Accumulates counts, slab byte totals, and reserved vs used capacity snapshots.
|
|
|
86
86
|
|
|
87
87
|
### aggregateNetworkStats
|
|
88
88
|
|
|
89
|
-
`(networksToSummarize: import("
|
|
89
|
+
`(networksToSummarize: import("src/utils/memory").NetworkView[], heuristics: import("src/utils/memory.utils").HeuristicBytes) => import("src/utils/memory.utils").Accumulators`
|
|
90
90
|
|
|
91
91
|
Aggregate per-network counters and slab metrics into a single accumulator.
|
|
92
92
|
|
|
@@ -98,7 +98,7 @@ Returns: Accumulated summary of network metrics.
|
|
|
98
98
|
|
|
99
99
|
### buildFlagSnapshot
|
|
100
100
|
|
|
101
|
-
`(configSnapshot: import("
|
|
101
|
+
`(configSnapshot: import("src/utils/memory.utils").ConfigSnapshot, allocationStats: import("src/utils/memory").SlabAllocStats) => { warnings: unknown; float32Mode: unknown; deterministicChainMode: unknown; enableGatingTraces: unknown; poolMaxPerBucket: number | null; poolPrewarmCount: number | null; enableNodePooling: boolean; allocStats: unknown; }`
|
|
102
102
|
|
|
103
103
|
Build flag snapshot derived from config and allocator stats.
|
|
104
104
|
|
|
@@ -115,7 +115,7 @@ Bundles precomputed accumulators, environment info, allocator stats, and flags.
|
|
|
115
115
|
|
|
116
116
|
### buildMemoryStatsSnapshot
|
|
117
117
|
|
|
118
|
-
`(input: import("
|
|
118
|
+
`(input: import("src/utils/memory.utils").BuildMemoryStatsInput) => import("src/utils/memory").MemoryStats`
|
|
119
119
|
|
|
120
120
|
Build the full MemoryStats snapshot from precomputed components.
|
|
121
121
|
|
|
@@ -126,7 +126,7 @@ Returns: Complete MemoryStats snapshot.
|
|
|
126
126
|
|
|
127
127
|
### buildSlabStats
|
|
128
128
|
|
|
129
|
-
`(accumulators: import("
|
|
129
|
+
`(accumulators: import("src/utils/memory.utils").Accumulators, networksToSummarize: import("src/utils/memory").NetworkView[], allocationStats: import("src/utils/memory").SlabAllocStats) => { slabBytes: number; slabArrayCount: number; fragmentationPct: number | null; reservedBytes: number | null; usedBytes: number | null; slabVersion: number | null; asyncBuilds: number; pooledFraction: number | null; }`
|
|
130
130
|
|
|
131
131
|
Assemble slab-related statistics for the MemoryStats payload.
|
|
132
132
|
|
|
@@ -139,7 +139,7 @@ Returns: Structured slab metrics block.
|
|
|
139
139
|
|
|
140
140
|
### calculateFragmentation
|
|
141
141
|
|
|
142
|
-
`(accumulators: import("
|
|
142
|
+
`(accumulators: import("src/utils/memory.utils").Accumulators) => number | null`
|
|
143
143
|
|
|
144
144
|
Compute fragmentation percentage from reserved vs used connection bytes.
|
|
145
145
|
|
|
@@ -150,7 +150,7 @@ Returns: Fragmentation percent (0-100) or null when undefined.
|
|
|
150
150
|
|
|
151
151
|
### calculatePooledFraction
|
|
152
152
|
|
|
153
|
-
`(allocationStats: import("
|
|
153
|
+
`(allocationStats: import("src/utils/memory").SlabAllocStats) => number | null`
|
|
154
154
|
|
|
155
155
|
Calculate pooled fraction from allocator stats with four-decimal precision.
|
|
156
156
|
|
|
@@ -169,7 +169,7 @@ Returns: Environment metrics structure for the snapshot.
|
|
|
169
169
|
|
|
170
170
|
### captureVersionMetadata
|
|
171
171
|
|
|
172
|
-
`(accumulators: import("
|
|
172
|
+
`(accumulators: import("src/utils/memory.utils").Accumulators, network: import("src/utils/memory").NetworkView) => void`
|
|
173
173
|
|
|
174
174
|
Capture slab metadata (version and async builds) once across all networks.
|
|
175
175
|
|
|
@@ -179,7 +179,7 @@ Parameters:
|
|
|
179
179
|
|
|
180
180
|
### collectConnectionTypedArrays
|
|
181
181
|
|
|
182
|
-
`(network: import("
|
|
182
|
+
`(network: import("src/utils/memory").NetworkView) => (Float32Array<ArrayBufferLike> | Float64Array<ArrayBufferLike> | Uint32Array<ArrayBufferLike> | Uint8Array<ArrayBufferLike> | Int32Array<ArrayBufferLike>)[]`
|
|
183
183
|
|
|
184
184
|
Gather all typed arrays that represent connection-parallel data on a network.
|
|
185
185
|
|
|
@@ -190,7 +190,7 @@ Returns: Typed arrays aligned to connections.
|
|
|
190
190
|
|
|
191
191
|
### computeCounts
|
|
192
192
|
|
|
193
|
-
`(network: import("
|
|
193
|
+
`(network: import("src/utils/memory").NetworkView) => CountSnapshot`
|
|
194
194
|
|
|
195
195
|
Capture simple counts for nodes and connections on a network view.
|
|
196
196
|
|
|
@@ -208,7 +208,7 @@ Keeps only the flags relevant to the memory snapshot to avoid leaking full confi
|
|
|
208
208
|
|
|
209
209
|
### createEmptyAccumulators
|
|
210
210
|
|
|
211
|
-
`() => import("
|
|
211
|
+
`() => import("src/utils/memory.utils").Accumulators`
|
|
212
212
|
|
|
213
213
|
Initialize a fresh accumulator snapshot for memory summaries.
|
|
214
214
|
|
|
@@ -216,7 +216,7 @@ Returns: Zeroed accumulators ready for aggregation.
|
|
|
216
216
|
|
|
217
217
|
### describeConnectionBytes
|
|
218
218
|
|
|
219
|
-
`(network: import("
|
|
219
|
+
`(network: import("src/utils/memory").NetworkView, heuristics: import("src/utils/memory.utils").HeuristicBytes) => number`
|
|
220
220
|
|
|
221
221
|
Determine bytes per connection using typed-array width or heuristic fallback.
|
|
222
222
|
|
|
@@ -237,7 +237,7 @@ These numbers represent typical JS object footprints, not exact runtime measurem
|
|
|
237
237
|
|
|
238
238
|
### normalizeNetworks
|
|
239
239
|
|
|
240
|
-
`(targets: import("
|
|
240
|
+
`(targets: import("src/utils/memory").NetworkView | import("src/utils/memory").NetworkView[] | undefined, trackedNetworks: import("src/utils/memory").NetworkView[]) => import("src/utils/memory").NetworkView[]`
|
|
241
241
|
|
|
242
242
|
Normalize provided targets to an array of networks, falling back to tracked registry.
|
|
243
243
|
|
|
@@ -249,7 +249,7 @@ Returns: Array of networks to summarize.
|
|
|
249
249
|
|
|
250
250
|
### safeGetSlabAllocationStats
|
|
251
251
|
|
|
252
|
-
`(getSlabAllocationStats: () => unknown) => import("
|
|
252
|
+
`(getSlabAllocationStats: () => unknown) => import("src/utils/memory").SlabAllocStats`
|
|
253
253
|
|
|
254
254
|
Safely read slab allocation stats, guarding against provider errors.
|
|
255
255
|
|
|
@@ -32,59 +32,59 @@ Use this as a reference architecture when building your own task-specific neuroe
|
|
|
32
32
|
### Core runtime
|
|
33
33
|
|
|
34
34
|
- `evolutionEngine.ts`
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
- Public façade entry point: `EvolutionEngine.runMazeEvolution(options)`.
|
|
36
|
+
- Delegates to modular files under `evolutionEngine/`.
|
|
37
37
|
- `evolutionEngine/`
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
38
|
+
- `optionsAndSetup.ts`: normalize options, prepare maze/distance map, create NEAT instance.
|
|
39
|
+
- `evolutionLoop.ts`: generation loop, cancellation, stop conditions, telemetry flow.
|
|
40
|
+
- `populationDynamics.ts`: pruning, simplify phase, anti-collapse, dynamic population.
|
|
41
|
+
- `trainingWarmStart.ts`: warm-start + Lamarckian/Baldwinian helpers.
|
|
42
|
+
- `telemetryMetrics.ts`: generation metrics collection/log formatting.
|
|
43
|
+
- `rngAndTiming.ts`, `scratchPools.ts`, `sampling.ts`, etc.: performance + deterministic helpers.
|
|
44
44
|
|
|
45
45
|
### Maze simulation pipeline
|
|
46
46
|
|
|
47
47
|
- `mazeVision.ts`
|
|
48
|
-
|
|
48
|
+
- Builds 6D inputs for the policy network.
|
|
49
49
|
- `mazeMovement.ts`
|
|
50
|
-
|
|
50
|
+
- Simulates one episode with action selection, movement, penalties/rewards, and final run result.
|
|
51
51
|
- `fitness.ts`
|
|
52
|
-
|
|
52
|
+
- Converts simulation outcomes into scalar fitness.
|
|
53
53
|
- `mazeUtils.ts`
|
|
54
|
-
|
|
54
|
+
- Encoding, BFS distance, progress calculations, coordinate utilities.
|
|
55
55
|
|
|
56
56
|
### Visualization and UX
|
|
57
57
|
|
|
58
58
|
- `dashboardManager.ts`
|
|
59
|
-
|
|
59
|
+
- Rich per-generation dashboard with telemetry history, archive of solved mazes, and trend snapshots.
|
|
60
60
|
- `mazeVisualization.ts`
|
|
61
|
-
|
|
61
|
+
- Colorized maze rendering and summary stats.
|
|
62
62
|
- `networkVisualization.ts`
|
|
63
|
-
|
|
63
|
+
- Network topology formatting/inspection.
|
|
64
64
|
- `terminalUtility.ts` / `browserTerminalUtility.ts`
|
|
65
|
-
|
|
65
|
+
- Rendering primitives for Node terminal and browser DOM.
|
|
66
66
|
- `browserLogger.ts`
|
|
67
|
-
|
|
67
|
+
- Browser-target logging utility.
|
|
68
68
|
|
|
69
69
|
### Scenario definitions and adapters
|
|
70
70
|
|
|
71
71
|
- `mazes.ts`
|
|
72
|
-
|
|
72
|
+
- Static mazes (`tiny`, `small`, `medium`, `large`, `minotaur`) plus procedural `MazeGenerator`.
|
|
73
73
|
- `interfaces.ts`
|
|
74
|
-
|
|
74
|
+
- Canonical contracts: run options, telemetry contracts, network/visualization types.
|
|
75
75
|
- `index.ts` and `asciiMaze.ts`
|
|
76
|
-
|
|
76
|
+
- Re-exports for easier imports.
|
|
77
77
|
|
|
78
78
|
### Demo and test entry points
|
|
79
79
|
|
|
80
80
|
- `browser-entry.ts`
|
|
81
|
-
|
|
81
|
+
- Public `start(...)` API for browser demo lifecycle.
|
|
82
82
|
- `index.html`
|
|
83
|
-
|
|
83
|
+
- Simple host page loading `docs/assets/ascii-maze.bundle.js`.
|
|
84
84
|
- `asciiMaze.e2e.test.ts`
|
|
85
|
-
|
|
85
|
+
- Curriculum-style end-to-end evolution in test form.
|
|
86
86
|
- `networkRefinement.ts` and `refineWinner.ts`
|
|
87
|
-
|
|
87
|
+
- Two refinement helpers (class-based and functional style).
|
|
88
88
|
|
|
89
89
|
---
|
|
90
90
|
|
|
@@ -168,15 +168,15 @@ At a high level, `EvolutionEngine.runMazeEvolution` performs:
|
|
|
168
168
|
2. Maze preparation (encoding, start/exit detection, distance map)
|
|
169
169
|
3. NEAT creation and optional warm-start seeding
|
|
170
170
|
4. Generation loop:
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
171
|
+
- evaluate population
|
|
172
|
+
- apply adaptive/population dynamics
|
|
173
|
+
- apply optional refinement phases
|
|
174
|
+
- log/update dashboard/telemetry
|
|
175
175
|
5. Stop when one of these occurs:
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
176
|
+
- solved threshold reached
|
|
177
|
+
- stagnation cap hit
|
|
178
|
+
- max generations reached
|
|
179
|
+
- cancellation/abort requested
|
|
180
180
|
|
|
181
181
|
The engine supports deterministic mode, telemetry toggles, persistence intervals, and dynamic population controls.
|
|
182
182
|
|
|
@@ -241,25 +241,25 @@ import { DashboardManager } from './dashboardManager';
|
|
|
241
241
|
import { TerminalUtility } from './terminalUtility';
|
|
242
242
|
|
|
243
243
|
const dashboard = new DashboardManager(
|
|
244
|
-
|
|
245
|
-
|
|
244
|
+
TerminalUtility.createTerminalClearer(),
|
|
245
|
+
(...args) => console.log(...args),
|
|
246
246
|
);
|
|
247
247
|
|
|
248
248
|
const result = await EvolutionEngine.runMazeEvolution({
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
249
|
+
mazeConfig: { maze: new MazeGenerator(24, 24).generate() },
|
|
250
|
+
agentSimConfig: { maxSteps: 2000 },
|
|
251
|
+
evolutionAlgorithmConfig: {
|
|
252
|
+
popSize: 40,
|
|
253
|
+
maxGenerations: 100,
|
|
254
|
+
maxStagnantGenerations: 50,
|
|
255
|
+
minProgressToPass: 95,
|
|
256
|
+
allowRecurrent: true,
|
|
257
|
+
},
|
|
258
|
+
reportingConfig: {
|
|
259
|
+
dashboardManager: dashboard,
|
|
260
|
+
logEvery: 1,
|
|
261
|
+
label: 'demo-24x24',
|
|
262
|
+
},
|
|
263
263
|
});
|
|
264
264
|
|
|
265
265
|
console.log(result.exitReason, result.bestResult?.progress);
|
|
@@ -272,17 +272,17 @@ console.log(result.exitReason, result.bestResult?.progress);
|
|
|
272
272
|
If you’re teaching or experimenting, these knobs are typically most impactful first:
|
|
273
273
|
|
|
274
274
|
1. `agentSimConfig.maxSteps`
|
|
275
|
-
|
|
275
|
+
- increase for larger/harder mazes
|
|
276
276
|
2. `evolutionAlgorithmConfig.popSize`
|
|
277
|
-
|
|
277
|
+
- larger population improves search breadth but costs compute
|
|
278
278
|
3. `evolutionAlgorithmConfig.maxGenerations`
|
|
279
|
-
|
|
279
|
+
- higher cap for difficult layouts
|
|
280
280
|
4. `evolutionAlgorithmConfig.minProgressToPass`
|
|
281
|
-
|
|
281
|
+
- solved threshold sensitivity
|
|
282
282
|
5. `lamarckianIterations` and `lamarckianSampleSize`
|
|
283
|
-
|
|
283
|
+
- adjust local supervised-style refinement pressure
|
|
284
284
|
6. `deterministic` + `randomSeed`
|
|
285
|
-
|
|
285
|
+
- reproducibility for educational comparisons
|
|
286
286
|
|
|
287
287
|
Then, for advanced learners:
|
|
288
288
|
|
|
@@ -297,15 +297,15 @@ Then, for advanced learners:
|
|
|
297
297
|
Try these in order:
|
|
298
298
|
|
|
299
299
|
1. **Perception ablation**
|
|
300
|
-
|
|
300
|
+
- Remove one input channel from `MazeVision` and observe learning degradation.
|
|
301
301
|
2. **Reward shaping experiment**
|
|
302
|
-
|
|
302
|
+
- Reduce exploration bonus and track effects on dead-end behavior.
|
|
303
303
|
3. **Curriculum comparison**
|
|
304
|
-
|
|
304
|
+
- Train directly on big mazes vs phased growth with transfer.
|
|
305
305
|
4. **Determinism study**
|
|
306
|
-
|
|
306
|
+
- Fix seed and compare run-to-run variance when toggling certain heuristics.
|
|
307
307
|
5. **Refinement impact**
|
|
308
|
-
|
|
308
|
+
- Compare before/after `NetworkRefinement.refineWinnerWithBackprop` on transfer tasks.
|
|
309
309
|
|
|
310
310
|
---
|
|
311
311
|
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import Network from '../../../src/architecture/network'; // Correct import for Network
|
|
2
1
|
import { MazeGenerator } from './mazes';
|
|
3
2
|
import { colors } from './colors';
|
|
4
3
|
import { DashboardManager } from './dashboardManager';
|
|
5
4
|
import { TerminalUtility } from './terminalUtility';
|
|
6
5
|
import { IDashboardManager } from './interfaces';
|
|
7
|
-
import {
|
|
8
|
-
|
|
6
|
+
import {
|
|
7
|
+
EvolutionEngine,
|
|
8
|
+
resolveMazeEvolutionPhaseOutcome,
|
|
9
|
+
} from './evolutionEngine';
|
|
9
10
|
|
|
10
11
|
/**
|
|
11
12
|
* Forces console output for this test by writing directly to stdout/stderr.
|
|
@@ -30,6 +31,9 @@ const dashboardManagerInstance: IDashboardManager = new DashboardManager(
|
|
|
30
31
|
forceLog,
|
|
31
32
|
);
|
|
32
33
|
|
|
34
|
+
/** Minimum progress required before the curriculum treats a phase as solved. */
|
|
35
|
+
const CURRICULUM_MIN_PROGRESS_TO_PASS = 95;
|
|
36
|
+
|
|
33
37
|
jest.setTimeout(3600000); //
|
|
34
38
|
|
|
35
39
|
/**
|
|
@@ -137,7 +141,7 @@ describe('ASCII Maze Solver using Neuro-Evolution', () => {
|
|
|
137
141
|
popSize: 40,
|
|
138
142
|
autoPauseOnSolve: false,
|
|
139
143
|
maxStagnantGenerations: 50,
|
|
140
|
-
minProgressToPass:
|
|
144
|
+
minProgressToPass: CURRICULUM_MIN_PROGRESS_TO_PASS,
|
|
141
145
|
// hard cap per phase (browser DEFAULT_MAX_GENERATIONS)
|
|
142
146
|
maxGenerations: 100,
|
|
143
147
|
lamarckianIterations: 4,
|
|
@@ -150,11 +154,12 @@ describe('ASCII Maze Solver using Neuro-Evolution', () => {
|
|
|
150
154
|
label: `procedural-curriculum-${dim}x${dim}`,
|
|
151
155
|
},
|
|
152
156
|
});
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
157
|
+
const phaseOutcome = resolveMazeEvolutionPhaseOutcome(
|
|
158
|
+
result,
|
|
159
|
+
proceduralPrevBest,
|
|
160
|
+
CURRICULUM_MIN_PROGRESS_TO_PASS,
|
|
161
|
+
);
|
|
162
|
+
proceduralPrevBest = phaseOutcome.nextBestNetwork;
|
|
158
163
|
|
|
159
164
|
expect(!!result?.bestNetwork).toBe(true);
|
|
160
165
|
});
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
# browser-entry
|
|
2
|
+
|
|
3
|
+
## browser-entry/browser-entry.types.ts
|
|
4
|
+
|
|
5
|
+
### AsciiMazeRunHandle
|
|
6
|
+
|
|
7
|
+
Public lifecycle handle returned by the browser demo entrypoint.
|
|
8
|
+
|
|
9
|
+
### BrowserEntryCurriculumContext
|
|
10
|
+
|
|
11
|
+
State and callbacks used by the curriculum runtime service.
|
|
12
|
+
|
|
13
|
+
### BrowserEntryEvolutionSettings
|
|
14
|
+
|
|
15
|
+
Evolution settings used for a single procedural maze phase.
|
|
16
|
+
|
|
17
|
+
### BrowserEntryHostElements
|
|
18
|
+
|
|
19
|
+
Resolved host elements used by logger, dashboard, and resize services.
|
|
20
|
+
|
|
21
|
+
### BrowserEntryHostServices
|
|
22
|
+
|
|
23
|
+
Browser host services assembled for one running demo instance.
|
|
24
|
+
|
|
25
|
+
### BrowserEntryStartFunction
|
|
26
|
+
|
|
27
|
+
`(container: string | HTMLElement | undefined, opts: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryStartOptions | undefined) => Promise<import("test/examples/asciiMaze/browser-entry/browser-entry.types").AsciiMazeRunHandle>`
|
|
28
|
+
|
|
29
|
+
Stable callable shape used by globals compatibility wiring.
|
|
30
|
+
|
|
31
|
+
### BrowserEntryStartOptions
|
|
32
|
+
|
|
33
|
+
Options accepted by the browser-hosted ASCII Maze entrypoint.
|
|
34
|
+
|
|
35
|
+
### BrowserEntryTelemetryHub
|
|
36
|
+
|
|
37
|
+
Lightweight telemetry hub contract shared between host and public handle.
|
|
38
|
+
|
|
39
|
+
### RuntimeAbortSignal
|
|
40
|
+
|
|
41
|
+
Runtime AbortSignal shape used for older or polyfilled environments.
|
|
42
|
+
|
|
43
|
+
### RuntimeAbortSignalConstructor
|
|
44
|
+
|
|
45
|
+
AbortSignal constructor shape with optional static composition helpers.
|
|
46
|
+
|
|
47
|
+
### RuntimeWindow
|
|
48
|
+
|
|
49
|
+
Global namespace exposed for direct browser-script loading compatibility.
|
|
50
|
+
|
|
51
|
+
## browser-entry/browser-entry.ts
|
|
52
|
+
|
|
53
|
+
### browser-entry
|
|
54
|
+
|
|
55
|
+
Public browser entry facade for the ASCII Maze demo module boundary.
|
|
56
|
+
|
|
57
|
+
The folder now owns host bootstrap, runtime orchestration, globals
|
|
58
|
+
compatibility, and resize handling behind focused helpers. This facade keeps
|
|
59
|
+
the public API stable while presenting a small orchestration-first surface.
|
|
60
|
+
|
|
61
|
+
### AsciiMazeRunHandle
|
|
62
|
+
|
|
63
|
+
Public lifecycle handle returned by the browser demo entrypoint.
|
|
64
|
+
|
|
65
|
+
### BrowserEntryStartFunction
|
|
66
|
+
|
|
67
|
+
`(container: string | HTMLElement | undefined, opts: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryStartOptions | undefined) => Promise<import("test/examples/asciiMaze/browser-entry/browser-entry.types").AsciiMazeRunHandle>`
|
|
68
|
+
|
|
69
|
+
Stable callable shape used by globals compatibility wiring.
|
|
70
|
+
|
|
71
|
+
### BrowserEntryStartOptions
|
|
72
|
+
|
|
73
|
+
Options accepted by the browser-hosted ASCII Maze entrypoint.
|
|
74
|
+
|
|
75
|
+
### start
|
|
76
|
+
|
|
77
|
+
`(container: string | HTMLElement, opts: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryStartOptions) => Promise<import("test/examples/asciiMaze/browser-entry/browser-entry.types").AsciiMazeRunHandle>`
|
|
78
|
+
|
|
79
|
+
## browser-entry/browser-entry.services.ts
|
|
80
|
+
|
|
81
|
+
### browser-entry.services
|
|
82
|
+
|
|
83
|
+
Compatibility facade for the dedicated browser-entry service modules.
|
|
84
|
+
|
|
85
|
+
The concrete implementations now live in focused files so callers can keep
|
|
86
|
+
importing from this stable boundary while internals evolve independently.
|
|
87
|
+
|
|
88
|
+
### composeBrowserEntryAbortSignal
|
|
89
|
+
|
|
90
|
+
`(internalController: AbortController, externalSignal: AbortSignal | undefined) => AbortSignal`
|
|
91
|
+
|
|
92
|
+
### createBrowserEntryEvolutionHostAdapter
|
|
93
|
+
|
|
94
|
+
`() => import("test/examples/asciiMaze/evolutionEngine/evolutionEngine.types").EvolutionHostAdapter`
|
|
95
|
+
|
|
96
|
+
### createBrowserEntryHostServices
|
|
97
|
+
|
|
98
|
+
`(hostElements: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryHostElements) => import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryHostServices`
|
|
99
|
+
|
|
100
|
+
### installBrowserEntryGlobals
|
|
101
|
+
|
|
102
|
+
`(start: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryStartFunction) => void`
|
|
103
|
+
|
|
104
|
+
### runBrowserEntryCurriculum
|
|
105
|
+
|
|
106
|
+
`(context: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryCurriculumContext) => void`
|
|
107
|
+
|
|
108
|
+
## browser-entry/browser-entry.constants.ts
|
|
109
|
+
|
|
110
|
+
### browser-entry.constants
|
|
111
|
+
|
|
112
|
+
Shared constants for the browser-hosted ASCII Maze demo lifecycle.
|
|
113
|
+
|
|
114
|
+
These values keep the browser entry facade declarative while the host,
|
|
115
|
+
resize, and curriculum services consume a single named configuration table.
|
|
116
|
+
|
|
117
|
+
### BROWSER_ENTRY_CONSTANTS
|
|
118
|
+
|
|
119
|
+
## browser-entry/browser-entry.host.services.ts
|
|
120
|
+
|
|
121
|
+
### createBrowserEntryHostServices
|
|
122
|
+
|
|
123
|
+
`(hostElements: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryHostElements) => import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryHostServices`
|
|
124
|
+
|
|
125
|
+
### createTelemetryHub
|
|
126
|
+
|
|
127
|
+
`() => import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryTelemetryHub<TTelemetry>`
|
|
128
|
+
|
|
129
|
+
Create a minimal telemetry hub backed by a Set of listeners.
|
|
130
|
+
|
|
131
|
+
Returns: A small hub optimized for browser demo listener counts.
|
|
132
|
+
|
|
133
|
+
### installResizeRedraw
|
|
134
|
+
|
|
135
|
+
`(observeTarget: HTMLElement | null, runtimeDashboard: import("test/examples/asciiMaze/dashboardManager/dashboardManager.types").DashboardPresentationAdapter) => () => void`
|
|
136
|
+
|
|
137
|
+
Attach dashboard redraw behavior to host resizes and return a cleanup function.
|
|
138
|
+
|
|
139
|
+
Parameters:
|
|
140
|
+
- `observeTarget` - - Element whose width should trigger redraw checks.
|
|
141
|
+
- `runtimeDashboard` - - Shared dashboard presentation adapter with redraw support.
|
|
142
|
+
|
|
143
|
+
Returns: Cleanup function that removes active observers or listeners.
|
|
144
|
+
|
|
145
|
+
### safelyRedrawDashboard
|
|
146
|
+
|
|
147
|
+
`(runtimeDashboard: import("test/examples/asciiMaze/dashboardManager/dashboardManager.types").DashboardPresentationAdapter) => void`
|
|
148
|
+
|
|
149
|
+
Safely request a dashboard redraw without letting host issues break the run.
|
|
150
|
+
|
|
151
|
+
Parameters:
|
|
152
|
+
- `runtimeDashboard` - - Shared dashboard presentation adapter with optional redraw support.
|
|
153
|
+
|
|
154
|
+
## browser-entry/browser-entry.abort.services.ts
|
|
155
|
+
|
|
156
|
+
### composeBrowserEntryAbortSignal
|
|
157
|
+
|
|
158
|
+
`(internalController: AbortController, externalSignal: AbortSignal | undefined) => AbortSignal`
|
|
159
|
+
|
|
160
|
+
## browser-entry/browser-entry.globals.services.ts
|
|
161
|
+
|
|
162
|
+
### createBrowserEntryEvolutionHostAdapter
|
|
163
|
+
|
|
164
|
+
`() => import("test/examples/asciiMaze/evolutionEngine/evolutionEngine.types").EvolutionHostAdapter`
|
|
165
|
+
|
|
166
|
+
### installBrowserEntryGlobals
|
|
167
|
+
|
|
168
|
+
`(start: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryStartFunction) => void`
|
|
169
|
+
|
|
170
|
+
## browser-entry/browser-entry.curriculum.services.ts
|
|
171
|
+
|
|
172
|
+
### runBrowserEntryCurriculum
|
|
173
|
+
|
|
174
|
+
`(context: import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryCurriculumContext) => void`
|
|
175
|
+
|
|
176
|
+
## browser-entry/browser-entry.utils.ts
|
|
177
|
+
|
|
178
|
+
### createBrowserEvolutionSettings
|
|
179
|
+
|
|
180
|
+
`(dimension: number) => import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryEvolutionSettings`
|
|
181
|
+
|
|
182
|
+
### didSolveBrowserMaze
|
|
183
|
+
|
|
184
|
+
`(progress: unknown) => boolean`
|
|
185
|
+
|
|
186
|
+
### getNextBrowserMazeDimension
|
|
187
|
+
|
|
188
|
+
`(currentDimension: number) => number`
|
|
189
|
+
|
|
190
|
+
### resolveBrowserEntryHostElements
|
|
191
|
+
|
|
192
|
+
`(container: string | HTMLElement) => import("test/examples/asciiMaze/browser-entry/browser-entry.types").BrowserEntryHostElements`
|
|
193
|
+
|
|
194
|
+
### scheduleBrowserEntryFrame
|
|
195
|
+
|
|
196
|
+
`(callback: () => void) => void`
|