ai-gateway/go.mod

86 lines
3.5 KiB
Modula-2
Raw Normal View History

2024-01-28 11:38:58 +00:00
module github.com/songquanpeng/one-api
2023-04-22 12:39:27 +00:00
// +heroku goVersion go1.18
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
go 1.20
2023-04-22 12:39:27 +00:00
require (
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/aws/aws-sdk-go-v2 v1.26.1
github.com/aws/aws-sdk-go-v2/credentials v1.17.11
github.com/aws/aws-sdk-go-v2/service/bedrockruntime v1.7.4
github.com/gin-contrib/cors v1.7.1
github.com/gin-contrib/gzip v1.0.0
github.com/gin-contrib/sessions v1.0.0
github.com/gin-contrib/static v1.1.1
github.com/gin-gonic/gin v1.9.1
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/go-playground/validator/v10 v10.19.0
2023-04-22 12:39:27 +00:00
github.com/go-redis/redis/v8 v8.11.5
github.com/golang-jwt/jwt v3.2.2+incompatible
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/google/uuid v1.6.0
github.com/gorilla/websocket v1.5.1
github.com/jinzhu/copier v0.4.0
github.com/pkg/errors v0.9.1
github.com/pkoukk/tiktoken-go v0.1.6
github.com/smartystreets/goconvey v1.8.1
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/stretchr/testify v1.9.0
golang.org/x/crypto v0.22.0
golang.org/x/image v0.15.0
gorm.io/driver/mysql v1.5.6
gorm.io/driver/postgres v1.5.7
gorm.io/driver/sqlite v1.5.5
gorm.io/gorm v1.25.9
2023-04-22 12:39:27 +00:00
)
require (
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
filippo.io/edwards25519 v1.1.0 // indirect
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.2 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.5 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.5 // indirect
github.com/aws/smithy-go v1.20.2 // indirect
github.com/bytedance/sonic v1.11.5 // indirect
github.com/bytedance/sonic/loader v0.1.1 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/cloudwego/base64x v0.1.3 // indirect
github.com/cloudwego/iasm v0.2.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
2023-04-22 12:39:27 +00:00
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/dlclark/regexp2 v1.11.0 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/gabriel-vasile/mimetype v1.4.3 // indirect
2023-04-22 12:39:27 +00:00
github.com/gin-contrib/sse v0.1.0 // indirect
2023-04-25 13:56:23 +00:00
github.com/go-playground/locales v0.14.1 // indirect
github.com/go-playground/universal-translator v0.18.1 // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/go-sql-driver/mysql v1.8.1 // indirect
2023-04-25 13:56:23 +00:00
github.com/goccy/go-json v0.10.2 // indirect
github.com/gopherjs/gopherjs v1.17.2 // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/gorilla/context v1.1.2 // indirect
github.com/gorilla/securecookie v1.1.2 // indirect
github.com/gorilla/sessions v1.2.2 // indirect
2023-08-12 11:20:12 +00:00
github.com/jackc/pgpassfile v1.0.0 // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/jackc/pgservicefile v0.0.0-20231201235250-de7065d80cb9 // indirect
github.com/jackc/pgx/v5 v5.5.5 // indirect
github.com/jackc/puddle/v2 v2.2.1 // indirect
2023-04-22 12:39:27 +00:00
github.com/jinzhu/inflection v1.0.0 // indirect
github.com/jinzhu/now v1.1.5 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/jtolds/gls v4.20.0+incompatible // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/klauspost/cpuid/v2 v2.2.7 // indirect
github.com/kr/text v0.2.0 // indirect
github.com/leodido/go-urn v1.4.0 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
2023-04-22 12:39:27 +00:00
github.com/mattn/go-sqlite3 v2.0.3+incompatible // indirect
2023-04-25 13:56:23 +00:00
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
2023-04-22 12:39:27 +00:00
github.com/modern-go/reflect2 v1.0.2 // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/pelletier/go-toml/v2 v2.2.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/smarty/assertions v1.15.0 // indirect
2023-04-25 13:56:23 +00:00
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
feat: support aws bedrockruntime claude3 (#1328) * feat: support aws bedrockruntime claude3 closes #622, closes #749, closes #1300 * fix: convert to aws claude model id * fix: Update AWS adapter to handle stream completions and calculate usage metrics Based on the file summaries provided, here are the important bullet points for the commit message: - Add functionality to handle stream completion events from AWS in the relay/adaptor/aws/main.go file - Marshall AWS response to OpenAI format and calculate usage metrics in the same file - Implement a custom render function for streaming events in the same file - Improve error handling for JSON unmarshalling and marshalling errors in the same file * fix: Implement AWS handler with usage tracking and error handling - Implemented streaming response handling for AWS handler - Set response content type to text/event-stream - Added error handling for failed marshaling/unmarshaling - Updated return values to include `relaymodel.ErrorWithStatusCode` and `relaymodel.Usage` - Improved error handling and response formatting for AWS adaptor * fix: Refactor AWS Adapter for Improved Model Mapping and Error Handling * Refactor AWS adapter to improve model management - Replace hardcoded model list in `adapter.go` with a function to get models from `awsModelIDMap` - Update `GetModelList` function to return model list directly - Add `GetChannelName` function to get channel name from `Adaptor` object * Improve error handling and code organization in main.go - Replace switch statement with a map to map AWS model IDs to OpenAI model IDs - Return an error if the model is not found in the map - Use a single return statement instead of wrapping multiple return statements in the `awsModelID` function - Add a new error message for when the model is not found in the map in the `Handler` function * fix: bug fix * chore: change variable name & package * chore: change variable name * perf: update config related code --------- Co-authored-by: JustSong <songquanpeng@foxmail.com>
2024-04-19 16:40:47 +00:00
github.com/ugorji/go/codec v1.2.12 // indirect
golang.org/x/arch v0.7.0 // indirect
golang.org/x/net v0.24.0 // indirect
golang.org/x/sync v0.7.0 // indirect
golang.org/x/sys v0.19.0 // indirect
golang.org/x/text v0.14.0 // indirect
google.golang.org/protobuf v1.33.0 // indirect
2023-04-25 13:56:23 +00:00
gopkg.in/yaml.v3 v3.0.1 // indirect
2023-04-22 12:39:27 +00:00
)