Audits services/llm-gateway against PostHog/ai-gateway and updates services/llm-gateway/PARITY.md from current implementation evidence. Use when either gateway changes auth, attribution, billing, endpoints, providers, models, routing, or metadata; when reviewing a Python gateway change; or when asked to refresh, verify, or report gateway parity. This skill updates the parity record but does not migrate callers.
69
85%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Compare the current implementations of both gateways and update services/llm-gateway/PARITY.md. Keep this audit separate from caller migration.
origin/master and record its SHA as the PostHog baseline.master yet.PostHog/ai-gateway main SHA with gh api repos/PostHog/ai-gateway/commits/main and record it as the Go baseline.main. Treat its contracts as pending until the change merges; do not record them as currently supported.PostHog/ai-gateway at main.Audit implementation code. README files and the existing parity table are starting points, not proof.
For the Python gateway, inspect:
services/llm-gateway/src/llm_gateway/api/ for routes and wire behaviorservices/llm-gateway/src/llm_gateway/auth/ for accepted credentialsservices/llm-gateway/src/llm_gateway/db/required_tables.py for the tables the gateway may read; a change adding a table read needs its posthog-cloud-infra SELECT grant landed in every environment firstservices/llm-gateway/src/llm_gateway/products/config.py for trusted product policy, models, and billingservices/llm-gateway/src/llm_gateway/rate_limiting/ for budgets and limitsservices/llm-gateway/src/llm_gateway/callbacks/ for event attributionposthog/llm/gateway_client.py and real call sites for required contractsFor the Go gateway, inspect:
internal/httpapi/routes.go and dispatch packages for API shapesinternal/auth/ and internal/principal/ for credential and identity policyinternal/httpapi/admission.go, internal/ledger/, and internal/quota/ for billing and limitsinternal/catalog/, internal/router/, and internal/dispatch/ for models, providers, translation, and failoverinternal/emitter/ and request parsing for attribution and metadatadocs/product.md for intended and deferred contracts, verified against codeCheck both request and response behavior. Matching route names do not prove parity for headers, streaming, errors, timeouts, retries, billing, or emitted events.
Do not treat caller-supplied telemetry as trusted policy. An ai_product event property does not replace product authentication, authorization, or billing.
Do not treat Python's unbilled flag as an automatic blocker. An internal workload can move to Go with a PostHog-owned team credential when debiting that wallet is the intended way to attribute PostHog spend. It is blocked only when it must preserve customer-specific billing policy or must debit no wallet.
For each difference, identify at least one affected use-case class. Remove details that do not change a migration decision.
Update services/llm-gateway/PARITY.md with the evidence:
PostHog/ai-gateway.When a gap closes, name obvious caller classes that are newly eligible to migrate. Do not modify those callers unless the user also asks for migration work. Use /migrating-llm-gateway-callers for that separate job.
Run:
pnpm exec oxfmt services/llm-gateway/PARITY.md .agents/skills/auditing-llm-gateway-parity/SKILL.md
pnpm exec markdownlint-cli2 --config .config/.markdownlint-cli2.jsonc services/llm-gateway/PARITY.md .agents/skills/auditing-llm-gateway-parity/SKILL.md
git diff --checkb0fece0
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.