Toolscore Logo

Getting Started

  • Installation
    • Requirements
    • From PyPI
    • From Source
    • Development Installation
    • Optional Dependencies
      • Remote MCP Servers and HTTP Validators
      • LLM-as-a-judge Metrics
      • LangChain Support
      • All Optional Features
      • Documentation
    • Verification
    • Next Steps
  • Quick Start
    • Install Toolscore
    • The fastest path: toolscore init + snapshots
      • 1. Scaffold a test suite
      • 2. Run pytest — the first run records a snapshot
      • 3. Review and approve the snapshot
      • The one-line assertion
    • Evaluating captured traces
    • Basic Usage
      • Command Line Interface
      • Python API (In-Memory)
      • Python API (File-Based)
    • Creating Gold Standards
    • Supported Trace Formats
      • OpenAI Format
      • Anthropic Format
      • Custom Format
      • Other Trace Sources
    • Check behavior and safety
    • Next Steps
  • What Toolscore Catches
    • Found with Toolscore
    • Scenarios
      • 1. Catch an agent that gives up after an error
      • 2. Find tool descriptions that point to tools that don’t exist
      • 3. Block destructive commands and leaked keys in CI
      • 4. Score the OpenTelemetry traces you already collect
    • Failures You Can Actually Read

Who it's for

  • For MCP Server Authors
    • 1. Grade it
    • 2. Check that the tools really do it
    • 3. Show the grade and gate CI
    • 4. Pin what you ship
  • For Agent Builders
    • 1. Scaffold a suite
    • 2. Say what the task must, may and must never do
    • 3. Check that the agent told the truth
    • 4. In CI
  • For Security and Platform Teams
    • 1. Pin every MCP server
    • 2. Lint the instructions that name the tools
    • 3. Block destructive calls and leaked credentials
    • 4. Review what coding agents did
  • For Researchers
    • 1. Check before you spend
    • 2. Run and compare
    • 3. Keep every run re-scorable
    • 4. Measure honesty, not only accuracy

Guides

  • User Guide
    • Understanding Metrics
      • Tool Invocation Accuracy
      • Tool Selection Accuracy
      • Sequence Edit Distance
      • Argument Match F1 Score
      • Redundant Call Rate
      • Required Call Recall
      • Failed Calls and Blind Retries
      • Credentials and Forbidden Calls
      • Side-Effect Success Rate
      • LLM-as-a-judge Semantic Correctness (Optional)
    • Scoring Semantics
      • Omitted args vs {}
      • Custom weights are renormalized
      • Strict mode
      • Calls are paired one-to-one
      • Loops vs. exploration
    • Working with Trace Formats
      • Auto-Detection
      • Explicit Format
    • Capturing Traces
      • From OpenAI
      • From Anthropic
      • From LangChain
    • Creating Effective Gold Standards
      • Best Practices
      • Example Gold Standard
    • Side-Effect Validation
      • HTTP Validation
      • Filesystem Validation
      • Database Validation
    • Generating Reports
      • JSON Reports
      • HTML Reports
    • Batch Evaluation
    • End-to-End Agent Testing
    • Data-Driven Testing with @toolscore.cases()
    • Pytest Integration
      • Using Fixtures
      • Available Fixtures
      • Assertion Helpers
      • Example Test Suite
    • Interactive Tutorials
    • Tips and Tricks
    • Troubleshooting
      • Common Issues
      • Getting Help
  • Snapshot Testing
    • The record → approve → replay story
    • The toolscore_snapshot fixture
      • Call signature
      • Pytest options
      • Environment variables
    • CLI commands
      • toolscore record — capture snapshots
      • toolscore approve — promote a recording to a baseline
      • toolscore snapshots — list / show / rm
    • Snapshot file format
    • CI behavior
    • The update flow
    • Programmatic API
  • Argument Matchers
    • The matchers
      • ANY — match any value
      • Regex — full-match a string
      • Approx — numeric closeness
      • Contains — membership
      • OneOf — value is one of
      • IsType — type check
    • The omitted-args vs {} contract
    • Strict mode interplay
    • API reference
  • Framework Integration Guide
    • LangGraph
    • Pydantic AI
    • OpenAI Responses API
    • OpenAI Agents SDK
    • Claude Agent SDK
    • browser-use
    • Inspect AI
    • CrewAI (experimental)
    • OpenTelemetry (any instrumented framework)
    • MCP sessions
  • Fluent API — expect()
    • Hero Example
    • Quick Start
    • Chain-Method Reference
    • Using Matchers
    • Async Agents
    • Forbidden-Only Contract
    • API Reference
      • expect()
      • Expectation
        • Expectation.__init__()
        • Expectation.on()
        • Expectation.calls()
        • Expectation.then_calls()
        • Expectation.does_not_call()
        • Expectation.with_score()
        • Expectation.with_weights()
        • Expectation.with_strict_args()
        • Expectation.run()
        • Expectation.run_async()
  • Behavior and Safety Checks
    • Failed calls and blind retries
    • Required calls completed
    • Credentials in tool arguments
    • Forbidden calls
      • Rules in a JSON file
    • Failing a build on violations
    • A complete record for harnesses
  • Honesty Checks
    • Example: a JavaScript escape hatch
    • Example: an ignored warning
    • Rules
    • The false_success metric
    • Where the final answer comes from
    • Configuration
    • In CI
    • How accurate the answer checks are
    • Limits
  • LLM-as-a-Judge
    • JudgeConfig
    • Provider inference
    • Environment-variable keys
    • Local / OpenAI-compatible endpoints (Ollama, vLLM, Groq)
    • Batching behavior
    • Extras install matrix
    • Using the judge from evaluate_trace
    • CLI flags
    • API reference
      • JudgeConfig
        • JudgeConfig.model
        • JudgeConfig.provider
        • JudgeConfig.api_key
        • JudgeConfig.base_url
        • JudgeConfig.temperature
        • JudgeConfig.max_retries
        • JudgeConfig.__init__()
      • infer_provider()
  • Testing MCP Servers
    • Test your MCP server in 60 seconds
    • Protocol versions
    • The subcommands
    • Remote servers (Streamable HTTP)
    • What the linter checks
      • Lint rules
    • Recording real sessions
    • What the grade means
    • Tuning the run
    • Using it in CI
    • Embedding the scorecard
    • Grade badges
    • Python API
  • Effect Probes
    • Safety: read-only by default
    • Round trips (writes)
    • Bounds (read-only)
    • Confidence and the grade
      • The grade cap
      • Probe rules
    • Probe configs: declare what you know
    • Argument values for sandboxed servers: --arg
    • Limits
  • Fault Injection
    • The workflow
    • The fault spec
    • Planted instructions (prompt injection)
    • The session file
    • Limits
  • Coding-Agent Sessions
    • Check one session
    • How the formats are read
    • List recent sessions
    • Share or test a session
  • Agent-Config Lint
    • What it reads
    • Rules
    • Example
  • Diff & Pinning
    • Pinning
      • Capabilities
      • Drift rules
      • Example: a rug pull, offline
      • Python
    • Diffing two servers
  • Agent Harness
    • What it guards
    • The spec
    • Outcomes
    • The run row
    • An offline example
    • A real model (costs money)
    • Python
    • Doctor: preflight
    • Exporting runs
  • Contracts v2
    • Semantics
    • Argument matchers
    • What it reports
    • Schema and Python
  • Receipts & Regrade
    • Receipts
    • Regrade
    • Tri-state evidence
    • Unknown, never 0: latency and cost
    • Complete records
  • Comparing Runs
    • Inputs
    • What it reports
    • Pre-declared decision rules
    • Choosing a variant
    • Python
  • CI/CD
    • Findings in code scanning and test reports
      • GitHub code scanning
      • GitLab and Jenkins (JUnit)
    • pre-commit
    • Show the grade in your README
  • Extending Toolscore
    • When you need a custom adapter
    • The BaseAdapter contract
    • Using a custom adapter
    • Request an adapter
  • Toolscore and Other MCP Tools
    • Where Toolscore fits
    • Which tool for which job
    • MCP Inspector
    • MCP security scanners
    • DeepEval
    • Promptfoo
    • The MCP conformance suite
    • Using them together

API Reference

  • API Reference
    • Core Module
      • Main Functions
        • evaluate()
        • assert_tools()
        • test_agent()
        • test_agent_async()
        • evaluate_trace()
        • load_gold_standard()
        • load_trace()
        • adapter_for()
        • Transcript
        • load_transcript()
        • transcript_from_data()
        • final_answer_of()
        • normalize_tool_name()
        • auto_extract()
        • from_otel()
        • from_openai_responses()
      • Result Container
        • EvaluationResult
    • Adapters Module
      • Base Classes
        • ToolCall
        • BaseAdapter
      • Adapter Implementations
        • OpenAI Adapter
        • Anthropic Adapter
        • LangChain Adapter
        • Gemini Adapter
        • MCP Adapter
        • OpenTelemetry Adapter
        • Custom Adapter
        • browser-use Adapter
        • Coding-agent Session Adapters
    • Matchers Module
      • ANY
      • Approx
        • Approx.__init__()
        • Approx.matches()
      • Contains
        • Contains.__init__()
        • Contains.matches()
      • IsType
        • IsType.__init__()
        • IsType.matches()
      • Matcher
        • Matcher.matches()
      • OneOf
        • OneOf.__init__()
        • OneOf.matches()
      • Regex
        • Regex.__init__()
        • Regex.matches()
    • Metrics Module
      • Accuracy Metrics
        • calculate_invocation_accuracy()
        • calculate_selection_accuracy()
      • Sequence Metrics
        • calculate_edit_distance()
      • Argument Metrics
        • calculate_argument_f1()
      • Required Calls
        • calculate_required_call_recall()
      • Efficiency Metrics
        • calculate_redundant_call_rate()
      • Safety: Credentials and Forbidden Calls
        • find_secrets()
        • redact_secrets()
        • check_forbidden_calls()
        • rules_from_json()
        • load_forbidden_rules()
        • call_matches_rule()
      • Honesty
        • check_honesty()
        • HonestyConfig
        • load_honesty_config()
        • apply_injections()
        • call_text()
        • HONESTY_RULES
      • Side-Effect Metrics
        • calculate_side_effect_success_rate()
      • Performance Metrics
        • calculate_latency()
        • calculate_cost_attribution()
        • Model prices
        • Default models
      • LLM-as-a-judge Metrics (Optional)
        • calculate_semantic_correctness()
        • calculate_batch_semantic_correctness()
    • Snapshots Module
      • snapshot_check()
      • Snapshot
        • Snapshot.name
        • Snapshot.calls
        • Snapshot.approved
        • Snapshot.source
        • Snapshot.created_at
        • Snapshot.updated_at
        • Snapshot.schema_version
        • Snapshot.toolscore_version
        • Snapshot.__post_init__()
        • Snapshot.to_dict()
        • Snapshot.from_dict()
        • Snapshot.__init__()
      • SnapshotStore
        • SnapshotStore.__init__()
        • SnapshotStore.path_for()
        • SnapshotStore.exists()
        • SnapshotStore.load()
        • SnapshotStore.save()
        • SnapshotStore.approve()
        • SnapshotStore.delete()
        • SnapshotStore.list()
        • SnapshotStore.pending()
    • MCP Module
      • Clients
        • MCPClient
        • MCPStdioClient
        • MCPHttpClient
        • MODERN_PROTOCOL_VERSION
        • LEGACY_PROTOCOL_VERSION
        • MCPToolDef
        • MCPToolResult
        • MCPError
        • MCPTimeoutError
        • MCPHTTPStatusError
        • content_to_text()
      • Recording sessions and injecting faults
        • MCPRecorder
        • FaultSpec
        • FaultRule
        • FaultInjector
        • Injection
        • FAULT_KINDS
        • load_fault_spec()
      • Server configuration
        • MCPServerSpec
        • load_mcp_config()
        • open_client()
      • Scorecard harness
        • generate_scenarios()
        • run_scenarios()
        • lint_tools()
        • dangling_reference_issues()
        • poisoning_issues()
        • annotation_issues()
        • output_schema_issues()
        • validate_instance()
        • Scenario
        • ScenarioResult
        • LintIssue
      • Argument values
        • ArgumentFixtures
        • load_fixtures()
        • parse_arg()
      • Effect probes
        • run_probes()
        • ProbeResult
        • ProbeConfig
        • RoundTripPair
        • BoundRelation
        • Agreement
        • CallSpec
        • load_probe_config()
        • builtin_relations()
        • is_read_tool()
        • write_basis()
        • PROBE_RULES
      • Scorecard
        • MCPScorecard
        • score_server()
        • grade_meets()
        • print_scorecard()
        • scorecard_to_json()
        • scorecard_to_markdown()
      • Badges
        • badge_svg()
        • badge_endpoint()
        • PROBE_GRADE_CAP
      • Snapshots, pinning and diffs
        • ServerSnapshot
        • load_snapshot()
        • write_snapshot()
        • snapshot_from_json()
        • build_lock()
        • verify_pin()
        • load_lock()
        • write_lock()
        • infer_capabilities()
        • load_capability_overrides()
        • PinReport
        • PinFinding
        • PIN_RULES
        • CAPABILITIES
        • diff_snapshots()
        • ServerDiff
        • ToolChange
        • render_diff()
      • Agent harness
        • run_agent()
        • run_study()
        • load_agent_spec()
        • spec_from_mapping()
        • regrade_rows()
        • evaluate_run()
        • estimate_study_cost()
        • preflight_prices()
        • check_build()
        • map_tools()
        • rules_guard()
        • allow()
        • deny()
        • OpenAIResponsesProvider
        • AnthropicMessagesProvider
        • ScriptedProvider
        • ModelProvider
        • AgentRun
        • AgentSpec
        • Budget
        • Limits
        • Price
        • GuardCall
        • GuardDecision
        • UnknownPriceError
        • BuildMismatchError
    • Contracts, Receipts, Evidence, Statistics and Export
      • Contracts
        • evaluate_contract()
        • load_contract()
        • contract_from_mapping()
        • is_contract()
        • matcher_from_json()
        • split_optional()
        • Contract
        • AlternativeGroup
      • Receipts and regrade
        • build_receipt()
        • write_receipt()
        • load_receipt()
        • verify_receipt()
        • regrade()
        • Regrade
        • ReceiptMismatchError
        • canonical_json()
        • json_sha256()
        • file_digest()
      • Evidence
        • STATES
        • Check
        • tally()
        • summary_line()
        • tri_state()
        • evaluation_evidence()
      • Statistics and selection
        • wilson_interval()
        • fisher_exact()
        • pass_hat_k()
        • compare_runs()
        • load_runs()
        • runs_from_traces()
        • run_from_row()
        • select_variant()
        • pareto_front()
        • evaluate_protocol()
        • load_protocol()
        • Run
        • VariantStats
        • Comparison
        • PairComparison
        • Selection
        • ProtocolResult
      • Export
        • export_records()
        • write_export()
        • validate_record()
        • record_from_run()
        • SCHEMA_VERSION
      • Doctor
        • run_doctor()
        • check_server()
        • doctor_report()
        • DoctorCheck
    • Sessions, Config Lint, Recorders and Inspect AI
      • Coding-agent sessions
        • AGENTS
        • SessionSummary
        • default_roots()
        • parse_since()
        • find_session_files()
        • summarize_session()
        • export_session()
        • read_trace_data()
      • Agent-config lint
        • CONFIG_RULES
        • INVENTORY_RULES
        • ConfigIssue
        • ConfigLintReport
        • discover_files()
        • lint_config()
      • Live recorders
        • ClaudeAgentSDKRecorder
        • OpenAIAgentsRecorder
      • Inspect AI scorer
        • METADATA_KEY
        • from_inspect_messages()
        • final_answer_from_state()
        • score_state()
        • toolscore_scorer()
      • Framework helpers
        • claude_agent_sdk_messages()
        • pydantic_ai_final_answer()
    • Validators Module
      • HTTP Validator
        • HTTPValidator
      • Filesystem Validator
        • FileSystemValidator
      • SQL Validator
        • SQLValidator
    • Reports Module
      • JSON Reports
        • generate_json_report()
      • HTML Reports
        • generate_html_report()
      • Markdown and CSV Reports
        • generate_markdown_report()
        • generate_csv_report()
      • Behavior and Safety Findings
        • behavior_findings()
      • SARIF and JUnit
        • STATUSES
        • Outcome
        • rule_description()
        • default_location()
        • to_sarif()
        • to_junit()
        • write_ci_reports()
        • outcomes_from_lint()
        • outcomes_from_scorecard()
        • outcomes_from_pin()
        • outcomes_from_diff()
        • outcomes_from_config_lint()
        • outcomes_from_honesty()
        • outcomes_from_evaluation()
        • ci_report_options()
    • Verdict Module
      • letter_grade()
      • FixSuggestion
        • FixSuggestion.tool
        • FixSuggestion.problem
        • FixSuggestion.fix
        • FixSuggestion.priority
        • FixSuggestion.__init__()
    • Overview
    • Basic Usage
    • Main Components
    • Quick Reference
      • Core Functions
      • Adapters
      • Metrics
      • Validators
      • Reports
  • Core Module
    • Main Functions
      • evaluate()
      • assert_tools()
      • test_agent()
      • test_agent_async()
      • evaluate_trace()
      • load_gold_standard()
      • load_trace()
      • adapter_for()
      • Transcript
        • Transcript.calls
        • Transcript.final_answer
        • Transcript.final_source
        • Transcript.injections
        • Transcript.success
        • Transcript.__init__()
      • load_transcript()
      • transcript_from_data()
      • final_answer_of()
      • normalize_tool_name()
      • auto_extract()
      • from_otel()
      • from_openai_responses()
    • Result Container
      • EvaluationResult
        • EvaluationResult.DEFAULT_WEIGHTS
        • EvaluationResult.__init__()
        • EvaluationResult.score
        • EvaluationResult.grade
        • EvaluationResult.selection_accuracy
        • EvaluationResult.argument_f1
        • EvaluationResult.sequence_accuracy
        • EvaluationResult.required_call_recall
        • EvaluationResult.false_success
        • EvaluationResult.scored_calls
        • EvaluationResult.evidence
        • EvaluationResult.policy_violations
        • EvaluationResult.RECORD_SCHEMA_VERSION
        • EvaluationResult.to_dict()
  • Adapters Module
    • Base Classes
      • ToolCall
        • ToolCall.tool
        • ToolCall.args
        • ToolCall.result
        • ToolCall.timestamp
        • ToolCall.duration
        • ToolCall.cost
        • ToolCall.metadata
        • ToolCall.__post_init__()
        • ToolCall.id
        • ToolCall.is_error
        • ToolCall.__init__()
      • BaseAdapter
        • BaseAdapter.parse()
    • Adapter Implementations
      • OpenAI Adapter
        • OpenAIAdapter
      • Anthropic Adapter
        • AnthropicAdapter
      • LangChain Adapter
        • LangChainAdapter
      • Gemini Adapter
        • GeminiAdapter
      • MCP Adapter
        • MCPAdapter
      • OpenTelemetry Adapter
        • OTelAdapter
        • tool_calls_from_otel()
      • Custom Adapter
        • CustomAdapter
      • browser-use Adapter
        • BrowserUseAdapter
      • Coding-agent Session Adapters
        • ClaudeCodeSessionAdapter
        • CodexSessionAdapter
  • Matchers Module
    • ANY
    • Approx
      • Approx.__init__()
      • Approx.matches()
    • Contains
      • Contains.__init__()
      • Contains.matches()
    • IsType
      • IsType.__init__()
      • IsType.matches()
    • Matcher
      • Matcher.matches()
    • OneOf
      • OneOf.__init__()
      • OneOf.matches()
    • Regex
      • Regex.__init__()
      • Regex.matches()
  • Metrics Module
    • Accuracy Metrics
      • calculate_invocation_accuracy()
      • calculate_selection_accuracy()
    • Sequence Metrics
      • calculate_edit_distance()
    • Argument Metrics
      • calculate_argument_f1()
    • Required Calls
      • calculate_required_call_recall()
    • Efficiency Metrics
      • calculate_redundant_call_rate()
    • Safety: Credentials and Forbidden Calls
      • find_secrets()
      • redact_secrets()
      • check_forbidden_calls()
      • rules_from_json()
      • load_forbidden_rules()
      • call_matches_rule()
    • Honesty
      • check_honesty()
      • HonestyConfig
        • HonestyConfig.warning_patterns
        • HonestyConfig.error_patterns
        • HonestyConfig.refusal_patterns
        • HonestyConfig.escape_hatch_tools
        • HonestyConfig.override_patterns
        • HonestyConfig.success_patterns
        • HonestyConfig.disclosure_patterns
        • HonestyConfig.neutral_patterns
        • HonestyConfig.done_tools
        • HonestyConfig.escape_window
        • HonestyConfig.min_shared_words
        • HonestyConfig.require_english
        • HonestyConfig.from_mapping()
        • HonestyConfig.__init__()
      • load_honesty_config()
      • apply_injections()
      • call_text()
      • HONESTY_RULES
    • Side-Effect Metrics
      • calculate_side_effect_success_rate()
    • Performance Metrics
      • calculate_latency()
      • calculate_cost_attribution()
      • Model prices
        • calculate_llm_cost()
        • lookup_pricing()
        • estimate_trace_cost()
        • UnknownModelPriceWarning
      • Default models
        • ANTHROPIC_BALANCED
        • ANTHROPIC_FAST
        • ANTHROPIC_TOP
        • DEFAULT_JUDGE_MODEL
        • GEMINI_DEFAULT
        • OPENAI_BALANCED
        • OPENAI_DEFAULT
        • VERIFIED_ON
    • LLM-as-a-judge Metrics (Optional)
      • calculate_semantic_correctness()
      • calculate_batch_semantic_correctness()
  • Snapshots Module
    • snapshot_check()
    • Snapshot
      • Snapshot.name
      • Snapshot.calls
      • Snapshot.approved
      • Snapshot.source
      • Snapshot.created_at
      • Snapshot.updated_at
      • Snapshot.schema_version
      • Snapshot.toolscore_version
      • Snapshot.__post_init__()
      • Snapshot.to_dict()
      • Snapshot.from_dict()
      • Snapshot.__init__()
    • SnapshotStore
      • SnapshotStore.__init__()
      • SnapshotStore.path_for()
      • SnapshotStore.exists()
      • SnapshotStore.load()
      • SnapshotStore.save()
      • SnapshotStore.approve()
      • SnapshotStore.delete()
      • SnapshotStore.list()
      • SnapshotStore.pending()
  • MCP Module
    • Clients
      • MCPClient
        • MCPClient.__init__()
        • MCPClient.server_messages
        • MCPClient.server_messages_dropped
        • MCPClient.protocol_version
        • MCPClient.era
        • MCPClient.server_info
        • MCPClient.server_instructions
        • MCPClient.server_capabilities
        • MCPClient.server_versions
        • MCPClient.__enter__()
        • MCPClient.__exit__()
        • MCPClient.start()
        • MCPClient.close()
        • MCPClient.list_tools()
        • MCPClient.call_tool()
      • MCPStdioClient
        • MCPStdioClient.__init__()
        • MCPStdioClient.__enter__()
      • MCPHttpClient
        • MCPHttpClient.__init__()
        • MCPHttpClient.display_url
        • MCPHttpClient.__repr__()
        • MCPHttpClient.__enter__()
      • MODERN_PROTOCOL_VERSION
      • LEGACY_PROTOCOL_VERSION
      • MCPToolDef
        • MCPToolDef.name
        • MCPToolDef.description
        • MCPToolDef.input_schema
        • MCPToolDef.annotations
        • MCPToolDef.output_schema
        • MCPToolDef.title
        • MCPToolDef.__init__()
      • MCPToolResult
        • MCPToolResult.content
        • MCPToolResult.is_error
        • MCPToolResult.raw
        • MCPToolResult.duration
        • MCPToolResult.input_required
        • MCPToolResult.input_requests
        • MCPToolResult.text
        • MCPToolResult.structured_content
        • MCPToolResult.has_structured_content
        • MCPToolResult.__init__()
      • MCPError
      • MCPTimeoutError
      • MCPHTTPStatusError
        • MCPHTTPStatusError.__init__()
      • content_to_text()
    • Recording sessions and injecting faults
      • MCPRecorder
        • MCPRecorder.__init__()
        • MCPRecorder.injections
        • MCPRecorder.calls_recorded
        • MCPRecorder.write()
        • MCPRecorder.run()
      • FaultSpec
        • FaultSpec.faults
        • FaultSpec.seed
        • FaultSpec.from_mapping()
        • FaultSpec.to_dict()
        • FaultSpec.__init__()
      • FaultRule
        • FaultRule.fault
        • FaultRule.tools
        • FaultRule.calls
        • FaultRule.probability
        • FaultRule.message
        • FaultRule.seconds
        • FaultRule.max_chars
        • FaultRule.forward
        • FaultRule.target_tool
        • FaultRule.canary
        • FaultRule.__post_init__()
        • FaultRule.forwards
        • FaultRule.matches()
        • FaultRule.__init__()
      • FaultInjector
        • FaultInjector.__init__()
        • FaultInjector.decide()
      • Injection
        • Injection.rule
        • Injection.tool
        • Injection.tool_call
        • Injection.seed
        • Injection.fault
        • Injection.canary
        • Injection.message
        • Injection.record()
        • Injection.synthesize()
        • Injection.modify()
        • Injection.__init__()
      • FAULT_KINDS
      • load_fault_spec()
    • Server configuration
      • MCPServerSpec
        • MCPServerSpec.name
        • MCPServerSpec.command
        • MCPServerSpec.env
        • MCPServerSpec.url
        • MCPServerSpec.headers
        • MCPServerSpec.transport
        • MCPServerSpec.__init__()
      • load_mcp_config()
      • open_client()
    • Scorecard harness
      • generate_scenarios()
      • run_scenarios()
      • lint_tools()
      • dangling_reference_issues()
      • poisoning_issues()
      • annotation_issues()
      • output_schema_issues()
      • validate_instance()
      • Scenario
        • Scenario.tool
        • Scenario.arguments
        • Scenario.kind
        • Scenario.description
        • Scenario.violations
        • Scenario.__init__()
      • ScenarioResult
        • ScenarioResult.scenario
        • ScenarioResult.ok
        • ScenarioResult.is_error
        • ScenarioResult.duration
        • ScenarioResult.detail
        • ScenarioResult.structured_content
        • ScenarioResult.has_structured_content
        • ScenarioResult.input_required
        • ScenarioResult.input_requests
        • ScenarioResult.status
        • ScenarioResult.evaluated
        • ScenarioResult.accepted_invalid_input
        • ScenarioResult.__init__()
      • LintIssue
        • LintIssue.tool
        • LintIssue.severity
        • LintIssue.message
        • LintIssue.fix
        • LintIssue.rule
        • LintIssue.__init__()
    • Argument values
      • ArgumentFixtures
        • ArgumentFixtures.shared
        • ArgumentFixtures.per_tool
        • ArgumentFixtures.raw
        • ArgumentFixtures.__bool__()
        • ArgumentFixtures.from_mapping()
        • ArgumentFixtures.from_options()
        • ArgumentFixtures.merged()
        • ArgumentFixtures.for_tool()
        • ArgumentFixtures.apply()
        • ArgumentFixtures.__init__()
      • load_fixtures()
      • parse_arg()
    • Effect probes
      • run_probes()
      • ProbeResult
        • ProbeResult.probe
        • ProbeResult.tool
        • ProbeResult.status
        • ProbeResult.rule
        • ProbeResult.confidence
        • ProbeResult.message
        • ProbeResult.basis
        • ProbeResult.fix
        • ProbeResult.evidence
        • ProbeResult.check
        • ProbeResult.severity
        • ProbeResult.graded
        • ProbeResult.__init__()
      • ProbeConfig
        • ProbeConfig.args
        • ProbeConfig.builtins
        • ProbeConfig.writes
        • ProbeConfig.exclude
        • ProbeConfig.pairs
        • ProbeConfig.relations
        • ProbeConfig.agreements
        • ProbeConfig.idempotent
        • ProbeConfig.from_mapping()
        • ProbeConfig.__init__()
      • RoundTripPair
        • RoundTripPair.write
        • RoundTripPair.read
        • RoundTripPair.read_args
        • RoundTripPair.write_args
        • RoundTripPair.key
        • RoundTripPair.__init__()
      • BoundRelation
        • BoundRelation.tool
        • BoundRelation.param
        • BoundRelation.values
        • BoundRelation.expect
        • BoundRelation.args
        • BoundRelation.unit
        • BoundRelation.id
        • BoundRelation.__init__()
      • Agreement
        • Agreement.left
        • Agreement.right
        • Agreement.expect
        • Agreement.id
        • Agreement.__init__()
      • CallSpec
        • CallSpec.tool
        • CallSpec.args
        • CallSpec.field
        • CallSpec.__init__()
      • load_probe_config()
      • builtin_relations()
      • is_read_tool()
      • write_basis()
      • PROBE_RULES
    • Scorecard
      • MCPScorecard
        • MCPScorecard.server_info
        • MCPScorecard.tools
        • MCPScorecard.results
        • MCPScorecard.lint
        • MCPScorecard.instructions
        • MCPScorecard.protocol_version
        • MCPScorecard.era
        • MCPScorecard.probes
        • MCPScorecard.probe_grade_cap
        • MCPScorecard.not_evaluated
        • MCPScorecard.accepted_invalid_input
        • MCPScorecard.happy_pass_rate
        • MCPScorecard.edge_resilience_rate
        • MCPScorecard.lint_error_count
        • MCPScorecard.lint_warning_count
        • MCPScorecard.lint_score
        • MCPScorecard.effect_rate
        • MCPScorecard.effect_label
        • MCPScorecard.probe_evidence
        • MCPScorecard.probe_failed_tools
        • MCPScorecard.probe_error_count
        • MCPScorecard.probe_warning_count
        • MCPScorecard.score
        • MCPScorecard.uncapped_grade
        • MCPScorecard.grade_cap_reasons
        • MCPScorecard.grade_capped
        • MCPScorecard.grade_cap_note
        • MCPScorecard.grade
        • MCPScorecard.total_tool_tokens
        • MCPScorecard.instructions_tokens
        • MCPScorecard.context_tokens
        • MCPScorecard.__init__()
      • score_server()
      • grade_meets()
      • print_scorecard()
      • scorecard_to_json()
      • scorecard_to_markdown()
    • Badges
      • badge_svg()
      • badge_endpoint()
      • PROBE_GRADE_CAP
    • Snapshots, pinning and diffs
      • ServerSnapshot
        • ServerSnapshot.tools
        • ServerSnapshot.server_info
        • ServerSnapshot.protocol_version
        • ServerSnapshot.era
        • ServerSnapshot.instructions
        • ServerSnapshot.source
        • ServerSnapshot.from_client()
        • ServerSnapshot.tool_map
        • ServerSnapshot.label
        • ServerSnapshot.to_json()
        • ServerSnapshot.__init__()
      • load_snapshot()
      • write_snapshot()
      • snapshot_from_json()
      • build_lock()
      • verify_pin()
      • load_lock()
      • write_lock()
      • infer_capabilities()
      • load_capability_overrides()
      • PinReport
        • PinReport.findings
        • PinReport.fail_on
        • PinReport.server
        • PinReport.failing
        • PinReport.ok
        • PinReport.drifted
        • PinReport.to_dict()
        • PinReport.__init__()
      • PinFinding
        • PinFinding.rule
        • PinFinding.severity
        • PinFinding.tool
        • PinFinding.message
        • PinFinding.diff
        • PinFinding.fields
        • PinFinding.__init__()
      • PIN_RULES
      • CAPABILITIES
      • diff_snapshots()
      • ServerDiff
        • ServerDiff.a
        • ServerDiff.b
        • ServerDiff.added
        • ServerDiff.removed
        • ServerDiff.changed
        • ServerDiff.lint_new
        • ServerDiff.lint_resolved
        • ServerDiff.server_changes
        • ServerDiff.scorecards
        • ServerDiff.new_tool_capabilities
        • ServerDiff.breaking
        • ServerDiff.score_regressions
        • ServerDiff.probe_deltas
        • ServerDiff.identical
        • ServerDiff.fails()
        • ServerDiff.to_dict()
        • ServerDiff.__init__()
      • ToolChange
        • ToolChange.tool
        • ToolChange.fields
        • ToolChange.diffs
        • ToolChange.breaking
        • ToolChange.capabilities_added
        • ToolChange.capabilities_removed
        • ToolChange.__init__()
      • render_diff()
    • Agent harness
      • run_agent()
      • run_study()
      • load_agent_spec()
      • spec_from_mapping()
      • regrade_rows()
      • evaluate_run()
      • estimate_study_cost()
      • preflight_prices()
      • check_build()
      • map_tools()
      • rules_guard()
      • allow()
      • deny()
      • OpenAIResponsesProvider
        • OpenAIResponsesProvider.provider
        • OpenAIResponsesProvider.__init__()
        • OpenAIResponsesProvider.start()
        • OpenAIResponsesProvider.complete()
        • OpenAIResponsesProvider.add_results()
        • OpenAIResponsesProvider.estimated_input_tokens()
      • AnthropicMessagesProvider
        • AnthropicMessagesProvider.provider
        • AnthropicMessagesProvider.__init__()
        • AnthropicMessagesProvider.start()
        • AnthropicMessagesProvider.complete()
        • AnthropicMessagesProvider.add_results()
        • AnthropicMessagesProvider.estimated_input_tokens()
      • ScriptedProvider
        • ScriptedProvider.provider
        • ScriptedProvider.__init__()
        • ScriptedProvider.start()
        • ScriptedProvider.complete()
        • ScriptedProvider.add_results()
        • ScriptedProvider.estimated_input_tokens()
      • ModelProvider
        • ModelProvider.provider
        • ModelProvider.model
        • ModelProvider.max_output_tokens
        • ModelProvider.start()
        • ModelProvider.complete()
        • ModelProvider.add_results()
        • ModelProvider.estimated_input_tokens()
        • ModelProvider.__init__()
      • AgentRun
        • AgentRun.status
        • AgentRun.calls
        • AgentRun.final_answer
        • AgentRun.turns
        • AgentRun.input_tokens
        • AgentRun.output_tokens
        • AgentRun.cost_usd
        • AgentRun.stop_reason
        • AgentRun.error
        • AgentRun.duration_s
        • AgentRun.guard_denials
        • AgentRun.trace()
        • AgentRun.__init__()
      • AgentSpec
        • AgentSpec.name
        • AgentSpec.server
        • AgentSpec.arms
        • AgentSpec.tasks
        • AgentSpec.repetitions
        • AgentSpec.seed
        • AgentSpec.budget
        • AgentSpec.limits
        • AgentSpec.guard
        • AgentSpec.verify
        • AgentSpec.allow_tools
        • AgentSpec.output
        • AgentSpec.base_dir
        • AgentSpec.cells()
        • AgentSpec.__init__()
      • Budget
        • Budget.max_usd
        • Budget.allow_unknown_price
        • Budget.spent_usd
        • Budget.unknown_cost_turns
        • Budget.turn_cost()
        • Budget.projected()
        • Budget.allows()
        • Budget.__init__()
      • Limits
        • Limits.max_turns
        • Limits.max_calls
        • Limits.__init__()
      • Price
        • Price.input
        • Price.output
        • Price.source
        • Price.__init__()
      • GuardCall
        • GuardCall.tool
        • GuardCall.arguments
        • GuardCall.task_id
        • GuardCall.arm_id
        • GuardCall.index
        • GuardCall.__init__()
      • GuardDecision
        • GuardDecision.allowed
        • GuardDecision.reason
        • GuardDecision.__init__()
      • UnknownPriceError
      • BuildMismatchError
  • Contracts, Receipts, Evidence, Statistics and Export
    • Contracts
      • evaluate_contract()
      • load_contract()
      • contract_from_mapping()
      • is_contract()
      • matcher_from_json()
      • split_optional()
      • Contract
        • Contract.required
        • Contract.optional
        • Contract.forbidden
        • Contract.weights
        • Contract.min_score
        • Contract.groups
        • Contract.expansions()
        • Contract.__init__()
      • AlternativeGroup
        • AlternativeGroup.id
        • AlternativeGroup.options
        • AlternativeGroup.__init__()
    • Receipts and regrade
      • build_receipt()
      • write_receipt()
      • load_receipt()
      • verify_receipt()
      • regrade()
      • Regrade
        • Regrade.source
        • Regrade.result
        • Regrade.receipt
        • Regrade.previous
        • Regrade.problems
        • Regrade.score_delta
        • Regrade.__init__()
      • ReceiptMismatchError
      • canonical_json()
      • json_sha256()
      • file_digest()
    • Evidence
      • STATES
      • Check
        • Check.check
        • Check.status
        • Check.detail
        • Check.__init__()
      • tally()
      • summary_line()
      • tri_state()
      • evaluation_evidence()
    • Statistics and selection
      • wilson_interval()
      • fisher_exact()
      • pass_hat_k()
      • compare_runs()
      • load_runs()
      • runs_from_traces()
      • run_from_row()
      • select_variant()
      • pareto_front()
      • evaluate_protocol()
      • load_protocol()
      • Run
        • Run.variant
        • Run.task
        • Run.outcome
        • Run.cost
        • Run.latency
        • Run.run_id
        • Run.__init__()
      • VariantStats
        • VariantStats.variant
        • VariantStats.n
        • VariantStats.counts
        • VariantStats.pass_rate
        • VariantStats.interval
        • VariantStats.pass_hat_k
        • VariantStats.k
        • VariantStats.tasks
        • VariantStats.tasks_short
        • VariantStats.cost
        • VariantStats.cost_known
        • VariantStats.latency
        • VariantStats.latency_known
        • VariantStats.metric()
        • VariantStats.__init__()
      • Comparison
        • Comparison.variants
        • Comparison.pairs
        • Comparison.k
        • Comparison.min_n
        • Comparison.alpha
        • Comparison.notes
        • Comparison.by_name()
        • Comparison.to_dict()
        • Comparison.__init__()
      • PairComparison
        • PairComparison.a
        • PairComparison.b
        • PairComparison.difference
        • PairComparison.p_value
        • PairComparison.overlap
        • PairComparison.distinguishable
        • PairComparison.verdict
        • PairComparison.__init__()
      • Selection
        • Selection.chosen
        • Selection.policy
        • Selection.objectives
        • Selection.ranking
        • Selection.pareto_front
        • Selection.scores
        • Selection.unknown
        • Selection.reason
        • Selection.to_dict()
        • Selection.__init__()
      • ProtocolResult
        • ProtocolResult.title
        • ProtocolResult.protocol_sha256
        • ProtocolResult.baseline
        • ProtocolResult.candidate
        • ProtocolResult.rules
        • ProtocolResult.decision
        • ProtocolResult.to_dict()
        • ProtocolResult.__init__()
    • Export
      • export_records()
      • write_export()
      • validate_record()
      • record_from_run()
      • SCHEMA_VERSION
    • Doctor
      • run_doctor()
      • check_server()
      • doctor_report()
      • DoctorCheck
        • DoctorCheck.name
        • DoctorCheck.status
        • DoctorCheck.detail
        • DoctorCheck.__init__()
  • Validators Module
    • HTTP Validator
      • HTTPValidator
        • HTTPValidator.__init__()
        • HTTPValidator.validate()
    • Filesystem Validator
      • FileSystemValidator
        • FileSystemValidator.__init__()
        • FileSystemValidator.validate()
    • SQL Validator
      • SQLValidator
        • SQLValidator.__init__()
        • SQLValidator.validate()
  • Reports Module
    • JSON Reports
      • generate_json_report()
    • HTML Reports
      • generate_html_report()
    • Markdown and CSV Reports
      • generate_markdown_report()
      • generate_csv_report()
    • Behavior and Safety Findings
      • behavior_findings()
    • SARIF and JUnit
      • STATUSES
      • Outcome
        • Outcome.check
        • Outcome.status
        • Outcome.message
        • Outcome.subject
        • Outcome.location
        • Outcome.line
        • Outcome.fix
        • Outcome.__init__()
      • rule_description()
      • default_location()
      • to_sarif()
      • to_junit()
      • write_ci_reports()
      • outcomes_from_lint()
      • outcomes_from_scorecard()
      • outcomes_from_pin()
      • outcomes_from_diff()
      • outcomes_from_config_lint()
      • outcomes_from_honesty()
      • outcomes_from_evaluation()
      • ci_report_options()

