textguard AGENTS.md

textguard AGENTS.md is an instructions file for Codex, OpenCode from shisa-ai/textguard. It costs 1,453 tokens per session, scanned A, original, Apache-2.0.

A repository guide for coding agents working on Textguard, a reusable Python package that normalizes and detects hostile text. It explains the project’s intended structure, design principles, and source documents.

In plain words
What is it for?
Use it when developing or reviewing the Textguard package, especially when deciding where to look for project guidance or how to reuse security logic without adding daemon-specific complexity.
Why use it?
It gives agents a shared set of rules and identifies which files contain the current plan, work history, and public documentation. This helps keep changes focused and consistent.

Instructions file for CodexOpenCode

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 instructions/shisa-ai/textguard/agents-md
Clone the repo
git clone --depth 1 https://github.com/shisa-ai/textguard

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for textguard AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/shisa-ai/textguard/agents-md.svg)](https://agentmods.dev/instructions/shisa-ai/textguard/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/shisa-ai/textguard/agents-md"><img src="https://agentmods.dev/badge/instructions/shisa-ai/textguard/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,453 This file is loaded in full into every session.
When invoked 1,453 The same file — it is already loaded in full.
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.01453 $0.01453
Opus 5 $0.00727 $0.00727
Sonnet 5 $0.00291 $0.00291
Haiku 4.5 $0.00145 $0.00145

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

Security

Grade A, and why

textguard AGENTS.md 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 4d 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.

AGENTS.md · 115 lines

How it starts

The opening of the file, as written. The whole thing — 115 lines — stays where its author put it; the contents beside it link to each section on GitHub.

textguard Agent Guide

textguard is a greenfield Python package being extracted from shisad work on hostile-text normalization and detection. Keep the security ideas strong, keep the package reusable, and avoid importing daemon/framework complexity that does not belong in a standalone library.

Instruction precedence: if this file conflicts with platform, system, or developer instructions, follow those first.

Current Source Of Truth

  • README.md is the public package overview and usage surface.
  • docs/PLAN.md is the working implementation plan.
  • WORKLOG.md is the chronological development log. Append entries when making design decisions, completing work, or changing direction. Do not rewrite earlier entries — the line-number stability matters for referencing.
  • CHANGELOG.md is the user-facing release history, reverse chronological. Update only when shipping a release or pre-release milestone.
  • Use shisad as a reference source for reusable text-defense logic, not as an architecture template.

First Principles

  • Preserve legitimate text by default. Normal multilingual Unicode input is a first-class use case, not collateral damage.
  • Do not make "convert everything to ASCII" the default behavior. Lossy or destructive transforms must be explicit opt-in.
  • Security features must improve safety without turning the package into a blunt text shredder.
  • Keep the package focused on text normalization, decoding, inspection, and sanitization primitives for LLM-adjacent systems.
  • Prefer pure, testable library code over framework coupling, background services, policy engines, or repo-specific runtime assumptions.
  • Bound all decoding and expansion behavior. No unbounded recursion, no unbounded size blowups, no regexes with obvious pathological behavior.

Intended Project Shape

Build toward a small public-package layout like this:

textguard/
|- src/textguard/        # library code
|- tests/                # unit and integration tests
|- pyproject.toml        # packaging metadata
|- README.md             # public install and usage docs
|- docs/PLAN.md          # optional implementation plan for non-trivial work
`- docs/PUBLISH.md       # optional release checklist

Read the full file on GitHub · 115 lines

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. 4d ago First seen · 115 lines · 1,453 tokens per session scan A 0e8f3a690276

Subscribe to this mod's changes

textguard AGENTS.md is an instructions file published in the GitHub repository shisa-ai/textguard (2 stars, last pushed 4mo ago), licensed Apache-2.0. It adds 1,453 tokens to every session, about $0.0073 per session on Opus 5. 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-31.