constants.go 667 B

12345678910111213141516171819202122232425
  1. package codex
  2. import (
  3. "github.com/QuantumNous/new-api/setting/ratio_setting"
  4. "github.com/samber/lo"
  5. )
  6. var baseModelList = []string{
  7. "gpt-5", "gpt-5-codex", "gpt-5-codex-mini",
  8. "gpt-5.1", "gpt-5.1-codex", "gpt-5.1-codex-max", "gpt-5.1-codex-mini",
  9. "gpt-5.2", "gpt-5.2-codex", "gpt-5.3-codex",
  10. }
  11. var ModelList = withCompactModelSuffix(baseModelList)
  12. const ChannelName = "codex"
  13. func withCompactModelSuffix(models []string) []string {
  14. out := make([]string, 0, len(models)*2)
  15. out = append(out, models...)
  16. out = append(out, lo.Map(models, func(model string, _ int) string {
  17. return ratio_setting.WithCompactModelSuffix(model)
  18. })...)
  19. return lo.Uniq(out)
  20. }