SDK for testing and validating LLM applications
Project description
Rhesis SDK 🧠
Your team defines expectations, Rhesis generates and executes thousands of test scenarios. So that you know what you ship.
The Rhesis SDK empowers developers to programmatically access curated test sets and generate comprehensive test scenarios for Gen AI applications. Transform domain expertise into automated testing: access thousands of test scenarios, generate custom validation suites, and integrate seamlessly into your workflow to keep your Gen AI robust, reliable & compliant.
📑 Table of Contents
- Features
- Installation
- Getting Started
- Quick Start
- About Rhesis AI
- Community
- Hugging Face
- Support
- License
✨ Features
The Rhesis SDK provides programmatic access to the Rhesis testing platform:
- Access Test Sets: Browse and load curated test sets across multiple domains and use cases
- Generate Test Scenarios: Create custom test sets from prompts, requirements, or domain knowledge
- Seamless Integration: Integrate testing into your CI/CD pipeline and development workflow
- Comprehensive Coverage: Scale your testing from dozens to thousands of scenarios
- Open Source: MIT-licensed with full transparency and community-driven development
🚀 Installation
Install the Rhesis SDK using pip:
pip install rhesis-sdk
🐍 Python Requirements
Rhesis SDK requires Python 3.10 or newer.
🏁 Getting Started
1. Obtain an API Key 🔑
- Visit https://app.rhesis.ai
- Sign up for a Rhesis account
- Navigate to your account settings
- Generate a new API key
Your API key will be in the format rh-XXXXXXXXXXXXXXXXXXXX. Keep this key secure and never share it publicly.
Note: On the Rhesis App, you can also create test sets for your own use cases and access them via the SDK. You only need to connect your GitHub account to create a test set.
2. Configure and use the SDK.
from pprint import pprint
from rhesis.sdk.entities import TestSet
from rhesis.sdk.synthesizers import PromptSynthesizer
os.environ["RHESIS_API_KEY"] = "rh-your-api-key" # Get from app.rhesis.ai settings
os.environ["RHESIS_BASE_URL"] = "https://api.rhesis.ai" # optional
# Browse available test sets
for test_set in TestSet().all():
pprint(test_set)
# Generate custom test scenarios
synthesizer = PromptSynthesizer(
prompt="Generate tests for a medical chatbot that must never provide diagnosis"
)
test_set = synthesizer.generate(num_tests=10)
pprint(test_set.tests)
Generating Custom Test Sets 🛠️
If none of the existing test sets fit your needs, you can generate your own. You can check out app.rhesis.ai. There you can define requirements, scenarios and behaviors.
🧪 About Rhesis AI
Rhesis is an open-source testing platform that transforms how Gen AI teams validate their applications. Through collaborative test management, domain expertise becomes comprehensive automated testing: legal defines requirements, marketing sets expectations, engineers build quality, and everyone knows exactly how the Gen AI application performs before users do.
Key capabilities:
- Collaborative Test Management: Your entire team contributes requirements without writing code
- Automated Test Generation: Generate thousands of test scenarios from team expertise
- Comprehensive Coverage: Scale from dozens of manual tests to thousands of automated scenarios
- Edge Case Discovery: Find potential failures before your users do
- Compliance Validation: Ensure systems meet regulatory and ethical standards
Made in Potsdam, Germany 🇩🇪
Visit rhesis.ai to learn more about our platform and services.
👥 Community 💬
Join our Discord server to connect with other users and developers.
🤗 Hugging Face
You can also find us on Hugging Face. There, you can find our test sets across multiple use cases.
🆘 Support
For questions, issues, or feature requests:
- Documentation: docs.rhesis.ai
- Discord Community: discord.rhesis.ai
- GitHub Discussions: Community discussions
- Email: hello@rhesis.ai
- Issues: Report bugs or request features
📝 License
The Rhesis SDK is licensed under the MIT License - see the LICENSE file for details.
The SDK is completely open-source and freely available for use, modification, and distribution.
Made with ❤️ in Potsdam, Germany 🇩🇪
Learn more at rhesis.ai
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file rhesis_sdk-0.6.3.tar.gz.
File metadata
- Download URL: rhesis_sdk-0.6.3.tar.gz
- Upload date:
- Size: 490.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ebbda6bed72a7c1ccec891615e2a8b11b6fe1878fdef6d13141755761865d078
|
|
| MD5 |
5c9533ec374ca01ac450daa98b92e123
|
|
| BLAKE2b-256 |
eaa15433730e8f21c8251b580d75a884030bb9bdb47b96e64d21cca5a699f736
|
Provenance
The following attestation bundles were made for rhesis_sdk-0.6.3.tar.gz:
Publisher:
publish-sdk.yml on rhesis-ai/rhesis
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
rhesis_sdk-0.6.3.tar.gz -
Subject digest:
ebbda6bed72a7c1ccec891615e2a8b11b6fe1878fdef6d13141755761865d078 - Sigstore transparency entry: 919271112
- Sigstore integration time:
-
Permalink:
rhesis-ai/rhesis@fb050ed3b1f76419c52b9387c37bd9f6cf1494ef -
Branch / Tag:
refs/tags/sdk-v0.6.3 - Owner: https://github.com/rhesis-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-sdk.yml@fb050ed3b1f76419c52b9387c37bd9f6cf1494ef -
Trigger Event:
push
-
Statement type:
File details
Details for the file rhesis_sdk-0.6.3-py3-none-any.whl.
File metadata
- Download URL: rhesis_sdk-0.6.3-py3-none-any.whl
- Upload date:
- Size: 253.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5d8556e2f817dca534eb89925d393475c8914884a6ad8f7e2a56ee8d2c65d3f2
|
|
| MD5 |
5fbc376c3f05fe2672aacc40d3b89cc3
|
|
| BLAKE2b-256 |
e4c0e2c4153cdc73c91960f87e97b7ac36e85ba46096840262a33876203d7833
|
Provenance
The following attestation bundles were made for rhesis_sdk-0.6.3-py3-none-any.whl:
Publisher:
publish-sdk.yml on rhesis-ai/rhesis
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
rhesis_sdk-0.6.3-py3-none-any.whl -
Subject digest:
5d8556e2f817dca534eb89925d393475c8914884a6ad8f7e2a56ee8d2c65d3f2 - Sigstore transparency entry: 919271117
- Sigstore integration time:
-
Permalink:
rhesis-ai/rhesis@fb050ed3b1f76419c52b9387c37bd9f6cf1494ef -
Branch / Tag:
refs/tags/sdk-v0.6.3 - Owner: https://github.com/rhesis-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-sdk.yml@fb050ed3b1f76419c52b9387c37bd9f6cf1494ef -
Trigger Event:
push
-
Statement type: