Skip to content

CiphemonJY/Desktop-Digimon

Repository files navigation

Desktop Digimon 🥚

A 3D pet Digimon desktop companion for macOS with real-time voice interaction and OpenClaw integration.

Version Platform Swift

Features

🦕 6 Evolution Stages

Your Digimon evolves based on task intensity:

  • Botamon → Idle/sleeping (power 0-9%)
  • Koromon → Light activity (power 10-24%)
  • Agumon → Normal work (power 25-49%)
  • Greymon → Heavy tasks (power 50-74%)
  • MetalGreymon → Complex work (power 75-94%)
  • WarGreymon → Peak cognitive load (power 95%+)

Power decays naturally when idle, returning to Agumon baseline.

🎤 Voice Interaction

  • Push-to-talk: Hold your configured key, speak commands
  • Fixed commands: "think", "work", "sleep", "wake", "digivolve", etc.
  • Free-text mode: Unrecognized speech → OpenClaw for natural language processing
  • TTS readback: OpenClaw responses spoken aloud via AVSpeechSynthesizer

🔗 OpenClaw Integration

Desktop Digimon connects to your OpenClaw instance via HTTP hooks:

  • Receives events for tool calls, subagent spawns, git pushes
  • Sends voice transcripts to OpenClaw for processing
  • Real-time TTS feedback on LLM responses

Installation

Requirements

  • macOS 13.0 or later
  • Xcode 15+ (for building)
  • Filament rendering engine (C++ headers required at compile time)
  • Whisper.cpp models (included in libs/whisper/)

Build from Source

# Clone the repository
git clone https://github.com/CiphemonJY/Desktop-Digimon.git
cd Desktop-Digimon

# Build with Swift Package Manager
swift build -c release

# Or open in Xcode
open Package.swift

Configuration

Edit ~/Library/Application Support/DesktopDigimon/config.json:

{
  "openclawHooksUrl": "http://127.0.0.1:18789/hooks/agent",
  "openclawHooksToken": "your-openclaw-token",
  "pushToTalkEnabled": true,
  "voiceEnabled": true
}

Usage

Voice Commands

Command Action
"think" Triggers thinking animation
"work" Triggers work animation
"sleep" Degenerates to Botamon
"wake" Returns to Agumon
"digivolve" Forces evolution to next stage
"status" Shows current power level and form
"help" Lists available commands

Keyboard Shortcuts

  • Push-to-talk: Configured in System Settings → Keyboard Shortcuts
  • Toggle window: Command+W
  • Quit: Command+Q

Architecture

Components

  • SwiftUI App — Main application with menu bar integration
  • FilamentBridge — C++ bridge to Filament 3D rendering engine
  • WhisperBridge — C++ bridge to Whisper speech recognition
  • HTTPServer — Loopback HTTP server for OpenClaw events (port 23333)
  • EventBridge — Event dispatcher for lifecycle events
  • VoiceLayer — STT/TTS management with push-to-talk
  • DigivolutionManager — Auto-evolution based on power level tracker

Security

  • App Sandbox enabled with minimal entitlements
  • Hardened Runtime with microphone access
  • Keychain storage for auth tokens
  • Constant-time comparison for authentication
  • Event type allowlist prevents malicious payloads

Development

Running Tests

swift test

Debugging

The app logs to stderr in JSON format. Capture with:

log stream --predicate 'subsystem == "ai.openclaw.desktop-digimon"' --info

Adding Animations

Animations are stored in assets/models/. Each model should have:

  • GLB format with embedded textures
  • Mixamo-style bone naming (capitalized)
  • Animation clips: Idle_Breath, Walk, Run, Attack, Special, Victory

Troubleshooting

Model not loading

Check that model files exist in assets/models/. The app shows an error overlay if the default Agumon model is missing.

Voice not working

  1. Ensure microphone permissions granted in System Settings → Privacy & Security
  2. Verify Whisper model exists at libs/whisper/models/ggml-base.en.bin
  3. Check voiceEnabled: true in config.json

OpenClaw events not received

  1. Verify openclawHooksToken matches your OpenClaw instance
  2. Check that OpenClaw HTTP hooks are enabled
  3. Ensure port 23333 is not blocked by firewall

License

MIT License — see LICENSE file.

Model assets may have separate licenses:

  • Agumon/Greymon/MetalGreymon/WarGreymon: Custom rigged models
  • Botamon/Koromon: Sketchfab CC Attribution

Status: v1.0-beta — Personal proof of concept. Not production-ready.

About

3D desktop pet Digimon for macOS with voice interaction and OpenClaw integration

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors