posturio

Posturio is now open source.

Posturio shipped an OpenAI-compatible AI gateway with policy-driven PII and secret guardrails, plus a cited-RAG layer on top. It didn't find product-market fit as a SaaS.

The engineering is real, so the engineering is now public. Two repos, MIT licensed, with working docker compose up quickstarts.

Repo · MIT

cordon

Self-hostable, OpenAI-compatible AI gateway. YAML policy engine with allow / block / redact / route_local actions. Inspect every prompt with regex + entropy + Luhn; reroute sensitive traffic to a local Llama instead of blocking. Audit-logged, OpenAI SDK drop-in.

FastAPI Postgres Redis Ollama Docker
Repo · MIT

cordon-rag

Cited RAG over a local corpus, routed through cordon so the gateway's guardrails apply to every LLM call. Lexical retriever (no embeddings), 45-doc Wikipedia-derived seed corpus, conversation persistence, single-file HTML console.

RAG FastAPI Postgres cordon

The killer demo, in three curls

# Case 1: normal prompt → routes to OpenAI
$ curl -d '{"messages":[{"role":"user","content":"Summarize the CAP theorem."}]}' …
{"gateway":{"provider":"openai","action":"allow","policy_rule":"default_allow"}}

# Case 2: PII detected → transparently reroutes to local Llama
$ curl -d '{"messages":[{"role":"user","content":"Draft reply for Jane Doe, SSN 123-45-6789."}]}' …
{"gateway":{"provider":"ollama","model":"llama3.2","action":"route_local","policy_rule":"pii_local_only"}}

# Case 3: secret detected → blocked, never reaches any provider
$ curl -d '{"messages":[{"role":"user","content":"Use AKIAIOSFODNN7EXAMPLE to deploy."}]}' …
HTTP 403  {"error":{"type":"policy_violation","rule":"block_secrets"}}