# Overmind Client
[](https://github.com/overmind-core/overmind-python/actions/workflows/publish.yml)
[](https://pypi.org/project/overmind/)
A client for the Overmind API that provides easy access to AI provider endpoints with policy enforcement.
## Features
- **Easy Integration**: Use major providers like OpenAI with the same call signatures
- **Policy Enforcement**: Apply customizable policies to your LLM inputs and outputs
- **Observability**: Log and explore all LLM calls and policy results
## Installation
```bash
pip install overmind
```
## Quick Start
### Use Overmind Proxy
Get your free Overmind API key at [console.overmindlab.ai](https://console.overmindlab.ai)
Below we initialise the Overmind client and call GPT-5-mini with `anonymize_pii` and `reject_irrelevant_answer` policies. This will prevent PII data leakage and ensure only relevant answers are produced.
```python
import os
from overmind.client import OvermindClient
# Set env variables (or pass directly to the client)
# Get your free overmind API key at console.overmindlab.ai
os.environ["OVERMIND_API_KEY"] = "your_overmind_api_key"
os.environ["OPENAI_API_KEY"] = "your_openai_api_key"
overmind = OvermindClient()
# Use existing OpenAI client methods
response = overmind.openai.responses.create(
model='gpt-5-mini',
input="Should I switch my mortgage now or wait for a year to have a lower interest rate?",
# Overmind built-in policies
input_policies=['anonymize_pii'],
output_policies=['reject_irrelevant_answer'],
)
response.summary()
```
### Define your own policies
There are different policy templates that can be set up at invocation time.
```python
# Define input policy to filter out PII
input_pii_policy = {
'policy_template': 'anonymize_pii',
'parameters': {
'pii_types': ['DEMOGRAPHIC_DATA', 'FINANCIAL_ID']
}
}
# Define output policy to check response against criteria
output_llm_judge_criteria = {
'policy_template': 'reject_llm_judge_with_criteria',
'parameters': {
'criteria': [
"Must not be a financial advice",
"Must answer the question fully",
]
}
}
input_messages = [
{
"role": "user",
"content": "Hi my name is Jon, account number 20194812. Should I switch my mortgage now or wait for a year to have a lower interest rate?"
}
]
result = overmind.openai.responses.create(
model='gpt-5-mini',
input=input_messages,
input_policies=[input_pii_policy],
output_policies=[output_llm_judge_criteria]
)
result.summary()
```
### Use Overmind Layers
For more complex use cases you can choose Overmind Layers - an API to call standalone policies without relying on us to call LLMs.
This use case is best demonstrated in our [LangGraph integration tutorial](https://github.com/overmind-core/overmind-python/blob/main/docs/Overmind%20Layers%20%26%20LangGraph%20tutorial.ipynb), although the Layers can be used with any framework.
## Further usage
There are a more detailed tutorials available for [Overmind Proxy](https://github.com/overmind-core/overmind-python/blob/main/docs/Overmind%20Proxy%20tutorial.ipynb) and [Overmind Layers & LangGraph integration](https://github.com/overmind-core/overmind-python/blob/main/docs/Overmind%20Layers%20%26%20LangGraph%20tutorial.ipynb).
We are not storing your API keys and you are solely responsible for managing them and the associated costs.
On our side we run policy executions for free as this is an alpha stage product. We may impose usage limits and scale our services up and down from time to time.
We appreciate any feedback, collaboration or other suggestions. You can reach out at [support@evallab.dev](mailto:support@evallab.dev)
Raw data
{
"_id": null,
"home_page": null,
"name": "overmind",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": "overmind, ai, api, client, policy, enforcement",
"author": "Overmind Ltd",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/f5/89/7cb2b12ba3c52eae423132d6d9ee9d61cb3dea52407bc924f62d11fda9ab/overmind-0.1.14.tar.gz",
"platform": null,
"description": "# Overmind Client\n\n[](https://github.com/overmind-core/overmind-python/actions/workflows/publish.yml)\n[](https://pypi.org/project/overmind/)\n\nA client for the Overmind API that provides easy access to AI provider endpoints with policy enforcement.\n\n## Features\n\n- **Easy Integration**: Use major providers like OpenAI with the same call signatures\n- **Policy Enforcement**: Apply customizable policies to your LLM inputs and outputs\n- **Observability**: Log and explore all LLM calls and policy results\n\n## Installation\n\n\n\n```bash\npip install overmind\n```\n\n\n## Quick Start\n\n### Use Overmind Proxy\n\nGet your free Overmind API key at [console.overmindlab.ai](https://console.overmindlab.ai)\n\nBelow we initialise the Overmind client and call GPT-5-mini with `anonymize_pii` and `reject_irrelevant_answer` policies. This will prevent PII data leakage and ensure only relevant answers are produced.\n```python\nimport os\nfrom overmind.client import OvermindClient\n\n# Set env variables (or pass directly to the client)\n# Get your free overmind API key at console.overmindlab.ai\nos.environ[\"OVERMIND_API_KEY\"] = \"your_overmind_api_key\"\nos.environ[\"OPENAI_API_KEY\"] = \"your_openai_api_key\"\n\novermind = OvermindClient()\n\n\n# Use existing OpenAI client methods\nresponse = overmind.openai.responses.create(\n model='gpt-5-mini',\n input=\"Should I switch my mortgage now or wait for a year to have a lower interest rate?\",\n # Overmind built-in policies\n input_policies=['anonymize_pii'],\n output_policies=['reject_irrelevant_answer'],\n)\n\nresponse.summary()\n```\n\n\n\n### Define your own policies\nThere are different policy templates that can be set up at invocation time.\n```python\n\n# Define input policy to filter out PII\ninput_pii_policy = {\n 'policy_template': 'anonymize_pii',\n 'parameters': {\n 'pii_types': ['DEMOGRAPHIC_DATA', 'FINANCIAL_ID']\n }\n}\n\n# Define output policy to check response against criteria\noutput_llm_judge_criteria = {\n 'policy_template': 'reject_llm_judge_with_criteria',\n 'parameters': {\n 'criteria': [\n \"Must not be a financial advice\",\n \"Must answer the question fully\",\n ]\n }\n}\n\ninput_messages = [\n {\n \"role\": \"user\", \n \"content\": \"Hi my name is Jon, account number 20194812. Should I switch my mortgage now or wait for a year to have a lower interest rate?\"\n }\n]\n\nresult = overmind.openai.responses.create(\n model='gpt-5-mini',\n input=input_messages,\n input_policies=[input_pii_policy],\n output_policies=[output_llm_judge_criteria]\n)\n\nresult.summary()\n```\n### Use Overmind Layers\n\nFor more complex use cases you can choose Overmind Layers - an API to call standalone policies without relying on us to call LLMs. \n\nThis use case is best demonstrated in our [LangGraph integration tutorial](https://github.com/overmind-core/overmind-python/blob/main/docs/Overmind%20Layers%20%26%20LangGraph%20tutorial.ipynb), although the Layers can be used with any framework.\n\n## Further usage\n\nThere are a more detailed tutorials available for [Overmind Proxy](https://github.com/overmind-core/overmind-python/blob/main/docs/Overmind%20Proxy%20tutorial.ipynb) and [Overmind Layers & LangGraph integration](https://github.com/overmind-core/overmind-python/blob/main/docs/Overmind%20Layers%20%26%20LangGraph%20tutorial.ipynb).\n\nWe are not storing your API keys and you are solely responsible for managing them and the associated costs.\n\nOn our side we run policy executions for free as this is an alpha stage product. We may impose usage limits and scale our services up and down from time to time.\n\nWe appreciate any feedback, collaboration or other suggestions. You can reach out at [support@evallab.dev](mailto:support@evallab.dev)\n",
"bugtrack_url": null,
"license": null,
"summary": "Python client for Overmind API",
"version": "0.1.14",
"project_urls": {
"Homepage": "https://github.com/overmind-core/overmind-python",
"Repository": "https://github.com/overmind-core/overmind-python"
},
"split_keywords": [
"overmind",
" ai",
" api",
" client",
" policy",
" enforcement"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "dc820bb05ca3ab7936c55e50606537884ca468b10255d7e019767f3f0b604835",
"md5": "8ab595e0556a4bd0521ee1013041d3e6",
"sha256": "19bf9ad0b6cacc02adedb4ec69f7449254c112fac4965f956ba92fdb9c125889"
},
"downloads": -1,
"filename": "overmind-0.1.14-py3-none-any.whl",
"has_sig": false,
"md5_digest": "8ab595e0556a4bd0521ee1013041d3e6",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 15744,
"upload_time": "2025-08-27T18:09:38",
"upload_time_iso_8601": "2025-08-27T18:09:38.532296Z",
"url": "https://files.pythonhosted.org/packages/dc/82/0bb05ca3ab7936c55e50606537884ca468b10255d7e019767f3f0b604835/overmind-0.1.14-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "f5897cb2b12ba3c52eae423132d6d9ee9d61cb3dea52407bc924f62d11fda9ab",
"md5": "028d7aa50670a502ce65d32607590d71",
"sha256": "be50b6de8fc163b047e86ce76a5508eb90b8cba3a165de5baa4487dabf28b9c0"
},
"downloads": -1,
"filename": "overmind-0.1.14.tar.gz",
"has_sig": false,
"md5_digest": "028d7aa50670a502ce65d32607590d71",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 12731,
"upload_time": "2025-08-27T18:09:39",
"upload_time_iso_8601": "2025-08-27T18:09:39.744409Z",
"url": "https://files.pythonhosted.org/packages/f5/89/7cb2b12ba3c52eae423132d6d9ee9d61cb3dea52407bc924f62d11fda9ab/overmind-0.1.14.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-27 18:09:39",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "overmind-core",
"github_project": "overmind-python",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "overmind"
}