mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
Disable import of langtrace (#185029)
## Summary Disables the import for langtrace. When imported, it immediately instruments openai lang client. This causes an issue where the completion.create return is no longer a native ReadableStream and we cannot tee off for pompt token counting ([here](https://github.com/elastic/kibana/blob/main/x-pack/plugins/stack_connectors/server/connector_types/openai/openai.ts#L309)) Under @dgieselaar request, i've commented out the import for now.
This commit is contained in:
parent
c7d682323a
commit
1ec9412e82
1 changed files with 9 additions and 9 deletions
|
@ -5,19 +5,19 @@
|
|||
* 2.0.
|
||||
*/
|
||||
|
||||
import { init } from '@langtrase/typescript-sdk';
|
||||
// import { init } from '@langtrase/typescript-sdk';
|
||||
|
||||
export function initLangtrace() {
|
||||
const apiKey = process.env.LANGTRACE_API_KEY;
|
||||
const apiHost = process.env.LANGTRACE_API_HOST;
|
||||
if (apiKey && apiHost) {
|
||||
init({
|
||||
api_host: apiHost,
|
||||
api_key: apiKey,
|
||||
write_to_langtrace_cloud: true,
|
||||
disable_instrumentations: {
|
||||
only: [],
|
||||
},
|
||||
});
|
||||
// init({
|
||||
// api_host: apiHost,
|
||||
// api_key: apiKey,
|
||||
// write_to_langtrace_cloud: true,
|
||||
// disable_instrumentations: {
|
||||
// only: [],
|
||||
// },
|
||||
// });
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue