Skip to content

Add repository skills and notebook schema validation - #74

Merged
gitgik merged 3 commits into
masterfrom
users/gitgik/repository-skills
Nov 22, 2026
Merged

gitgik merged 3 commits into
masterfrom
users/gitgik/repository-skills

Conversation

@gitgik

@gitgik gitgik commented Nov 16, 2026 •

Copy link
Copy Markdown
Owner

Purpose

Give contributors focused agent workflows for this repository without adding an orchestration framework or new dependencies. All new instructions and code were written for this repository.

Changes

  • Add four skills: PR creation, PR review, notebook validation, and technical content review.
  • Add AGENTS.md with shared editing expectations and links to the skills.
  • Add a read-only notebook schema helper and run it before the existing nbval CI step.
  • Test malformed JSON, invalid structure and versions, required and unique cell IDs in newer formats, unreadable files, batch failures, and validation without execution or rewriting. Valid legacy formats remain accepted.

The skills cover evidence-based findings, paired content, numerical assumptions, tradeoffs, explicit publishing approval, and honest reporting of validation limits.

Validation

  • copilot skill list --json discovers and enables all four project skills; copilot instruction list discovers AGENTS.md.
  • All 17 tracked notebook schemas pass.
  • Full local notebook execution suite passed on Python 3.14. After the final validator changes, all 5 validator tests and 7 subtests pass; all 17 actual notebook schemas pass.
  • GitHub CI passes all 34 tests on Python 3.9, 3.10, and 3.11. Schema checks, Markdown links, and Codacy pass.
  • New Markdown links resolve and git diff --check passes.

Independent of #73. No articles, notebooks, saved outputs, or dependency manifests change. Skills provide guidance; they do not prove design correctness or enforce every instruction.

Add original, focused workflows for PR creation and review, notebook validation, and system-design content review. Add a read-only schema checker using existing dependencies, regression tests, and an existing-CI integration.

Validated all 17 notebook schemas and the complete local pytest/nbval suite (33 tests). Confirmed Copilot skill/instruction discovery and local links.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 7411b498-db61-4f72-8629-4af2b007c3a4
Use nbformat's non-mutating iterator so missing required IDs in newer formats cannot be repaired before validation. Add a regression confirmed failing before the fix while preserving acceptance of valid older formats.

All 17 notebook schemas and 33 tests pass locally.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 7411b498-db61-4f72-8629-4af2b007c3a4

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

The validator can incorrectly accept notebooks with missing or duplicate cell IDs and abort the batch on malformed notebook structures instead of reporting them as invalid.

2 open issues
What changed in this PR

This PR adds contributor guidance and notebook schema validation to the repository’s existing article and example workflows, without introducing new dependencies or changing notebook content.

Changes:

  • Add four focused skills and shared editing expectations in AGENTS.md.
  • Run a read-only notebook schema helper before the existing nbval CI step.
  • Add tests for invalid inputs, batch failure handling, and validation without execution or rewriting.
File Description
tests/​test_validate_notebooks.py Tests schema validation, error reporting, batch handling, and file preservation.
AGENTS.md Defines shared contributor expectations and links to skills.
.github/​workflows/​ipynb_tests.yml Adds schema validation before notebook tests.
.github/​skills/​validate-notebooks/​SKILL.md Documents schema, execution, and paired-content checks.
.github/​skills/​validate-notebooks/​scripts/​validate_notebooks.py Implements read-only batch schema validation.
.github/​skills/​review-pr/​SKILL.md Guides evidence-based reviews and bounded reporting.
.github/​skills/​review-design-content/​SKILL.md Guides checks of technical claims, assumptions, and tradeoffs.
.github/​skills/​create-pr/​SKILL.md Defines scoped validation and approval-aware publishing steps.

Review effort: Balanced

Check ID uniqueness after raw schema validation. Verify both valid modern notebooks and rejected duplicate IDs, missing/null modern cells, and continuation to later batch inputs. All five validator tests, seven subtests, and 17 real notebook schemas pass locally.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 7411b498-db61-4f72-8629-4af2b007c3a4

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues are reported for the contributor workflow and read-only notebook validation changes.

No open issues 🎉

2 resolved since last review

Review effort: Balanced

@gitgik
gitgik merged commit 6ad8d58 into master Nov 22, 2026
9 checks passed
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.

2 participants