Skip to main content

TypeSafe plugin for LiveKit Agents

Support for TypeSafe Jev decision models. Jev evaluates probability questions, named choices, and ordered scores over a conversation in one request.

Installation

pip install livekit-plugins-typesafe

Pre-requisites

Set TYPESAFE_API_KEY for the TypeSafe API, or OPENROUTER_API_KEY to use Jev through OpenRouter's Decisions API.

Usage

from livekit.agents import llm, utils
from livekit.plugins import typesafe

async with utils.http_context.open():
    model = typesafe.DecisionModel(model="jev-latest")
    # or: typesafe.DecisionModel.with_openrouter()
    context = llm.ChatContext.empty()
    context.add_message(role="user", content="Please let me speak to a person.")
    response = await model.evaluate(
        input=context,
        decisions={
            "handoff": llm.Probability("The caller requests a human."),
            "intent": llm.Choice(
                "What does the caller want?",
                options={"booking": "Make a reservation", "other": "Anything else"},
            ),
            "frustration": llm.Score(
                "How frustrated is the caller?", levels=["Calm", "Annoyed", "Angry"]
            ),
        },
    )
    for name, result in response.results.items():
        print(name, result.value)

input also accepts a string, which is sent as-is. Each requested decision appears in either response.results or response.errors. Request failures and malformed responses raise.

Models

jev-latest is the most recent stable release and jev-preview the most recent release overall; TypeSafe moves both aliases as new versions ship. Pin jev-1.14.0 or jev-1.13.0 for a fixed version.

Notes

  • Jev rounds probabilities and scores to two decimal places. Results keep the provider's values.
  • Score answers must return a legend that matches the requested levels.
  • provider_data["confidence"] describes how concentrated the distribution is, not the probability that the answer is correct.
  • A conversation is sent as a role: text transcript of user and assistant messages. System and developer messages, agent instructions, and non-text content are never sent.

Metadata

Release files for livekit-plugins-typesafe 1.8.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for livekit-plugins-typesafe 1.8.10
File Size Uploaded Provenance Actions
livekit_plugins_typesafe-1.8.10.tar.gz 5.8 kB With provenance Details for livekit_plugins_typesafe-1.8.10.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for livekit-plugins-typesafe 1.8.10
File Interpreter ABI Platform Actions
livekit_plugins_typesafe-1.8.10-py3-none-any.whl Python 3 none any Details for livekit_plugins_typesafe-1.8.10-py3-none-any.whl

Total release size: 12.0 kB

Release files / livekit_plugins_typesafe-1.8.10.tar.gz

Download URL livekit_plugins_typesafe-1.8.10.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
7c257f9c7288e755ffdbd4869d68ab40e68f045d7cd0c3af35bb26450283db12
BLAKE2b-256 checksum
How to use checksums
c87451c4c95417cd9559acc01d3b79decd672836c5bcb7f88877026c2139749e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

Release files / livekit_plugins_typesafe-1.8.10-py3-none-any.whl

Download URL livekit_plugins_typesafe-1.8.10-py3-none-any.whl
Size 6.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a6f95c669ef11e79f3fcc9bcee03b76cfaae0fd495636d4a712e0f4fa6a6c887
BLAKE2b-256 checksum
How to use checksums
22c314de5156693084a3a17205be3c365eca8c4968eb3b57ea2d1c7ccf9dad2d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

Security for livekit-plugins-typesafe 1.8.10

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for livekit_plugins_typesafe-1.8.10.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page