@hailer/mcp 2.0.0-beta.5 → 2.0.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -30,10 +30,12 @@ Apps are scaffolded and published exclusively through the scripts: `npx @hailer/
30
30
  npx @hailer/create-app <project-name> --template react-ts
31
31
  ```
32
32
 
33
- - Run from a parent directory (`mkdir -p apps` first if needed)
34
- - NEVER copy an existing app scaffold fresh
35
- - The CLI is interactive-only via `npm create` always pass name + template as arguments
36
- - Then `cd apps/<project-name> && npm install`
33
+ **This exact form is non-interactive it runs with zero prompts. Do NOT deviate:**
34
+ - **`<project-name>` is a POSITIONAL argument, not a flag.** `--name <x>` is silently ignored and the CLI drops to an interactive "Project name:" prompt that hangs an agent. Put the name first, bare.
35
+ - **`--template` must be a real template name:** `react-ts` (recommended), `react`, `react-swc-ts`, `vanilla-ts`, `vanilla`, `preact-ts`, `preact`, `svelte-ts`, `svelte`. NOT `minimal` (invalid → drops to a "Select a framework" prompt that hangs).
36
+ - **Use a fresh, lowercase, kebab-case name** in an empty target dir — that skips the overwrite prompt AND the package-name prompt. e.g. `injured-players-cost`.
37
+ - Never run `npx @hailer/create-app` bare and never pipe input to it (`echo …|`, `printf`, `expect`) — the one-line form above already needs no input.
38
+ - Run from a parent directory (`mkdir -p apps` first if needed), NEVER copy an existing app, then `cd <project-name> && npm install`.
37
39
  </scaffold>
38
40
 
39
41
  <build>
@@ -12,10 +12,28 @@ triggers:
12
12
 
13
13
  Patterns and templates for building Hailer apps with @hailer/app-sdk.
14
14
 
15
+ <build-philosophy>
16
+ ## How to Build Fast: Correct Data First, Theme Does the Looks
17
+
18
+ The goal of the first version is **showing the correct data the user asked for** — not a custom-designed UI. Get the data right; the user iterates on looks afterward. Two rules make apps both fast and good:
19
+
20
+ 1. **Spend your effort on the data layer, because that's what's easy to get wrong.** Read the real field/phase/workflow IDs from `workspace/enums.ts` + `fields.ts` (never guess, never use labels as keys), fetch with the SDK, and read field values by ID. A dashboard that shows the *wrong* numbers beautifully is a failure; correct numbers in plain components is a success.
21
+
22
+ 2. **Do NOT hand-design UI or build a component library — the scaffold already installed the Hailer theme.** `main.tsx` wires `<ChakraProvider theme={hailerTheme}>`, so **every stock Chakra component is already on Hailer brand** (Nunito Sans, the full Hailer palette, light/dark via system) and there are **214 ready icons** in `src/hailer/theme/icons/`. Compose the UI from plain Chakra primitives — they look right for free:
23
+ - Layout: `Box`, `Flex`, `Grid`, `SimpleGrid`, `Stack`, `Container`
24
+ - Data: `Stat`/`StatLabel`/`StatNumber`/`StatHelpText` (stat cards), `Table`/`Thead`/`Tbody`/`Tr`/`Td`, `Card`/`CardHeader`/`CardBody`
25
+ - Text/state: `Heading`, `Text`, `Badge`, `Tag`, `Spinner`, `Skeleton`, `Alert`
26
+ - Import icons like `import { HailerSearch } from './hailer/theme/icons/HailerSearch'`
27
+
28
+ Don't write custom CSS, custom color values, or bespoke styled components on the first pass. Reach for a Chakra component; it's already themed. The user refines the look later — your job is correct data in a clean themed shell.
29
+
30
+ 3. **Always handle the three states** — loading (`Spinner`/`Skeleton`), empty (a `Text`, never a crash), and outside-Hailer (the app must render standalone — never block on `inside`). Real data is async; assume it's missing first.
31
+ </build-philosophy>
32
+
15
33
  <critical-rules>
16
34
  ## CRITICAL: Scaffolding and Data Sources
17
35
 
18
- **Scaffold new apps with `npx @hailer/create-app` — scaffold fresh, never copy an existing app.** Never manually create the project structure. (Apps are script-only — no MCP scaffold tool exists.)
36
+ **Scaffold with the exact non-interactive form: `npx @hailer/create-app <name> --template react-ts`.** The name is POSITIONAL (not `--name`), the template must be valid (`react-ts`/`react`/`vanilla-ts`/`svelte-ts`/…, NOT `minimal`), and the dir must be fresh that combination runs with zero prompts. A bare `npx @hailer/create-app`, a wrong `--name` flag, an invalid template, or piping input all drop into an interactive prompt that hangs the agent. Scaffold fresh, never copy an existing app, never hand-create the structure. (Apps are script-only — no MCP scaffold tool exists.)
19
37
 
20
38
  **For project data structure (workflows, fields, phases):**
21
39
  - READ workspace/ TypeScript files directly (fields.ts, phases.ts, enums.ts)
package/CLAUDE.md CHANGED
@@ -25,7 +25,7 @@ Before any MCP call, ask: "Is this answerable from `workspace/` files or a CLI?"
25
25
  | Create / modify insights config | Edit `insights.ts` → `npm run insights-push:force` | — (runtime `run_insight` is fine) |
26
26
  | Create / modify document templates | Edit `templates/` → `npm run templates-sync:force` | — |
