# Project Overview

## What is this project?

Hikari Desktop is a Tauri-based desktop application that wraps Claude Code with a visual anime character companion (Hikari) who appears on screen. It provides a rich UI for interacting with Claude Code, including conversation management, agent monitoring, cost tracking, and more.

The app was inspired by a Hatsune Miku mod for the ship AI in _The Outer Worlds_ — the idea of an AI assistant with an anime girl avatar that you can actually _see_.

## Goals

- Provide a beautiful, personalised interface for Claude Code
- Surface real-time status (thinking, typing, searching, etc.) through animated character sprites
- Track costs, context usage, and agent activity across sessions
- Support power-user workflows: multi-tab conversations, todo lists, git integration, MCP server management, session compaction, and more
- Build a foundation for autonomous task execution (agent orchestration, PRD-driven workflows)

## Tech Stack

- **Frontend**: Svelte 5 + TypeScript + Tailwind CSS
- **Backend**: Rust (Tauri v2)
- **Build**: Vite + pnpm
- **Testing**: Vitest (frontend) + cargo test (backend)
- **Linting**: ESLint + Prettier (frontend) + Clippy (backend)
- **IPC**: Tauri commands + events between Rust and Svelte

## Architecture

```
hikari-desktop/
├── src/                        # Svelte frontend
│   └── lib/
│       ├── components/         # UI components (panels, modals, status bar)
│       ├── stores/             # Svelte stores (state management)
│       ├── types/              # TypeScript type definitions
│       └── utils/              # Utility functions
├── src-tauri/                  # Rust backend
│   └── src/
│       ├── commands.rs         # Tauri command handlers
│       ├── wsl_bridge.rs       # Claude Code process management
│       ├── types.rs            # Shared types & CharacterState enum
│       └── stats.rs            # Cost tracking
└── public/                     # Static assets (sprites, sounds)
```

Claude Code is launched as a child process via `WslBridge`, communicating via `--output-format stream-json` (NDJSON). Messages flow from the Rust backend to the Svelte frontend via Tauri events.
