diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index 6a87e18..1473325 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -10,6 +10,9 @@ on: jobs: sync: name: POST /functions/sync-templates + # Forks provide their own catalog delivery path. Never post a fork commit + # to InsForge's production marketplace sync endpoint. + if: github.repository == 'InsForge/insforge-templates' runs-on: ubuntu-latest steps: - name: Trigger sync diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index 04a6dee..7bdd5d6 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -31,13 +31,6 @@ jobs: working-directory: scripts run: npm test - # We deliberately do NOT run `npm install` on each template in CI: - # contributors install locally before opening a PR, package-lock.json - # makes the install reproducible, and the slow per-template install - # would dominate CI time as the registry grows. The static checks below - # (JSON parse, file existence, secret patterns, SQL parse, edge-function - # tsc) cover what install would catch except the rare "package was - # yanked from npm" case — we'll catch that via Dependabot/Snyk later. edge-function-tsc: name: tsc --noEmit on edge functions runs-on: ubuntu-latest @@ -92,3 +85,33 @@ jobs: exit 1 fi done + + publishable-builds: + name: Native template build and artifact admission + runs-on: ubuntu-latest + needs: [validate-registry] + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '22' + - name: Enable pinned package managers + run: corepack enable + - name: Build every native template with its controlled profile + run: | + { node -e "for (const item of require('./registry.json')) if (item.publishingCompatibility === 'native') console.log(item.slug + '\t' + item.buildProfile)"; printf 'react\tvite-npm-v1\ntodo\tnext-static-npm-v1\n'; } | + while IFS=$'\t' read -r slug profile; do + case "$profile" in + vite-npm-v1|next-static-npm-v1) + (cd "$slug" && npm ci --ignore-scripts && npm run build) + ;; + vite-pnpm-v1|next-static-pnpm-v1) + (cd "$slug" && pnpm install --frozen-lockfile --ignore-scripts && pnpm run build) + ;; + *) + echo "::error::$slug declares unknown controlled profile $profile" + exit 1 + ;; + esac + node scripts/verify-publishable-template.mjs "$slug" + done diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6339e87..b6cc0ec 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -24,6 +24,7 @@ Templates listed on https://insforge.dev/templates live in this repo. Adding one "framework": "nextjs", "features": ["auth", "ai"], "tags": ["my-tag"], + "requiredCapabilities": ["ai.chat", "ai.streaming", "storage"], "cover": "assets/covers/my-template.png", "demo_url": "https://my-demo.us-east.insforge.app", "author": "Your Name", @@ -31,6 +32,9 @@ Templates listed on https://insforge.dev/templates live in this repo. Adding one } ``` + `requiredCapabilities` is optional. Declare only capabilities the template actually uses; + Insight Flow rejects creation before provisioning when the active runtime cannot satisfy them. + 6. Open the PR. CI (`Validate Registry`) must be green. A maintainer will review and merge. ## CI checks diff --git a/README.md b/README.md index e644dd4..d5c839e 100644 --- a/README.md +++ b/README.md @@ -50,9 +50,11 @@ If you prefer to inspect a template manually, clone this repository, move into a | Template | Framework | Best for | Includes | | --- | --- | --- | --- | -| [`chatbot`](./chatbot) | Next.js App Router | Building an AI chat product on top of InsForge | Persisted chat history, file uploads, auth, storage, optional Vercel AI Gateway support | +| [`chatbot`](./chatbot) | Next.js App Router | Building an AI chat product on the Insight Flow runtime | Persisted chat history, streaming AI, file uploads, auth, and Platform-backed object storage | | [`crm`](./crm) | Next.js App Router | Building an authenticated internal tool or CRM | Sales pipeline, lead management, client flows, RLS, seeded defaults | | [`e-commerce`](./e-commerce) | Next.js App Router | Launching a storefront with user accounts and checkout | Seeded catalog, product pages, cart, checkout, account area, analytics | +| [`web-research-agent`](./web-research-agent) | React + Vite | Building evidence-led browser research workflows | Browser-backed investigations, cited synthesis, evidence ledger, auth, and RLS | +| [`website-change-monitor`](./website-change-monitor) | React + Vite | Tracking meaningful changes across important web pages | Scheduled checks, durable snapshots, before/after diffs, AI classification, auth, and RLS | ### Auth Provider Overlays @@ -100,6 +102,8 @@ For full setup details, go directly to the template README you want to use: - [`chatbot/README.md`](./chatbot/README.md) - [`crm/README.md`](./crm/README.md) - [`e-commerce/README.md`](./e-commerce/README.md) +- [`web-research-agent/README.md`](./web-research-agent/README.md) +- [`website-change-monitor/README.md`](./website-change-monitor/README.md) - [`nextjs/README.md`](./nextjs/README.md) - [`react/README.md`](./react/README.md) diff --git a/admin-dashboard/index.html b/admin-dashboard/index.html index d209b78..60d2647 100644 --- a/admin-dashboard/index.html +++ b/admin-dashboard/index.html @@ -8,6 +8,7 @@
+