Skip to content

Commit 06d5f83

Browse files
committed
feat: MVP-2 Alpha - Tauri desktop, auth, AI gateway, sync engine and server infrastructure
Client: - Add Tauri desktop app integration (src-tauri config, icons, main.rs) - Add authentication system (Supabase client, login/register pages, AuthContext) - Add AI plugin system (plugin loader, remote/local fallback, useAI hook) - Add sync engine (SyncEngine, OfflineQueue, NetworkManager, SyncContext) - Add storage layer abstraction (interfaces, factory pattern, writeWithLog) - Add PWA install prompt, network status hook, mode manager - Add HTTP API client and utility modules (platform, uuid) - Refactor feynman, flashcards, notes, pomodoro, sm2, storage modules Server: - Add AI gateway service (Python/FastAPI: chains, providers, routers, middleware) - Add sync service (Go: handlers, middleware, protobuf definitions) - Add Docker infrastructure (docker-compose, Dockerfiles) - Add shared protobuf definitions (ai_service, sync_service, common) Docs: - Update architecture design, tech selection ADR, sync strategy docs Config: - Add .env.example template, update .gitignore, vite and tsconfig
1 parent 2cee1b6 commit 06d5f83

165 files changed

Lines changed: 34125 additions & 3038 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.env.example‎

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# ===========================================
2+
# 课伴 (KeBan) MVP-2 Alpha 环境变量模板
3+
# ===========================================
4+
# 复制此文件为 .env 并填入实际值
5+
6+
# --- 前端 (client/) ---
7+
8+
# Supabase 认证(在 https://supabase.com 创建项目后获取)
9+
VITE_SUPABASE_URL=https://your-project-id.supabase.co
10+
VITE_SUPABASE_ANON_KEY=your-anon-key
11+
12+
# 后端服务地址
13+
VITE_API_BASE_URL=http://localhost:8080
14+
VITE_AI_GATEWAY_URL=http://localhost:8000
15+
VITE_API_HEALTH_URL=/api/health
16+
VITE_SYNC_SERVER_URL=http://localhost:8080
17+
18+
# --- 后端 (server/) ---
19+
20+
# AI 模型 API Key(在对应平台注册获取)
21+
# 通义千问:https://dashscope.aliyun.com
22+
QWEN_API_KEY=sk-your-qwen-api-key
23+
24+
# DeepSeek:https://platform.deepseek.com
25+
DEEPSEEK_API_KEY=sk-your-deepseek-key
26+
27+
# 智谱 GLM(可选,作为备选模型):https://open.bigmodel.cn
28+
GLM_API_KEY=
29+
30+
# 数据库(Docker Compose 默认值,本地开发无需修改)
31+
DATABASE_URL=postgresql://keban:keban_dev@localhost:5432/keban
32+
REDIS_URL=redis://localhost:6379
33+
34+
# JWT 安全密钥(生产环境必须修改为随机字符串)
35+
JWT_SECRET=change-this-to-a-random-string-in-production
36+
37+
# 服务端口
38+
SYNC_SERVICE_PORT=8080
39+
AI_GATEWAY_PORT=8000

‎.gitignore‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,19 @@ dist/
99
build/
1010
*.exe
1111
*.wasm
12+
*.pdb
13+
*.dll
14+
client/src-tauri/target/
1215

1316
# IDE
1417
.vscode/
1518
.idea/
1619
*.swp
1720
*.swo
21+
.qoder/
22+
23+
# Git worktree
24+
vPpiCi/
1825

1926
# OS
2027
.DS_Store

‎client/app-icon.png‎

3.83 KB
Loading

0 commit comments

Comments
 (0)