OpenViSTAI · Agents · Blockchain · Crypto
Menu
Local & Self-hosted AI

React Native Transformers

React Native Transformers is a TypeScript library for running Hugging Face transformer models on-device in React Native and Expo apps, using ONNX Runtime for inference.

Independent OpenViST project profile, based on linked sources.

React Native Transformers — OpenViST project profile in Local & Self-hosted AI.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Consider it when building a React Native or Expo app that needs on-device transformer inference and you can accommodate its native setup and the repository's inactive maintenance status.

Who it is for

  • React Native developers adding local language-model inference to mobile apps.
  • Expo developers who can configure native dependencies and use a development client.

Documented uses

  • Generate text in a React Native or Expo app using an on-device transformer model.
  • Build app interactions that answer questions or process language without sending prompts to a hosted model service.
  • Download and cache model files for use by an app.
Before you choose

Requirements & limits

  • Inference uses ONNX Runtime through the onnxruntime-react-native dependency.
  • Model files must be fetched or otherwise made available to the app; the README shows a fetch callback and an Expo cache example.
  • Expo development requires a development client rather than Expo Go because of native code.
  • The repository notice says active maintenance ended in July 2025.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Set up the library in an Expo app

Configure the documented native dependencies and Babel plugin for an Expo integration.

Before you start

  • An Expo application
  • onnxruntime-react-native
  • A development client using EAS Development Build or Expo Prebuild

Steps

  1. Install onnxruntime-react-native and react-native-transformers.

  2. Add onnxruntime-react-native to the Expo plugins configuration in app.json or app.config.js.

  3. Add babel-plugin-transform-import-meta to the Babel plugins configuration.

  4. Use a development client rather than Expo Go because the library uses native code.

Expected outcome

The documented Expo-side dependency and configuration setup is in place for integrating the library.

Guide limitations

  • This setup recipe does not cover loading a model or generating text.
  • The repository says the project is no longer actively maintained.
Source-based practical guide

Load an ONNX Llama model and generate text

Follow the README example to initialize a Hugging Face ONNX model and pass generated text to an app interface.

Before you start

  • A configured React Native or Expo app with the library and ONNX Runtime dependency
  • A model repository and ONNX model file
  • A fetch function that returns the downloaded model file location

Steps

  1. Import Pipeline from react-native-transformers.

  2. Initialize Pipeline.TextGeneration with the model repository and ONNX file path.

  3. Provide the required fetch function for model files.

  4. Call Pipeline.TextGeneration.generate with a prompt and use its callback to update the displayed output.

Expected outcome

The example connects a text-generation prompt to generated text displayed in the app.

Guide limitations

  • The README example downloads model files; it does not establish that they are already available offline.
  • The repository says the project is no longer actively maintained.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
15 October 2026
Original website title
daviddaytw/react-native-transformers · Official homepage title · retained in its source language