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.
npx agentmods add instructions/zexion7873/copilot-setting/javagit clone --depth 1 https://github.com/zexion7873/copilot-settingWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.01326 | $0.01326 |
| Opus 5 | $0.00663 | $0.00663 |
| Sonnet 5 | $0.00265 | $0.00265 |
| Haiku 4.5 | $0.00133 | $0.00133 |
Grade A, and why
copilot-setting java.instructions.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 yesterday.
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.
How it starts
The opening of the file, as written. The whole thing — 77 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Java 8 Conventions
This project is Java 8. AI models default to modern Java, and that pull is strong — treat it as a bias to correct, not a preference to follow. A newer-version symbol won't compile, but the convention and correctness rules below fail only at review or runtime — don't lean on the build to catch them. If you are not certain something exists in Java 8, verify against this file before writing it — never guess.
Language Boundary (Java 9+ Forbidden)
var, records, sealed classes, text blocks, pattern matchingList.of(),Map.of(),Set.of()— useArrays.asList()/Collections.unmodifiableMap()(note:Arrays.asListis fixed-size but element-mutable and allows nulls, unlikeList.of— wrap inCollections.unmodifiableListwhen true immutability matters)String.isBlank(),String.strip()— useStringUtilsor.trim().isEmpty()Optional.ifPresentOrElse(),Optional.stream()- Module system (
module-info.java) try-with-resourceson a pre-declared effectively-final variable (Java 9) — declare the resource inside thetry (...)parentheses instead; try-with-resources itself is Java 7 and stays mandatory for JDBC (instructions/sql.instructions.md)
Optional
- Return type only — never field, parameter, or collection element
orElse()for cheap defaults;orElseGet()for expensive computationorElseThrow(SomeException::new)over.get()—.get()throws crypticNoSuchElementException. Note: Java 8 requires the supplier formorElseThrow(() -> new ...)— the no-argorElseThrow()is Java 10+.
Streams
- One operation per line; break chain at
.collect() - Never modify external state inside
forEach/map/filter - Prefer
forloop for simple iterations with side effects
Date and Time
- Use
java.time(LocalDate,LocalDateTime,ZonedDateTime,Instant,Duration) for business logic, computation, and internal date handling — a Java 8 feature and the default for new code - Two hard exceptions on this stack — Hibernate 4.2 has no
java.timesupport (that arrived in Hibernate 5'shibernate-java8module) and JSTL 1.2<fmt:formatDate>accepts onlyjava.util.Date:- hbm.xml-mapped entity date fields stay
java.util.Date/java.sql.Timestamp— aLocalDateTimefield has no Hibernate 4.2 type mapping (fails, or silently persists as a serialized BLOB) - dates passed to a JSP for
<fmt:formatDate>stayjava.util.Date(instructions/jsp.instructions.md)
- hbm.xml-mapped entity date fields stay
- Convert at the service boundary with
Date.from(instant)/Date.toInstant()betweenjava.timelogic and the persistence / view layers - Still avoid
java.util.Calendar(mutable, error-prone) in new code
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.
- yesterday First seen · 77 lines · 1,326 tokens per session scan A e67f462e1e44
copilot-setting java.instructions.md is an instructions file published in the GitHub repository zexion7873/copilot-setting (1 stars, last pushed 28d ago), licensed MIT. It adds 1,326 tokens to every session, about $0.0066 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.
Other instructions, from other repositories
ai-agent-rules-generator copilot.instructions.md
Glitch WooCommerce Payment Gateway plugin coding guidelines — auto-doc sync for plugin, features, and infrastructure.
ai-agent-rules-generator agent-observations.instructions.md
Mandatory agent observation logging — anomalies, recommendations, and critical findings must be disclosed before commit.
ai-agent-rules-generator task.instructions.md
Task execution rules for Glitch WooCommerce Payment Gateway engineering work.
ai-agent-rules-generator doc-sync.instructions.md
Documentation sync rules — which docs to update when code changes.
ai-agent-rules-generator browsetools.instructions.md
Browser verification rules for Glitch WooCommerce Payment Gateway using Chrome DevTools MCP.
ai-agent-rules-generator devtools.instructions.md
Browser DevTools and local development access credentials.