Skip to content

Conversation

giamir
Copy link
Contributor

@giamir giamir commented Oct 20, 2025

SPARK-93

Attention: 2 vibe coded files are checked in as part of this PR

This PR introduces a script that analyze the content of the stacks-svelte source and related storybook docs and generates a llms.txt summarizing all that content in markdown easily digestible by LLMs.

The only package I could find out there to take storybook docs and make them LLMs friendly was this one. Unfortunately though the package support only storybook v7 and v8 and we are using v9. It also uses playwright under the hood.

Until there’s a more established package that supports converting Storybook docs to Markdown, I’ve opted to vibe code what we need in a very isolated tools folder. In general, I’m not in favor of checking in code generated by LLMs unless we fully understand it. However, for this specific use case, I think it’s acceptable — the script is unlikely to need ongoing maintenance, and even if it breaks, the only loss would be something primarily useful for LLMs.

How to test

  • Check out this branch
  • Run npm run storybook:build -w @stackoverflow/stacks-svelte
  • Open packages/stacks-svelte/netlify/dist/llms.txt and check the generated markdown

Deployment Preview: https://deploy-preview-2012--stacks-svelte.netlify.app/llms.txt

Copy link

changeset-bot bot commented Oct 20, 2025

⚠️ No Changeset found

Latest commit: a62d9cf

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

netlify bot commented Oct 20, 2025

Deploy Preview for stacks-svelte ready!

Name Link
🔨 Latest commit a62d9cf
🔍 Latest deploy log https://app.netlify.com/projects/stacks-svelte/deploys/68f741a7cbddae000812027e
😎 Deploy Preview https://deploy-preview-2012--stacks-svelte.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

netlify bot commented Oct 20, 2025

Deploy Preview for stacks ready!

Name Link
🔨 Latest commit a62d9cf
🔍 Latest deploy log https://app.netlify.com/projects/stacks/deploys/68f741a77af89900084d0ef8
😎 Deploy Preview https://deploy-preview-2012--stacks.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@giamir giamir marked this pull request as ready for review October 21, 2025 08:17
Copy link
Contributor

@dancormier dancormier left a comment

Choose a reason for hiding this comment

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

Unfortunately though the package support only storybook v7 and v8 and we are using v9. It also uses playwright under the hood.

We're finally on the cutting edge 🎉

In general, I’m not in favor of checking in code generated by LLMs unless we fully understand it. However, for this specific use case, I think it’s acceptable — the script is unlikely to need ongoing maintenance, and even if it breaks, the only loss would be something primarily useful for LLMs.

100% agree. Seems like a wise, low-liability use of vibe coding.


I followed the PR instructions and llms.txt generated exactly as in the preview (besides **Generated:** 2025-10-21T20:08:03.165Z of course 🙂). Solid LGTM material!

@giamir giamir merged commit b5a23dd into develop Oct 22, 2025
18 checks passed
@giamir giamir deleted the SPARK-93/generate-llmstxt-from-storybook branch October 22, 2025 07:42
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