Skip to content

CheFu-code/Quantum-App

Repository files navigation

Quantum

Quantum is the Expo/React Native mobile client for the Quantum AI assistant. It mirrors the Quantum web app experience with chat threads, model tiers, tool toggles, file attachments, local conversation history, settings, and the same /api/chat request contract.

Stack

  • Expo SDK 56
  • React Native 0.85
  • Expo Router
  • TypeScript
  • Android native project generated by Expo prebuild

Setup

Install dependencies:

npm install

If Android commands are not visible in PowerShell, set them for the current session:

$env:ANDROID_HOME="$env:LOCALAPPDATA\Android\Sdk"
$env:ANDROID_SDK_ROOT=$env:ANDROID_HOME
$env:JAVA_HOME="C:\Program Files\Microsoft\jdk-17.0.19.10-hotspot"
$env:Path="$env:JAVA_HOME\bin;$env:ANDROID_HOME\platform-tools;$env:ANDROID_HOME\emulator;$env:Path"

Run on Android

Start an emulator:

emulator -avd RN_API_35

Check that Android can see it:

adb devices

Then build and install the app:

npx expo run:android

First builds may download Gradle and Android dependencies. That is normal.

Run with Expo

Start the Expo dev server:

npm start

Run the web target:

npm run web

The project includes native modules, so Android development builds should use npx expo run:android.

Chat Endpoint

By default, the app calls:

https://quantum.chefuinc.com/api/chat

To point the app at the local Next.js Quantum web app, start the web app and set:

$env:EXPO_PUBLIC_QUANTUM_CHAT_API_URL="http://localhost:3003/api/chat"

Restart Expo after changing this value.

For Android emulator access to a server running on your computer, use:

$env:EXPO_PUBLIC_QUANTUM_CHAT_API_URL="http://10.0.2.2:3003/api/chat"

Project Layout

src/app/                  Expo Router entry screens
src/components/quantum/   Quantum mobile UI components
src/constants/            Models, preferences, endpoint config, UI constants
src/hooks/                Chat state and action hooks
src/lib/                  Attachments, API client, storage, thread utilities
src/types/                Shared Quantum chat types
android/                  Generated native Android project

Useful Commands

npx tsc --noEmit
npx expo run:android
npm run web

Notes

  • Conversation history is stored locally with AsyncStorage.
  • Attachments are read as base64 and sent to the Quantum chat API.
  • The Android emulator hostname for your computer is 10.0.2.2, not localhost.
  • If adb or emulator is not recognized, re-run the Android environment commands above.

Releases

No releases published

Packages

 
 
 

Contributors