Skip to content

docs: add CLAUDE.md with working rules and evaluation-honesty guardrails - #6

Open
vkosuri wants to merge 4 commits into
mainfrom
claude/add-claude-md
Open

docs: add CLAUDE.md with working rules and evaluation-honesty guardrails#6
vkosuri wants to merge 4 commits into
mainfrom
claude/add-claude-md

Conversation

@vkosuri

@vkosuri vkosuri commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Adds a repo-root CLAUDE.md — the persistent context file AI coding sessions load automatically, so working rules and project knowledge carry across sessions instead of being re-derived each time. Completes the org-wide sweep (web-live #31, 20factor-analyser #28, firmware #126, datasets #7, bujo.js #2).

Contents (verified against the README, ci.yml, and pytest.ini):

  • Evaluation honesty as the first rule: never report a number without its split; this repo's own documented lesson (cnn_gnn.py's ~99% memorization vs ~43–47% held-out) is quoted as the standing warning, and the publicly used ~65–80%-on-new-writers figure is pinned so it doesn't drift upward in future copy.
  • Exact CI commands: CPU pip install with the extra index URL, py_compile syntax gate, pytest, and the --demo self-check for the seq2seq pipeline.
  • Security-pinned dependencies flagged as such (torch CVE-2025-32434, scikit-learn CVE-2024-5206) so the pins aren't casually loosened.
  • Repo map including the do-not-extend status of the legacy cnn_gnn.py.
  • Cross-repo contract: training pickles and writer-split ordering come from vahinitech/datasets, pseudonymous codes only, aggregate-only reporting (datasets#6).

One file added, nothing else touched.


Generated by Claude Code

claude added 2 commits July 21, 2026 02:15
Persistent per-repo context for AI-assisted sessions: the
held-out-split-only reporting rule (with this repo's own 99%-vs-43%
memorization lesson), security-pinned dependency note, exact CI
commands, repo map, and the datasets-repo pickle/writer-split contract.
…s/**)

Same rationale as the sibling repos: a markdown-only change can't affect
py_compile/pytest results, so the full pipeline is pure wait time.
paths-ignore only skips when EVERY changed file matches -- a mixed PR
still runs everything.

vkosuri commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

Added a second commit: ci.yml now has paths-ignore: ['**/*.md', 'docs/**'] on both push and pull_request, so a docs-only PR skips the pipeline. A mixed PR still runs everything. CLAUDE.md updated to document this.


Generated by Claude Code

Repo-tailored review guidance using the path-scoped instructions format
(applyTo: "**"). Leads with evaluation honesty (split disclosure
required on any accuracy claim, citing this repo's own 99%-vs-43%
memorization lesson) and the torch.load/pickle security pin rationale.

vkosuri commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

Added .github/instructions/code-review.instructions.md — repo-tailored GitHub Copilot code-review guidance (path-scoped format, applyTo: "**"). Leads with evaluation honesty (citing this repo's own 99%-vs-43% memorization lesson) and the security-pinned dependency rationale.


Generated by Claude Code

… consent)

New working rule in CLAUDE.md and a matching review check in
code-review.instructions.md. Points at this repo's own correct existing
pattern (docs/impacx_onhw_analysis.md citing and independently
reimplementing ImpAcX_OnHW, not copying it) as the model to follow.

vkosuri commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

Added a research-code provenance rule to both CLAUDE.md and code-review.instructions.md. Points at this repo's own correct existing pattern (docs/impacx_onhw_analysis.md citing and independently reimplementing ImpAcX_OnHW, not copying it) as the model any future reference-implementation work should follow.


Generated by Claude Code

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds repo-wide “persistent context” documentation for AI-assisted sessions and reviewers, centering evaluation-honesty guardrails and security/dependency pin rationale, plus updates CI triggers to skip docs-only changes.

Changes:

  • Added CLAUDE.md with working rules, repo map, and CI command cheatsheet.
  • Updated CI workflow triggers to ignore docs-only changes (**/*.md, docs/**).
  • Added .github/instructions/code-review.instructions.md to standardize review focus (provenance, security, evaluation honesty).

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.

File Description
CLAUDE.md New persistent context/rules doc for AI sessions, including CI commands and repo guardrails.
.github/workflows/ci.yml Adjusts CI triggers so markdown/docs-only changes don’t run the pipeline.
.github/instructions/code-review.instructions.md Adds structured review instructions emphasizing provenance, security, and evaluation honesty.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread CLAUDE.md
Comment on lines +16 to +18
`docs/impacx_onhw_analysis.md` explicitly analyzes ImpAcX_OnHW's
pipeline and `plot_results.py` is rebuilt "in the style of" its
`plot_kNN_results.py" — independently reimplemented, cited, not copied.
Comment thread CLAUDE.md
Comment on lines +40 to +43
pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cpu # CPU/CI
python -m py_compile *.py # syntax gate (CI does this)
pytest # tests/ — split, writer inference, augmentation, CTC
python onhw_seq2seq.py --demo # verifies the seq2seq pipeline on synthetic data, no dataset needed
Comment on lines +38 to +41
- Any use of `torch.load`/pickle-based loading on data that isn't fully
trusted (e.g., a checkpoint from an external source) should use
`weights_only=True` or equivalent — this is exactly the class of bug
CVE-2025-32434 was.
Comment thread .github/workflows/ci.yml
Comment on lines 1 to +7
name: CI

on:
# Docs-only changes (README/CLAUDE.md/docs/**) skip this whole pipeline --
# nothing here builds or tests markdown. A push/PR that touches even one
# non-doc file still runs everything; paths-ignore only fires when EVERY
# changed file matches.
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.

3 participants