Skip to content

Auto generate skill files from source code - #285

Open
saadeghi wants to merge 3 commits into
paper-design:mainfrom
saadeghi:main
Open

Auto generate skill files from source code#285
saadeghi wants to merge 3 commits into
paper-design:mainfrom
saadeghi:main

Conversation

@saadeghi

@saadeghi saadeghi commented Jul 31, 2026

Copy link
Copy Markdown

Following up on #284 PR

@itsdouges:

We'd only be interested in something like this if it were auto generated using the available TypeScript types so it always stays up-to-date.

This PR adds the skill files again, now automatically generated from the TypeScript source so it stays up to date.

With this PR, people can run this command so their agent can use Paper Shaders

npx skills add paper-design/shaders

The generator uses TypeScript types and mappings as the source of truth to generate:

  • SKILL.md
  • references/usage.md
  • One reference file per exported shader

CI checks that generated files are current. publish.js regenerates and commits them when a package is released. The skills are committed to GitHub.

No shader runtime behavior is changed. Type-checking, build, and all 23 tests pass.


Note

Low Risk
Documentation and build/CI tooling only; publish gains an automated git commit/push for skills/ but does not alter shader libraries or consumer runtime behavior.

Overview
Adds a @paper-design/skill-generator workspace package that builds skills/paper-shaders/ (root SKILL.md, references/usage.md, and one markdown file per exported shader) by parsing shader TS/TSX, docs *-def.ts, presets, uniforms, and shader comments—so agent-facing docs track the real API instead of hand-maintained prose.

Root scripts generate-skills and check-skills wire the generator; a new Generated Skills PR workflow type-checks the package and fails if committed output is stale. publish.js now runs generation before publish and, after a successful non–dry-run release, commits and pushes updated skills/ when they changed.

No changes to shader runtime packages—only tooling, generated markdown, lockfile/workspace metadata, and publish/CI glue.

Reviewed by Cursor Bugbot for commit 5c5b6e3. Bugbot is set up for automated code reviews on this repo. Configure here.

@vercel

vercel Bot commented Jul 31, 2026

Copy link
Copy Markdown

@saadeghi is attempting to deploy a commit to the Paper Design Team on Vercel.

A member of the Team first needs to authorize it.

@cursor cursor Bot 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.

Cursor Bugbot has reviewed your changes using high effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want fixes drafted automatically? Bugbot Autofix can create code changes for findings. A team admin can enable Autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 3eb7211. Configure here.

Comment thread packages/skill-generator/src/source-model.ts
Comment thread packages/skill-generator/src/catalog.ts
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