Skip to content

Add a 数学的表記 section to AIRULES.md - #343

Merged
ikuwow merged 2 commits into
mainfrom
add-math-notation-section
Jul 30, 2026
Merged

Add a 数学的表記 section to AIRULES.md#343
ikuwow merged 2 commits into
mainfrom
add-math-notation-section

Conversation

@ikuwow

@ikuwow ikuwow commented Jul 30, 2026

Copy link
Copy Markdown
Owner

Summary

Add a ## 数学的表記 section to AIRULES.md, right after ## 応答の姿勢と判断.

The user reads undergraduate-level math and often parses a formula faster than the equivalent prose. The existing bullet 数学的・構造的な説明は定量的・体系的に行う states that goal but supplies no trigger, so responses stayed prose-only in practice.

Design choices the diff does not show

The trigger is a property of the content (relations that turn ambiguous in prose), not a topic list. A topic-based trigger would fire on "math questions" and stay silent exactly where notation helps most — latency, cost, and complexity estimates in ordinary engineering discussion. The parenthetical list is marked as examples so it stays subordinate to that criterion rather than acting as an independent trigger, and one sub-bullet guards the failure mode this kind of rule dies from: formalizing the whole explanation instead of the one relation inside it.

The scope line is explicit because the adjacent ## 出力フォーマット section excludes conversation. Without it, a reader could carry that exclusion over by analogy, which would disable the section for the case the user cares about most.

Notation is one bullet rather than a glyph table or a dedicated skill. The request was for math to be chosen more often, not for notation to be standardized; a glyph reference serves the latter and can be added if that need appears. Keeping the section short also keeps it pasteable into claude.ai preferences — scripts/deploy.sh symlinks AIRULES.md only to ~/.claude/CLAUDE.md, ~/.codex/AGENTS.md, and ~/.junie/AGENTS.md (deploy.sh:64,79,84), so claude.ai is a manual copy.

## 出力フォーマット's emphasis-markup exception is extended to cover math spans. The _ in $x_i$ is a subscript rather than emphasis, and that section governs authoring, so this scopes the authoring rule without asserting anything about how a parser treats _ inside a math span.

The existing 数学的・構造的な説明は定量的・体系的に行う bullet is left in place. The new section covers the 定量的 half but not the 構造的・体系的 half, so it is not a full replacement.

vladimirrott/claude-math (MIT) was evaluated as an off-the-shelf option. Its skills/math-unicode/SKILL.md is a notation and glyph guide with no policy on when to use math, and it forbids LaTeX unconditionally, which conflicts with using LaTeX where it renders. Not adopted.

Review fixes

The notation bullet originally named terminals as the non-rendering side. That assertion is unverified, and the first draft hedged it in this body while stating it as fact in the rule text — the exact drift AIRULES.md prohibits in its own hedge-preservation bullet. It is also wrong for two deploy targets: Junie renders in a JetBrains GUI panel, and claude.ai renders LaTeX. The bullet now switches on whether the environment renders LaTeX, which is the actual axis, and cites GitHub's Web UI as an example rather than reproducing a documented set it could drift from.

The reading-aloud example n が2倍でレイテンシは4倍 does not follow from O(n²), since an upper bound holds even when T is constant, yet O(·) was the only asymptotic symbol the section licensed. Θ(·) and Ω(·) are now licensed and the example is tied to T ∝ n².

was dropped rather than glossed: its convention splits between Vinogradov (f ≲ g ⟺ f = O(g), redundant with the licensed O(·)) and the engineering reading of "roughly at most", so licensing it without fixing a convention would have invited inconsistent use.

Smaller fixes: the symbol-definition duty was narrowed to variables and parameters, so it stops contradicting the licensed-symbol bullet; the approximation rule now says which symbol to use instead of only asking for a distinction.

Verification

  • GitHub's documented math support was read directly and matches the bullet: $…$, $`…`$, $$…$$, and math blocks, in Issues, Discussions, pull requests, wikis, and Markdown files (GitHub Docs: Writing mathematical expressions)
  • No claim about terminal LaTeX rendering remains in the rule text, so nothing in the section depends on an unverified tool behavior
  • No inline triple-backtick left in prose: the notation bullet names the math code block instead of writing the fence, which would otherwise be an unterminated inline code span

ikuwow and others added 2 commits July 30, 2026 14:29
The user reads undergraduate-level math and often finds a formula
faster to parse than prose. The existing "数学的・構造的な説明は
定量的・体系的に行う" bullet states the goal but gives no trigger,
so responses stayed prose-only.

This section supplies the missing parts: when to reach for notation,
what symbol vocabulary can be used without explanation, and which
formalizations to avoid. Notation is handled in one bullet that
switches on the render target, so the section stays self-contained
enough to paste into claude.ai preferences (deploy.sh only symlinks
AIRULES.md to Claude Code, Codex, and Junie).

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TjSPJwmFZsyAKSiNqYZaxK
Review of the first draft surfaced two substantive defects.

The notation bullet named terminals as the non-rendering side. That
assertion is unverified — the PR body hedged it, the rule body did not,
which is exactly what AIRULES.md's own hedge-preservation rule forbids.
It is also wrong for two of the file's deploy targets: Junie renders in
a GUI panel, and claude.ai renders LaTeX. The bullet now switches on
whether the environment renders LaTeX, which is the actual axis, and
cites GitHub's Web UI as an example rather than an enumeration that
drifts from the documented set (Issues, Discussions, pull requests,
wikis, Markdown files).

The reading-aloud example "n が2倍でレイテンシは4倍" does not follow
from O(n²) — an upper bound holds even for constant T — yet O(·) was
the only asymptotic symbol the section licensed. Θ(·) and Ω(·) are now
licensed and the example is tied to T ∝ n².

Smaller fixes: scope stated explicitly, since the adjacent 出力フォーマット
section excludes conversation and silence invited that reading by
analogy; symbol-definition duty narrowed to variables and parameters so
it stops contradicting the licensed-symbol bullet; ≲ dropped, as its
convention splits between Vinogradov (constant-factor upper bound,
redundant with O(·)) and the engineering "roughly at most"; the
approximation rule made operational instead of merely asking for a
distinction; the trigger's parenthetical marked as examples so it reads
as subordinate to the ambiguity criterion rather than as an independent
trigger; P(·) added next to E[·].

出力フォーマット's emphasis-markup exception now covers math spans. The
`_` in `$x_i$` is a subscript, not emphasis, and the section it lives in
governs authoring, so this scopes the authoring rule without asserting
anything about how any parser treats `_` inside a math span.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TjSPJwmFZsyAKSiNqYZaxK
@ikuwow
ikuwow marked this pull request as ready for review July 30, 2026 06:24
@ikuwow
ikuwow merged commit f60c67e into main Jul 30, 2026
6 checks passed
@ikuwow
ikuwow deleted the add-math-notation-section branch July 30, 2026 06:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant