CoolFace
Apppublic

cgi-domh/CGI-Reachy-Assistant-App

sourceHugging Faceupdated 18h agoView on Hugging Face
0likes
App README

CGI • Reachy APP

A Reachy Mini JavaScript/Web application that answers questions about CGI using a curated, official-CGI knowledge base.

Development

bash
npm install
npm run dev

Open the Vite URL in a browser. The Reachy host shell handles authentication, robot selection, WebRTC and session lifecycle.

Hugging Face OAuth

This app uses the Reachy Mini host shell for Hugging Face authentication. The Space metadata sets hf_oauth: true, and index.html contains the __OAUTH_CLIENT_ID__, __OAUTH_SCOPES__, __SPACE_HOST__, and __SPACE_ID__ placeholders that Hugging Face substitutes when serving the built HTML. The Reachy SDK host shell then reads those values and handles sign-in, redirect handling, session storage, sign-out, robot selection, and the Reachy session lifecycle.

No Hugging Face client secret is placed in the browser bundle. For production, keep the default openid profile scopes unless the app has a documented need for additional permissions.

For local development, you can either use the Reachy SDK's VITE_HF_TOKEN/VITE_HF_USERNAME development shortcut or register a local OAuth client and set VITE_HF_OAUTH_CLIENT_ID. Never commit .env.local or access tokens.

Configuration

Copy .env.example to .env.local and configure provider endpoints.

Do not put private API keys in a browser bundle. For production, point the provider adapters at a server-side proxy or provider endpoint that is safe to expose.

Knowledge ingestion

bash
npm run ingest:cgi

The ingestion script only accepts URLs whose hostname is explicitly allowlisted. It writes public/cgi-knowledge.json.

Runtime architecture

dispatch.ts loads the Reachy host shell or the embedded app. embed.ts owns the conversation state machine. Provider-neutral adapters live under src/providers/; CGI retrieval lives under src/cgi/; robot movements live under src/motion/.

Current limitations

  • —The initial knowledge file is intentionally small and reproducible; run the ingestion command to refresh it.
  • —Wake-word/STT/TTS are adapter interfaces with a browser-safe HTTP implementation. A production deployment should normally use a server-side provider proxy.
  • —The app uses Reachy's WebRTC media stream and does not request the computer microphone with getUserMedia().