- 07 Feb, 2026 10 commits
-
-
fix: add paragraph breaks between reasoning summary chunks
Calcium-Ion committed -
fix: Claude stream block index/type transitions
Calcium-Ion committed -
feat(oauth): implement custom OAuth provider
Calcium-Ion committed -
feat: Force beta=true parameter for Anthropic channel
Seefs committed -
feat: add Codex channel disclaimer (i18n, OpenAI terms)
Calcium-Ion committed -
Seefs committed
-
🔧 CaIon committed -
🔧 Modified the formatUserLogs function to include a startIdx parameter, allowing for more flexible log ID assignment. Updated calls to this function in GetLogByTokenId and GetUserLogs to pass the appropriate starting index.
CaIon committed -
✨ chore: Improve subscription billing fallback and UI statesCalcium-Ion committed -
🔔 feat: Add subscription-aware quota notifications and update UI copyCalcium-Ion committed
-
- 06 Feb, 2026 27 commits
-
-
🔔 Routes quota alerts through a subscription-specific check when billing from subscriptions, preventing wallet-based thresholds from triggering false warnings. Updates the notification settings description and localization keys to clarify that both wallet and subscription balances are monitored.
t0ng7u committed -
🛠 Aligns the error variable types in the subscription-first path so that quota fallback checks use the correct NewAPIError. This prevents build failures and preserves the intended wallet fallback when subscription pre-consume returns an insufficient quota error.
t0ng7u committed -
✨ Add a lightweight active-subscription check to skip subscription pre-consume when none exist, reducing unnecessary transactions and locks. In the subscription UI, disable subscription-first options when no active plan is available, show the effective fallback to wallet with a clear notice, and distinguish “invalidated” from “expired” states. Update i18n strings across supported locales to reflect the new messages and status labels.
t0ng7u committed -
refactor: 抽象统一计费会话 BillingSession
Calcium-Ion committed -
✨ refactor(wallet): Top-up layout to embed subscription plans into the recharge card tabsCalcium-Ion committed -
✨ - Defaulting to subscriptions when available and avoiding initial flash when no plans exist. - Adjust the wide-screen layout to place wallet and invite sections side by side, simplify the subscription header and controls, and add padding to prevent card borders from clipping. - Update related i18n strings by adding the new tab label and removing the obsolete subscription blurb.
t0ng7u committed -
- Settle 部分失败保护:新增 fundingSettled 标记,资金来源提交后 令牌调整失败不再导致 Refund 误退已结算的资金 - 订阅多扣费修复:trySubscription 传 subConsume 而非 preConsumedQuota 给 preConsume,保证三者(amount/preConsume/FinalPreConsumedQuota)一致 - 令牌回滚错误记录:preConsume 中 funding 失败时令牌回滚错误不再丢弃 - 移除钱包路径死代码:用户额度不足的 strings.Contains 匹配不可能命中 - WalletFunding.Refund 不重试:IncreaseUserQuota 非幂等,重试会多退
CaIon committed -
将散落在多个文件中的预扣费/结算/退款逻辑抽象为统一的 BillingSession 生命周期管理: - 新增 BillingSettler 接口 (relay/common/billing.go) 避免循环引用 - 新增 FundingSource 接口 + WalletFunding / SubscriptionFunding 实现 (service/funding_source.go) - 新增 BillingSession 封装预扣/结算/退款原子操作 (service/billing_session.go) - 新增 SettleBilling 统一结算辅助函数,替换各 handler 中的 quotaDelta 模式 - 重写 PreConsumeBilling 为 BillingSession 工厂入口 - controller/relay.go 退款守卫改用 BillingSession.Refund() 修复的 Bug: - 令牌额度泄漏:PreConsumeTokenQuota 成功但 DecreaseUserQuota 失败时未回滚 - 订阅退款遗漏:FinalPreConsumedQuota=0 但 SubscriptionPreConsumed>0 时跳过退款 - 订阅多扣费:subConsume 强制为 1 但 FinalPreConsumedQuota 不同步 - 退款路径不统一:钱包/订阅退款逻辑现统一由 FundingSource.Refund 分派
CaIon committed -
fix: /v1/chat/completions -> /v1/responses json_schema
Calcium-Ion committed -
Seefs committed
-
CaIon committed
-
MUTED64 committed
-
QuentinHsu committed
-
- Change ESCAPE character from '\' to '!' for compatibility with MySQL/PostgreSQL/SQLite - Adjust sanitization logic to escape '!' and '_' correctly, improving input validation for search queries
CaIon committed -
CaIon committed
-
fix: harden token search with pagination, rate limiting and input validation
Calcium-Ion committed -
- Add configurable per-user token creation limit (max_user_tokens) - Sanitize search input patterns to prevent expensive queries - Add per-user search rate limiting (by user ID) - Add pagination to search endpoint with strict page size cap - Skip empty search fields instead of matching nothing - Hide internal errors from API responses - Fix Interface2String float64 formatting causing config parse failures - Add float-string fallback in config system for int/uint fields
CaIon committed -
feat: add claude-opus-4-6
Calcium-Ion committed -
🔒 fix(security): sanitize AI-generated HTML to prevent XSS in playgroundCalcium-Ion committed -
🔒 Mitigate XSS vulnerabilities in the playground where AI-generated content is rendered without sanitization, allowing potential script injection via prompt injection attacks. MarkdownRenderer.jsx: - Replace dangerouslySetInnerHTML with a sandboxed iframe for HTML preview - Use sandbox="allow-same-origin" to block script execution while allowing CSS rendering and iframe height auto-sizing - Add SandboxedHtmlPreview component with automatic height adjustment CodeViewer.jsx: - Add escapeHtml() utility to encode HTML entities before rendering - Rewrite highlightJson() to process tokens iteratively, escaping each token and structural text before wrapping in syntax highlighting spans - Escape non-JSON and very-large content paths that previously bypassed sanitization - Update linkRegex to correctly match URLs containing & entities These changes only affect the playground (AI output rendering). Admin- configured content (home page, about page, footer, notices) remains unaffected as they use separate code paths and are within the trusted admin boundary.
t0ng7u committed -
Seefs committed
-
Seefs committed
-
https://github.com/prnake/new-apiPapersnake committed
-
Papersnake committed
-
Papersnake committed
-
Papersnake committed
-
Papersnake committed
-
- 05 Feb, 2026 3 commits