Development

  • Contributing
    • Development Setup
    • Code Style
    • Type Hints
    • Testing
    • Commit Messages
    • Pull Request Process
    • Adding New Features
      • Adding a New Trace Adapter
      • Adding a New Metric
      • Adding a New Validator
    • Documentation
    • Questions?
    • Code of Conduct
    • License
  • Changelog
    • Unreleased
    • 1.11.0 - 2026-11-03
      • Highlights
      • Added
        • MCP
        • Effect probes (toolscore.mcp.probes)
        • Honesty checks (toolscore.metrics.honesty)
        • Fault injection (toolscore.mcp.faults)
        • Agent harness (toolscore.mcp.agent)
        • Pinning and diffs (toolscore.mcp.pin, toolscore.mcp.server_diff, toolscore.mcp.snapshot)
        • Contracts, receipts and evidence
        • Runs, selection, export and doctor
        • Agents in the wild
        • Agent-config lint
        • Claude Code plugin and demo
        • Examples
        • SARIF and JUnit (toolscore.reports.ci)
        • pre-commit
        • GitHub Action
        • Integrations
        • Models and prices
      • Changed
      • Fixed
    • 1.10.0 - 2026-10-03
      • Highlights
      • Added
        • Traces keep what happened
        • Behavior and safety
        • GitHub Action
        • Examples
        • MCP
        • Integrations
      • Fixed
      • Notes
    • 1.9.1 - 2026-10-01
      • Fixed
      • Known limitation
    • 1.9.0 - 2026-09-28
      • Added
      • Fixed
    • 1.8.1 - 2026-06-19
      • Highlights
      • Added
        • Snapshot Testing
        • MCP Scorecard
        • Fluent API, Matchers & Diffs
        • Framework & Async Support
        • Multi-Provider LLM Judge
        • Scaffolding & Quality
      • Changed
      • Fixed
    • 1.6.0
      • Added - Instant Value: Zero-Friction API
        • Auto-Detect Provider Responses
        • End-to-End Agent Testing
        • Data-Driven Pytest Decorator
    • 1.5.0
      • Added - In-Memory API, Integration Helpers & Simplified Output
        • In-Memory Python API
        • Integration Helpers (toolscore.integrations)
        • Simplified CLI Output
        • README & Positioning
    • 1.4.0 - 2026-01-09
      • Added - Self-Explaining Metrics, Regression Testing & GitHub Action
        • Self-Explaining Metrics
        • Regression Testing (toolscore regression)
        • GitHub Action
      • Changed
      • New Files
    • 1.2.0 - 2025-10-28
      • Added - 🎯 Multi-Provider Support & Export Formats
        • 🤖 Google Gemini Adapter
        • 📊 CSV Export (--csv)
        • 📝 Markdown Export (--markdown)
        • 💰 LLM Cost Estimation
        • 🔧 CI/CD Integration Template
        • 🛤️ Trajectory Evaluation
        • 🔌 MCP (Model Context Protocol) Adapter
        • 📦 Production Trace Capture
        • 🔍 Enhanced State Validators
      • Changed
      • Testing
    • 1.1.0 - 2025-10-18
      • Added - 🎯 Week 2: Major UX & Developer Experience Improvements
        • 🚀 Zero-Friction Onboarding (toolscore init)
        • ⚡ Synthetic Test Generator (toolscore generate)
        • 📊 Quick Compare (toolscore compare)
        • 🔍 Interactive Debug Mode (--debug)
        • 💡 Actionable Error Messages
      • Added - 🎯 Week 1: Core Evaluation Features
        • Tool Correctness Metric
        • Integrated LLM-as-a-Judge
        • Parameter Schema Validation
        • Example Datasets
      • Added - 🎯 Previous Features
      • Changed
      • Fixed
    • 0.1.0 - 2025-10-13
      • Added
      • Documentation
Toolscore
  • Python Module Index

Python Module Index

t
 
t
- toolscore
    toolscore.config_lint
    toolscore.evidence
    toolscore.inspect_scorer
    toolscore.matchers
    toolscore.models
    toolscore.recorders
    toolscore.reports.ci
    toolscore.sessions

© Copyright 2025-2026, Yotam Braun.

Built with Sphinx using a theme provided by Read the Docs.