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 rules/ai-learning-gems/ai-learning-gems.github.io/semantic-coloringgit clone --depth 1 https://github.com/AI-Learning-Gems/AI-Learning-Gems.github.ioWrote 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.
[](https://agentmods.dev/rules/ai-learning-gems/ai-learning-gems.github.io/semantic-coloring)<a href="https://agentmods.dev/rules/ai-learning-gems/ai-learning-gems.github.io/semantic-coloring"><img src="https://agentmods.dev/badge/rules/ai-learning-gems/ai-learning-gems.github.io/semantic-coloring.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.03141 |
| Opus 5 | $0.00000 | $0.01571 |
| Sonnet 5 | $0.00000 | $0.00628 |
| Haiku 4.5 | $0.00000 | $0.00314 |
Grade A, and why
semantic-coloring 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.
How it starts
The opening of the file, as written. The whole thing — 234 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Semantic Concept Coloring
Rules for applying consistent semantic color-coding to key concepts throughout textbook chapters. This technique uses author-provided color as a visual signal (Mayer's Signaling Principle) to help readers mentally separate and track concept categories.
Research basis: Color-coding is a form of visual signaling with meta-analytic support (Alpizar et al. 2020, g = 0.22; Richter et al. 2016, d = 0.22). Liu et al. (2021) found large effect sizes (eta-squared = 0.23) with lower cognitive load (measured by pupil diameter and EEG). This is fundamentally different from student-directed highlighting (Dunlosky LOW utility): author-provided semantic color-coding is expert-curated, consistent, and functions as a perceptual signal, not a learning activity. It leverages pre-attentive processing (Treisman & Gelade 1980), the Von Restorff isolation effect, and dual coding (Paivio 1986).
When to Apply
The coloring pass is part of the editing workflow (edit-textbook-chapter.md). It runs AFTER prose-quality editing is complete — it should be the last content-level pass before final verification. The writing workflow (write-textbook-chapter.md) may also apply coloring during initial writing, especially in the Chapter Overview paragraph where the technique has the highest impact.
The Color Palette (WCAG AA Compliant)
All colors pass WCAG AA (4.5:1 minimum) for normal-size text on white backgrounds. They are Tailwind CSS 600-700 shades, chosen for perceptual distinguishability and colorblind safety.
| # | Name | Hex | WCAG Ratio | Prose Syntax | LaTeX Syntax |
|---|---|---|---|---|---|
| 1 | Indigo | #4F46E5 |
6.29:1 | [**term**]{style="color: #4F46E5;"} |
$\textcolor{#4F46E5}{symbol}$ |
| 2 | Emerald | #047857 |
5.48:1 | [**term**]{style="color: #047857;"} |
$\textcolor{#047857}{symbol}$ |
| 3 | Rose | #E11D48 |
4.70:1 | [**term**]{style="color: #E11D48;"} |
$\textcolor{#E11D48}{symbol}$ |
| 4 | Sky | #0369A1 |
5.93:1 | [**term**]{style="color: #0369A1;"} |
$\textcolor{#0369A1}{symbol}$ |
| 5 | Amber | #B45309 |
5.02:1 | [**term**]{style="color: #B45309;"} |
$\textcolor{#B45309}{symbol}$ |
| 6 | Purple | #7E22CE |
6.98:1 | [**term**]{style="color: #7E22CE;"} |
$\textcolor{#7E22CE}{symbol}$ |
| 7 | Teal | #0F766E |
5.23:1 | [**term**]{style="color: #0F766E;"} |
$\textcolor{#0F766E}{symbol}$ |
| 8 | Slate | #475569 |
7.58:1 | [**term**]{style="color: #475569;"} |
$\textcolor{#475569}{symbol}$ |
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.
- 4d ago First seen · 234 lines · 0 tokens per session scan A fa5b4219eb94
semantic-coloring is a cursor rule published in the GitHub repository AI-Learning-Gems/AI-Learning-Gems.github.io (22 stars, last pushed 2mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 3,141 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.
Other cursor rules, from other repositories
prototype-previewer
Build interactive prototype reviewers with synced review notes and Figma capture pages.
figma-performance
Handling large documents efficiently in the Plugin API.
7-day-nextjs-web-design-cursor
A seven-day design workflow for web products that will be built in Next.js.
principle-reinterpretation-system
デザイン原則の再解釈システム - 全体ロジック説明.
mermaid
Diagram Creator. Load when the user requests "Create a diagram".
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.