PAI

A guide for coordinating Personal AI Infrastructure with Gemini command configurations used by GitHub Actions.

In plain words
What is it for?
Use it to compare PAI findings with Gemini pull-request reviews, assess coverage gaps, and escalate critical findings for human review.
Why use it?
It helps an agent understand what automated review already covers so it can find missing checks without repeating the same work.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/docxology/codomyrmex/pai
Clone the repo
git clone --depth 1 https://github.com/docxology/codomyrmex
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 346 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00346
Opus 5 $0.00000 $0.00173
Sonnet 5 $0.00000 $0.00069
Haiku 4.5 $0.00000 $0.00035

Measured 2d ago against content hash 90cfea5b4f04, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

PAI scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.github/commands/PAI.md · 37 lines

What it actually says

.github/commands — PAI Integration Guide

Status: Active | Last Updated: February 2026

Purpose

PAI reads Gemini command configs to understand the automated review/triage system. PAI does not invoke these commands directly — they run via GitHub Actions.

PAI Phase Mapping

PAI Phase Usage
OBSERVE Read TOML configs to understand what AI review is already providing
THINK Assess if review coverage gaps exist (e.g., no security-focused review pass)
PLAN Consider whether a new Gemini command config would fill a gap
VERIFY Check if Gemini review comments on a PR align with PAI's own review findings

Understanding the Review System

The gemini-review.toml runs Gemini as a code reviewer on every PR. PAI should:

  • Complement Gemini's review, not duplicate it
  • Focus on architectural concerns Gemini may miss (cross-module impact, ISC coverage)
  • Escalate to human review anything Gemini flags as 🔴 Critical

Key Operational Notes

  • Gemini reviews post as GitHub review comments (visible in PR Conversations tab)
  • Commands run in isolated Actions environments with no access to repository secrets
  • The additional_context env var in workflow steps customizes per-run focus areas
  • gemini-scheduled-triage.toml runs weekly — check it when issues appear unlabeled

Constraints

  • Do not modify TOML prompts without testing on a fork — changes affect all future PRs
  • Preserve all security constraints (input demarcation, scope limitation, tool exclusivity)
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 37 lines · 0 tokens per session scan A 90cfea5b4f04

Subscribe to this mod's changes

PAI is a command published in the GitHub repository docxology/codomyrmex (11 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 346 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.