Braintrust
Skill ComeOnOliver/skillshub/skills/TerminalSkills/skills/braintrust
π§ The right skill, one API call. AI agent skills registry with token-efficient skill resolution. 5,000+ skills from 500+ top repos.From the repository description
npx -y skills add ComeOnOliver/skillshub --skill braintrustAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
SKILL.md
2.6 KB, 599 tokens by cl100k_base, as published. Nobody here has run it
Braintrust β AI Evaluation and Observability
You are an expert in Braintrust, the evaluation and observability platform for AI applications. You help developers run systematic evaluations, compare model versions, track experiments, log production traces, and measure quality metrics β with a focus on making AI development as rigorous as traditional software testing.
Core Capabilities
import { Eval, init } from "braintrust";
init({ apiKey: process.env.BRAINTRUST_API_KEY });
// Run evaluation
await Eval("support-chatbot", {
data: () => [
{ input: "How do I reset my password?", expected: "Go to Settings > Security > Reset Password" },
{ input: "What's the pricing?", expected: "Plans start at $29/month" },
{ input: "I need a refund", expected: "Contact support at [email protected]" },
],
task: async (input) => {
const response = await callChatbot(input);
return response.text;
},
scores: [
// Built-in scorers
Factuality, // Does output match expected facts?
ClosedQA, // Is the answer correct given context?
// Custom scorer
(output, expected) => {
const containsKey = expected.toLowerCase().split(" ")
.some(word => output.toLowerCase().includes(word));
return { name: "keyword_match", score: containsKey ? 1 : 0 };
},
],
});
// Results visible in Braintrust dashboard with diffs, regressions, improvements
# Python
from braintrust import Eval
Eval(
"rag-pipeline",
data=lambda: [{"input": q, "expected": a} for q, a in test_pairs],
task=lambda input: rag_pipeline.query(input),
scores=[Factuality, Relevance],
)
Installation
npm install braintrust autoevals
# or
pip install braintrust autoevals
Best Practices
- Eval-driven development β Write evals first, then iterate on prompts/models; measure before optimizing
- Built-in scorers β Use Factuality, ClosedQA, Relevance from
autoevals; LLM-based quality scoring - Custom scorers β Add domain-specific metrics; combine with built-in for comprehensive evaluation
- Experiments β Each eval run is an experiment; compare side-by-side in dashboard
- Production logging β Use
braintrust.traced()for production observability; same dashboard as evals - CI integration β Run evals in CI; fail builds on quality regressions
- Dataset management β Store test datasets in Braintrust; version and share across team
- A/B comparison β Compare two model versions on the same dataset; statistical significance reported
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.