PlayTorch
A framework for rapidly creating on-device mobile AI experiences with PyTorch and React Native.
A framework for rapidly creating on-device mobile AI experiences with PyTorch and React Native.

On-device inference
Runs PyTorch Mobile models directly on the phone for vision and language tasks, with no server round trip.
React Native SDK (torchlive)
Exposes torch, torchvision and media modules to JavaScript so models can be called from React Native code.
PlayTorch mobile app and Snacks
A companion app lets developers scan a QR code and test JavaScript snippets on a real device in minutes.
Camera and Canvas views
Built-in CameraView and CanvasView components capture frames and render results such as bounding boxes overlaid on the camera feed.
Text tokenizers
Includes BasicTokenizer and WordpieceTokenizer modules for natural language processing pipelines.
Ready-made demos
Ships examples for image classification, object detection (YOLOv5), question answering, AnimeGAN style transfer and a French translator.
Custom model preparation
Tooling to package and optimise your own PyTorch models for mobile deployment.
Mobile developers prototyping image classification or object detection features that run offline on the device.
Researchers and students demonstrating PyTorch models on phones without building a custom native app.
Hackathon and proof-of-concept teams wanting to test an AI idea on a real device in minutes via the PlayTorch app.
React Native engineers adding on-device language tasks such as question answering or translation to an app.
Educators teaching on-device machine learning concepts using the ready-made demo snacks.