Encyclopedia Evalica / Datasets / flush()

flush() illustration

flush()

/fluhsh/An SDK method that forces all buffered dataset records or trace spans to be written to Braintrust immediately. This is useful in short-lived jobs (like serverless) where buffered data might not be sent before the process exits. (verb)

We call flush() at the end of the job to guarantee traces are exported.

Related Datasets terms

From the docs

Get started with Evals

Braintrust is the observability platform for agents in production. By actively applying intelligence to agent traces and automatically surfacing critical patterns, Braintrust helps teams at Notion, Stripe, Box, OpenAI, and Cloudflare ship quality agents at scale.

Start building