This roadmap reflects the sequence that matches the repository today:
- establish a working browser inference baseline,
- improve the model and the training/export workflow,
- deploy the app to Cloudflare Pages through GitHub Actions,
- return to the broader visualization vision afterward.
Current milestone status:
- Phase 1 - Browser Baseline: completed
- Phase 2 - Model Improvement + Training Pipeline: completed
- Phase 3 - Cloudflare Deploy: next
- Phase 4 - Advanced Visualization: future
Status: completed
DrawCanvasfor digit input- preprocessing to
28x28 PixelGridpreview- browser model loading from
public/model - prediction UI with top class and all class confidences
- clear/reset and model retry flow
- User can draw and clear reliably.
- Model loads in the browser.
- Prediction returns a
10-class confidence vector. - The baseline UI works on desktop and mobile layouts.
Status: completed
- dedicated
training/workspace - baseline and CNN experiment scripts
- Python training workspace in
training/python/ cnn-visualizer-cnn-v2- TensorFlow.js artifact export pipeline
- updated
public/model/model.jsonand shard - preprocessing alignment improvements in the browser
The committed training summary reports approximately:
- best validation accuracy:
0.9905 - test accuracy:
0.9910
- Model training is reproducible from repo docs.
- Browser artifacts can be regenerated from the training flow.
- The improved CNN is committed under
public/model/. - Browser preprocessing is better aligned with real drawn digits.
Status: next
Deploy the current static app to Cloudflare Pages through GitHub Actions.
.github/workflows/deploy-cloudflare-pages.yml- GitHub repository secrets for Cloudflare auth
- repository variable for the Pages project name
- build with
npm ciandnpm run build - deploy
dist/withcloudflare/wrangler-action@v3 - production verification that
/model/model.jsonresolves correctly
- Push to
mainbuilds and deploys automatically. - The deployed site loads the model assets correctly.
- Draw -> preprocess -> predict works in production.
- The workflow can be rerun safely.
Status: future
Resume the original educational visualization track after deploy is stable.
- intermediate activation extraction
- layer-by-layer explanation UI
- step/auto progression modes
- kernel traversal visualization
- richer rendering modules if the product still needs them
- Visualization features are built on top of the stable baseline.
- Model/runtime correctness remains intact.
- New rendering work does not regress deployability.
- drawing
- preprocessing
- prediction UX
- error states
- baseline experiments
- CNN architecture iteration
- Python training
- TF.js export compatibility
- static build validation
- Cloudflare Pages workflow
- production asset verification
- activation extraction
- render payload design
- educational interaction model
The repo now follows this dependency order:
- stable browser baseline first,
- stronger model second,
- deployment third,
- advanced visualization after the runtime and artifact pipeline are stable.
That order reduces the risk of building visualization complexity on top of unstable model or deployment behavior.
- Risk: deploy docs or workflow target the wrong platform.
- Mitigation: keep deployment docs Cloudflare-only.
- Risk: model artifacts and browser topology drift apart.
- Mitigation: regenerate through the shared export path.
- Risk: preprocess changes improve local examples but hurt production behavior.
- Mitigation: validate with repeated handwritten digit checks.
- Risk: visualization work restarts before deploy is stable.
- Mitigation: finish Cloudflare deployment first.
The next milestone is complete when:
- Phase 3 deploy workflow exists,
- Cloudflare production deploy succeeds,
- model assets are reachable in production,
- browser prediction behavior matches the local production build.