Skip to content

Commit 9032220

Browse files
committed
chore: fix lint issues
1 parent 9c9ffae commit 9032220

File tree

2 files changed

+3
-11
lines changed

2 files changed

+3
-11
lines changed

packages/agent-api/src/functions/chats-post.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -83,19 +83,11 @@ export async function postChats(request: HttpRequest, context: InvocationContext
8383
}
8484

8585
const model = new ChatOpenAI({
86-
configuration: {
87-
baseURL: azureOpenAiEndpoint,
88-
async fetch(url, init = {}) {
89-
const token = await getAzureOpenAiTokenProvider()();
90-
const headers = new Headers(init.headers);
91-
headers.set('Authorization', `Bearer ${token}`);
92-
return fetch(url, { ...init, headers });
93-
},
94-
},
86+
configuration: { baseURL: azureOpenAiEndpoint },
9587
modelName: process.env.AZURE_OPENAI_MODEL ?? 'gpt-5-mini',
9688
streaming: true,
9789
useResponsesApi: true,
98-
apiKey: 'not_used',
90+
apiKey: getAzureOpenAiTokenProvider(),
9991
});
10092
const chatHistory = new AzureCosmsosDBNoSQLChatMessageHistory({
10193
sessionId,

packages/agent-api/src/tracing.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { OTLPTraceExporter } from '@opentelemetry/exporter-trace-otlp-http';
77
import { NodeTracerProvider } from '@opentelemetry/sdk-trace-node';
88
import { SimpleSpanProcessor } from '@opentelemetry/sdk-trace-base';
99
import { LangChainInstrumentation } from '@arizeai/openinference-instrumentation-langchain';
10-
import * as CallbackManagerModule from "@langchain/core/callbacks/manager";
10+
import * as CallbackManagerModule from '@langchain/core/callbacks/manager';
1111

1212
let isTracingInitialized = false;
1313
if (!isTracingInitialized) {

0 commit comments

Comments
 (0)