Skip to content

issue #478/context auto detect playbooks#486

Merged
roblevintennis merged 1 commit into
masterfrom
issue-#478/context-auto-detect-playbooks
Apr 29, 2026
Merged

issue #478/context auto detect playbooks#486
roblevintennis merged 1 commit into
masterfrom
issue-#478/context-auto-detect-playbooks

Conversation

@roblevintennis

@roblevintennis roblevintennis commented Apr 29, 2026

Copy link
Copy Markdown
Contributor

manual smoke-test steps:

  1. Build a local tarball: bash v2/scripts/build-local-tarball.sh
  2. Install into an example app and run npx agnosticui-cli playbook dashboard --framework react --force
  3. Verify src/playbooks/dashboard/sdui.json was written
  4. Run npx agnosticui-cli context and confirm the Agentic Intent section appears in CLAUDE.md

…ent recipes

- playbook.ts: write sdui.json to destRoot on install so ag context can find it
- context.ts: scan src/playbooks/*/sdui.json, render Agentic Intent section,
  announce detected playbooks, warn on stale schema version, show count in summary box
- context.test.ts: 5 new tests (no dir, empty dir, one valid, one stale, two valid)
- playbook.test.ts: 1 new test verifying sdui.json is written to destRoot
@netlify

netlify Bot commented Apr 29, 2026

Copy link
Copy Markdown

Deploy Preview for agnosticui-demo-react ready!

Name Link
🔨 Latest commit 89e1e5a
🔍 Latest deploy log https://app.netlify.com/projects/agnosticui-demo-react/deploys/69f21a232ca7cf0008942801
😎 Deploy Preview https://deploy-preview-486--agnosticui-demo-react.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.

@netlify

netlify Bot commented Apr 29, 2026

Copy link
Copy Markdown

Deploy Preview for agnosticui-demo-lit ready!

Name Link
🔨 Latest commit 89e1e5a
🔍 Latest deploy log https://app.netlify.com/projects/agnosticui-demo-lit/deploys/69f21a233eba7b00081517f8
😎 Deploy Preview https://deploy-preview-486--agnosticui-demo-lit.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.

@netlify

netlify Bot commented Apr 29, 2026

Copy link
Copy Markdown

Deploy Preview for agnosticui-demo-vue ready!

Name Link
🔨 Latest commit 89e1e5a
🔍 Latest deploy log https://app.netlify.com/projects/agnosticui-demo-vue/deploys/69f21a2379714d00080db348
😎 Deploy Preview https://deploy-preview-486--agnosticui-demo-vue.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.

@roblevintennis

Copy link
Copy Markdown
Contributor Author

Verification

  • Unit tests: 20 passing (12 in context.test.ts covering no-playbooks-dir, empty-dir, one valid, one stale-version, and two-valid scenarios; 8 in playbook.test.ts including the new assertion that sdui.json is written to destRoot).

  • Manual smoke test: Ran a full end-to-end flow against a fresh Vite + React project in /tmp/ using the locally built CLI tarball:

  1. ag init + ag add button to establish a working project
  2. ag playbook dashboard --framework react --force — confirmed src/playbooks/dashboard/sdui.json was written with correct slug, version, intent triggers, and recipe
  3. ag context --format claude — CLI announced Detected 1 installed playbook (dashboard), and
    CLAUDE.md contained the full ## AgnosticUI Agentic Intent — Playbook Recipes section with triggers, component recipe, and notes rendered correctly
  4. Installed a second playbook (login), re-ran ag context — CLI announced Detected 2 installed playbooks (dashboard, login), both sections appeared in CLAUDE.md, and grep -c
    'agnosticui:context:start' CLAUDE.md returned 1 confirming idempotency

@roblevintennis roblevintennis merged commit 5c10865 into master Apr 29, 2026
17 checks passed
@roblevintennis roblevintennis deleted the issue-#478/context-auto-detect-playbooks branch April 29, 2026 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant