Skip to content
Open
Show file tree
Hide file tree
Changes from 69 commits
Commits
Show all changes
130 commits
Select commit Hold shift + click to select a range
a03049c
feat(stage-ui): add URL-based model import with VPM support
inoribea Oct 6, 2025
3c83593
fix: resolve CORS and WebSocket issues for Vercel deployment
inoribea Oct 6, 2025
ab5d779
feat(stage-ui): auto-select default providers from environment
inoribea Oct 6, 2025
2e8be01
chore: add provider environment variables to build config
inoribea Oct 6, 2025
0876fad
docs: add Vercel deployment environment variables guide
inoribea Oct 6, 2025
835df56
fix(build): configure turbo and vercel for proper deployment
inoribea Oct 6, 2025
bb148ec
fix(vercel): use workspace flag for build command and add turbo env vars
inoribea Oct 6, 2025
e882bd6
fix(turbo): use globalPassThroughEnv to suppress optional env var war…
inoribea Oct 6, 2025
73ab790
fix(vercel): disable remote cache and update build command
inoribea Oct 6, 2025
aae39ee
fix(build): configure output directory and suppress turbo env warnings
inoribea Oct 6, 2025
bdca07f
fix(turbo): add passThroughEnv override to suppress env warnings
inoribea Oct 6, 2025
f8b4ac2
revert(build): restore original output directory configuration
inoribea Oct 6, 2025
f21f527
fix(build): expose dist output
inoribea Oct 6, 2025
e273737
chore(repo): pass env vars to turbo build
inoribea Oct 6, 2025
affec0e
feat(stage-ui): allow env default models
inoribea Oct 6, 2025
c9b3231
fix(stage-ui): skip onboarding when env configured
inoribea Oct 6, 2025
12e3a7c
fix(stage-ui): keep provider settings interactive
inoribea Oct 6, 2025
649cd56
fix(stage-web): self host fonts and ensure zod
inoribea Oct 6, 2025
ae5c4fb
Merge branch 'moeru-ai:main' into main
inoribea Oct 6, 2025
fd460fc
feat(memory): integrate configurable memory providers
inoribea Oct 6, 2025
dff1c29
fix(server-runtime): add missing @proj-airi/memory-system dependency
inoribea Oct 7, 2025
15c44f2
Merge upstream/main while preserving memory system
inoribea Oct 7, 2025
62d491a
feat(i18n): add Chinese translations for memory settings
inoribea Oct 7, 2025
0c447cc
feat(live2d): support loading model3.json from URL with auto resource…
inoribea Oct 7, 2025
e192419
docs: add Chinese guide for Vercel deployment
inoribea Oct 7, 2025
aebe5b2
feat(stage-web): integrate vercel analytics and refresh sw
inoribea Oct 7, 2025
f77fcd3
fix(vercel): add SPA rewrites to fix dynamic import 404 errors on pag…
inoribea Oct 7, 2025
b4bfaed
fix(character-card): properly integrate character card fields into sy…
inoribea Oct 7, 2025
2715450
fix(i18n): add missing Chinese translations for memory settings
inoribea Oct 7, 2025
8cff755
fix(character-card): ensure system prompt is properly initialized and…
inoribea Oct 7, 2025
48718bf
fix(storage): add error handling for corrupted localStorage data
inoribea Oct 7, 2025
8983047
debug: add initialization logging to character card and chat stores
inoribea Oct 7, 2025
3f5d3aa
fix(character-card): initialize default card before chat store to ens…
inoribea Oct 7, 2025
9cb01cc
revert: remove character card debug logs and incorrect fixes
inoribea Oct 7, 2025
8eff377
fix(character-card): force clear chat history when switching cards fo…
inoribea Oct 7, 2025
431cdbc
fix(character-card): fix SSR initialization and chat store sync issues
inoribea Oct 7, 2025
e8c79f0
debug: add system prompt logging to diagnose LLM prompt issue
inoribea Oct 7, 2025
9da0a3c
debug: add LLM request logging to verify messages sent to provider
inoribea Oct 7, 2025
6f05239
fix(character-card): add logging and auto-clear chat on card switch
inoribea Oct 7, 2025
3b9423e
fix(character-card): watch activeCardId for proper change detection
inoribea Oct 7, 2025
be71bd8
fix(providers): skip health checks in browser to avoid CORS errors
inoribea Oct 7, 2025
de1a6af
merge: sync with upstream moeru-ai/airi
inoribea Oct 7, 2025
1ca1c19
fix(stage-web): self host fonts and ensure zod
inoribea Oct 6, 2025
56d48c0
docs: add .env.example for Vercel deployment configuration
inoribea Oct 7, 2025
a80bd5c
docs(vercel): add complete environment variable reference for all AI …
inoribea Oct 7, 2025
0d3cac6
chore(deps): sync pnpm lockfile
inoribea Oct 7, 2025
1cc596e
feat(env): add Cloudflare Workers AI and memory system environment va…
inoribea Oct 8, 2025
4fe348c
fix(env): enable CLOUDFLARE_ACCOUNT_ID and fix memory API for static …
inoribea Oct 8, 2025
a8a59a8
refactor(memory): modularize memory settings page with overview compo…
inoribea Oct 8, 2025
2db6e0c
feat(api): add Vercel serverless functions for memory system
inoribea Oct 8, 2025
a4f8b07
chore(deps): add @vercel/node for serverless functions
inoribea Oct 8, 2025
c98981f
chore(deps): update lockfile for Vercel deployment
inoribea Oct 8, 2025
c4f9caf
feat(websocket): add environment variable to disable WebSocket connec…
inoribea Oct 8, 2025
16238b5
feat(api): implement standalone memory service for Vercel serverless
inoribea Oct 8, 2025
314a32e
fix(api): implement full short-term memory support (Vercel KV + Upsta…
inoribea Oct 8, 2025
301aa58
feat(memory): implement serverless long-term memory with Postgres+pgv…
inoribea Oct 8, 2025
edee944
Update .env.example
inoribea Oct 8, 2025
e4f8159
chore: update Upstash environment variables to match Vercel defaults
inoribea Oct 8, 2025
87fa653
fix(config): improve environment variable handling for memory and Web…
inoribea Oct 8, 2025
213c8c0
fix(config): defer memory env to vercel
inoribea Oct 8, 2025
8afc61d
fix(api): add missing dependencies for Vercel serverless functions
inoribea Oct 8, 2025
bd20788
feat(memory): add Cloudflare API token support and configuration stat…
inoribea Oct 8, 2025
5c492ca
fix(api): remove ES module type to fix Vercel serverless deployment
inoribea Oct 8, 2025
1c908d3
fix(config): restore correct Upstash and Cloudflare environment varia…
inoribea Oct 8, 2025
c9a1a4f
fix(memory): add comprehensive Upstash env var support and local dev …
inoribea Oct 8, 2025
73bb4f5
fix(vite): remove incorrect API proxy configuration
inoribea Oct 8, 2025
d64fd62
fix(vercel): correct build command and output directory path
inoribea Oct 8, 2025
4817064
fix(vercel): restore working build command with pnpm filter
inoribea Oct 8, 2025
b80bf6d
fix(memory): install runtime deps for vercel functions
inoribea Oct 10, 2025
92ae252
fix(vercel): correct API routing and build configuration for proper d…
inoribea Oct 10, 2025
7b52e83
fix(vercel): correct runtime format for API functions
inoribea Oct 10, 2025
9b34358
fix(vercel): pin node runtime version
inoribea Oct 10, 2025
5d6d144
fix(memory): streamline embedding configuration
inoribea Oct 10, 2025
af3e1a0
fix(stage-web): force browser onnx runtime
inoribea Oct 10, 2025
97a19e7
fix(memory): align long-term defaults
inoribea Oct 10, 2025
1556a2c
fix(memory): persist long-term entries and align embedding config
inoribea Oct 10, 2025
11c4175
fix(memory): align embedding env priorities and pg pooling
inoribea Oct 10, 2025
4982f63
fix: restore tracking rewrites and Live2D stage safety
inoribea Oct 10, 2025
42df634
feat(memory): fix long-term memory storage and enhance keyword detection
inoribea Oct 10, 2025
55780b7
Merge upstream/main while preserving memory system fixes
inoribea Oct 10, 2025
8636a24
fix(memory): enhance storage logic for AI responses and fix search debug
inoribea Oct 10, 2025
eec70b5
fix: update pnpm lockfile after dependency updates
inoribea Oct 10, 2025
b20bc31
fix: resolve TypeScript compilation errors in API
inoribea Oct 10, 2025
e5530f8
fix: embedding configuration translation and Cloudflare API token
inoribea Oct 10, 2025
2a7051d
fix: add missing database environment variables to Vite config
inoribea Oct 10, 2025
8cd811f
fix: remove unused defu dependency from server-sdk
inoribea Oct 10, 2025
f78af0f
fix: add Upstash Redis environment variables to Vite config
inoribea Oct 10, 2025
7c14e76
fix: update pnpm lockfile after Upstash environment variables addition
inoribea Oct 10, 2025
03f9d73
fix(memory): localize embedding config and detect upstash defaults
inoribea Oct 10, 2025
26c6c25
fix(memory): align memory config defaults with translations
inoribea Oct 10, 2025
ad060c9
fix(memory): restore baseline memory configuration
inoribea Oct 10, 2025
64e1c9a
fix(i18n): add embedding translation keys under pages.memory.embedding
inoribea Oct 10, 2025
ceae51a
fix(vite): add missing Upstash environment variable names
inoribea Oct 10, 2025
5495b51
fix(memory): default to upstash-redis when configured, fallback to ve…
inoribea Oct 10, 2025
78867ae
fix(i18n): add settings.memory namespace for embedding translations
inoribea Oct 10, 2025
f392a77
fix(i18n): add settings.memory namespace for English translations
inoribea Oct 10, 2025
d2c1d1a
fix(api): add missing pg dependency
inoribea Oct 10, 2025
185955e
chore: trigger Vercel rebuild for i18n translations
inoribea Oct 10, 2025
616a19a
fix(memory): improve Cloudflare embedding response parsing with debug…
inoribea Oct 10, 2025
6e1149d
chore: force Vercel clean rebuild for i18n translations
inoribea Oct 10, 2025
e3468b3
fix(vercel): ensure i18n package is built before stage-web
inoribea Oct 10, 2025
1a9bd85
fix(vercel): remove framework field to use custom buildCommand
inoribea Oct 10, 2025
e8b1491
docs: add database migration for memory_embeddings table
inoribea Oct 10, 2025
26d06d4
fix(memory): correct API response data structure in frontend
inoribea Oct 10, 2025
d3f173d
feat(providers): add environment variable support for speech providers
inoribea Oct 11, 2025
fb2182d
feat: add comprehensive vision and messaging modules
inoribea Oct 11, 2025
3dace27
fix(vision): resolve build issues and integrate image generation
inoribea Oct 11, 2025
83f62a6
fix(vision): add vision provider support and fix type issues
inoribea Oct 11, 2025
d11590c
fix(hearing): restore green indicator for hearing module
inoribea Oct 11, 2025
e15f19a
feat(messaging): improve messaging module configuration and icon display
inoribea Oct 11, 2025
2a39daf
fix(stores): add missing airi-card module export
inoribea Oct 11, 2025
f6c3b96
fix(vision): resolve toString error by ensuring consistent return str…
inoribea Oct 11, 2025
f9cd7da
feat(ui): add speech, hearing, and image input toggle buttons
inoribea Oct 11, 2025
673b286
feat(ui): improve toggle buttons logic and permissions handling
inoribea Oct 11, 2025
11b5c4a
fix: resolve VAD auto-start and syntax errors
inoribea Oct 11, 2025
7819768
fix: add Factorio icon to gaming module display
inoribea Oct 11, 2025
853c84a
fix: resolve module icons and vision/speech provider display issues
inoribea Oct 12, 2025
1a9d905
fix: revert IconStatusItem changes and fix Messaging/Vision layout
inoribea Oct 12, 2025
27289d3
fix: revert vision store to use generateImage with providerOptions
inoribea Oct 12, 2025
fa39a37
fix: allow environment variables to override empty provider configura…
inoribea Oct 12, 2025
effda04
fix: use iconColor for colorful Minecraft and Factorio icons
inoribea Oct 12, 2025
9c2c12a
fix: properly display colorful icons without grayscale filter
inoribea Oct 12, 2025
35f6b05
fix: implement messaging module directly in page instead of component
inoribea Oct 12, 2025
de1fe28
fix: revert messaging page and use monochrome gaming icons
inoribea Oct 12, 2025
3bad8c0
fix: restore original Minecraft and Factorio icons using iconColor
inoribea Oct 12, 2025
7a0bc74
fix: properly compare nested objects in environment variable matching
inoribea Oct 12, 2025
471dbb4
fix: restore messaging module ui and speech env imports
inoribea Oct 12, 2025
1ae65ed
fix: restore messaging forms and env-driven defaults
inoribea Oct 12, 2025
e0ba938
fix: restore messaging forms and vision layout
inoribea Oct 12, 2025
a4d4e84
Merge upstream/main into main (prefer ours on conflicts)
inoribea Oct 28, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
119 changes: 119 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
# ============================================
# AIRI Stage Web - Environment Configuration
# ============================================
# This file contains all environment variables needed for deploying
# AIRI Stage Web on Vercel or running it locally.
# Copy this file to .env and fill in your actual values.

# ============================================
# Provider Health Checks
# ============================================
# Skip provider health checks to avoid CORS errors in serverless deployments.
# Recommended: true for browser/Vercel environments
VITE_SKIP_PROVIDER_HEALTH_CHECK=true
Comment on lines +8 to +13
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why?


# ============================================
# Default Providers (REQUIRED)
# ============================================
# These must match configured provider identifiers
DEFAULT_CHAT_PROVIDER=openai
DEFAULT_SPEECH_PROVIDER=openai-audio-speech
DEFAULT_TRANSCRIPTION_PROVIDER=openai-audio-transcription

# ============================================
# OpenAI Configuration
# ============================================
OPENAI_API_KEY=sk-...
OPENAI_BASE_URL=https://api.openai.com/v1/
OPENAI_MODEL=gpt-4o-mini

# ============================================
# OpenRouter Configuration
# ============================================
OPENROUTER_API_KEY=sk-or-...

# ============================================
# Anthropic Claude Configuration
# ============================================
ANTHROPIC_API_KEY=sk-ant-...

# ============================================
# Google Gemini Configuration
# ============================================
GOOGLE_GENERATIVE_AI_API_KEY=AIza...

# ============================================
# AIRI Backend WebSocket
# ============================================
# WebSocket endpoint for live configurator feature
# Point to your AIRI backend for remote module configuration
# Set VITE_DISABLE_WEBSOCKET=true to disable WebSocket in serverless deployments
VITE_AIRI_WS_URL=wss://airi.yourdomain.com/ws
VITE_DISABLE_WEBSOCKET=true

# ============================================
# Short-Term Memory Configuration (Vercel Serverless)
# ============================================
# Short-term memory stores conversation history via /api/memory/* serverless functions
# Supports Vercel KV (recommended) or Upstash Redis

# Option 1: Vercel KV (automatically provided when you create a KV database in Vercel Storage tab)
KV_URL=https://*.kv.vercel-storage.com
KV_REST_API_URL=https://*.kv.vercel-storage.com
KV_REST_API_TOKEN=AX****
KV_REST_API_READ_ONLY_TOKEN=AW****
Comment on lines +97 to +107
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we have some form of provider abstraction for integrating different providers later?


# Option 2: Upstash Redis (automatically provided when you create Upstash integration in Vercel)
UPSTASH_KV_REST_API_URL=https://us1-bold-foo.upstash.io
UPSTASH_KV_URL=https://us1-bold-foo.upstash.io
UPSTASH_KV_REST_API_TOKEN=AX****
UPSTASH_REDIS_URL=redis://default:****@us1-bold-foo.upstash.io:6379
Comment on lines +109 to +113
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This part can be seen as a better impl against https://github.com/moeru-ai/airi/pull/636/files#r2418559828


# Short-term memory settings
SHORT_TERM_MEMORY_PROVIDER=vercel-kv
MEMORY_NAMESPACE=memory
SHORT_TERM_MEMORY_MAX_MESSAGES=20
SHORT_TERM_MEMORY_TTL_SECONDS=1800

# ============================================
# Long-Term Memory Configuration (Optional)
# ============================================
# Long-term memory enables semantic search via vector databases
# Supports Postgres+pgvector or Qdrant
# Set to 'none' to disable long-term memory
LONG_TERM_MEMORY_PROVIDER=postgres-pgvector
MEMORY_LONG_TERM_PROVIDER=postgres-pgvector

# ============================================
# PostgreSQL + pgvector Configuration
# ============================================
# Required when LONG_TERM_MEMORY_PROVIDER=postgres-pgvector
# Vercel Postgres URL is automatically provided when you create a Postgres database in Vercel Storage tab
POSTGRES_URL=postgresql://user:pass@host/db
DATABASE_URL=postgresql://user:pass@host/db
MEMORY_TABLE_NAME=memory_embeddings

# ============================================
# Qdrant Configuration
# ============================================
# Required when LONG_TERM_MEMORY_PROVIDER=qdrant
QDRANT_URL=https://xyz.cloud.qdrant.io
QDRANT_API_KEY=your-api-key
QDRANT_COLLECTION_NAME=memory

# ============================================
# Embedding Provider Configuration (Required for Long-Term Memory)
# ============================================
# Provider: openai or cloudflare
EMBEDDING_PROVIDER=openai
EMBEDDING_MODEL=text-embedding-3-small
EMBEDDING_DIMENSIONS=1536

# OpenAI Embedding Configuration
OPENAI_API_KEY=sk-...
OPENAI_BASE_URL=https://api.openai.com/v1/

# Cloudflare Workers AI Configuration (alternative to OpenAI)
CLOUDFLARE_ACCOUNT_ID=1234567890abcdef
CLOUDFLARE_API_TOKEN=your-cf-token
CLOUDFLARE_EMBEDDING_MODEL=@cf/baai/bge-base-en-v1.5
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,7 @@ twitter-session.json
result*



# Coding helpers
AGENTS.md
CLAUDE.md
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,10 @@ Please update the version in `Cargo.toml` after running `bumpp`:
npx bumpp --no-commit --no-tag
```

## Deployment to Vercel

See [docs/content/en/docs/guides/deploy/vercel.md](docs/content/en/docs/guides/deploy/vercel.md) for the up-to-date deployment guide.

## Support of LLM API Providers (powered by [xsai](https://github.com/moeru-ai/xsai))

- [x] [302.AI (sponsored)](https://share.302.ai/514k2v)
Expand Down
Loading