Skip to content

fix: remove Minimax from FETCHABLE channels - #2619

Merged
seefs001 merged 2 commits into
QuantumNous:mainfrom
RedwindA:fix/disableMinimaxFetchModels
Jan 9, 2026
Merged

seefs001 merged 2 commits into
QuantumNous:mainfrom
RedwindA:fix/disableMinimaxFetchModels

Conversation

@RedwindA

@RedwindA RedwindA commented Jan 9, 2026 •

Copy link
Copy Markdown
Contributor

PR 类型

  • Bug 修复
  • 新功能
  • 文档更新
  • 其他

PR 是否包含破坏性更新?

  • 是
  • 否

PR 描述

close #2614 since minimax doesn't provide model list api

Summary by CodeRabbit

  • Bug Fixes

    • Disabled automatic model list retrieval for one channel variant; the “fetch models” action will no longer appear for that variant.
  • New Features

    • Added three additional MiniMax models to the available model list, making them selectable where model choices are presented.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai

coderabbitai Bot commented Jan 9, 2026 •

Copy link
Copy Markdown
Contributor

Walkthrough

Removed numeric entry 35 from MODEL_FETCHABLE_TYPES in the EditChannelModal component and added three MiniMax models to the Minimax ModelList in relay/channel/minimax/constants.go, changing which channel types can fetch models and expanding available minimax models.

Changes

Cohort / File(s) Summary
Channel Configuration — Model Fetching
web/src/components/table/channels/modals/EditChannelModal.jsx
Removed 35 from MODEL_FETCHABLE_TYPES, disabling the "获取模型列表" action for channel type 35.
Minimax Model Registry
relay/channel/minimax/constants.go
Added three models to ModelList: "MiniMax-M2.1", "MiniMax-M2.1-lightning", "MiniMax-M2" ( +3 entries).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • seefs001

Poem

🐰 I hopped through code at break of dawn,
Removed a number, then added three on,
Type thirty-five lost the fetchable key,
MiniMax grew — hops of glee! 🥕✨

🚥 Pre-merge checks | ✅ 2 | ❌ 3
❌ Failed checks (3 warnings)
Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR addresses issue #2614 by removing Minimax from FETCHABLE channels, but contradicts this by adding three Minimax models to the ModelList. Either remove the Minimax models from ModelList to fully resolve the issue, or clarify the intent of adding these models given Minimax lacks model list API support.
Out of Scope Changes check ⚠️ Warning The addition of three Minimax models to ModelList appears unrelated to the stated objective of removing Minimax from FETCHABLE channels. Remove the Minimax model additions from relay/channel/minimax/constants.go or justify their necessity in relation to issue #2614.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'fix: remove Minimax from FETCHABLE channels' accurately describes the main change in EditChannelModal.jsx.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

📜 Recent review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b51d1e2 and c975b4c.

📒 Files selected for processing (1)
  • relay/channel/minimax/constants.go
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: AAEE86
Repo: QuantumNous/new-api PR: 1658
File: web/src/components/table/channels/modals/EditChannelModal.jsx:555-569
Timestamp: 2025-08-27T02:15:25.448Z
Learning: In EditChannelModal.jsx, the applyModelMapping function transforms the models list by replacing original model names (mapping values) with display names (mapping keys). The database stores this transformed list containing mapped keys. On channel load, data.models contains these mapped display names, making the initialization filter if (data.models.includes(key)) correct.
Learnt from: AAEE86
Repo: QuantumNous/new-api PR: 1658
File: web/src/components/table/channels/modals/EditChannelModal.jsx:555-569
Timestamp: 2025-08-27T02:15:25.448Z
Learning: In EditChannelModal.jsx, the database stores mapped keys (display names) in the models field after applying model mapping transformations. When loading a channel, data.models contains the mapped keys, not the original model names. The filtering logic if (data.models.includes(key)) in the initialization is correct.
🔇 Additional comments (2)
relay/channel/minimax/constants.go (2)

17-19: Good addition - addresses issue #2614.

Adding these three models directly to the hardcoded ModelList is the correct approach since Minimax doesn't provide a model list API. This resolves the issue where these models (shown on Minimax's site) were not appearing in the project's model list.


17-19: Model names verified as official per Minimax documentation.

The new models ("MiniMax-M2.1", "MiniMax-M2.1-lightning", "MiniMax-M2") match the official identifiers from Minimax's API documentation. While they use PascalCase unlike the existing lowercase models in the list, this casing is required by Minimax's official naming convention for the M2 series and cannot be changed. The addition correctly addresses issue #2614.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@seefs001
seefs001 merged commit e1d43a8 into QuantumNous:main Jan 9, 2026
ennnnny pushed a commit to ennnnny/new-api that referenced this pull request Mar 17, 2026
…etchModels

fix: remove Minimax from FETCHABLE channels
@coderabbitai coderabbitai Bot mentioned this pull request Jun 2, 2026
8 of 11 tasks
salem-2007 added a commit to salem-2007/new-api that referenced this pull request Sep 10, 2026
…etchModels

fix: remove Minimax from FETCHABLE channels
junjundesk pushed a commit to junjundesk/new-api that referenced this pull request Oct 3, 2026
…etchModels

fix: remove Minimax from FETCHABLE channels
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MiniMax渠道配置有问题

2 participants