07

Safety & Tools

Boundaries & Agents

These two concerns, safety and tool use, are grouped because both are typically layered on after core alignment. Safety teaches the model where boundaries are and how to stay useful without causing harm. Tool-use teaches the model to act as an agent: searching, calling APIs, reading files, and executing code. They use different data formats but share the same training stage.

Safety Dataset Types

Dataset TypeExample UnitTurn TypeLabelGoalBehaviorsWeaknessesCuration Concerns
Refusal examplesUnsafe prompt + safe refusalSingle-turnPreferred refusalStop disallowed behaviorRefusing harmful requestsOver-refusal on benign queriesPolicy coverage, edge cases
Safe completionRisky prompt + harmless answerSingle-turnPreferred safe answerContinue safelyRedirection, safer assistanceCan feel evasiveNuance in partial-help cases
Borderline casesAmbiguous prompt + policy answerSingle/multi-turnBest interpretationImprove consistencyBetter handling of gray areasAnnotator disagreementClear policy, rater calibration
Adversarial promptsJailbreaks, injectionsSingle/multi-turnSafe outcomeRobustnessResistance to manipulationOngoing contest with attackersAttack type diversity, coverage
De-escalationEmotional/dangerous inputMulti-turnHelpful safe responseHuman-centered safetySupportive, calm, boundedCan flatten emotional nuanceSeverity levels, cultural sensitivity

Tool-Use & Agent Datasets

Dataset TypeExample UnitTurn TypeFormatGoalBehaviorsWeaknessesCuration Concerns
Function-callingPrompt + schema + tool callMulti-turn/actionStructured JSON/actionCall tools correctlyTool selection, argument formattingTied to specific tool versionsSchema versioning, execution tests
Retrieval QAQuery + passages + answerSingle-turnContext-grounded answerUse evidenceGrounded answering, citationsMay overfit to citation formatEvidence mapping, freshness
Browser/searchSearch terms, clicks, readsMulti-stepSequential observationsFind and synthesize infoSearch planning, source selectionFragile to UI changesRealistic page snapshots
Code executionPrompt, code, result, repairMulti-stepAction-observation loopLearn from runtime feedbackDebugging, iterative repairOverfitting to specific testsStrong hidden test suites
Workflow orchestrationMulti-tool business flowMulti-stepState transitionsComplete real tasksPlanning and action chainingComplex credit assignmentEnd-to-end success metrics
Detailed Descriptions

Key Point

A good safety dataset does not just teach the model to say "I can't help with that." It teaches:

  • when refusal is necessary
  • when safer partial help is possible
  • how to redirect productively
  • how to stay calm under adversarial prompting