Name | cryptex-ai JSON |
Version |
0.3.3
JSON |
| download |
home_page | None |
Summary | Zero-config temporal isolation for AI/LLM applications - Bulletproof secrets isolation with zero cognitive overhead |
upload_time | 2025-07-22 00:20:59 |
maintainer | None |
docs_url | None |
author | AnthemFlynn |
requires_python | >=3.11 |
license | MIT |
keywords |
ai
isolation
llm
mcp
secrets
security
|
VCS |
 |
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Cryptex-AI
<div align="center">
**Zero-config temporal isolation for AI/LLM applications**
*Bulletproof secrets isolation with zero cognitive overhead*
[](https://pypi.org/project/cryptex-ai/)
[](https://pypi.org/project/cryptex-ai/)
[](https://opensource.org/licenses/MIT)
[](https://github.com/AnthemFlynn/cryptex-ai/actions)
[](https://codecov.io/gh/AnthemFlynn/cryptex-ai)
[**Documentation**](https://anthemflynn.github.io/cryptex-ai/) | [**Examples**](./examples/) | [**PyPI**](https://pypi.org/project/cryptex-ai/) | [**Changelog**](./CHANGELOG.md)
</div>
---
## The Problem
AI/LLM applications face an impossible choice:
- **Expose secrets to AI** β Security nightmare π
- **Hide secrets completely** β Broken functionality π₯
## The Solution
Cryptex-ai provides **true temporal isolation** - AI services receive safe placeholders while your functions use real secrets through automatic call interception.
```python
from cryptex_ai import protect_secrets
# Works immediately - no config files required!
@protect_secrets(["openai_key"])
async def ai_tool(prompt: str, api_key: str) -> str:
# Function receives: real API key for processing
# AI service receives: {{OPENAI_API_KEY}} (intercepted)
import openai
return await openai.chat.completions.create(
model="gpt-4",
messages=[{"role": "user", "content": prompt}],
api_key=api_key # Real key for function, placeholder to AI
)
```
**One decorator line = complete temporal isolation** β¨
---
## π Key Features
- **π§ Zero Configuration**: Works immediately, no setup required
- **β‘ Built-in Patterns**: OpenAI, Anthropic, GitHub, file paths, databases
- **π‘οΈ Security First**: Zero dependencies, no config files, no parsing vulnerabilities
- **π High Performance**: <5ms sanitization, <10ms resolution
- **π Universal**: Works with any Python function - FastMCP, FastAPI, Django, Flask, etc.
- **π― True Isolation**: Monkey-patches AI libraries to intercept actual calls
- **π Simple API**: 95% of users need zero config, 5% get simple registration
---
## π¦ Installation
### Using pip (recommended)
```bash
pip install cryptex-ai
```
### Using uv (modern Python package manager)
```bash
uv add cryptex-ai
```
**Requirements**: Python 3.11+ β’ Zero dependencies
---
## β‘ Quick Start
### Zero-Config Protection (95% of users)
Cryptex works immediately with built-in patterns for common secrets:
```python
from cryptex_ai import protect_secrets
# Protect OpenAI API calls
@protect_secrets(["openai_key"])
async def ai_completion(prompt: str, api_key: str) -> str:
# AI context: "{{OPENAI_API_KEY}}"
# Function execution: "sk-real-key-here..."
return await openai.chat.completions.create(
model="gpt-4",
messages=[{"role": "user", "content": prompt}],
api_key=api_key
)
# Protect file operations
@protect_secrets(["file_path"])
async def read_file(file_path: str) -> str:
# AI context: "/{USER_HOME}/.../{filename}"
# Function execution: "/Users/alice/secrets/document.txt"
with open(file_path, 'r') as f:
return f.read()
# Protect multiple secrets at once
@protect_secrets(["github_token", "file_path", "database_url"])
async def process_data(repo_path: str, token: str, db_url: str) -> dict:
# All secrets automatically protected
data = await fetch_from_github(repo_path, token)
result = await process_ai_data(data)
await save_to_database(result, db_url)
return result
```
### Convenience Decorators
For common patterns, use convenience decorators:
```python
from cryptex_ai import protect_api_keys, protect_files, protect_all
@protect_api_keys() # Protects OpenAI + Anthropic keys
async def ai_function(openai_key: str, anthropic_key: str) -> str:
# Both API keys automatically protected
pass
@protect_files() # Protects file system paths
async def file_function(file_path: str) -> str:
# File paths automatically protected
pass
@protect_all() # Protects all built-in patterns
async def comprehensive_function(api_key: str, file_path: str, db_url: str) -> str:
# Everything automatically protected
pass
```
---
## π οΈ Built-in Patterns
Cryptex includes battle-tested patterns that handle **95% of real-world usage**:
| Pattern | Detects | Example | Placeholder |
|---------|---------|---------|-------------|
| `openai_key` | OpenAI API keys | `sk-...` | `{{OPENAI_API_KEY}}` |
| `anthropic_key` | Anthropic API keys | `sk-ant-...` | `{{ANTHROPIC_API_KEY}}` |
| `github_token` | GitHub tokens | `ghp_...` | `{{GITHUB_TOKEN}}` |
| `file_path` | User file paths | `/Users/...`, `/home/...` | `/{USER_HOME}/.../{filename}` |
| `database_url` | Database URLs | `postgres://...`, `mysql://...` | `{{DATABASE_URL}}` |
**No configuration required** - patterns work out of the box! π¦
---
## π§ Custom Patterns (Advanced - 5% of users)
For edge cases, register custom patterns programmatically:
```python
from cryptex_ai import register_pattern, protect_secrets
# Register custom pattern once
register_pattern(
name="slack_token",
regex=r"xoxb-[0-9-a-zA-Z]{51}",
placeholder="{{SLACK_TOKEN}}",
description="Slack bot token"
)
# Use immediately in decorators
@protect_secrets(["slack_token"])
async def slack_integration(token: str) -> str:
return await slack_api_call(token)
# Bulk registration
from cryptex_ai import register_patterns
register_patterns([
("discord_token", r"[MNO][A-Za-z\d]{23}\.[\w-]{6}\.[\w-]{27}", "{{DISCORD_TOKEN}}"),
("custom_key", r"myapp-[a-f0-9]{32}", "{{CUSTOM_KEY}}")
])
```
---
## ποΈ Framework Examples
### FastMCP Tools
```python
from fastmcp import FastMCPServer
from cryptex_ai import protect_secrets
server = FastMCPServer("my-server")
@server.tool()
@protect_secrets(["openai_key"])
async def ai_tool(prompt: str, api_key: str) -> str:
# MCP sees: ai_tool("Hello", "{{OPENAI_API_KEY}}")
# Tool gets: real API key for execution
return await openai_call(prompt, api_key)
```
### FastAPI Endpoints
```python
from fastapi import FastAPI
from cryptex_ai import protect_secrets
app = FastAPI()
@app.post("/api/process")
@protect_secrets(["database_url", "openai_key"])
async def process_endpoint(data: dict, db_url: str, api_key: str):
# Request/response logs show placeholders
# Endpoint gets real secrets for execution
return await process_with_secrets(data, db_url, api_key)
```
### Django Views
```python
from django.http import JsonResponse
from cryptex_ai import protect_secrets
@protect_secrets(["database_url"])
async def django_view(request, db_url: str):
# Django logs show placeholders
# View gets real database URL
return JsonResponse(await query_database(db_url))
```
### Any Python Function
```python
from cryptex_ai import protect_secrets
@protect_secrets(["github_token"])
def sync_function(token: str) -> str:
# Works with sync functions too!
return github_api_call(token)
@protect_secrets(["openai_key"])
async def async_function(api_key: str) -> str:
# And async functions
return await openai_call(api_key)
```
---
## β‘ Performance
Cryptex is designed for production workloads:
| Metric | Performance | Context |
|--------|-------------|---------|
| **Sanitization** | <5ms | 1KB payloads |
| **Resolution** | <10ms | 10 placeholders |
| **Memory Overhead** | <5% | vs unprotected apps |
| **Startup Time** | 0ms | Zero dependencies |
| **Throughput** | >1000 req/s | Typical workloads |
*Benchmarked on MacBook Pro M1, Python 3.11*
---
## ποΈ Architecture
### Three-Phase Temporal Isolation
```
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
β Raw Secrets β β AI Processing β β Tool Execution β
β β β β β β
β sk-abc123... βββββΆβ {{OPENAI_KEY}} βββββΆβ sk-abc123... β
β /Users/alice/ β β /{USER_HOME}/ β β /Users/alice/ β
β ghp_xyz789... β β {{GITHUB_TOKEN}} β β ghp_xyz789... β
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
Phase 1: Phase 2: Phase 3:
Sanitization AI sees safe Resolution for
for AI context placeholders tool execution
```
### Zero-Config Philosophy
- **π« No Attack Surface**: No config files to inject, no parsing to exploit
- **β‘ Lightning Fast**: Zero file I/O, zero parsing overhead
- **π― Decorator Focused**: Lightweight, predictable, zero dependencies
- **π¨βπ» Developer Friendly**: Works immediately, no setup friction
- **π Security First**: Configuration in version-controlled code only
---
## π Examples
Explore comprehensive examples in the [`examples/`](./examples/) directory:
- **[Basic Usage](./examples/basic_usage.py)**: Zero-config protection patterns
- **[FastAPI Integration](./examples/fastapi_example.py)**: Web API protection
- **[Real World Usage](./examples/real_world_usage.py)**: Complex multi-pattern scenarios
Run examples locally:
```bash
git clone https://github.com/AnthemFlynn/cryptex-ai.git
cd cryptex-ai
# See working temporal isolation
python simple_live_test.py
# Compare protected vs unprotected
python comparison_test.py
# Run basic examples
python examples/basic_usage.py
```
---
## π‘οΈ Security
Cryptex follows security-first principles:
- **Zero Dependencies**: No external packages, no supply chain attacks
- **Zero Config Files**: No TOML parsing, no injection attacks
- **Minimal Attack Surface**: No file I/O, pure Python standard library
- **Secure by Default**: Built-in patterns tested against real-world secrets
- **Audit Trail**: Full temporal isolation with context tracking
- **Pattern Validation**: Runtime regex validation and comprehensive error handling
**Security Policy**: See [SECURITY.md](./SECURITY.md) for vulnerability reporting.
---
## π§ͺ Testing
### Using pip
```bash
# Install dependencies
pip install -e ".[dev]"
# Run test suite
make test
# Run with coverage
make test-coverage
# Performance benchmarks
make test-performance
# Security tests
make test-security
```
### Using uv
```bash
# Install dependencies
uv sync --dev
# Run test suite
uv run make test
# Run with coverage
uv run make test-coverage
# Performance benchmarks
uv run make test-performance
# Security tests
uv run make test-security
```
---
## π€ Contributing
We welcome contributions! Cryptex follows a **zero-config philosophy** - keep it simple.
### Quick Development Setup
```bash
# Install uv first (if not already installed)
curl -LsSf https://astral.sh/uv/install.sh | sh
# Clone and set up the project
git clone https://github.com/AnthemFlynn/cryptex-ai.git
cd cryptex-ai
make dev-setup # Creates venv and installs dependencies with uv
make test # Run test suite
make lint # Code quality checks
make format # Code formatting
```
### Development Guidelines
- **Zero-Config First**: No configuration files in middleware libraries
- **Security First**: Every change requires security review
- **Performance Matters**: <5ms sanitization, <10ms resolution
- **Test Everything**: Every bug gets a test, every feature gets tests
- **SOLID Principles**: Clean architecture and abstractions
See [CONTRIBUTING.md](./CONTRIBUTING.md) for detailed guidelines.
---
## π Roadmap
- **v0.3.1** β
: Repository migration, documentation site, CI/CD improvements
- **v0.4.0**: Enhanced pattern validation and error reporting
- **v0.5.0**: Advanced caching and performance optimizations
- **v0.6.0**: Plugin system for custom secret sources
- **v1.0.0**: Production hardening and stability guarantees
---
## π License
MIT License - see [LICENSE](./LICENSE) file for details.
---
## π Acknowledgments
- **FastMCP Community**: For excellent MCP server patterns
- **FastAPI**: For inspiring clean API design
- **Python Community**: For async/await and type system excellence
- **Security Researchers**: For temporal isolation concepts
---
<div align="center">
**Made with β€οΈ for the AI/LLM community**
[β Star us on GitHub](https://github.com/AnthemFlynn/cryptex-ai) | [π Read the Docs](https://anthemflynn.github.io/cryptex-ai/) | [π¬ Join Discussions](https://github.com/AnthemFlynn/cryptex-ai/discussions)
</div>
Raw data
{
"_id": null,
"home_page": null,
"name": "cryptex-ai",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.11",
"maintainer_email": null,
"keywords": "ai, isolation, llm, mcp, secrets, security",
"author": "AnthemFlynn",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/ff/8c/4d4000cdf0fc51c9bb3af2fcfc98bfc4a5021813dd2b453b0c545da40c36/cryptex_ai-0.3.3.tar.gz",
"platform": null,
"description": "# Cryptex-AI\n\n<div align=\"center\">\n\n**Zero-config temporal isolation for AI/LLM applications**\n\n*Bulletproof secrets isolation with zero cognitive overhead*\n\n[](https://pypi.org/project/cryptex-ai/)\n[](https://pypi.org/project/cryptex-ai/)\n[](https://opensource.org/licenses/MIT)\n[](https://github.com/AnthemFlynn/cryptex-ai/actions)\n[](https://codecov.io/gh/AnthemFlynn/cryptex-ai)\n\n[**Documentation**](https://anthemflynn.github.io/cryptex-ai/) | [**Examples**](./examples/) | [**PyPI**](https://pypi.org/project/cryptex-ai/) | [**Changelog**](./CHANGELOG.md)\n\n</div>\n\n---\n\n## The Problem\n\nAI/LLM applications face an impossible choice:\n- **Expose secrets to AI** \u2192 Security nightmare \ud83d\udd13\n- **Hide secrets completely** \u2192 Broken functionality \ud83d\udca5\n\n## The Solution\n\nCryptex-ai provides **true temporal isolation** - AI services receive safe placeholders while your functions use real secrets through automatic call interception.\n\n```python\nfrom cryptex_ai import protect_secrets\n\n# Works immediately - no config files required!\n@protect_secrets([\"openai_key\"])\nasync def ai_tool(prompt: str, api_key: str) -> str:\n # Function receives: real API key for processing\n # AI service receives: {{OPENAI_API_KEY}} (intercepted)\n import openai\n return await openai.chat.completions.create(\n model=\"gpt-4\",\n messages=[{\"role\": \"user\", \"content\": prompt}],\n api_key=api_key # Real key for function, placeholder to AI\n )\n```\n\n**One decorator line = complete temporal isolation** \u2728\n\n---\n\n## \ud83d\ude80 Key Features\n\n- **\ud83d\udd27 Zero Configuration**: Works immediately, no setup required\n- **\u26a1 Built-in Patterns**: OpenAI, Anthropic, GitHub, file paths, databases\n- **\ud83d\udee1\ufe0f Security First**: Zero dependencies, no config files, no parsing vulnerabilities\n- **\ud83d\ude84 High Performance**: <5ms sanitization, <10ms resolution\n- **\ud83d\udd17 Universal**: Works with any Python function - FastMCP, FastAPI, Django, Flask, etc.\n- **\ud83c\udfaf True Isolation**: Monkey-patches AI libraries to intercept actual calls\n- **\ud83d\udcdd Simple API**: 95% of users need zero config, 5% get simple registration\n\n---\n\n## \ud83d\udce6 Installation\n\n### Using pip (recommended)\n```bash\npip install cryptex-ai\n```\n\n### Using uv (modern Python package manager)\n```bash\nuv add cryptex-ai\n```\n\n**Requirements**: Python 3.11+ \u2022 Zero dependencies\n\n---\n\n## \u26a1 Quick Start\n\n### Zero-Config Protection (95% of users)\n\nCryptex works immediately with built-in patterns for common secrets:\n\n```python\nfrom cryptex_ai import protect_secrets\n\n# Protect OpenAI API calls\n@protect_secrets([\"openai_key\"])\nasync def ai_completion(prompt: str, api_key: str) -> str:\n # AI context: \"{{OPENAI_API_KEY}}\"\n # Function execution: \"sk-real-key-here...\"\n return await openai.chat.completions.create(\n model=\"gpt-4\",\n messages=[{\"role\": \"user\", \"content\": prompt}],\n api_key=api_key\n )\n\n# Protect file operations\n@protect_secrets([\"file_path\"])\nasync def read_file(file_path: str) -> str:\n # AI context: \"/{USER_HOME}/.../{filename}\"\n # Function execution: \"/Users/alice/secrets/document.txt\"\n with open(file_path, 'r') as f:\n return f.read()\n\n# Protect multiple secrets at once\n@protect_secrets([\"github_token\", \"file_path\", \"database_url\"])\nasync def process_data(repo_path: str, token: str, db_url: str) -> dict:\n # All secrets automatically protected\n data = await fetch_from_github(repo_path, token)\n result = await process_ai_data(data)\n await save_to_database(result, db_url)\n return result\n```\n\n### Convenience Decorators\n\nFor common patterns, use convenience decorators:\n\n```python\nfrom cryptex_ai import protect_api_keys, protect_files, protect_all\n\n@protect_api_keys() # Protects OpenAI + Anthropic keys\nasync def ai_function(openai_key: str, anthropic_key: str) -> str:\n # Both API keys automatically protected\n pass\n\n@protect_files() # Protects file system paths\nasync def file_function(file_path: str) -> str:\n # File paths automatically protected\n pass\n\n@protect_all() # Protects all built-in patterns\nasync def comprehensive_function(api_key: str, file_path: str, db_url: str) -> str:\n # Everything automatically protected\n pass\n```\n\n---\n\n## \ud83d\udee0\ufe0f Built-in Patterns\n\nCryptex includes battle-tested patterns that handle **95% of real-world usage**:\n\n| Pattern | Detects | Example | Placeholder |\n|---------|---------|---------|-------------|\n| `openai_key` | OpenAI API keys | `sk-...` | `{{OPENAI_API_KEY}}` |\n| `anthropic_key` | Anthropic API keys | `sk-ant-...` | `{{ANTHROPIC_API_KEY}}` |\n| `github_token` | GitHub tokens | `ghp_...` | `{{GITHUB_TOKEN}}` |\n| `file_path` | User file paths | `/Users/...`, `/home/...` | `/{USER_HOME}/.../{filename}` |\n| `database_url` | Database URLs | `postgres://...`, `mysql://...` | `{{DATABASE_URL}}` |\n\n**No configuration required** - patterns work out of the box! \ud83d\udce6\n\n---\n\n## \ud83d\udd27 Custom Patterns (Advanced - 5% of users)\n\nFor edge cases, register custom patterns programmatically:\n\n```python\nfrom cryptex_ai import register_pattern, protect_secrets\n\n# Register custom pattern once\nregister_pattern(\n name=\"slack_token\",\n regex=r\"xoxb-[0-9-a-zA-Z]{51}\",\n placeholder=\"{{SLACK_TOKEN}}\",\n description=\"Slack bot token\"\n)\n\n# Use immediately in decorators\n@protect_secrets([\"slack_token\"])\nasync def slack_integration(token: str) -> str:\n return await slack_api_call(token)\n\n# Bulk registration\nfrom cryptex_ai import register_patterns\nregister_patterns([\n (\"discord_token\", r\"[MNO][A-Za-z\\d]{23}\\.[\\w-]{6}\\.[\\w-]{27}\", \"{{DISCORD_TOKEN}}\"),\n (\"custom_key\", r\"myapp-[a-f0-9]{32}\", \"{{CUSTOM_KEY}}\")\n])\n```\n\n---\n\n## \ud83c\udfd7\ufe0f Framework Examples\n\n### FastMCP Tools\n\n```python\nfrom fastmcp import FastMCPServer\nfrom cryptex_ai import protect_secrets\n\nserver = FastMCPServer(\"my-server\")\n\n@server.tool()\n@protect_secrets([\"openai_key\"])\nasync def ai_tool(prompt: str, api_key: str) -> str:\n # MCP sees: ai_tool(\"Hello\", \"{{OPENAI_API_KEY}}\")\n # Tool gets: real API key for execution\n return await openai_call(prompt, api_key)\n```\n\n### FastAPI Endpoints\n\n```python\nfrom fastapi import FastAPI\nfrom cryptex_ai import protect_secrets\n\napp = FastAPI()\n\n@app.post(\"/api/process\")\n@protect_secrets([\"database_url\", \"openai_key\"])\nasync def process_endpoint(data: dict, db_url: str, api_key: str):\n # Request/response logs show placeholders\n # Endpoint gets real secrets for execution\n return await process_with_secrets(data, db_url, api_key)\n```\n\n### Django Views\n\n```python\nfrom django.http import JsonResponse\nfrom cryptex_ai import protect_secrets\n\n@protect_secrets([\"database_url\"])\nasync def django_view(request, db_url: str):\n # Django logs show placeholders\n # View gets real database URL\n return JsonResponse(await query_database(db_url))\n```\n\n### Any Python Function\n\n```python\nfrom cryptex_ai import protect_secrets\n\n@protect_secrets([\"github_token\"])\ndef sync_function(token: str) -> str:\n # Works with sync functions too!\n return github_api_call(token)\n\n@protect_secrets([\"openai_key\"])\nasync def async_function(api_key: str) -> str:\n # And async functions\n return await openai_call(api_key)\n```\n\n---\n\n## \u26a1 Performance\n\nCryptex is designed for production workloads:\n\n| Metric | Performance | Context |\n|--------|-------------|---------|\n| **Sanitization** | <5ms | 1KB payloads |\n| **Resolution** | <10ms | 10 placeholders |\n| **Memory Overhead** | <5% | vs unprotected apps |\n| **Startup Time** | 0ms | Zero dependencies |\n| **Throughput** | >1000 req/s | Typical workloads |\n\n*Benchmarked on MacBook Pro M1, Python 3.11*\n\n---\n\n## \ud83c\udfd7\ufe0f Architecture\n\n### Three-Phase Temporal Isolation\n\n```\n\u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510 \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510 \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\n\u2502 Raw Secrets \u2502 \u2502 AI Processing \u2502 \u2502 Tool Execution \u2502\n\u2502 \u2502 \u2502 \u2502 \u2502 \u2502\n\u2502 sk-abc123... \u2502\u2500\u2500\u2500\u25b6\u2502 {{OPENAI_KEY}} \u2502\u2500\u2500\u2500\u25b6\u2502 sk-abc123... \u2502\n\u2502 /Users/alice/ \u2502 \u2502 /{USER_HOME}/ \u2502 \u2502 /Users/alice/ \u2502\n\u2502 ghp_xyz789... \u2502 \u2502 {{GITHUB_TOKEN}} \u2502 \u2502 ghp_xyz789... \u2502\n\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518 \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518 \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\n Phase 1: Phase 2: Phase 3:\n Sanitization AI sees safe Resolution for\n for AI context placeholders tool execution\n```\n\n### Zero-Config Philosophy\n\n- **\ud83d\udeab No Attack Surface**: No config files to inject, no parsing to exploit\n- **\u26a1 Lightning Fast**: Zero file I/O, zero parsing overhead\n- **\ud83c\udfaf Decorator Focused**: Lightweight, predictable, zero dependencies\n- **\ud83d\udc68\u200d\ud83d\udcbb Developer Friendly**: Works immediately, no setup friction\n- **\ud83d\udd12 Security First**: Configuration in version-controlled code only\n\n---\n\n## \ud83d\udcda Examples\n\nExplore comprehensive examples in the [`examples/`](./examples/) directory:\n\n- **[Basic Usage](./examples/basic_usage.py)**: Zero-config protection patterns\n- **[FastAPI Integration](./examples/fastapi_example.py)**: Web API protection\n- **[Real World Usage](./examples/real_world_usage.py)**: Complex multi-pattern scenarios\n\nRun examples locally:\n\n```bash\ngit clone https://github.com/AnthemFlynn/cryptex-ai.git\ncd cryptex-ai\n\n# See working temporal isolation\npython simple_live_test.py\n\n# Compare protected vs unprotected \npython comparison_test.py\n\n# Run basic examples\npython examples/basic_usage.py\n```\n\n---\n\n## \ud83d\udee1\ufe0f Security\n\nCryptex follows security-first principles:\n\n- **Zero Dependencies**: No external packages, no supply chain attacks\n- **Zero Config Files**: No TOML parsing, no injection attacks\n- **Minimal Attack Surface**: No file I/O, pure Python standard library\n- **Secure by Default**: Built-in patterns tested against real-world secrets\n- **Audit Trail**: Full temporal isolation with context tracking\n- **Pattern Validation**: Runtime regex validation and comprehensive error handling\n\n**Security Policy**: See [SECURITY.md](./SECURITY.md) for vulnerability reporting.\n\n---\n\n## \ud83e\uddea Testing\n\n### Using pip\n```bash\n# Install dependencies\npip install -e \".[dev]\"\n\n# Run test suite\nmake test\n\n# Run with coverage\nmake test-coverage\n\n# Performance benchmarks\nmake test-performance\n\n# Security tests\nmake test-security\n```\n\n### Using uv\n```bash\n# Install dependencies\nuv sync --dev\n\n# Run test suite\nuv run make test\n\n# Run with coverage\nuv run make test-coverage\n\n# Performance benchmarks\nuv run make test-performance\n\n# Security tests\nuv run make test-security\n```\n\n---\n\n## \ud83e\udd1d Contributing\n\nWe welcome contributions! Cryptex follows a **zero-config philosophy** - keep it simple.\n\n### Quick Development Setup\n\n```bash\n# Install uv first (if not already installed)\ncurl -LsSf https://astral.sh/uv/install.sh | sh\n\n# Clone and set up the project\ngit clone https://github.com/AnthemFlynn/cryptex-ai.git\ncd cryptex-ai\nmake dev-setup # Creates venv and installs dependencies with uv\nmake test # Run test suite\nmake lint # Code quality checks\nmake format # Code formatting\n```\n\n### Development Guidelines\n\n- **Zero-Config First**: No configuration files in middleware libraries\n- **Security First**: Every change requires security review\n- **Performance Matters**: <5ms sanitization, <10ms resolution\n- **Test Everything**: Every bug gets a test, every feature gets tests\n- **SOLID Principles**: Clean architecture and abstractions\n\nSee [CONTRIBUTING.md](./CONTRIBUTING.md) for detailed guidelines.\n\n---\n\n## \ud83d\udcc8 Roadmap\n\n- **v0.3.1** \u2705: Repository migration, documentation site, CI/CD improvements\n- **v0.4.0**: Enhanced pattern validation and error reporting\n- **v0.5.0**: Advanced caching and performance optimizations\n- **v0.6.0**: Plugin system for custom secret sources\n- **v1.0.0**: Production hardening and stability guarantees\n\n---\n\n## \ud83d\udcdc License\n\nMIT License - see [LICENSE](./LICENSE) file for details.\n\n---\n\n## \ud83d\ude4f Acknowledgments\n\n- **FastMCP Community**: For excellent MCP server patterns\n- **FastAPI**: For inspiring clean API design\n- **Python Community**: For async/await and type system excellence\n- **Security Researchers**: For temporal isolation concepts\n\n---\n\n<div align=\"center\">\n\n**Made with \u2764\ufe0f for the AI/LLM community**\n\n[\u2b50 Star us on GitHub](https://github.com/AnthemFlynn/cryptex-ai) | [\ud83d\udcd6 Read the Docs](https://anthemflynn.github.io/cryptex-ai/) | [\ud83d\udcac Join Discussions](https://github.com/AnthemFlynn/cryptex-ai/discussions)\n\n</div>\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Zero-config temporal isolation for AI/LLM applications - Bulletproof secrets isolation with zero cognitive overhead",
"version": "0.3.3",
"project_urls": {
"Documentation": "https://anthemflynn.github.io/cryptex-ai/",
"Homepage": "https://github.com/AnthemFlynn/cryptex-ai",
"Issues": "https://github.com/AnthemFlynn/cryptex-ai/issues",
"Repository": "https://github.com/AnthemFlynn/cryptex-ai"
},
"split_keywords": [
"ai",
" isolation",
" llm",
" mcp",
" secrets",
" security"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "c632c7785af7330bc617afd2a796a645bf4b462441f3fb0bc4c7af9c4ae0fff4",
"md5": "4fdc826524aaa2e09f2100c8b5f2ff88",
"sha256": "7739f7ceed69d73bc8b426a2f372c1744c5d7afb88f2e20760e74b14b4d0804f"
},
"downloads": -1,
"filename": "cryptex_ai-0.3.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4fdc826524aaa2e09f2100c8b5f2ff88",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.11",
"size": 33700,
"upload_time": "2025-07-22T00:20:57",
"upload_time_iso_8601": "2025-07-22T00:20:57.896699Z",
"url": "https://files.pythonhosted.org/packages/c6/32/c7785af7330bc617afd2a796a645bf4b462441f3fb0bc4c7af9c4ae0fff4/cryptex_ai-0.3.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "ff8c4d4000cdf0fc51c9bb3af2fcfc98bfc4a5021813dd2b453b0c545da40c36",
"md5": "4e85347e32efd26ce596154f2a2e68b3",
"sha256": "e8c13469561df5b1e4bb3c0170dd6ec3e348a2e908f52ff52491c79113e4b2fc"
},
"downloads": -1,
"filename": "cryptex_ai-0.3.3.tar.gz",
"has_sig": false,
"md5_digest": "4e85347e32efd26ce596154f2a2e68b3",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.11",
"size": 203075,
"upload_time": "2025-07-22T00:20:59",
"upload_time_iso_8601": "2025-07-22T00:20:59.541996Z",
"url": "https://files.pythonhosted.org/packages/ff/8c/4d4000cdf0fc51c9bb3af2fcfc98bfc4a5021813dd2b453b0c545da40c36/cryptex_ai-0.3.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-07-22 00:20:59",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "AnthemFlynn",
"github_project": "cryptex-ai",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "cryptex-ai"
}