27
27
  | Test function field code | vitest locally | `test_function_field` |
28
- | Scaffold an app | `npx @hailer/create-app` (fresh never copy an existing app) | — (script-only; no MCP tool exists) |
28
+ | Scaffold an app | `npx @hailer/create-app <name> --template react-ts` (name is POSITIONAL, not `--name`; bare command PROMPTS and hangs agents) | — (script-only; no MCP tool exists) |
29
29
  | Publish an app | `cd app && npm run publish-production -- --force` (add `--market` for marketplace versions) | — (script-only; no MCP tool exists) |
30
30
  | Create / modify apps registry | Edit `workspace/apps.ts` → `npx hailer-sdk ws-config apps push --force` | `manage_app` |
31
31
  | Create / update activities | MCP `create_activity`, `update_activity` | — |
@@ -99,7 +99,7 @@ Always use `:force` — the non-force variants prompt interactively.
99
99
 
100
100
  | Step | How |
101
101
  |------|-----|
102
- | Scaffold | `npx @hailer/create-app` — scaffold fresh, never copy an existing app |
102
+ | Scaffold | `npx @hailer/create-app <name> --template react-ts` (name POSITIONAL; bare = interactive prompt that hangs agents) — scaffold fresh, never copy an existing app |
103
103
  | Local dev | `cd app && npm run dev` |
104
104
  | Publish | `cd app && npm run publish-production -- --force` (add `--market` for marketplace; `--force` skips the overwrite prompt that hangs agents); then share via `manage_app` add_member |
105
105
  | Register / share | Edit `workspace/apps.ts` → `npx hailer-sdk ws-config apps push --force` |
@@ -142,4 +142,6 @@ Load in sub-agents via the Skill tool. Never in main context.
142
142
 
143
143
  **Essential:** `/save`, `/handoff`, `/prd`, `/autoplan`, `/ws-pull`
144
144
 
145
- **Squads** (drive the native Workflow tool): `/app-squad "<desc>"`, `/review-squad [target]`, `/debug-squad "<bug>"`
145
+ **Squads** (drive the native Workflow tool): `/review-squad [target]`, `/debug-squad "<bug>"`
146
+
147
+ Build apps with a single agent + the `hailer-app-builder` / `create-and-publish-app` skills — faster than fanning out a squad (no shared-contract prep, no cross-agent integration fixups).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hailer/mcp",
3
- "version": "2.0.0-beta.5",
3
+ "version": "2.0.0-beta.8",
4
4
  "config": {
5
5
  "docker": {
6
6
  "registry": "registry.gitlab.com/hailer-repos/hailer-mcp"
@@ -1,37 +0,0 @@
1
- ---
2
- description: Build a Hailer app with hyper-parallel component teams
3
- argument-hint: "app description"
4
- allowed-tools: Workflow, Bash, Read, Skill, Agent
5
- ---
6
- # App Squad
7
-
8
- Hyper-parallel app build: the orchestrator does ALL prep, then a Workflow fans out one agent per component with everything pre-loaded. Component agents do ZERO discovery — they just write code.
9
-
10
- **Goal:** $ARGUMENTS
11
-
12
- ## Step 1: Prep (you, before the Workflow)
13
-
14
- - **Schema**: read `workspace/enums.ts` + relevant `workspace/<Name>_<id>/fields.ts`/`phases.ts` via a fast sub-agent (never in main context). Only if there's no `workspace/` dir, fall back to MCP `describe_workflows` (+ `include: ["schema","phases"]`).
15
- - **Scaffold**: `npx @hailer/create-app` — NEVER copy an existing app. (Apps are script-only — no MCP scaffold tool exists.)
16
- - **Read the scaffold SDK**: `src/hailer/use-app.ts` (store API), `src/main.tsx` (providers), `ls src/hailer/theme/icons/`. Read one working app from `apps/` for live SDK patterns.
17
- - **Skills**: load `hailer-app-builder` + `hailer-design-system` once; their content goes into the contract.
18
-
19
- ## Step 2: Shared contract
20
-
21
- One document every agent receives verbatim: all workflow/field/phase IDs; the actual use-app.ts store shape and fetch patterns; helper functions; the component manifest (name, file path, props, renders what); exact import paths incl. icons; the working-app SDK patterns (**apps must render outside Hailer — never block on `inside`**); both skills' content.
22
-
23
- ## Step 3: Workflow fan-out
24
-
25
- Author a Workflow script (this command is your opt-in to call the Workflow tool): `parallel()` over the component manifest — Shell (App.tsx: nav, state, fetching), Overview (dashboard), List (table: filters, sorting), Detail (modal), plus one per extra workflow. Each agent gets the full contract + its mission and returns ONLY complete TypeScript/React code as its final text.
26
-
27
- ## Step 4: Assemble + verify (you)
28
-
29
- Write each component to its file, delete scaffold demo components, fix import/prop mismatches, then `npx tsc --noEmit` and `npx vite build`. Under ~5 errors: fix directly; structural failures: re-spawn that one agent with the error and contract.
30
-
31
- Report: path, component count, build/TS status, next steps (`cd apps/<name> && npm run dev`, test in the Hailer iframe).
32
-
33
- ## Rules
34
-
35
- - NEVER copy existing apps — scaffold fresh
36
- - Agents never load skills or read files — you pre-load and paste
37
- - Include ACTUAL SDK code in the contract, not summaries