Commit Graph

5480 Commits

Author SHA1 Message Date
刘泓宾 53aeee4ff7 Comment out price data adjustment logic
Comment out code that modifies price data based on image count.
测试发现,如果是接入阿里百炼平台的qwen-image-2.0系列模型,这边计费的时候会出现 0.2*n*倍率*n的情况,最前面的0.2*n会直接显示为模型价格。
例如:
日志详情	模型价格 $0.600000,专属倍率 0.3
其他详情	大小 1080*1920, 品质 standard, 生成数量 3, 其他倍率 n: 3.000000
计费过程	模型价格:$0.600000 * 专属倍率:0.3 = $0.180000
2026-03-31 17:12:06 +08:00
CaIon 5238f279db feat: record stream interruption reasons via StreamStatus
- Add StreamStatus type (relay/common) to track stream end reason
  (done/timeout/client_gone/scanner_error/eof/panic/ping_fail) and
  accumulate soft errors during streaming via sync.Once + sync.Mutex.
- Add StreamResult (relay/helper) as the callback interface: adapters
  call sr.Error() for soft errors, sr.Stop() for fatal, sr.Done() for
  normal completion. No early-return problem — multiple errors per chunk
  are naturally supported.
- Refactor StreamScannerHandler callback from func(string) bool to
  func(string, *StreamResult). All 9 channel adapters updated.
- Write stream_status into log other JSON field (admin-only) with
  status ok/error, end_reason, error_count, and error messages.
