ai-gateway/common
ckt1031 1d15157f7d
feat: keep sync with dall-e updates (#679)
* Updated ImageRequest struct and OpenAIModels,
added new Dall-E models and size ratios

* Fixed suspect `or`

* Refactored size ratio calculation in
relayImageHelper function

* Updated the format of resolution keys in
DalleSizeRatios map

* Added error handling for unsupported image size in
relayImageHelper function

* Added validation for number of generated images
and defined image generation ratios

* Refactored variable name from
DalleGenerationImageAmountRatios to
DalleGenerationImageAmounts

* Added validation for prompt length in
relayImageHelper function

* Updated model validation and removed size not
supported error in relayImageHelper function

* Refactored image size and model validation in
relayImageHelper function

* chore: discard binary file

* chore: update impl

---------

Co-authored-by: cktsun1031 <65409152+cktsun1031@users.noreply.github.com>
Co-authored-by: JustSong <songquanpeng@foxmail.com>
2023-11-17 20:03:16 +08:00
..
constants.go feat: able to set RELAY_TIMEOUT 2023-10-22 20:39:49 +08:00
crypto.go Initial commit 2023-04-22 20:39:27 +08:00
custom-event.go refactor: rename file to conform to standards 2023-05-13 15:43:55 +08:00
database.go fix: fix postgresql support (#606) 2023-10-22 18:38:29 +08:00
email.go fix: fix SMTPFrom not updated in some cases (close #34) 2023-05-13 22:04:36 +08:00
embed-file-system.go Initial commit 2023-04-22 20:39:27 +08:00
gin.go feat: support group now (close #17, close #72, close #85, close #104, close #136) 2023-06-07 23:26:00 +08:00
group-ratio.go chore: format logs 2023-06-22 10:59:01 +08:00
init.go refactor: update logging related logic 2023-09-17 15:39:46 +08:00
logger.go feat: create new log file when too many logs recorded 2023-09-17 16:35:30 +08:00
model-ratio.go feat: keep sync with dall-e updates (#679) 2023-11-17 20:03:16 +08:00
rate-limit.go Initial commit 2023-04-22 20:39:27 +08:00
redis.go fix: update cache immediately after cache get 2023-08-16 23:40:50 +08:00
utils.go fix: fix postgresql support (#606) 2023-10-22 18:38:29 +08:00
validate.go Initial commit 2023-04-22 20:39:27 +08:00
verification.go Initial commit 2023-04-22 20:39:27 +08:00