KeiSeiKit-1.0/_blocks/rule-math-first.md
denis 0b901cf2f9 feat: KeiSeiKit v0.1.0 — initial public release
Generic Constructor-Pattern agent kit for Claude Code. Zero personal data,
fully English, MIT-licensed.

Contents:
- 34 reusable blocks (baseline, rules, stack/deploy/domain/api/scraper)
- 14 cross-project agent manifests (code/ml/infra/researcher/critic/...)
- 6 portable skills (/new-agent, /research, /test-gen, /debug-deep, /pr-review, /refactor)
- Rust assembler (single binary, ~500 KB)
- 3 hooks (auto-reassemble, pre-commit validate, no-hand-edit)
- install.sh (idempotent, cargo-builds on first run)
- MIT LICENSE

All 6 sanity greps pass: 0 Russian text, 0 specific project names,
0 incident numbers, 0 user paths, 0 hardcoded IPs, 0 API keys.

cargo check + assemble --validate: both pass on 14 manifests.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-20 23:58:34 +08:00

967 B

MATH FIRST (mandatory for ML / physics / theory work)

  1. Expression first — 1-3 lines LaTeX/Unicode BEFORE prose
  2. What is UNNECESSARY? — remove before adding
    • Learned parameters? WHY? Can you do without?
    • Hyperparameters? WHY? Determined by input?
    • Activation functions? WHY? Normalize enough?
    • Separate projection matrices? WHY? Does the input already encode this?
    • Gate/gating? WHY? Normalize = implicit gate?
    • Separate decoder? WHY? Can you reuse the state directly as output?
  3. Count — params, hyperparams, FLOPs, memory
  4. ONLY THEN — proof / plan / code

Prohibited: prose before expression, "fixes" before experimental confirmation, imposing form instead of deriving from input.

If adding — justify mathematically:

BAD:  "let's add decay λ for stability"  (where does λ come from?)
GOOD: "the normalization step already contains implicit decay — verify experimentally before adding"