- Frontend: display stream status in log detail expansion for admins.
2026-03-31 16:54:39 +08:00
CaIon 5402bf417d feat: expose i18n instance to the global window object for easier access 2026-03-31 16:54:39 +08:00
Seefs c766913baf Merge pull request #3507 from QuantumNous/dependabot/go_modules/golang.org/x/image-0.38.0
chore(deps): bump golang.org/x/image from 0.23.0 to 0.38.0
2026-03-31 16:52:35 +08:00
dependabot[bot] 40dc43f44e chore(deps): bump golang.org/x/image from 0.23.0 to 0.38.0
Bumps [golang.org/x/image](https://github.com/golang/image) from 0.23.0 to 0.38.0.
- [Commits](https://github.com/golang/image/compare/v0.23.0...v0.38.0)

---
updated-dependencies:
- dependency-name: golang.org/x/image
  dependency-version: 0.38.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-03-30 16:24:46 +00:00
Seefs fbf235d222 Merge pull request #3461 from feitianbubu/pr/0ec3d7a1b2cc1375b5c7fe041ae94d714eb03a69
feat: prevent metadata from overriding model fields
2026-03-27 15:36:01 +08:00
feitianbubu 62b9aaa520 feat: prevent metadata from overriding model fields 2026-03-27 15:31:41 +08:00
Calcium-Ion 22b6b16702 Merge pull request #3440 from seefs001/refactor/expose-skip-retry-option
refactor: expose skip-retry option and show it in rules list
2026-03-25 14:11:37 +08:00
Seefs 6154b8e3cd refactor: expose skip-retry option and show it in rules list 2026-03-25 14:06:35 +08:00
Calcium-Ion ff66288e3a Merge pull request #3438 from seefs001/fix/openrouter-usage
fix: restore pre-3400 OpenRouter billing semantics
2026-03-25 14:02:08 +08:00
Seefs 926e1781dd fix: preserve cache usage in openai-to-claude response conversion 2026-03-25 13:49:21 +08:00
Seefs d4a470a638 fix: restore pre-3400 OpenRouter billing semantics 2026-03-25 13:24:52 +08:00
Seefs 9f61407bf0 fix: restore pre-3400 OpenRouter billing semantics 2026-03-25 13:11:51 +08:00
CaIon dbf900a531 fix: restore doubao coding plan deprecation and regex ignored models lost during conflict resolution 2026-03-25 00:04:01 +08:00
CaIon 7399e4721b feat: add slide-in animations and update translations for new UI elements
# Conflicts:
#	web/src/components/table/channels/modals/EditChannelModal.jsx
2026-03-24 23:57:58 +08:00
CaIon a5e20269dd security: harden Docker and release CI workflows
- Pin all GitHub Actions to commit SHA to prevent supply chain attacks
- Enable SLSA provenance attestation (mode=max) and SBOM generation
- Add cosign keyless signing for Docker images via GitHub OIDC
- Capture and output image digests to GitHub Job Summary
- Pin Dockerfile base images to digest (bun:1, golang:1.26.1-alpine, debian:bookworm-slim)
- Add SHA256 checksum generation for binary releases (Linux/macOS/Windows)
- Update actions/checkout v3->v4, actions/setup-go v3->v5 in release.yml
2026-03-24 23:56:15 +08:00
Calcium-Ion 9ae9040b3c Merge pull request #3401 from seefs001/fix/convert-openai-detail-field
fix: the "detail" field is empty, an empty field was sent to upstream
2026-03-23 15:04:06 +08:00
Calcium-Ion 0191a68d4e Merge pull request #3400 from seefs001/fix/openai-usage
refactor: optimize billing flow for OpenAI-to-Anthropic convert
2026-03-23 15:03:57 +08:00
Calcium-Ion 16221f8279 Merge pull request #3399 from seefs001/refactor/codex-usage
Refactor/codex usage
2026-03-23 15:03:47 +08:00
Calcium-Ion 763c3ff709 Merge pull request #3331 from seefs001/fix/claude-beta-query
fix: apply forced beta query at final upstream URL stage
2026-03-23 15:03:36 +08:00
Calcium-Ion c667e4706a Merge pull request #3333 from seefs001/fix/channel-affinity-disable
fix: honor channel affinity skip-retry when channel is disabled
2026-03-23 15:03:23 +08:00
Calcium-Ion 216b94dac0 Merge pull request #3335 from seefs001/chore/adjuct-default-settings
adjuct default settings
2026-03-23 15:03:01 +08:00
Calcium-Ion 49eb533aaf Merge pull request #3381 from seefs001/feature/regex-ignored-upstream-models
feat: support regex-prefixed ignored upstream models
2026-03-23 15:02:44 +08:00
Calcium-Ion 7693edae53 Merge pull request #3393 from seefs001/fix/oauth-bind
fix: oauth bind callback handling
2026-03-23 15:02:34 +08:00
Seefs ded4a124e2 fix: the "detail" field is empty, an empty field was sent to the upstream system. 2026-03-23 15:00:20 +08:00
Calcium-Ion d6982c8182 Merge pull request #3379 from seefs001/refactor/rm-coding-plan
fix: disable doubao coding plan selection
2026-03-23 14:53:13 +08:00
Seefs 9ecad90652 refactor: optimize billing flow for OpenAI-to-Anthropic convert 2026-03-23 14:22:12 +08:00
Seefs 929b5060ea refactor: simplify codex account modal and collapse raw json by default 2026-03-23 13:54:54 +08:00
Seefs 755ece2f01 refactor: simplify codex account modal and collapse raw json by default 2026-03-23 00:58:59 +08:00
Seefs f40eb4e5d2 fix: oauth bind callback handling 2026-03-23 00:48:55 +08:00
Seefs 45f65c297b feat: support regex-prefixed ignored upstream models 2026-03-22 15:43:03 +08:00
Seefs 6c074ef897 fix: disable doubao coding plan selection 2026-03-22 15:01:09 +08:00
CaIon deff59a5be fix: increase StreamScannerMaxBufferMB limit and add handling for gpt-5.4-nano prefix 2026-03-22 13:55:10 +08:00
Seefs 3c516084f8 Merge pull request #3360 from lcq225/docs/improve-bt-installation-guide
docs: 完善宝塔面板部署教程并修复链接错误
2026-03-22 00:43:13 +08:00
Seefs 4d675b4d1f Merge pull request #3357 from wenyifancc/cache_llama_cpp
feat: Add support for counting cache-hit tokens in llama.cpp
2026-03-22 00:39:49 +08:00
Seefs 87b426f306 Merge pull request #3369 from RedwindA/feat/logsManagement
feat: add server log file management to performance settings
2026-03-22 00:32:01 +08:00
RedwindA 49db5147c3 fix: align log cleanup button with other controls in the row 2026-03-21 21:48:31 +08:00
RedwindA 13122aa0fa fix: refresh log info on partial delete failure 2026-03-21 21:11:52 +08:00
RedwindA dcd0911612 fix: log management race condition, partial delete reporting, and UX issues
- Fix data race on gin.DefaultWriter during log rotation by adding LogWriterMu
- Report partial failure when some log files fail to delete instead of always returning success
- Fix misleading "logging disabled" banner shown before API responds
- Fix en.json translation for numeric validation message
2026-03-21 20:40:39 +08:00
RedwindA e904579a5b feat: add server log file management to performance settings
Add API endpoints (GET/DELETE /api/performance/logs) to list and clean up
server log files by count or by age. Track the active log file path in
the logger to prevent deleting the currently open log. Add a management
UI section in the performance settings page with log directory info,
file statistics, and cleanup controls. Includes i18n translations for
all supported languages (en, fr, ja, ru, vi, zh-CN, zh-TW).
2026-03-21 20:06:49 +08:00
mm413 e80d867f38 Update docs/installation/BT.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2026-03-20 20:13:30 +08:00
lcq225 cf86fe5fea docs: 完善宝塔面板部署教程并修复链接错误
- 完善 docs/installation/BT.md,从 2 行扩展为完整教程
- 包含前置要求、安装步骤、配置说明、常见问题
- 修复 README.zh_CN.md 中的链接错误
- 所有内容基于官方文档 https://docs.newapi.pro 编写
2026-03-20 20:06:09 +08:00
Calcium-Ion 42846c692e Merge pull request #3359 from seefs001/feature/normalize-bearer-type
fix: normalize generic oauth bearer token type
2026-03-20 17:08:46 +08:00
Seefs 1911520eba fix: normalize generic oauth bearer token type 2026-03-20 17:07:03 +08:00
wenyifan 2c3ae32c8e fix map 2026-03-20 16:48:04 +08:00
CaIon 64f41efc47 chore: remove FUNDING.yml file as it is no longer needed 2026-03-20 16:44:30 +08:00
wenyifan 498199b37d fix code quality 2026-03-20 16:38:48 +08:00
wenyifan ff29900f30 feat: Add support for counting cache-hit tokens in llama.cpp OpenAI-Compatible API 2026-03-20 16:10:18 +08:00
Seefs eff51857d0 refactor: show codex account info tag and highlight plan type in usage modal 2026-03-20 16:00:36 +08:00
Seefs e9f8f62796 fix: raise default overload disk threshold to 95% 2026-03-19 16:58:13 +08:00