Instructions to use Nipun/pocket-pilot-json-decisions-0.8b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use Nipun/pocket-pilot-json-decisions-0.8b with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("unsloth/Qwen3.5-0.8B") model = PeftModel.from_pretrained(base_model, "Nipun/pocket-pilot-json-decisions-0.8b") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Unsloth Desktop
Pocket Pilot JSON Decisions · 0.8B
A task-adapted decision model for the three-lane Pocket Pilot teaching game. It reads structured obstacle JSON and answers a supplied schema in one forward pass, with zero generated answer tokens. It contains language LoRA adapters and a learned Clef-style joint decision head over Qwen3.5-0.8B.
This checkpoint accepts JSON, not images. The image experiment is trained separately. Both the native Unsloth checkpoint and a verified WebGPU export are included. The image experiment is saved separately.
Measured results
216 held-out scenes, with geometry-disjoint integer barrier-position bands. Training has 540 scenes; a separate 108-scene partition fits temperatures.
| Question | Fresh decision head | Trained |
|---|---|---|
| Which lane is open? | 72/216 (33.3%) | 216/216 (100%) |
| Is the middle lane blocked? | 72/216 (33.3%) | 216/216 (100%) |
| Which vertical third contains the barrier center? | 71/216 (32.9%) | 204/216 (94.4%) |
| Open lane, asked alone | not measured | 216/216 (100%) |
The earlier 22 diagnostic scenes also returned the correct lane (22/22), and saving/reloading changed none of those decisions. Test ECE across all three question types: 0.0168. Score accuracy uses the most likely level; the returned score is a probability-weighted average and may be fractional.
Warm synchronized median local request latency on NVIDIA RTX A2000 12GB:
- Three questions: 64.7 ms (95th percentile 65.0 ms).
- Lane question alone: 45.2 ms (95th percentile 45.4 ms).
These include input processing and result readback, excluding model loading/download and network time. They are not browser/WebGPU timings. The fresh-head baseline is not a prompted-chat model or a pretrained Clef/Liquid benchmark.
Browser / WebGPU
Choose Pocket Pilot · trained JSON · local WebGPU in the game, then Load and One decision. Deployment may briefly lag this model release. No API key or inference upload is needed. The first download is about 1.38 GB; a WebGPU device with shader-f16 and sufficient memory is required. Browser caching is best-effort.
On an Apple M2 Max, the browser evaluation covered the same 216 test scenes at each question count:
| Questions | Correct lane | Median local decision | p95 |
|---|---|---|---|
| 1 | 216/216 | 111.2 ms | 113.0 ms |
| 2 | 216/216 | 138.6 ms | 141.7 ms |
| 3 | 216/216 | 166.9 ms | 170.7 ms |
Three-question WebGPU evaluation also returned 216/216 middle-blocked labels and 204/216 vertical levels, with zero classification changes from native inference. These are warm browser times including preprocessing/readback, excluding download/setup. Device and browser differences matter; native CUDA and browser times are separate measurements. Accuracy is on this fixed game and schema, not general vision or general reasoning.
The export materializes the native NF4 backbone plus trained LoRA updates as float16 and keeps the trained decision head in float32. It scores the supplied schema; it does not generate text. A second 4-bit browser quantization was rejected due to hidden-state numerical drift. The optimized ONNX architecture uses fused recurrent attention instead of slow Scan loops. All learned template initializers are replaced with the trained tensors; an exact byte check permits reusing the original weight-file layout. Dynamic input lengths are supported. One to three road questions, in lane / middle-blocked / proximity order, are accepted.
browser/: pinned-download assets and SHA-256 manifest;.gzfiles decompress losslessly in-browser.browser-runtime/: runtime source, build instructions and dependency lock.export/: weight materialization, head export, native parity and packaging code.evaluation/browser-*: complete held-out responses and timings.
Use with Unsloth
Install Unsloth at revision 20cdc23470263c13f7e6f1eda6d01a62b9b64aeb in a CUDA environment. The measured run used torch 2.10.0, transformers 5.17.0, and Unsloth/Unsloth Zoo 2026.10.2.
from unsloth import FastDecisionModel
model, processor = FastDecisionModel.from_pretrained(
"Nipun/pocket-pilot-json-decisions-0.8b",
max_seq_length=1024,
load_in_4bit=True,
)
FastDecisionModel.for_inference(model)
state = {
"input_kind": "structured scene, no image",
"lane_order": ["left", "middle", "right"],
"canvas_height": 480,
"car_lane_index": 1.0,
"obstacles": [
{"lane": "left", "y": 180, "height": 49},
{"lane": "right", "y": 180, "height": 49},
],
}
questions = {
"lane": {
"type": "choice",
"instructions": "Which lane contains no obstacle? Infer the opening from the obstacles list. Ignore the car position.",
"criteria": {
lane: "The " + lane + " lane contains no obstacle."
for lane in ("left", "middle", "right")
},
}
}
print(FastDecisionModel.predict(model, processor, state, questions))
Use predict.py --model <downloaded-repository> --input json for JSON-line requests and typed responses with timing metadata. It does not invoke a game oracle or correct the answer. Do not use a text-generation pipeline: it will omit the trained decision head.
Training and files
- Base:
unsloth/Qwen3.5-0.8B, revision23c69c53358a07516b5827588b3fdb12ae78fd65. - 4-bit backbone; LoRA rank/alpha 16; fresh Clef joint schema head width 512.
- Three epochs, 204 optimizer steps, effective batch 8, seed 3407.
- Backbone LR 0.0002; decision-head LR 0.0001.
- Targets are derived from deterministic game geometry, not another model.
- Questions belonging to a scene remain in the same partition. Training permutes question order. Clef sorts option keys internally.
adapter_model.safetensors: trained LoRA weights.joint_head.safetensors/joint_head_config.json: trained decision head.unsloth_decision_config.json: base revision and calibrated temperatures.data/: all synthetic JSON examples and split/hash manifest.evaluation/: per-scene before/after answers, metrics and reload checks.training/train_unsloth.py: exact executed training script.weights-manifest.json: SHA-256 hashes for both weight files.
From the repository root, the training script accepts --data data --out <new-run-directory>. Install bitsandbytes and trackio alongside the pinned Unsloth environment. Trackio is configured locally with no public Space.
Limits
This is a narrow game-specific adaptation, not evidence of general reasoning or robust autonomous driving. All three gap classes appear in training and testing. Numerical scene states are new, but the game, schema and rendering conventions are fixed. Near-boundary vertical classification is imperfect. Accuracy above is measured on static scenes. Closed-loop success and speeds still depend on device latency and game timing. Image input is not supported by this checkpoint. Only the supplied road schemas and up to 1,024 encoded tokens are supported by this browser export.
Model confidence is an estimate, not proof. No API keys, private game sessions or personal training data are included.
Weights retain the base model’s Apache-2.0 license. Training/inference depend on Unsloth (AGPL-3.0) and its Cloudflare Clef implementation; those software licenses remain applicable. See Unsloth’s decision-training recipe.
- Downloads last month
- 29