EcosystemTooling
Braintrust
Export Fabric traces and evaluation context to Braintrust.
Run fh add braintrust to install the current SDK and generate a managed, redacted observer plus its contract test. Attach stable job/agent/session/model metadata and keep evaluation datasets separate from production session storage.
import { createObservabilityObserver } from '@fabric-harness/sdk';
import { initLogger } from 'braintrust';
const logger = initLogger({ projectName: 'fabric-harness' });
const onEvent = createObservabilityObserver({
integration: 'braintrust',
correlation: { agentId: 'support', jobId: runId, submissionId, tenantId },
send: (record) => logger.log({ input: record.event, metadata: record.correlation }),
});
const agent = await init({ onEvent });Prompt, output, tool, and customer content capture must be explicitly enabled and redacted. Keep the Braintrust API key host-side and flush the client during process shutdown.
The default record contains event identity and correlation only. Set captureData: true only after
reviewing the recursive key/secret redaction policy. A runnable fixture is in
examples/with-observability.