File size: 4,468 Bytes
efc59a3 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | ---
license: other
license_name: mit-and-apache-2.0
license_link: LICENSE
language:
- en
pipeline_tag: text-classification
tags:
- railshot
- rack-lab
- intel-ncs1
- openvino
- onnx
- streaming
- sqlite
---
# RailShot Stream v0.1 Preview
[](assets/hero-motion.webp)
RailShot runs ordered, restartable text decision sessions on a single machine. It keeps separate documents for each stream, runs the MagicEightBall decision head on CPU or the original Intel Neural Compute Stick, and commits each accepted fragment and result to SQLite before replying. The release includes the compact MagicEightBall native archive, a portable ONNX graph, and the three frontline policy banks.
## Industry replay
The records below are authored simulations. Every row was executed on the CPU and the physical NCS1. The second process reopened the same journal, retrieved the original approval result for an exact retry, then applied the new veto.
| Workflow | Split approval completed | Added after restart | New proposal |
| --- | --- | --- | --- |
| Dealership service intake | **Service requested. Intake approved.** → `review_service_intake` | **Customer declined.** | `null` |
| Manufacturing maintenance | **Vibration alert. Maintenance review approved.** → `review_mechanical_alert` | **Maintenance hold.** | `null` |
| Store equipment review | **Camera offline. Security review approved.** → `review_camera_alert` | **Alert cleared.** | `null` |
**48/48 checks passed across both backends.** Each workflow also exercises a sequence gap, a conflicting retry, an independent stream and a reset. A separate physical replay accepted exactly **131,072 tokens** and recovered after rejecting a 131,073-token append. [Raw industry results](measurements/industry-results.json) · [Physical limit and restart replay](measurements/physical-replay.json)
[](assets/industry-replay.webp)
## Run the preview
Download the repository as a directory and run from its root. The examples below use Windows PowerShell.
~~~powershell
hf download tablinum/RailShot-Stream --local-dir RailShot-Stream
cd RailShot-Stream
python -m pip install numpy onnxruntime sentencepiece
python industry_replay.py --out ./results/cpu
~~~
For a physical NCS1 replay, use a functioning Windows OpenVINO 2020.3.2 toolchain with Python 3.7 and SentencePiece 0.1.99. Keep the original stick in its cold USB state before each session.
~~~powershell
$toolchain = 'C:/path/to/ncs1'
$native = Join-Path $toolchain '.venv/Scripts/python.exe'
& $native -m pip install sentencepiece==0.1.99
python industry_replay.py --out ./results/physical --native-python $native --toolchain $toolchain
~~~
Here's an individual stream on the dealership policy.
~~~powershell
$bundle = 'labs/shave_models/boolean/industries/frontline/bundle'
@'
{"stream_id":"service-42","seq":1,"append":"Service requested. Intake "}
{"stream_id":"service-42","seq":2,"append":"approved."}
{"stream_id":"service-42","seq":3,"append":" Customer declined."}
'@ | python -m apps.railshot --db results/dealership.sqlite3 --artifact "$bundle/model.onnx" --bank dealership
~~~
On NCS1, run the same command with the legacy interpreter and pass `--backend ncs1 --toolchain $toolchain --artifact "$bundle/ncs1-native.blob"`. Give the native lane its own journal. The [runtime guide](RUN.md) explains sequencing, replay, error responses, and the durable transaction boundary.
## Scope
The device runs the learned MagicEightBall decision head. Host code handles the pinned tokenizer, evidence phrases, sequencing, and SQLite. Each page example produces a review proposal for another application or person. This preview covers authored policy phrases and local process restart. It stores request text in the local journal. Disk flushes affect acknowledgement latency, and longer histories require more recovery replay between resets.
[MagicEightBall](https://huggingface.co/tablinum/MagicEightBall) · [The Break Room](https://huggingface.co/spaces/tablinum/The-Break-Room) · [MyriadForge](https://github.com/chadstthomas-svg/myriadforge) · [License notices](NOTICE.md) · [File hashes](SHA256SUMS.txt)
|