1. 07 Feb, 2026 7 commits
  2. 06 Feb, 2026 10 commits
  3. 05 Feb, 2026 15 commits
    • yangjianbo's avatar
      feat: vesion -> 0.1.70 · a113dd4d
      yangjianbo authored
      a113dd4d
    • yangjianbo's avatar
      build(工具链): 升级 Go 到 1.25.7 · 98f79315
      yangjianbo authored
      98f79315
    • yangjianbo's avatar
      a38bd413
    • yangjianbo's avatar
      9e1535e2
    • iBenzene's avatar
      037a4099
    • shaw's avatar
      fix: 修复管理页面活跃会话数始终显示为0的问题 · ae1934f7
      shaw authored
      问题原因:Redis Pipeline 执行 Lua 脚本时出现 NOSCRIPT 错误,
      因为 redis.NewScript 使用 EVALSHA 执行脚本,当 Redis 重启或
      脚本未被缓存时,Pipeline 模式无法自动回退到 EVAL。
      
      解决方案:在 NewSessionLimitCache 初始化时预加载所有 Lua 脚本
      到 Redis,确保后续 Pipeline 执行时脚本已被缓存。
      ae1934f7
    • shaw's avatar
      feat: 新增全局错误透传规则功能 · 39e05a2d
      shaw authored
      支持管理员配置上游错误如何返回给客户端:
      - 新增 ErrorPassthroughRule 数据模型和 Ent Schema
      - 实现规则的 CRUD API(/admin/error-passthrough-rules)
      - 支持按错误码、关键词匹配,支持 any/all 匹配模式
      - 支持按平台过滤(anthropic/openai/gemini/antigravity)
      - 支持透传或自定义响应状态码和错误消息
      - 实现两级缓存(Redis + 本地内存)和多实例同步
      - 集成到 gateway_handler 的错误处理流程
      - 新增前端管理界面组件
      - 新增单元测试覆盖核心匹配逻辑
      
      优化:
      - 移除 refreshLocalCache 中的冗余排序(数据库已排序)
      - 后端 Validate() 增加匹配条件非空校验
      39e05a2d
    • ianshaw's avatar
      7b46bbb6
    • ianshaw's avatar
      feat(gemini): 增强 API 授权错误处理,自动提取并显示激活 URL · d2527e36
      ianshaw authored
      当 Gemini for Google Cloud API 未启用时(SERVICE_DISABLED 错误),
      系统现在会:
      - 自动检测 403 PERMISSION_DENIED 错误
      - 从错误响应中提取 API 激活 URL
      - 向用户显示清晰的错误消息和可点击的激活链接
      - 提供操作指引(启用后等待几分钟)
      
      新增文件:
      - internal/pkg/googleapi/error.go: Google API 错误解析器
      - internal/pkg/googleapi/error_test.go: 完整的测试覆盖
      - GEMINI_API_ERROR_HANDLING.md: 实现文档
      
      修改文件:
      - internal/repository/geminicli_codeassist_client.go:
        在 LoadCodeAssist 和 OnboardUser 中增强错误处理
      
      这大大改善了用户体验,用户不再需要手动从错误日志中查找激活 URL。
      d2527e36
    • shaw's avatar
      feat: 支持用户专属分组倍率配置 · 2b192f7d
      shaw authored
      2b192f7d
    • IanShaw027's avatar
      fix(gemini): 修复已注册用户 OAuth 授权时错误调用 onboardUser 的问题 · 979114db
      IanShaw027 authored
      问题:Google One Ultra 等已注册用户在 OAuth 授权时,如果 LoadCodeAssist
      返回了 currentTier/paidTier 但没有返回 cloudaicompanionProject,之前的
      逻辑会继续调用 onboardUser,导致 INVALID_ARGUMENT 错误。
      
      修复:对齐 Gemini CLI 的处理逻辑:
      - 当检测到用户已注册(有 currentTier/paidTier)时,不再调用 onboardUser
      - 先尝试从 Cloud Resource Manager 获取可用项目
      - 如果仍无法获取,返回友好的错误提示,引导用户手动填写 Project ID
      
      这个修复解决了 Google One 订阅用户无法正常授权的问题。
      979114db
    • Lemon's avatar
      39a0359d
    • shaw's avatar
      feat(auth): 实现 Refresh Token 机制 · 49a3c437
      shaw authored
      - 新增 Access Token + Refresh Token 双令牌认证
      - 支持 Token 自动刷新和轮转
      - 添加登出和撤销所有会话接口
      - 前端实现无感刷新和主动刷新定时器
      49a3c437
    • JIA-ss's avatar
      feat(gateway): filter /v1/usage stats by API Key instead of UserID · fa3ea5ee
      JIA-ss authored
      
      
      Previously the /v1/usage endpoint aggregated usage stats (today/total
      tokens, cost, RPM/TPM) across all API Keys belonging to the user.
      This made it impossible to distinguish usage from different API Keys
      (e.g. balance vs subscription keys).
      
      Now the usage stats are filtered by the current request's API Key ID,
      so each key only sees its own usage data. The balance/remaining fields
      are unaffected and still reflect the user-level wallet balance.
      
      Changes:
      - Add GetAPIKeyDashboardStats to repository interface and implementation
      - Add getPerformanceStatsByAPIKey helper (also fixes TPM to include
        cache_creation_tokens and cache_read_tokens)
      - Add GetAPIKeyDashboardStats to UsageService
      - Update Usage handler to call GetAPIKeyDashboardStats(apiKey.ID)
      Co-Authored-By: default avatarClaude Opus 4.5 <noreply@anthropic.com>
      fa3ea5ee
    • shaw's avatar
      fix(gateway): 修复工具名转换破坏 Anthropic 特殊工具的问题 · 05af95da
      shaw authored
      未知工具名不再进行 PascalCase/snake_case 转换,保持原样透传。
      修复 text_editor_20250728 等 Anthropic 特殊工具被错误转换的问题。
      05af95da
  4. 04 Feb, 2026 4 commits
  5. 03 Feb, 2026 4 commits
    • shaw's avatar
      chore: fix gofmt formatting · df1c2383
      shaw authored
      df1c2383
    • liuxiongfeng's avatar
      fix(gemini): 导出 DummyThoughtSignature 常量并修复跨账号签名验证 · 6baf8108
      liuxiongfeng authored
      - 将 dummyThoughtSignature 改为导出的 DummyThoughtSignature 常量,供跨包使用
      - 修改 gemini_native_signature_cleaner.go 将删除签名改为替换为 dummy 签名
        这样可以跳过 Gemini 3 的签名验证,解决粘性会话切换账号时的验证失败问题
      - 更新相关测试文件
      
      Fixes: 粘性会话切换账号时 thoughtSignature 验证失败导致 400 错误
      6baf8108
    • liuxiongfeng's avatar
      fix(openai): 统一 OAuth instructions 处理逻辑,修复 Codex CLI 400 错误 · 9a48b2e9
      liuxiongfeng authored
      - 修改 applyCodexOAuthTransform 函数签名,增加 isCodexCLI 参数
      - 移除 && !isCodexCLI 条件,对所有 OAuth 请求统一处理
      - 新增 applyInstructions/applyCodexCLIInstructions/applyOpenCodeInstructions 辅助函数
      - 新增 isInstructionsEmpty 函数检查 instructions 字段是否为空
      - 添加 Codex CLI 和非 Codex CLI 场景的测试用例
      
      逻辑说明:
      - Codex CLI + 有 instructions: 保持不变
      - Codex CLI + 无 instructions: 补充 opencode 指令
      - 非 Codex CLI: 使用 opencode 指令覆盖
      9a48b2e9
    • bayma888's avatar
      fix(lint): format gateway_service.go with gofmt · 3fed478e
      bayma888 authored
      3fed478e