(name string)
| 560 | } |
| 561 | |
| 562 | func GetAudioRatio(name string) float64 { |
| 563 | if strings.Contains(name, "-realtime") { |
| 564 | if strings.HasSuffix(name, "gpt-4o-realtime-preview") { |
| 565 | return 8 |
| 566 | } else if strings.Contains(name, "gpt-4o-mini-realtime-preview") { |
| 567 | return 10 / 0.6 |
| 568 | } else { |
| 569 | return 20 |
| 570 | } |
| 571 | } |
| 572 | if strings.Contains(name, "-audio") { |
| 573 | if strings.HasPrefix(name, "gpt-4o-audio-preview") { |
| 574 | return 40 / 2.5 |
| 575 | } else if strings.HasPrefix(name, "gpt-4o-mini-audio-preview") { |
| 576 | return 10 / 0.15 |
| 577 | } else { |
| 578 | return 40 |
| 579 | } |
| 580 | } |
| 581 | return 20 |
| 582 | } |
| 583 | |
| 584 | func GetAudioCompletionRatio(name string) float64 { |
| 585 | if strings.HasPrefix(name, "gpt-4o-realtime") { |
no test coverage detected