Starmoon

Starmoon

An open source voice-enabled, compact, empathic AI hardware + software 🤖 framework for companionship, entertainment, education, pediatric care, IoT robotics applications, AI-enhanced robotics application services, research, and DIY robotics kit development using Python, NextJs, Arduino, ESP32, LLMs (GPT), STT, TTS, Emotion Analysis, AI agent

Stars: 348

Visit
 screenshot

Starmoon is an affordable, compact AI-enabled device that can understand and respond to your emotions with empathy. It offers supportive conversations and personalized learning assistance. The device is cost-effective, voice-enabled, open-source, compact, and aims to reduce screen time. Users can assemble the device themselves using off-the-shelf components and deploy it locally for data privacy. Starmoon integrates various APIs for AI language models, speech-to-text, text-to-speech, and emotion intelligence. The hardware setup involves components like ESP32S3, microphone, amplifier, speaker, LED light, and button, along with software setup instructions for developers. The project also includes a web app, backend API, and background task dashboard for monitoring and management.

README:

 Starmoon - An affordable, empathic, and conversational AI companion

Starmoon is an affordable, compact AI-enabled device, you can take anywhere and converse with. It can understand your emotions and respond with empathy, offering supportive conversations and personalized learning assistance.

Check our Roadmap

Starmoon-logo

Discord Follow GitHub forks GitHub stars

License: GPLv3    Node.js React

Demo Highlights 🎥

https://github.com/user-attachments/assets/89394491-9d87-48ab-b2df-90028118450b

If you can't see the video, you can watch it here

Key features 🎯

  • Cost-effective: Assemble the device yourself with affordable off-the-shelf components.
  • Voice-enabled emotional intelligence: Understand and analyze insights in your emotions through your conversations in real time.
  • Open-source: Fully open-source, you can deploy Starmoon locally and self-host to ensure the privacy of your data.
  • Compact device: Only slightly larger than an Apple Watch, you can carry the device anywhere.
  • Reduced screen time: A myriad of AI companions are screen-based, and our intention is to give your eyes a rest.

Getting Started 🚀

Prerequisites 📋

  1. API keys and services:

  2. Hardware list (Tax and shipping rates may vary by region)

Software setup 🖥️

  • Step 0: Clone the repository:

    git clone https://github.com/StarmoonAI/Starmoon.git && cd Starmoon
  • Step 1: Set up Supabase:

    supabase start
    supabase db reset
  • Step 2: Copy the .env.example files

    cp .env.example .env
  • Step 3: Update tokens in the .env file

    • For local set up, you only need to update OPENAI_API_KEY, MS_SPEECH_ENDPOINTY, SPEECH_KEY, SPEECH_REGION, DG_API_KEY, HF_ACCESS_TOKEN
  • Step 4: Launch the project

    • If you have a Mac, go to Docker Desktop > Settings > General and check that the "file sharing implementation" is set to VirtioFS.

      docker compose pull
      docker compose up

      If you are a developer, you can run the project in development mode with the following command: docker compose -f docker-compose.yml up --build

  • Step 5: Login to the app

Hardware setup 🧰

  • Step 0 (Optional): Build the device yourself (alternatively, the Starmoon DIY Dev Kit comes pre-assembled so you can focus on working with your own frontend + backend)

    • Follow the instructions here in Pin Configuration section for more details on assembly
  • Step 1: Click PlatformIO Icon in VScode left sidebar

    • Click "Pick a folder"
    • Select the location of the firmware folder in the current project.
  • Step 2: Update and WebSocket server details in src/Config.cpp

    • Find your WiFi ip adress (websocket_server_host) by command ipconfig (under Default Gateway) in Windows or ifconfig (under inet xxx.x.x.x netmask 0xff000000) in Linux/MacOS, or you can also follow the instructions here

      const char *websocket_server = "<your-server-host-ip>"; // Wifi settings -> Your Wifi I.P.
      const uint16_t websocket_port = 8000; 
      const char *websocket_path = "/starmoon";
      const char *auth_token = "<your-STARMOON_API_KEY-here>"; // generate your STARMOON_API_KEY in your starmoon account settings page
  • Step 3: Build the firmware

    • Click Build button in the PlatformIO toolbar or run the build task.
  • Step 4: Upload the firmware to the device

    • Connect your ESP32-S3 to your computer using usb.
    • Click the Upload button to run the upload task, or Upload and Monitor button to run the upload task and monitor the device.
  • Step 5: Hardware usage

    • Power the device -> Use your phone/tablet/pc to connect "Starmoon device" WiFi and follow the instructions to set up internet connection (only support 2.4Ghz WiFi).

    • Once the software and firmware are set up, you can push the button to power on the ESP32 device and start talking to the device.

Updating Starmoon App 🚀

  • Step 1: Pull the latest changes

    git pull
  • Step 2: Update the migration

    supabase migration up

License

This project is licensed under the GPL-3.0 License - see the LICENSE file for details

For Tasks:

Click tags to check more tools for each tasks

For Jobs:

Alternative AI tools for Starmoon

Similar Open Source Tools

For similar tasks

For similar jobs