remove extraneous bedrock load errors, don't force bedrock openai adapter
This commit is contained in:
parent
e389050dda
commit
ed3217aaff
2 changed files with 0 additions and 10 deletions
|
|
@ -21,7 +21,6 @@ import {
|
|||
import { safeParseToolCallArgs } from "../../tools/parseArgs.js";
|
||||
import { renderChatMessage, stripImages } from "../../util/messageContent.js";
|
||||
import { BaseLLM } from "../index.js";
|
||||
import { LlmApiRequestType } from "../openaiTypeConverters.js";
|
||||
import { PROVIDER_TOOL_SUPPORT } from "../toolSupport.js";
|
||||
import { getSecureID } from "../utils/getSecureID.js";
|
||||
|
||||
|
|
@ -48,7 +47,6 @@ interface PromptCachingMetrics {
|
|||
}
|
||||
|
||||
class Bedrock extends BaseLLM {
|
||||
protected useOpenAIAdapterFor: (LlmApiRequestType | "*")[] = ["*"];
|
||||
static providerName = "bedrock";
|
||||
static defaultOptions: Partial<LLMOptions> = {
|
||||
region: "us-east-1",
|
||||
|
|
|
|||
|
|
@ -60,10 +60,6 @@ export class BedrockApi implements BaseLlmApi {
|
|||
private _currentToolResponse: Partial<ToolUseState> | null = null;
|
||||
|
||||
constructor(protected config: BedrockConfig) {
|
||||
if (!config.env?.region) {
|
||||
throw new Error("region is required for Bedrock API");
|
||||
}
|
||||
|
||||
if (config.env?.accessKeyId || config?.env?.secretAccessKey) {
|
||||
if (!config.env?.accessKeyId) {
|
||||
throw new Error(
|
||||
|
|
@ -75,10 +71,6 @@ export class BedrockApi implements BaseLlmApi {
|
|||
"secretAccessKey is required for Bedrock API. Only found accessKeyId",
|
||||
);
|
||||
}
|
||||
} else if (!config.env?.profile) {
|
||||
throw new Error(
|
||||
"AWS credentials profile not found. Please provide accessKeyId and secretAccessKey or profile",
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue