Skip to content
Back to search

vibe

Developer toolkit for vibe coding AI apps on the ibl.ai platform. Scaffold a production-ready Next.js app with iblai-app-cli and the @iblai/iblai-js SDK: SSO auth, AI chat, profiles, notifications, and analytics wired up out of the box. Pre-built components, Claude Code skills, and a hosted backend at iblai.app. Deploy in minutes.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today

Check it deeper on your machine

It has changed since its scan on 11 Nov 2026.

As a Claude Code plugin, install it and then ask Claude Code:

/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/iblai/vibe with scanskillsafety

Or from a terminal, clone it and run it:

git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/iblai/vibe'

It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/iblai--vibe/badge.svg)](/listings/iblai--vibe)

HTML

<a href="/listings/iblai--vibe"><img src="/api/listings/iblai--vibe/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 25 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.

  1. {
  2. "name": "iblai",
  3. "owner": {
  4. "name": "ibl.ai",
  5. "url": "https://ibl.ai"
  6. },
  7. "metadata": {
  8. "description": "Skills for building on and operating the ibl.ai platform."
  9. },
  10. "plugins": [
  11. {
  12. "name": "iblai-vibe",
  13. "source": "./",
  14. "description": "Build apps on ibl.ai and operate the platform headlessly \u2014 136 skills (iblai-vibe-* with visual components, iblai-api-* headless), the /iblai-vibe-start intake, and the @iblai/mcp SDK-docs server.",
  15. "category": "development",
  16. "keywords": [
  17. "ibl.ai",
  18. "agents",
  19. "sso",
  20. "nextjs",
  21. "rest-api"
  22. ]
  23. }
  24. ]
  25. }
README.md · README · 330 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.

  1. <!-- AI agents: when a user points you at this repository or has these skills installed, read AGENTS.md, then begin with the four questions in skills/start/iblai-vibe-start/SKILL.md before touching any file. -->
  2. <div align="center">
  3. <a href="https://ibl.ai"><img src="https://ibl.ai/images/iblai-logo.png" alt="ibl.ai" width="300"></a>
  4. # ibl.ai/base
  5. Ship AI-powered apps fast — and run the platform behind them. Backend included.
  6. [![Release](https://img.shields.io/github/v/release/iblai/vibe?label=skills%20release)](https://github.com/iblai/vibe/releases/latest)
  7. [![Skills](https://img.shields.io/badge/skills-154_%C2%B7_ui_54_%C2%B7_api_66-CC785C)](docs/skill-kinds.md)
  8. [![Next.js](https://img.shields.io/badge/Next.js-000000?logo=nextdotjs&logoColor=white)](https://nextjs.org)
  9. [![TypeScript](https://img.shields.io/badge/TypeScript-3178C6?logo=typescript&logoColor=white)](https://www.typescriptlang.org)
  10. [![Tailwind CSS](https://img.shields.io/badge/Tailwind_CSS-06B6D4?logo=tailwindcss&logoColor=white)](https://tailwindcss.com)
  11. [![Claude Code](https://img.shields.io/badge/Claude_Code-CC785C?logoColor=white)](https://claude.ai/code)
  12. [![OpenAI Codex](https://img.shields.io/badge/OpenAI_Codex-000000?logo=openai&logoColor=white)](https://openai.com/codex)
  13. [![Cursor](https://img.shields.io/badge/Cursor-000000?logoColor=white)](https://cursor.com)
  14. [![Desktop & Mobile](https://img.shields.io/badge/Desktop_%26_Mobile-supported-blue)](skills/ship/iblai-vibe-ops-build/SKILL.md)
  15. [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](#license)
  16. </div>
  17. > **Note:** This toolkit runs against the hosted `iblai.app` environment. If you'd like a license to the full platform codebase to run locally or self-host, reach out to our team at [ibl.ai/contact](https://ibl.ai/contact).
  18. ---
  19. Build the app you actually need on [ibl.ai](https://ibl.ai) — sign-in, an AI
  20. agent to talk to, users and admins, custom data, memory, analytics, billing —
  21. as a website and as macOS, Windows, iOS, and Android apps. Or run the platform
  22. with no UI at all. One install; your coding agent does the rest.
  23. ## Three steps
  24. **1. Install the skills** in the agent you already use.
  25. ```bash
  26. npx skills add iblai/base --all # Claude Code, OpenAI Codex, Cursor, OpenCode, Copilot …
  27. ```
  28. Claude Code users can install the plugin instead (same skills, plus the SDK-docs
  29. MCP server, updated with `/plugin update`): `/plugin marketplace add iblai/vibe`
  30. then `/plugin install iblai-vibe@iblai`.
  31. **2. Say hello.**
  32. ```text
  33. /iblai-vibe-connect
  34. /iblai-vibe-auth
  35. /iblai-vibe-agent-chat
  36. /iblai-vibe-project
  37. /iblai-vibe-profile
  38. /iblai-vibe-account
  39. /iblai-vibe-analytics
  40. /iblai-vibe-notification
  41. /iblai-vibe-invite
  42. /iblai-vibe-workflow
  43. /iblai-vibe-local-llm
  44. /iblai-vibe-course-access
  45. /iblai-vibe-course-create
  46. /iblai-vibe-onboard
  47. /iblai-build
  48. /iblai-test
  49. /iblai-vibe-ops-upgrade
  50. /iblai-vibe-rbac
  51. /iblai-vibe-agent-search
  52. /iblai-vibe-agent-setting
  53. /iblai-vibe-agent-access
  54. /iblai-vibe-agent-api
  55. /iblai-vibe-agent-dataset
  56. /iblai-vibe-agent-disclaimer
  57. /iblai-vibe-agent-embed
  58. /iblai-vibe-agent-history
  59. /iblai-vibe-agent-llm
  60. /iblai-vibe-agent-memory
  61. /iblai-vibe-agent-prompt
  62. /iblai-vibe-agent-safety
  63. /iblai-vibe-agent-task
  64. /iblai-vibe-agent-tool
  65. ```
  66. What each skill does:
  67. - `/iblai-vibe-connect` -- connects the project to an ibl.ai organization via a one-click browser flow, writing the org key + a minted API token into the env files (the token never passes through the chat). Runs first, before building.
  68. - `/iblai-vibe-auth` -- adds authentication and configures the app for ibl.ai login.
  69. - `/iblai-vibe-agent-chat` -- adds the full in-process agent chat surface.
  70. - `/iblai-vibe-project` -- adds the in-process Projects surface (project landing page with chat input, files, instructions, assigned agents).
  71. - `/iblai-vibe-profile` -- adds profile UI and profile settings flows.
  72. - `/iblai-vibe-account` -- adds account and organization settings.
  73. - `/iblai-vibe-analytics` -- adds analytics dashboards and reporting views.
  74. - `/iblai-vibe-notification` -- adds notifications UI and notification center flows.
  75. - `/iblai-vibe-invite` -- adds user invitation dialogs for tenant admin.
  76. - `/iblai-vibe-workflow` -- adds agent workflows: the organization's list (opened from an agent) and the visual editor (`WorkflowsList`, `WorkflowEditor`).
  77. - `/iblai-vibe-local-llm` -- defines the contract for adding on-device LLM inference (Ollama / Foundry) to a Tauri desktop build: Tauri command names, event names, and the React hook shape the SDK consumes via `localLLMProps`.
  78. - `/iblai-vibe-course-access` -- adds edX course-content pages with outline sidebar, tab strip, iframe, and access control.
  79. - `/iblai-vibe-course-create` -- drives the ibl.ai Course Creation API to programmatically generate, edit, and publish edX courses.
  80. - `/iblai-vibe-onboard` -- designs and builds a high-converting questionnaire-style onboarding flow.
  81. - `/iblai-vibe-ops-build` -- builds and runs the app on desktop and mobile (macOS, Windows x64 + ARM64 / Surface, Linux, iOS, Android).
  82. - `/iblai-vibe-ops-test` -- builds, tests and touch tests the app in a real browser before it is presented to the user.
  83. - `/iblai-vibe-ops-upgrade` -- upgrades the `@iblai/iblai-js` SDK and vibe skills to the latest versions.
  84. - `/iblai-vibe-scaffold` -- scaffolds a new app or adds features; holds the base + agent project templates and documents the assembly steps.
  85. - `/iblai-vibe-iconography` -- generates every app-icon size (Tauri desktop, iOS, Windows MSIX, macOS) from a single source image.
  86. - `/iblai-vibe-windows-msix` -- builds and distributes a Tauri app as a Windows MSIX package (sideloading or Microsoft Store).
  87. - `/iblai-vibe-deslop` -- audits and hardens an existing codebase for production readiness (two-phase audit then safety-tiered fixes).
  88. - `/iblai-vibe-rbac` -- reference for the default RBAC roles (student, tenant admin, mentor editor, analytics viewer, etc.), the platform's action-definitions endpoint, and the SDK components (`<Admin>`, `<RolesTab>`, `<PoliciesTab>`) that render the Roles + Policies management UI.
  89. - `/iblai-vibe-agent-search` -- adds the agent search/browse page (starred, featured, custom, and default agents).
  90. - `/iblai-vibe-agent-setting` -- adds the agent Settings tab (Basic, Discovery, Capabilities and Welcome Screen sub-tabs, plus copy and delete) built on `AgentSettingsProvider`.
  91. - `/iblai-vibe-agent-access` -- adds the agent Access tab (role-based access control for editor and chat roles).
  92. - `/iblai-vibe-agent-api` -- adds the agent API tab (API key management).
  93. - `/iblai-vibe-agent-dataset` -- adds the agent Datasets tab (searchable dataset table with upload).
  94. - `/iblai-vibe-agent-disclaimer` -- adds the agent Disclaimers tab (user agreement and advisory).
  95. - `/iblai-vibe-agent-embed` -- adds the agent Embed tab (embed code, custom styling, shareable links).
  96. - `/iblai-vibe-agent-history` -- adds the agent History tab (conversation history with filters and export).
  97. - `/iblai-vibe-agent-llm` -- adds the agent LLM tab (model provider selection).
  98. - `/iblai-vibe-agent-memory` -- adds the agent Memory tab (enable/disable memory and manage memories).
  99. - `/iblai-vibe-agent-prompt` -- adds the agent Prompts tab (system prompts and suggested prompts).
  100. - `/iblai-vibe-agent-safety` -- adds the agent Safety tab (moderation prompts and flagged content).
  101. - `/iblai-vibe-agent-task` -- adds the agent Tasks tab (schedule automated periodic agent tasks with run logs).
  102. - `/iblai-vibe-agent-tool` -- adds the agent Tools tab (enable/disable agent tools).
  103. ### Security Skills
  104. 8 authorized-use security skills covering reconnaissance, source-code
  105. audits (OWASP Top 10), OSINT, disk forensics, incident triage, cloud
  106. configuration auditing, dependency vulnerabilities, and prompt-injection
  107. testing.
  108. /iblai-vibe-start
  109. ```
  110. Four questions — new project or existing code · one organization, many, or none ·
  111. who signs in · what it's about (users · memories · agents · organizations). Then
  112. it connects your ibl.ai organization (one click in the browser, or two pasted
  113. values — the token never enters the chat) and builds. Thirty seconds after you
  114. sign in you are chatting with your own agent, with users, an admin area, custom
  115. user and organization settings, memory, analytics, and billing already wired.
  116. **3. Ship.** `/iblai-vibe-ops-deploy` gives you a URL. `/iblai-vibe-ops-build`
  117. gives you macOS, Windows, iOS, and Android.
  118. New to ibl.ai? [ibl.ai/join](https://ibl.ai/join) creates your account and your
  119. organization — free to start. Want the details of every step?
  120. [Getting started →](docs/getting-started.md)
  121. ## What you get
  122. vibe-starter, the app `/iblai-vibe-start` sets up for the common case:
  123. - **Sign-in** with ibl.ai SSO, pinned to your organization
  124. - **Home is a chat** with your agent; `/agents` to browse; `/setup` to pick or create one
  125. - **Users and admins** — profile, a User/Admin switch, an admin area (people, invites, roles, analytics, billing, memory, organization)
  126. - **Custom data** per user and per organization, stored on the platform — no database of your own
  127. - **Memory, analytics, notifications, billing** — the platform's own, already on the page
  128. - **Tests** (Vitest + Playwright) and a server helper for anything the components don't cover
  129. Every piece is a skill you can also add to an existing app.
  130. ## Six things almost every app touches
  131. Whatever you build, you will read or write these. Each has a component skill
  132. and a headless twin that does the same thing over REST:
  133. | | With a screen | Headless |
  134. |---|---|---|
  135. | **Custom data per user** — preferences, flags, onboarding, app state | `/iblai-vibe-user-metadata` | `/iblai-api-profile-metadata` |
  136. | **The user's profile** — name, bio, image, résumé | `/iblai-vibe-profile` | `/iblai-api-profile` |
  137. | **Memory** — user-global, per user × agent, agent knowledge | `/iblai-vibe-memory-guide` → `/iblai-vibe-memory`, `/iblai-vibe-agent-memory` | `/iblai-api-agent-memory` |
  138. | **Custom data per organization** — branding, toggles, defaults | `/iblai-vibe-org-metadata` | `/iblai-api-org` |
  139. | **Agent configuration** — create; identity, visibility, capabilities | `/iblai-vibe-agent-create` → `/iblai-vibe-agent-setting` | `/iblai-api-agent-create`, `/iblai-api-agent-setting` |
  140. | **Analytics** — usage, transcripts, costs, audit, reports | `/iblai-vibe-analytics` | `/iblai-api-analytics` |
  141. Not sure whether you want the per-user, per-agent, or per-organization one?
  142. [Which scope stores what →](docs/catalogue.md#core)
  143. ## The skills, by folder
  144. Two families in one install: **🖥️ `iblai-vibe-*`** mounts a visual component in
  145. your app; **🔌 `iblai-api-*`** does the same thing headlessly over REST — for a
  146. script, a CI job, or your own backend. [How they differ →](docs/skill-kinds.md)
  147. | Folder | What it covers | Skills |
  148. |---|---|---|
  149. | [`start/`](skills/start) | The first conversation, connecting your organization, sign-in, the starter | 11 |
  150. | [`agents/`](skills/agents) | Chat, browse, create, and configure agents — every settings tab | 61 |
  151. | [`users/`](skills/users) | Profiles, custom user data, memories, roles and admins, invitations, the official apps' first-run journeys | 19 |
  152. | [`organizations/`](skills/organizations) | Organization settings and metadata, branding, integrations | 10 |
  153. | [`billing/`](skills/billing) | How you are charged, credits, spend caps, choosing a pricing rail | 5 |
  154. | [`monetization/`](skills/monetization) | Charge your users: app paywall, item sales, subscriptions, revenue | 7 |
  155. | [`analytics/`](skills/analytics) | Usage, users, topics, transcripts, costs, reports | 2 |
  156. | [`content/`](skills/content) | Courses, catalog, credentials, admissions, Open edX Studio, avatar video | 26 |
  157. | [`ship/`](skills/ship) | Test, deploy, hosting, native builds, app stores | 12 |
  158. | [`security/`](skills/security) | Authorized-use security work | 8 |
  159. The full list with one line per skill: [docs/catalogue.md](docs/catalogue.md).
  160. ## Keep it current
  161. This repo changes often. Installed skills are a copy — refresh them with the
  162. install command above, or `/iblai-vibe-ops-upgrade` in Claude Code (your agent
  163. will suggest it when the copy is more than two weeks old).
  164. [Details →](docs/keep-current.md)
  165. ## Learn more
  166. - [Getting started](docs/getting-started.md) — the journey in detail, and what to do when you already have an app
  167. - [How sign-in and organizations work](docs/auth-model.md) — one organization, many, or none
  168. - [Users, agents, organizations](docs/domain-model.md) — the data every app is built on
  169. - [How money works](skills/billing/iblai-vibe-pricing/SKILL.md) · [Ship anywhere](docs/ship.md) · [The two MCP servers](docs/mcp-servers.md)
  170. - [Contributing a skill](CONTRIBUTING.md) — including where it goes and how to catalogue it
  171. Vibe is designed to be built with AI. The [@iblai/mcp](https://www.npmjs.com/package/@iblai/mcp) server gives Claude Code deep knowledge of the ibl.ai platform, and the bundled skills guide you through every common task.
  172. ### MCP Server
  173. Add this to your `.mcp.json` at the project root:
  174. ```json
  175. {
  176. "mcpServers": {
  177. "iblai": {
  178. "command": "npx",
  179. "args": ["-y", "@iblai/mcp"]
  180. }
  181. }
  182. }
  183. ```
  184. This gives your AI assistant access to:
  185. ```
  186. get_component_info("ChatWidget") # Props, usage, examples for any component
  187. get_hook_info("useAdvancedChat") # Hook parameters and return types
  188. get_api_query_info("useGetUserMetadataQuery") # RTK Query endpoint details
  189. get_provider_setup("auth") # Provider hierarchy and setup code
  190. create_page_template("Dashboard", "mentor") # Generate a page following ibl.ai patterns
  191. ```
  192. ### Claude Code Skills
  193. The scaffolded app ships with skills that teach Claude how to work with your codebase. Instead of reading docs, you tell Claude what you want and the skills provide the context:
  194. | Skill | Description |
  195. |-------|-------------|
  196. | `/iblai-vibe-connect` | Connect the project to an ibl.ai org — one-click browser flow that writes the org key + a minted API token into the env files (no token in the chat) |
  197. | `/iblai-vibe-auth` | Add SSO authentication (includes CLI installation guide) |
  198. | `/iblai-vibe-agent-chat` | Add the full in-process agent chat surface |
  199. | `/iblai-vibe-project` | Add the in-process Projects surface (project landing page — chat input + files + instructions + assigned agents) |
  200. | `/iblai-vibe-profile` | Add profile dropdown + settings page |
  201. | `/iblai-vibe-account` | Add account/org settings page |
  202. | `/iblai-vibe-analytics` | Add analytics dashboard |
  203. | `/iblai-vibe-notification` | Add notification bell + center page |
  204. | `/iblai-vibe-invite` | Add user invitation dialogs |
  205. | `/iblai-vibe-workflow` | Agent workflows: the organization's list + visual editor |
  206. | `/iblai-vibe-local-llm` | Contract for on-device LLM (Ollama / Foundry) in a Tauri desktop build — command names, event names, hook shape the SDK reads via `localLLMProps` |
  207. | `/iblai-vibe-course-access` | Add course-content pages (edX user UI) |
  208. | `/iblai-vibe-course-create` | Generate, edit, and publish edX courses via the ibl.ai Course Creation API |
  209. | `/iblai-vibe-component` | Overview of all components + app creation paths |
  210. | `/iblai-vibe-onboard` | Design and build a high-converting onboarding questionnaire flow |
  211. | `/iblai-landing` | Build a high-converting landing page using a 12-section conversion framework |
  212. | `/iblai-vibe-ops-build` | Build and run on desktop and mobile (macOS, Windows x64 + ARM64, Linux, iOS, Android) |
  213. | `/iblai-vibe-ops-test` | Build, test and touch test your app in a real browser before showing work |
  214. | `/iblai-vibe-ops-upgrade` | Upgrade ibl.ai CLI, SDK, and vibe skills to the latest versions |
  215. | `/iblai-vibe-scaffold` | Scaffold a new app or add features — the base/agent project templates + the assembly steps |
  216. | `/iblai-vibe-iconography` | Generate every app-icon size (Tauri desktop, iOS, Windows MSIX, macOS) from one source image |
  217. | `/iblai-vibe-windows-msix` | Build and distribute a Tauri app as a Windows MSIX (sideload / Microsoft Store) |
  218. | `/iblai-vibe-deslop` | Audit and harden an existing codebase for production readiness (two-phase audit → safety-tiered fixes) |
  219. | `/iblai-vibe-rbac` | Reference: default RBAC roles, action-definitions endpoint, and the SDK Roles + Policies components |
  220. | `/iblai-vibe-agent-search` | Add the agent search/browse page (starred, featured, custom, default) |
  221. | `/iblai-vibe-agent-setting` | Add the agent Settings tab (name, visibility, copy, delete) |
  222. | `/iblai-vibe-agent-access` | Add the agent Access tab (RBAC for editor and chat roles) |
  223. | `/iblai-vibe-agent-api` | Add the agent API tab (API key management) |
  224. | `/iblai-vibe-agent-dataset` | Add the agent Datasets tab (searchable dataset table with upload) |
  225. | `/iblai-vibe-agent-disclaimer` | Add the agent Disclaimers tab (user agreement and advisory) |
  226. | `/iblai-vibe-agent-embed` | Add the agent Embed tab (embed code, custom styling, shareable links) |
  227. | `/iblai-vibe-agent-history` | Add the agent History tab (conversation history with filters and export) |
  228. | `/iblai-vibe-agent-llm` | Add the agent LLM tab (model provider selection) |
  229. | `/iblai-vibe-agent-memory` | Add the agent Memory tab (enable/disable memory and manage memories) |
  230. | `/iblai-vibe-agent-prompt` | Add the agent Prompts tab (system prompts and suggested prompts) |
  231. | `/iblai-vibe-agent-safety` | Add the agent Safety tab (moderation prompts and flagged content) |
  232. | `/iblai-vibe-agent-task` | Add the agent Tasks tab (schedule automated periodic agent tasks with run logs) |
  233. | `/iblai-vibe-agent-tool` | Add the agent Tools tab (enable/disable agent tools) |
  234. Skills are in `skills/` (symlinked to `.claude/skills/`). Read them, extend them, or write your own.
  235. ## Platform Capabilities
  236. | Feature | Web | macOS | Windows/Surface | iOS | Android |
  237. |---------|-----|-------|-----------------|-----|---------|
  238. | SSO Authentication | Yes | Yes | Yes | No | No |
  239. | AI Chat | Yes | Yes | Yes | Yes | Yes |
  240. | User Profile | Yes | Yes | Yes | Yes | Yes |
  241. | Account Settings | Yes | Yes | Yes | Yes | Yes |
  242. | Analytics Dashboard | Yes | Yes | Yes | Yes | Yes |
  243. | Notifications | Yes | Yes | Yes | Yes | Yes |
  244. > **iOS & Android SSO limitation:** Mobile WebViews use a non-standard user-agent that SSO providers reject. Completing the OAuth flow requires a system browser popup (ASWebAuthenticationSession on iOS, Chrome Custom Tabs on Android). This is not yet implemented -- mobile users must authenticate via another method for now.
  245. ## Deploy Anywhere
  246. ### Vercel (recommended)
  247. One-click deploy. Connect your repo, set your environment variables, and push.
  248. Or deploy with the `vercel` CLI -- see [`/iblai-vibe-ops-deploy`](skills/iblai-vibe-ops-deploy/SKILL.md):
  249. ```bash
  250. npx vercel deploy --prod --token="$VERCEL_TOKEN" --yes --public
  251. ```
  252. ### Tauri (Desktop & Mobile)
  253. Build native apps for macOS, Windows, Linux, iOS, and Android:
  254. Add the Tauri shell (see [`/iblai-vibe-ops-build`](skills/ship/iblai-vibe-ops-build/SKILL.md)), then:
  255. ```bash
  256. pnpm exec tauri build # Desktop build for current platform
  257. pnpm exec tauri ios init # iOS project setup
  258. ```
  259. ## Resources
  260. ## Built with iblai/vibe
  261. [Agentic OS](https://os.ibl.ai) ([iblai/os](https://github.com/iblai/os)) ·
  262. [Agentic LMS](https://lms.ibl.ai) ([iblai/lms](https://github.com/iblai/lms)) ·
  263. [vibe-agent](https://github.com/iblai/vibe-agent) (one creator, one agent, one paywall) ·
  264. marketing skills in [iblai/vibe-marketing](https://github.com/iblai/vibe-marketing)
  265. ## License
  266. MIT — [ibl.ai](https://ibl.ai)
scripts/test-skills-agent.sh · Bundled script · 160 lines · 1 finding marked
  1. #!/bin/bash
  2. # Tier-2 skill test: run a skill the way it actually executes — a headless
  3. # Claude agent following SKILL.md inside a scratch vibe app — then assert the
  4. # result compiles and builds. Tier-3 (RUN_LIVE=1) boots the built app and runs
  5. # the real SSO login flow against it.
  6. #
  7. # Usage:
  8. # scripts/test-skills-agent.sh <skill> [<skill>…] # explicit skills
  9. # scripts/test-skills-agent.sh --changed # skills touched vs origin/main
  10. #
  11. # Env:
  12. # MAX_TURNS agent turn cap (default 40)
  13. # AGENT_TIMEOUT seconds per skill (default 900)
  14. # RUN_LIVE=1 after build: pnpm start + Playwright SSO login (needs
  15. # AUTH_HOST, PLAYWRIGHT_USERNAME, PLAYWRIGHT_PASSWORD,
  16. # IBLAI_TEST_TENANT_KEY, IBLAI_TEST_API_KEY)
  17. #
  18. # Log hygiene: the agent only ever sees dummy credentials; real secrets enter
  19. # only the live-tier Playwright/server env. Server output goes to a file, never
  20. # the console. No `set -x` — do not add one.
  21. set -euo pipefail
  22. ROOT="$(cd "$(dirname "$0")/.." && pwd)"
  23. STARTER="$ROOT/skills/start/iblai-vibe-ops-init/assets/vibe-starter"
  24. skill_path() { ls -d "$ROOT"/skills/*/"$1" 2>/dev/null | head -1; }
  25. WORK="$ROOT/.skill-tests/agent"
  26. MAX_TURNS="${MAX_TURNS:-40}"
  27. AGENT_TIMEOUT="${AGENT_TIMEOUT:-900}"
  28. fail() { echo "✗ $*" >&2; exit 1; }
  29. note() { echo "• $*"; }
  30. command -v claude >/dev/null || fail "claude CLI not found (npm i -g @anthropic-ai/claude-code)"
  31. # ---- resolve target skills ----------------------------------------------
  32. skills=()
  33. if [[ "${1:-}" == "--changed" ]]; then
  34. base="${BASE_REF:-origin/main}"
  35. git -C "$ROOT" rev-parse --verify -q "$base" >/dev/null || base="main"
  36. while IFS= read -r dir; do
  37. [[ -f "$(skill_path "$dir")/SKILL.md" ]] && skills+=("$dir")
  38. done < <(git -C "$ROOT" diff --name-only "$base"...HEAD -- skills/ | awk -F/ '{print $3}' | sort -u)
  39. if [[ ${#skills[@]} -eq 0 ]]; then
  40. echo "test-skills-agent: no skills changed vs $base — nothing to do."
  41. exit 0
  42. fi
  43. else
  44. [[ $# -ge 1 ]] || fail "usage: $0 <skill>… | --changed"
  45. skills=("$@")
  46. fi
  47. # ---- scratch app helpers -------------------------------------------------
  48. make_scratch() {
  49. local dest="$1"
  50. rm -rf "$dest"
  51. mkdir -p "$dest"
  52. # Copy starter sources; link node_modules (agent must not need network).
  53. (cd "$STARTER" && find . -maxdepth 1 -mindepth 1 \
  54. ! -name node_modules ! -name .next ! -name test-results ! -name playwright-report \
  55. -exec cp -a {} "$dest/" \;)
  56. if [[ -d "$STARTER/node_modules" ]]; then
  57. # Hardlink clone, not a symlink — Turbopack refuses node_modules symlinks
  58. # that point outside the project root.
  59. cp -al "$STARTER/node_modules" "$dest/node_modules"
  60. else
  61. (cd "$dest" && pnpm install --frozen-lockfile --ignore-scripts --prefer-offline >/dev/null)
  62. fi
  63. # Dummy env — the agent NEVER sees real credentials.
  64. printf 'NEXT_PUBLIC_MAIN_TENANT_KEY=testtenant\nIBLAI_API_KEY=dummy-not-a-real-key\n' > "$dest/.env.local"
  65. printf 'DOMAIN=iblai.app\nPLATFORM=testtenant\nTOKEN=dummy-not-a-real-key\n' > "$dest/iblai.env"
  66. # Make every skill discoverable in the scratch project.
  67. mkdir -p "$dest/.claude"
  68. mkdir -p "$dest/.claude/skills"; for d in "$ROOT"/skills/*/*/; do cp -a "$d" "$dest/.claude/skills/"; done
  69. }
  70. json_field() { # json_field <file> <expr> (node-evaluated, prints value or empty)
  71. node -e "const m=require('$1');const v=$2;if(v)console.log(Array.isArray(v)?v.join('\n'):v)" 2>/dev/null || true
  72. }
  73. # ---- per-skill run -------------------------------------------------------
  74. overall=0
  75. for skill in "${skills[@]}"; do
  76. [[ -f "$(skill_path "$skill")/SKILL.md" ]] || { echo "✗ $skill: no such skill"; overall=1; continue; }
  77. scratch="$WORK/$skill"
  78. note "$skill → scratch $scratch"
  79. make_scratch "$scratch"
  80. prompt="Use the $skill skill to add its feature to this app. Follow the skill exactly. Do not ask questions; use placeholder values wherever a real ID, UUID, or credential is required. Stop when the skill's own verification steps pass or cannot proceed further without real credentials."
  81. log="$scratch/.agent-run.log"
  82. note "$skill: running agent (max ${MAX_TURNS} turns, ${AGENT_TIMEOUT}s cap)"
  83. if ! (cd "$scratch" && timeout "$AGENT_TIMEOUT" \
  84. claude -p "$prompt" --dangerously-skip-permissions --max-turns "$MAX_TURNS" \
  85. >"$log" 2>&1); then
  86. echo "✗ $skill: agent run failed or timed out — last 40 lines:"
  87. tail -40 "$log" | sed 's/^/ /'
  88. overall=1
  89. continue
  90. fi
  91. note "$skill: typecheck + build"
  92. if ! (cd "$scratch" && pnpm typecheck >"$scratch/.typecheck.log" 2>&1); then
  93. echo "✗ $skill: typecheck failed after agent run:"
  94. tail -30 "$scratch/.typecheck.log" | sed 's/^/ /'
  95. overall=1
  96. continue
  97. fi
  98. if ! (cd "$scratch" && pnpm build >"$scratch/.build.log" 2>&1); then
  99. echo "✗ $skill: build failed after agent run:"
  100. tail -30 "$scratch/.build.log" | sed 's/^/ /'
  101. overall=1
  102. continue
  103. fi
  104. # Optional assertions from skills/<skill>/test.json
  105. manifest="$(skill_path "$skill")/test.json"
  106. if [[ -f "$manifest" ]]; then
  107. while IFS= read -r f; do
  108. [[ -z "$f" ]] && continue
  109. [[ -e "$scratch/$f" ]] || { echo "✗ $skill: expected file missing: $f"; overall=1; }
  110. done < <(json_field "$manifest" "m.assert_files")
  111. fi
  112. # ---- tier 3: live platform (opt-in, real credentials from env) --------
  113. if [[ "${RUN_LIVE:-0}" == "1" ]]; then
  114. : "${AUTH_HOST:?RUN_LIVE=1 needs AUTH_HOST}"
  115. : "${PLAYWRIGHT_USERNAME:?RUN_LIVE=1 needs PLAYWRIGHT_USERNAME}"
  116. : "${PLAYWRIGHT_PASSWORD:?RUN_LIVE=1 needs PLAYWRIGHT_PASSWORD}"
  117. : "${IBLAI_TEST_TENANT_KEY:?RUN_LIVE=1 needs IBLAI_TEST_TENANT_KEY}"
  118. note "$skill: live tier — starting server"
  119. printf 'NEXT_PUBLIC_MAIN_TENANT_KEY=%s\nIBLAI_API_KEY=%s\n' \
  120. "$IBLAI_TEST_TENANT_KEY" "${IBLAI_TEST_API_KEY:-}" > "$scratch/.env.local"
  121. (cd "$scratch" && pnpm start >"$scratch/.server.log" 2>&1) &
  122. server_pid=$!
  123. trap 'kill $server_pid 2>/dev/null || true' EXIT
  124. for _ in $(seq 1 30); do
  125. curl -sf -o /dev/null "http://localhost:3000" && break
  126. sleep 1
  127. done
  128. # Real SSO login via the starter's own Playwright setup. Minimal reporter,
  129. # no traces/video/screenshots, sanitized failure output (URLs can carry
  130. # SSO authorization codes).
  131. if (cd "$scratch" && APP_HOST="http://localhost:3000" AUTH_HOST="$AUTH_HOST" \
  132. PLAYWRIGHT_USERNAME="$PLAYWRIGHT_USERNAME" PLAYWRIGHT_PASSWORD="$PLAYWRIGHT_PASSWORD" \
  133. pnpm exec playwright test e2e/auth.setup.ts --config e2e/playwright.config.ts --project=setup-chromium \
  134. --reporter=dot --trace=off \
  135. >"$scratch/.live.log" 2>&1); then
  136. note "$skill: live SSO login OK"
  137. else
  138. echo "✗ $skill: live SSO login failed (details withheld from log — see $scratch/.live.log locally)"
  139. overall=1
  140. fi
  141. kill "$server_pid" 2>/dev/null || true
  142. trap - EXIT
  143. fi
  144. echo "✓ $skill"
  145. done
  146. exit "$overall"

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.