Metadata-Version: 2.5
Name: truvelocity-tevv
Version: 2026.11.20.3
Summary: TruVelocity for AI TEVV: black-box, evidence-based test, evaluation, verification and validation of AI agents (chat, task and multi-agent).
Author: Innominds
License-Expression: LicenseRef-Innominds-Proprietary
License-File: LICENSE
Classifier: Development Status :: 5 - Production/Stable
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Quality Assurance
Classifier: Topic :: Software Development :: Testing
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: jsonschema>=4.21
Requires-Dist: pyyaml>=6.0
Provides-Extra: anthropic
Requires-Dist: anthropic>=0.40; extra == 'anthropic'
Provides-Extra: azure
Requires-Dist: openai>=1.40; extra == 'azure'
Provides-Extra: azure-blob
Requires-Dist: azure-identity>=1.15; extra == 'azure-blob'
Requires-Dist: azure-storage-blob>=12.19; extra == 'azure-blob'
Provides-Extra: chat
Requires-Dist: websockets>=12; extra == 'chat'
Provides-Extra: dev
Requires-Dist: build>=1.2; extra == 'dev'
Requires-Dist: fastapi>=0.115; extra == 'dev'
Requires-Dist: httpx>=0.27; extra == 'dev'
Requires-Dist: langgraph>=0.2; extra == 'dev'
Requires-Dist: mcp>=2.3; extra == 'dev'
Requires-Dist: mypy>=1.11; extra == 'dev'
Requires-Dist: openpyxl>=3.1; extra == 'dev'
Requires-Dist: psycopg[binary]>=3.2; extra == 'dev'
Requires-Dist: pymysql>=1.1; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24; extra == 'dev'
Requires-Dist: pytest-cov>=5.0; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.6; extra == 'dev'
Requires-Dist: sqlalchemy>=2.0; extra == 'dev'
Requires-Dist: starlette>=0.37; extra == 'dev'
Requires-Dist: types-jsonschema>=4.21; extra == 'dev'
Requires-Dist: types-openpyxl>=3.1; extra == 'dev'
Requires-Dist: types-pyyaml>=6.0; extra == 'dev'
Requires-Dist: uvicorn>=0.30; extra == 'dev'
Requires-Dist: websockets>=12; extra == 'dev'
Provides-Extra: kafka
Requires-Dist: confluent-kafka>=2.3; extra == 'kafka'
Provides-Extra: langgraph
Requires-Dist: langgraph>=0.2; extra == 'langgraph'
Provides-Extra: mcp
Requires-Dist: mcp>=2.3; extra == 'mcp'
Provides-Extra: mysql
Requires-Dist: pymysql>=1.1; extra == 'mysql'
Requires-Dist: sqlalchemy>=2.0; extra == 'mysql'
Provides-Extra: oracle
Requires-Dist: oracledb>=2.0; extra == 'oracle'
Requires-Dist: sqlalchemy>=2.0; extra == 'oracle'
Provides-Extra: otel
Requires-Dist: starlette>=0.37; extra == 'otel'
Requires-Dist: uvicorn>=0.30; extra == 'otel'
Provides-Extra: postgres
Requires-Dist: psycopg[binary]>=3.2; extra == 'postgres'
Requires-Dist: sqlalchemy>=2.0; extra == 'postgres'
Provides-Extra: proxy
Requires-Dist: httpx>=0.27; extra == 'proxy'
Requires-Dist: starlette>=0.37; extra == 'proxy'
Requires-Dist: uvicorn>=0.30; extra == 'proxy'
Provides-Extra: s3
Requires-Dist: boto3>=1.34; extra == 's3'
Provides-Extra: servicebus
Requires-Dist: azure-identity>=1.15; extra == 'servicebus'
Requires-Dist: azure-servicebus>=7.11; extra == 'servicebus'
Provides-Extra: sql
Requires-Dist: sqlalchemy>=2.0; extra == 'sql'
Provides-Extra: sqlserver
Requires-Dist: pyodbc>=5.1; extra == 'sqlserver'
Requires-Dist: sqlalchemy>=2.0; extra == 'sqlserver'
Provides-Extra: ui
Requires-Dist: openpyxl>=3.1; extra == 'ui'
Description-Content-Type: text/markdown

