dark
0e3173189f
feat: add AI billing module (quota + usage)
- QuotaService: CheckAndFreeze, Settle, Unfreeze
- UsageService: Record, UpdateConversationStats
- Skip billing for user-provided API keys
1 month ago
dark
9f7466064c
feat: seed AI providers, models, Casbin policies, menu
- 5 providers: OpenAI, Claude, Qwen, Zhipu, DeepSeek
- 9 models with pricing and capabilities
- Casbin policies for AI routes (user role)
- AI 对话 menu item
1 month ago
dark
3937c72d14
feat: add AI provider abstraction layer
- AIProvider interface (Chat + ChatStream)
- OpenAI-compatible adapter (covers OpenAI, Qwen, Zhipu, DeepSeek)
- Anthropic adapter (Claude models)
- Factory pattern for provider creation
- Unified types (ChatRequest, ChatResponse, StreamChunk)
1 month ago
dark
332f2cf59b
feat: add 7 AI entity models + AutoMigrate
- AIProvider, AIModel, AIApiKey (platform config)
- AIConversation, AIChatMessage (chat data)
- AIUsageRecord, AIUserQuota (billing data)
- AutoMigrate updated in servicecontext.go
1 month ago
dark
38f4e740fa
feat: implement all backend logic for menu, role, org management
1 month ago
dark
6df3f8795f
feat: API definitions and goctl generated code for menu/role/org
1 month ago
dark
41b1e091ce
feat: add currentOrgId to User entity, JWT Claims, and auth middleware
1 month ago
dark
d2cb7fa8c8
feat: login by phone/username, register requires phone, seed uses username
1 month ago
dark
f7ab873ca7
refactor: remove email from JWT Claims and auth context
1 month ago
dark
d92aba8294
feat: 仪表盘对接后端 API,添加仪表盘 E2E 测试
1 month ago
dark
40e5ccfb70
user
1 month ago
dark
8a12ad04db
Initial commit: Add project structure and .gitignore
2 months ago