# OGuardAI: Privacy Layer for LLMs > OGuardAI is a semantic data protection runtime for AI systems. It detects sensitive entities in text, replaces them with typed semantic tokens (e.g., {{email:e_001}}), lets LLMs process the safe text, then deterministically restores originals in the output. ## Core Capabilities - **Detect**: 16 entity types via 30+ regex patterns + GLiNER/spaCy NER - **Tokenize**: Replace PII with semantic tokens that preserve context (gender, formality, language) - **Transform**: Send safe text to the LLM of your choice (OpenAI, Anthropic, Mistral, local models) - **Rehydrate**: Restore tokens to originals with 6 restore modes per output channel - **Policy Engine**: Per-entity-type rules (tokenize, block, pass-through) with GDPR profiles - **Output Guard**: Fail-closed second-pass scan for newly generated PII in LLM output ## Entity Types person, email, phone, company, customer_id, order, address, location, iban, ssn, ip, url, credit_card, date_of_birth, passport, health_id ## Restore Modes full, partial, masked, formatted, abstract, none ## Output Channels user_output, internal_summary, customer_email, tool_payload, export, log_safe ## Architecture - **Runtime Plane** (Rust): core engine, server, tokenizer, transformer, rehydrator, policy engine, session management - **Integration Plane**: TypeScript SDK (@oguardai/sdk), Python SDK (oguardai-sdk), MCP server, HTTP proxy - **Session Model**: Stateless AES-256-GCM encrypted sealed sessions with HKDF key derivation ## Deployment Self-hosted: you run the entire runtime in your own infrastructure and hold every secret. The proprietary runtime is private today and provided under a written agreement with Oronts (request access at https://OGuard.ai/request): - Container images: ghcr.io/oronts/oguardai/{server,detector-py,proxy} (the unit of delivery, by tag or digest) - Helm chart (OCI): helm install oguardai oci://ghcr.io/oronts/charts/oguardai --version 0.1.0 - Docker Compose: consumes the published images - Signed release archive: oguardai CLI + oguardai-server with SHA-256 checksum, Cosign signature, and SBOM - Cloud recipes: ECS, Cloud Run, Container Apps (the image plus platform YAML) The SDKs and MCP server are Apache-2.0: TypeScript (npm), Python (pip), Go (go get), Java (Maven). ## API Endpoints - POST /v1/transform: Transform text/JSON/chat messages, return safe output + session state - POST /v1/rehydrate: Restore tokens using session state + output channel policy - POST /v1/detect: Detect entities only (no transformation) - POST /v1/evaluate-policy: Evaluate policy against entities - POST /v1/transform/stream: Streaming transform (SSE) - POST /v1/rehydrate/stream: Streaming rehydrate (SSE) - GET /v1/health: Health check - GET /v1/capabilities: List entity types, languages, detectors ## Links - Docs: https://OGuard.ai/docs - GitHub: https://github.com/oronts/oguardai - Company: https://oronts.com/en ## Optional - llms-full.txt: https://OGuard.ai/llms-full.txt