# TruVelocity™ for AI TEVV

**Know what your AI agents actually did, not just what they said.**

TruVelocity™ is a black-box, evidence-based test, evaluation, verification and validation (TEVV) framework for AI
agents: chat assistants, task
agents (LangGraph, OpenAI Agents SDK, custom loops) and multi-agent workflows. It judges every checkpoint on
independent evidence (the agent's tool calls as a recording proxy saw them, its handoffs, the data it changed)
and compares that with what the agent claims. It runs the same scenarios under injected faults, rephrasings and
repeats, and turns the results into release decisions.

```bash
pip install truvelocity-tevv                    # the tv / truvelocity-tevv commands and the library
pip install "truvelocity-tevv[mcp,proxy,otel]"  # plus the MCP server, the recording proxy and A2A tap, the OTel receiver
```

Python 3.11 or later, on Windows, Linux or macOS. © Innominds. All rights reserved.

`tv --version` also tells you when a newer release is on PyPI, and the command to upgrade (one anonymous request to
pypi.org with a 2-second limit; silent when offline; `TV_NO_UPDATE_CHECK=1` turns it off, and it is off when `CI` is set).

## Five minutes, offline

```bash
tv demo                               # the whole tour on a scripted agent: no Docker, no LLM, no network
tv console --runs-dir tv_demo --open  # browse the runs, reports, comparisons and gates
tv docs --open                        # the full guide, shipped inside the package
```

## Practise on a real LLM agent

```bash
tv practice-project                   # an expense desk agent to onboard: catalog, Context, Docker Compose file, guide
cd expense-desk-practice              # put your LLM key in .env, then:
docker compose up -d --wait           # the agent, its tools and TruVelocity's recording proxy (Docker Desktop)
tv ui --allow-runs --open             # all six steps to a release decision; TruVelocity-Onboard-a-New-Agent.html guides you
```

No Docker: `pip install "harbor-expense-agent[all]" "truvelocity-tevv[ui,proxy]"`, then `tv practice-agent` in the project
folder (leave it running) instead of `docker compose`. No LLM key: `tv practice-project --scripted`, whose `.env` runs the
agent's offline rule-based model (`DEFAULT_LLM_PROVIDER=SCRIPTED`, `LLM_SCRIPT=expense_agent.policy:factory`): no LLM
call, no cost, the same steps and planted defects.

## Test your own agent

```bash
tv new task my-agent-tests            # or: tv new workflow ... / tv new chat ...
cd my-agent-tests                     # catalog.yaml, environment.py, truvelocity-tevv-gate.yaml, .env.example, README.md
tv validate catalog.yaml
tv run catalog.yaml --env environment:environment --repeats 3 --perturbations all
tv report latest
tv gate latest --policy truvelocity-tevv-gate.yaml
tv init --ci github --catalog catalog.yaml --env environment:environment   # or --ci azure
```

## Enterprise systems

```bash
pip install "truvelocity-tevv[postgres]"     # or [sqlserver], [mysql], [oracle], [sql] for SQLAlchemy alone
```

```python
from truvelocity_tevv.adapters.state.factory import make_state
from truvelocity_tevv.adapters.drivers.queue import QueueDriver, ServiceBusTransport
from truvelocity_tevv.profiles.task import task_environment


def environment(worker):
    return task_environment(
        name="claims",
        driver=QueueDriver(ServiceBusTransport.from_env(), request="claims-events", reply="claims-results"),
        state=[
            make_state("oracle+oracledb://reader:***@db:1521/?service_name=CLAIMS", schema="CLAIMS"),
            make_state("https://crm.test.example/api", resources={"cases": "/cases"}),
        ],
    )
```

Any SQL database SQLAlchemy supports, read-only, with tables and keys found by reflection. A factory picks the
adapter from a URL or path. There are drivers for HTTP, chat, OpenAI-compatible endpoints, Azure Service Bus and
Kafka. `tv library` lists reusable scenario packs (privacy, prompt injection, unsafe writes, payments and
approvals, identity across handoffs, conversation handling, answers and boundaries, tone and policy) that a catalog
includes with its own parameters; each tags its scenarios with catalogue test types.

## Across initiatives

```bash
pip install "truvelocity-tevv[s3]"           # or [azure-blob], or [postgres] etc. for a database store; a folder needs nothing
tv push                               # share the latest run (store, initiative and team in truvelocity-tevv.yaml)
tv run catalog.yaml --env environment:environment --publish
tv portfolio --store s3://quality-results/truvelocity_tevv --csv portfolio.csv
tv console --store s3://quality-results/truvelocity_tevv --open
```

The portfolio shows every initiative and project: the latest gate verdict, pass rate, pass^k, open defects by
severity, the trend, and each run's report. Nothing is shared without `tv push` or `--publish`.

The starter project connects to an agent behind HTTP. Put `tv proxy` in front of the agent's tools, and
`tv a2a` between its agents, to get an independent record of every call and handoff and to inject faults.

## How an agent is judged

Each checkpoint is judged at five stages, and TruVelocity™ reports the first one that failed:

| Stage | Question |
|---|---|
| goal | Did it understand the request? |
| plan | Was its course sensible (steps, loops, handoffs, approvals before writes)? |
| action | Did it take only allowed, correct actions, with the right arguments, for the right person? |
| end state | Is the data right afterwards, and did nothing else change? |
| output | Is what it told the user true, complete and consistent with what it did? |

Seven **evidence seams** (SE-01 to SE-07) catch the failures an agent's own account hides. Examples: a call it
reported that never happened, a write it never mentioned, success announced after a failure, a handoff that
carries another customer's identity, and a different deployment that behaves differently.

## What you get

- **Profiles:** conversational, task and workflow (handoffs, identity on every hop, failure containment).
- **Reliability:** repeats and perturbations, pass^k, robustness and flaky detection, plus fault injection in
  the tool server's own format.
- **Change:** run-by-run comparison, and deployment parity (model, host, framework) judged against
  run-to-run noise.
- **Governance:**
  - defect lists (JSON and CSV) and JUnit for CI;
  - capability packs and a release gate with per-capability thresholds;
  - a 71-type test scorecard, with each type's catalogue metrics measured or marked not measured;
  - grader calibration (Cohen's kappa), and rubric grading for tone and written policy.
- **Reports:** a customer-facing execution report (`execution-report.html` and `.json`): a readiness statement,
  KPI cards and charts, test-type and test-data coverage, persona views, findings with evidence and next actions,
  and the trend against the previous comparable run; personal details masked. Plus the one-file engineering report.
- **Sharing:** a local token-protected console and a shared store across initiatives.
- **Automation:** `tv mcp` gives an AI assistant one tool per command. GitHub Actions and Azure DevOps
  templates come from `tv init`.
- **Security defaults:**
  - listeners bind to 127.0.0.1 and need tokens;
  - secrets come only from the environment or `.env` and are never printed;
  - personal data is masked before evidence is stored, and retention is enforced.

## MCP server

`tv mcp` (install the `mcp` extra) gives an AI assistant one tool per command over stdio. Claude Code:

```bash
claude mcp add truvelocity_tevv -- tv mcp
```

Claude Desktop and other `mcpServers` clients:

```json
{ "mcpServers": { "truvelocity_tevv": { "command": "tv", "args": ["mcp"] } } }
```

Every tool result is marked as data, never instructions, because it can quote what an agent said.

## Commands

| Command | Purpose |
|---|---|
| `demo`, `new`, `docs` | The offline tour, a starter project, the guide |
| `library` | The scenario library: list packs, show one, add it to a catalog |
| `push`, `pull`, `portfolio` | Share runs to a folder, S3 or Azure Blob store; copy them back; the cross-initiative view |
| `validate`, `translate` | Check catalogs; convert a suite catalog |
| `run`, `show`, `report`, `gc` | Run a catalog; inspect runs; the engineering and execution reports; retention |
| `compare`, `defects`, `junit`, `scorecard`, `pack`, `gate`, `calibrate` | Run-level analysis and governance |
| `init` | A CI pipeline that runs, reports and gates |
| `console`, `mcp` | The browser console; the MCP server |
| `proxy`, `a2a`, `otel` | Observers: recording MCP proxy, agent-to-agent tap, OpenTelemetry receiver |

`tv <command> --help` lists every option. Examples use fictitious data (Harbor Mutual).
