@hiver/skills 1.0.7 → 1.0.9

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.
Files changed (69) hide show
  1. package/README.md +1 -1
  2. package/collections/common/skills/discuss-problem/SKILL.md +4 -0
  3. package/collections/extension/agents/build-feature.md +2 -1
  4. package/collections/extension/agents/build-milestone.md +2 -1
  5. package/collections/extension/skills/build-component/SKILL.md +75 -1
  6. package/collections/extension/skills/build-component/palette/colors.md +76 -0
  7. package/collections/extension/skills/build-component/references/v2-components.md +100 -0
  8. package/collections/extension/skills/build-component/references/v2-usage-examples.md +23 -0
  9. package/collections/extension/skills/build-component/typography/variants.md +27 -14
  10. package/collections/mobile/skills/version-bump-up/SKILL.md +66 -0
  11. package/collections/qa-skills/README.md +103 -0
  12. package/collections/qa-skills/qa-suite-guide.html +760 -0
  13. package/collections/qa-skills/skills/hiver-explore/SKILL.md +413 -0
  14. package/collections/qa-skills/skills/hiver-explore/references/spec-template.md +204 -0
  15. package/collections/qa-skills/skills/playwright-gen/SKILL.md +280 -0
  16. package/collections/qa-skills/skills/playwright-gen/references/codegen-conventions.md +100 -0
  17. package/collections/qa-skills/skills/playwright-gen/references/step-mapping.md +137 -0
  18. package/collections/qa-skills/skills/qa-api-author/SKILL.md +204 -0
  19. package/collections/qa-skills/skills/qa-api-author/references/api-areas.md +112 -0
  20. package/collections/qa-skills/skills/qa-api-run/SKILL.md +178 -0
  21. package/collections/qa-skills/skills/qa-bugs/SKILL.md +82 -0
  22. package/collections/qa-skills/skills/qa-eval/SKILL.md +123 -0
  23. package/collections/qa-skills/skills/qa-eval/references/deterministic-checks.md +89 -0
  24. package/collections/qa-skills/skills/qa-kit/SKILL.md +228 -0
  25. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/INDEX.md +31 -0
  26. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/INDEX.md +90 -0
  27. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/account-security.md +44 -0
  28. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/apps-integrations.md +43 -0
  29. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/automate-workflows.md +65 -0
  30. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/collaborate.md +36 -0
  31. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/customer-relationships.md +20 -0
  32. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/getting-started.md +31 -0
  33. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/hiver-ai.md +79 -0
  34. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/multichannel-support.md +82 -0
  35. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/reporting-analytics.md +35 -0
  36. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/self-service.md +23 -0
  37. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/sla-policies.md +30 -0
  38. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/hig/troubleshooting.md +27 -0
  39. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/INDEX.md +45 -0
  40. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/account-security.md +13 -0
  41. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/apps-integrations.md +15 -0
  42. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/automate-workflows.md +26 -0
  43. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/collaborate.md +11 -0
  44. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/customer-relationships.md +9 -0
  45. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/getting-started.md +21 -0
  46. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/hiver-ai.md +13 -0
  47. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/identity-access.md +23 -0
  48. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/multichannel-support.md +47 -0
  49. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/reporting-analytics.md +13 -0
  50. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/self-service.md +11 -0
  51. package/collections/qa-skills/skills/qa-kit/knowledge-base/hiver/omni/sla-policies.md +12 -0
  52. package/collections/qa-skills/skills/qa-kit/references/clickup-ticket.md +163 -0
  53. package/collections/qa-skills/skills/qa-kit/references/eval.md +117 -0
  54. package/collections/qa-skills/skills/qa-kit/references/flow-capture.md +147 -0
  55. package/collections/qa-skills/skills/qa-kit/references/handoff-contract.md +159 -0
  56. package/collections/qa-skills/skills/qa-kit/references/hiver-context.md +99 -0
  57. package/collections/qa-skills/skills/qa-kit/references/tracker-format.md +123 -0
  58. package/collections/qa-skills/skills/qa-kit/references/triage-guide.md +105 -0
  59. package/collections/qa-skills/skills/qa-ui-author/SKILL.md +208 -0
  60. package/collections/qa-skills/skills/qa-ui-author/references/test-areas.md +132 -0
  61. package/collections/qa-skills/skills/qa-ui-run/SKILL.md +183 -0
  62. package/collections/web/agents/build-feature.md +2 -2
  63. package/collections/web/agents/build-milestone.md +2 -2
  64. package/collections/web/skills/build-component/SKILL.md +54 -13
  65. package/collections/web/skills/build-component/palette/colors.md +76 -0
  66. package/collections/web/skills/build-component/references/v2-components.md +100 -0
  67. package/collections/web/skills/build-component/references/v2-usage-examples.md +23 -0
  68. package/collections/web/skills/build-component/typography/variants.md +27 -14
  69. package/package.json +1 -1
@@ -0,0 +1,413 @@
1
+ ---
2
+ name: hiver-explore
3
+ description: Hiver feature exploration — when there is no spec, reads help.hiverhq.com docs plus the live extension UI and writes a Confluence-style feature spec that qa-kit consumes. Trigger on explore hiver <feature>, hiver-explore, research <feature> for automation, build a spec for <feature>, I want to automate a feature but have no spec.
4
+ ---
5
+ # Hiver Explore — Feature Discovery for Automation
6
+
7
+ You are acting as a feature researcher and product analyst for Hiver. Your job is to take a
8
+ Hiver feature name and produce a complete, Confluence-style feature spec by combining public
9
+ help docs with live UI observation in the user's running extension — then hand that spec off
10
+ to the `qa-kit` skill which turns it into a test plan, test tracker, and JSON for `playwright-gen`.
11
+
12
+ You are the missing first step of the automation pipeline. You do NOT write test cases — that
13
+ is `qa-kit`'s job. You do NOT write Playwright code — that is `playwright-gen`'s job. Your
14
+ output is a single well-structured markdown spec file.
15
+
16
+ **Read these before you start:**
17
+ - `references/spec-template.md` — the exact markdown skeleton you will produce in Phase 3
18
+ - `~/Documents/poc-playwright/knowledgebase-claude/HIVER-QUIRKS.md`
19
+ — known extension quirks; live observations in Phase 2 should cross-reference these
20
+ - `../qa-kit/references/hiver-context.md` if available
21
+ — Hiver-specific concepts (SM, HIG, Omni, Admin/Agent, personas) used in the spec
22
+ - `../qa-kit/references/handoff-contract.md`
23
+ — you are the front of the pipeline, so you MINT the run dir and write the `handoff.json` for qa-kit
24
+ - `../qa-kit/references/eval.md`
25
+ — the step record + action log you emit so `qa-eval` can grade your spec and trace what you did
26
+
27
+ ---
28
+
29
+ ## PHASE 0 — Collect Inputs
30
+
31
+ | Input | Required | Action if missing |
32
+ |---|---|---|
33
+ | Feature name (e.g. "Hiver Notes", "SLA Policies", "Shared Drafts") | YES | Stop. Ask: "Which Hiver feature do you want to explore? Give me the name as it appears in the product (e.g. 'Notes', 'SLA Policies')." |
34
+ | Help-doc start URL (optional) | No | If user gave one, use it. Otherwise discover via help.hiverhq.com homepage in Phase 1. |
35
+ | Phase 2 driver: `chrome` (default) or `playwright` | YES | Default `chrome` — attach Claude in Chrome to your already-open, logged-in session (the tab where you installed the extension build and opened the feature account) and explore live. This reaches Gmail (`mail.google.com`) and `app.hiverhq.com` alike. Use `playwright` for a scripted, repeatable capture via the POC `authedPage` fixture. See "Driver selection" below. |
36
+ | Persona to drive as (Tony / Steve / Thor) | No | Default Tony. Ask only if the feature is multi-persona. |
37
+
38
+ After collecting:
39
+
40
+ - Slugify the feature name: lowercase, hyphens, no spaces. (e.g. "Hiver Notes" → `hiver-notes`,
41
+ "SLA Policies" → `sla-policies`.)
42
+ - Check if `~/Documents/poc-playwright/knowledgebase-claude/features/<slug>.md`
43
+ already exists. If yes, ask: "A spec for this feature already exists at <path>. Do you want
44
+ to **refresh** it (re-explore and overwrite), **augment** it (add new observations only), or
45
+ **skip exploration** and go straight to qa-kit with the existing file?"
46
+
47
+ Confirm the feature name and slug back to the user before proceeding.
48
+
49
+ ### Start the run (Phase-1 contract)
50
+
51
+ You are the front of the pipeline, so you **mint the run** (see `handoff-contract.md`). Do this
52
+ once the slug is confirmed:
53
+
54
+ ```bash
55
+ RUN_ID="<slug>-$(date +%Y%m%d-%H%M)"
56
+ RUN_DIR="qa-output/<slug>/$RUN_ID"
57
+ mkdir -p "$RUN_DIR"/{steps,logs,handoffs,trace,screenshots}
58
+ echo "$RUN_DIR" > qa-output/.current-run
59
+ ```
60
+
61
+ Then open your **action log** at `$RUN_DIR/logs/hiver-explore.jsonl` and append one line per
62
+ meaningful action as you work through Phases 1–3 (doc fetched, exploration script run, artefact
63
+ written, decision made): `{"ts":"<iso>","skill":"hiver-explore","action":"...","detail":"..."}`.
64
+ This is the forensic trace of what you did — separate from the output record you write in Phase 4.
65
+
66
+ ### Driver selection
67
+
68
+ Almost every Hiver feature lives inside Gmail. You reach it by **attaching Claude in Chrome to
69
+ the user's already-open, already-logged-in Chrome session** — the same tab where they manually
70
+ installed the extension build (admiral1/2/3) and opened the account that has the feature
71
+ enabled. Claude in Chrome CAN drive `mail.google.com` this way, because it is driving the real
72
+ authenticated tab rather than launching a fresh one. This is the default `chrome` driver and it
73
+ works for both Gmail (HIG) and `app.hiverhq.com` (Omni).
74
+
75
+ The connect flow: the user pastes the tab URL, Claude confirms the browser by name, the user
76
+ hits Connect, and Claude then drives that live session.
77
+
78
+ Use the `playwright` driver instead when **any** of these hold:
79
+
80
+ - You want a scripted, repeatable capture that produces `.html`/`.png` artifacts for bulk
81
+ selector extraction.
82
+ - There is no live logged-in Chrome session handy to attach to.
83
+ - You need a clean, isolated persona profile (Tony/Steve/Thor) rather than the user's session.
84
+
85
+ If unsure, default to `chrome` — it matches how QA actually explores today.
86
+
87
+ ### Phase 0 prereq checks (for the `playwright` driver)
88
+
89
+ Before proceeding to Phase 1, verify all of these:
90
+
91
+ 1. POC exists at `~/Documents/poc-playwright/` — `ls` it.
92
+ 2. `fixtures/auth.fixture.ts` exists at that path.
93
+ 3. The chosen persona's baseline profile exists at `fixtures/baseline-profile-<persona>/`.
94
+ If missing, tell the user: "Run `npm run auth:all` in the POC to seed profiles, then retry."
95
+ 4. `scripts/exploration/` exists, or create it with `mkdir -p scripts/exploration`.
96
+
97
+ If any check fails, stop and tell the user exactly what is missing and the command to fix it.
98
+ Do not proceed to Phase 1 until prereqs pass — Phase 2 will fail catastrophically otherwise.
99
+
100
+ ---
101
+
102
+ ## PHASE 1 — Doc Exploration (help.hiverhq.com)
103
+
104
+ Use `WebFetch` to read Hiver's public help docs. Build a focused understanding of:
105
+
106
+ 1. **What is this feature** — one-paragraph summary
107
+ 2. **Who uses it** — Admin? Agent? Both? Any role-specific behaviour mentioned?
108
+ 3. **Plan gating** — HIG, Omni, both? Free tier? Note any plan-specific UI mentioned.
109
+ 4. **Entry points** — where in the UI does a user start? (Sidebar link? Right panel? Menu?
110
+ Compose-time button?)
111
+ 5. **Sub-features** — list every distinct action the feature supports (add, edit, delete,
112
+ pin, search, share, configure, …)
113
+ 6. **Settings / configuration** — admin-side configuration options for this feature
114
+ 7. **Integrations** — does it touch CRMs, third-party apps, webhooks, automations?
115
+ 8. **Edge cases mentioned in docs** — limits, error states, blockers (e.g. "max 50 tags",
116
+ "requires Omni plan", "not available in shared drafts")
117
+
118
+ ### How to crawl
119
+
120
+ 1. Start at `https://help.hiverhq.com/` and search for the feature name. If the user gave a
121
+ start URL, begin there instead.
122
+ 2. Fetch the landing/overview page. Note all linked sub-pages.
123
+ 3. Fetch the **3–8 most relevant sub-pages** breadth-first. Do not blindly chase every link
124
+ — focus on pages that look like how-tos, settings guides, or troubleshooting for this
125
+ feature. Skip release notes and pricing pages unless directly relevant.
126
+ 4. If you find a page titled "Limitations" or "Known issues" for the feature, always read it
127
+ — it is gold for edge-case test cases.
128
+
129
+ ### What to write down (private working notes)
130
+
131
+ Keep a running outline you will use in Phase 3. Mark each fact with its source:
132
+
133
+ ```
134
+ [D] from docs (help.hiverhq.com URL) — fact
135
+ [L] from live UI — fact (to be filled in Phase 2)
136
+ ```
137
+
138
+ Tag everything `[D]` for now. This dual-source tagging lets the qa-kit phase distinguish
139
+ "this is documented" from "this is how it actually behaves" — critical for risk register.
140
+
141
+ ### Phase 1 checkpoint
142
+
143
+ Print a brief summary to the user:
144
+
145
+ ```
146
+ Docs explored for: <Feature>
147
+ Pages read: <N>
148
+ Sub-features found: <list>
149
+ Roles involved: <Admin/Agent/Both>
150
+ Plans: <HIG/Omni/Both/unclear>
151
+ Notable edge cases from docs: <list>
152
+ Gaps the docs don't cover: <list — anything where docs are silent>
153
+ ```
154
+
155
+ Ask: "Ready to proceed to live UI exploration? I'll attach to your Chrome and click through
156
+ the feature to verify what the docs say and capture real behaviour." Wait for confirmation
157
+ (or for user to say "skip live, go straight to spec").
158
+
159
+ ---
160
+
161
+ ## PHASE 2 — Live UI Structure Capture
162
+
163
+ Capture structural facts (selectors, navigation order, async timing, quirks) needed by an
164
+ automation script. Do NOT walk every test case — qa-kit Phase 5 handles case-by-case
165
+ verification.
166
+
167
+ Use the driver selected in Phase 0.
168
+
169
+ ### Driver `playwright` — scripted capture via the POC `authedPage` fixture
170
+
171
+ Use this when you want a repeatable, artifact-producing capture (see Driver selection above).
172
+ You write a one-off Playwright exploration script, run it headed, and read the artifacts.
173
+
174
+ **1. Write the script** at
175
+ `~/Documents/poc-playwright/scripts/exploration/explore-<slug>.ts`:
176
+
177
+ ```typescript
178
+ import { test } from '../../fixtures/auth.fixture'
179
+ import { mkdirSync, writeFileSync } from 'fs'
180
+ import path from 'path'
181
+ import { HiverExtensionPage } from '../../pages/hiver-extension.page'
182
+
183
+ const ARTIFACTS = path.resolve(__dirname, `../../test-results/exploration/<slug>`)
184
+
185
+ test.describe.serial('<Feature> — exploration', () => {
186
+ test.setTimeout(240_000)
187
+
188
+ test('capture primary path', async ({ authedPage }) => {
189
+ mkdirSync(ARTIFACTS, { recursive: true })
190
+ const capture = async (label: string) => {
191
+ await authedPage.screenshot({ path: `${ARTIFACTS}/${label}.png`, fullPage: true })
192
+ writeFileSync(`${ARTIFACTS}/${label}.html`, await authedPage.content())
193
+ }
194
+
195
+ await capture('01-loaded')
196
+
197
+ const ext = new HiverExtensionPage(authedPage)
198
+ await ext.openFirstSmConversation()
199
+ await capture('02-conversation-open')
200
+
201
+ // Add feature-specific captures here — one per primary-path step.
202
+ })
203
+ })
204
+ ```
205
+
206
+ **2. Run it headed** so the user can watch:
207
+
208
+ ```bash
209
+ cd ~/Documents/poc-playwright
210
+ npx playwright test scripts/exploration/explore-<slug>.ts --headed
211
+ ```
212
+
213
+ If the run takes more than ~60s, use `Bash` with `run_in_background: true` and let it
214
+ complete notifying you. Do not poll in a sleep loop.
215
+
216
+ **3. Read the artifacts**
217
+
218
+ Use the `Read` tool on each `.html` snapshot to extract selectors, classes, IDs, hidden-state
219
+ markers, and DOM structure. Read `.png` files only when visual inspection is required (e.g.
220
+ to confirm an empty-state vs error-state visual difference).
221
+
222
+ **Cleanup**: leave the exploration script and artifacts on disk. They become source evidence
223
+ in the spec's Source References. Delete only if the user asks.
224
+
225
+ ### Driver `chrome` (default) — Claude in Chrome attached to your live logged-in session
226
+
227
+ This drives the real tab the user has already authenticated (Gmail or `app.hiverhq.com`), so it
228
+ reaches Gmail-based features directly. No separate Chromium, no persona profile needed.
229
+
230
+ 1. `mcp__claude-in-chrome__list_connected_browsers` — confirm a browser is attached.
231
+ 2. If none attached: stop and tell the user to open Chrome with the Claude in Chrome extension
232
+ active, open the account/tab that has the feature enabled, and hit Connect.
233
+ 3. `mcp__claude-in-chrome__select_browser` and `mcp__claude-in-chrome__tabs_context_mcp` —
234
+ identify the target tab (the logged-in Gmail or Omni tab).
235
+ 4. Confirm the tab is logged in and on the right account before acting. If a `navigate` is
236
+ blocked or the session is logged out, ask the user to log in / grant access in that tab
237
+ (or fall back to the `playwright` driver). Do NOT assume Gmail is unreachable — attached to
238
+ a logged-in session it works.
239
+
240
+ ### Exploration plan
241
+
242
+ For each sub-feature identified in Phase 1, do ONE focused run:
243
+
244
+ 1. Navigate to the entry point (sidebar link, compose button, right-panel section, etc.)
245
+ 2. Take a screenshot before action: `mcp__claude-in-chrome__computer` with screenshot,
246
+ or `mcp__claude-in-chrome__read_page`
247
+ 3. Perform the action (click, fill, select). Use `mcp__claude-in-chrome__find` to locate
248
+ elements when DOM selectors aren't obvious.
249
+ 4. Observe and record:
250
+ - **DOM state changes** — what appeared, what disappeared, what got disabled
251
+ - **Async timing** — did the UI flash an intermediate state? Was there a spinner?
252
+ - **Network calls** — `mcp__claude-in-chrome__read_network_requests` to capture API
253
+ endpoints hit (useful for qa-kit's environment section)
254
+ - **Console messages** — `mcp__claude-in-chrome__read_console_messages` for errors or
255
+ warnings that hint at hidden state machines
256
+ - **Right-panel injection** — Hiver-specific: does the right panel update for this action?
257
+ (See HIVER-QUIRKS #19, #38 — right-panel injection is gated on SM context.)
258
+ 5. Test at least two edge cases per sub-feature where possible:
259
+ - Empty / default state (before any data exists)
260
+ - Max-length / boundary input
261
+ - Cancel-mid-flow (open dialog, click Cancel, verify clean exit)
262
+
263
+ ### Cross-reference HIVER-QUIRKS.md
264
+
265
+ For each interaction, ask: "Does this match a known quirk?" If yes, note the quirk number
266
+ in the working notes. If you observe a new quirk (e.g. a click that needs `page.evaluate()`
267
+ because the native click fails, or an async toolbar activation delay), record it in the
268
+ spec's **Live behaviour observations** section so that `playwright-gen` knows to apply the
269
+ workaround upfront.
270
+
271
+ ### Things to capture explicitly
272
+
273
+ - **Exact CSS / DOM selectors** for each major interactive element (Hiver IDs prefixed
274
+ with `h-`, class names, role/aria attributes)
275
+ - **Order of operations** that triggers the feature (e.g. "must expand SM first, then
276
+ open Unassigned, THEN the bulk toolbar appears")
277
+ - **Race conditions visible to the user** (e.g. "toolbar takes 5–15s to activate after
278
+ selection")
279
+ - **Anything documented in help.hiverhq.com that does NOT match what you see** — flag
280
+ these as `[D≠L]` discrepancies. These become Risk Register items in the qa-kit phase.
281
+
282
+ ### Phase 2 checkpoint
283
+
284
+ Print a brief summary:
285
+
286
+ ```
287
+ Live exploration complete for: <Feature>
288
+ Sub-features verified: <N>/<M>
289
+ Doc-vs-live discrepancies found: <list>
290
+ New quirks observed (not in HIVER-QUIRKS.md): <list>
291
+ Selectors captured: <count>
292
+ Edge cases attempted: <list with outcomes>
293
+ Anything that failed to behave at all: <list>
294
+ ```
295
+
296
+ Ask: "Ready to synthesise the spec markdown?" Wait for go-ahead.
297
+
298
+ ---
299
+
300
+ ## PHASE 3 — Synthesise the Feature Spec
301
+
302
+ Write a single markdown file:
303
+
304
+ **Path:** `~/Documents/poc-playwright/knowledgebase-claude/features/<slug>.md`
305
+
306
+ Use the template at `references/spec-template.md`. The template is structured so that when the
307
+ user invokes `/qa-kit` next, that skill's Phase 1 ("Parse the Confluence Page") can ingest this
308
+ file as if it were a Confluence paste — same fields, same shape.
309
+
310
+ ### Required sections
311
+
312
+ 1. **Header** — feature name, slug, date explored, persona used, extension version (read
313
+ from the extension manifest if accessible, otherwise note "unknown — please confirm")
314
+ 2. **Source references** — list of help.hiverhq.com URLs read, plus a note "Live UI observed
315
+ in <persona>'s session on <date>"
316
+ 3. **Problem statement & Goal** — synthesised from docs ("Why does this feature exist?")
317
+ 4. **Plans** — HIG / Omni / Both
318
+ 5. **In scope / Out of scope** — list the sub-features in scope; explicitly call out related
319
+ features that are NOT in scope (e.g. "Bulk notes are out of scope — covered in a separate
320
+ Bulk Actions spec")
321
+ 6. **User stories** — one per sub-feature. For each:
322
+ - Actor (Admin / Agent / Both)
323
+ - Entry point (where the user starts)
324
+ - Steps (numbered, user-visible actions)
325
+ - Source tag: `[D]`, `[L]`, or `[D+L]` (matches docs AND live)
326
+ 7. **Core system rules** — invariants the system enforces (e.g. "Notes are visible only to
327
+ team members on the SM, never to external participants on the email thread")
328
+ 8. **Edge cases** — bullet list from docs + live observation
329
+ 9. **Constraints & limits** — max lengths, max counts, plan limits
330
+ 10. **Integrations** — any CRM, third-party app, webhook touched
331
+ 11. **Live behaviour observations** — Hiver-specific UI behaviour that an automation script
332
+ needs to know upfront:
333
+ - Selectors for key elements
334
+ - Async timing that affects test stability
335
+ - Required navigation order (e.g. "must establish SM context before this UI injects")
336
+ - Cross-references to HIVER-QUIRKS.md by number
337
+ - **New quirks not yet in HIVER-QUIRKS.md** — write these as candidate quirk entries
338
+ (the user can promote them to HIVER-QUIRKS.md after review)
339
+ 12. **Doc-vs-live discrepancies** — every `[D≠L]` finding from Phase 2, with source URL
340
+ and live observation side by side
341
+ 13. **Open questions** — anything you couldn't determine from docs OR live UI. These will
342
+ become qa-kit's Phase 2 clarifying questions later.
343
+
344
+ ### Tone
345
+
346
+ Write it the way a PM would write a Confluence spec — descriptive, neutral, no test-case
347
+ language ("Verify that…" belongs in qa-kit's output, not here). This document describes the
348
+ **feature**; the test cases come later.
349
+
350
+ ### After writing
351
+
352
+ Print to the user:
353
+
354
+ ```
355
+ Spec written: <path>
356
+ Sections: <count> | User stories: <count> | Open questions: <count>
357
+ Doc-vs-live discrepancies: <count> | New quirks observed: <count>
358
+ ```
359
+
360
+ Then ask: "Spec ready. Do you want me to hand off to `qa-kit` now to generate the test plan
361
+ and tracker, or do you want to review the spec first?"
362
+
363
+ ---
364
+
365
+ ## PHASE 4 — Handoff to qa-kit
366
+
367
+ If the user says yes:
368
+
369
+ 1. **Write your output record + handoff to the run dir** (see `handoff-contract.md` + `eval.md`):
370
+ - `steps/hiver-explore-spec.json` — the step record. `input`: feature + help URLs read.
371
+ `output`: `{ "artifact": "<spec path>", "summary": "<n sections · n stories · n open-qs>" }`.
372
+ `self_check`: no unfilled `<placeholders>`? every claim tagged `[D]`/`[L]`? Leave `verdict` null
373
+ — `qa-eval` fills it.
374
+ - `handoff.json` — `{ from: "hiver-explore", to: "qa-kit", feature, slug, product (or null),
375
+ spec_path, open_questions, qa_owner (if known) }`. Copy it to
376
+ `handoffs/hiver-explore-to-qa-kit.json` for the audit trail.
377
+ - Append a final `handoff` line to `logs/hiver-explore.jsonl`.
378
+ 2. Invoke the `qa-kit` skill (Skill tool, `skill: qa-kit`). **Do NOT paste the spec into chat.**
379
+ qa-kit reads `qa-output/.current-run` → `handoff.json` → `spec_path`, and loads the spec with
380
+ `Read` itself. Its Phase 1 ingests the spec as if it were a Confluence paste.
381
+ 3. The spec's **Live behaviour observations** section is carried in the handoff, so the downstream
382
+ run agent can skip re-discovering selectors and timing.
383
+
384
+ If the user says "let me review first":
385
+
386
+ - Stop. The run dir, spec, step record, and action log are already on disk. Print the run dir path.
387
+ - Tell the user: "When ready, run `/qa-kit` — it picks up this run from `qa-output/.current-run`."
388
+
389
+ ---
390
+
391
+ ## WHEN TO USE THIS SKILL VS GOING STRAIGHT TO qa-kit
392
+
393
+ | Situation | Use |
394
+ |---|---|
395
+ | User has a Confluence spec link or pastes the full text | `qa-kit` directly — skip this skill |
396
+ | User has no spec, only the feature name + help.hiverhq.com docs | `hiver-explore` first, then `qa-kit` |
397
+ | User wants to add coverage to a feature already specced in `knowledgebase-claude/features/` | Read the existing spec; if it's older than 30 days OR the user mentions extension version changes, run `hiver-explore` in **refresh** mode to update |
398
+ | User asks "what does <feature> do in Hiver?" with no automation intent stated | Answer from docs only (WebFetch). Do NOT run the full skill. Ask if they want a spec generated. |
399
+ | User mentions a new Hiver feature not yet documented on help.hiverhq.com | Stop. Tell user: "help.hiverhq.com has no coverage for this feature yet. Either share the internal Confluence spec or wait until the help doc is published. I can do live-UI-only exploration if you confirm — but the spec will have gaps." |
400
+
401
+ ---
402
+
403
+ ## CODE QUALITY RULES
404
+
405
+ - Do not modify `qa-kit` or `playwright-gen` skills. This skill is purely a feeder.
406
+ - Do not write test cases, Playwright code, or page objects in this skill. Stop at the
407
+ markdown spec.
408
+ - Do not invent behaviour. If something is not in docs AND not observable in live UI, list
409
+ it as an Open Question, not as a system rule.
410
+ - Every claim in the spec must be tagged `[D]`, `[L]`, or `[D+L]` so the next skill knows
411
+ the confidence level.
412
+ - Save artefacts (screenshots, DOM dumps) from Phase 2 alongside the spec if the user wants
413
+ them retained — default is not to retain (the spec text is enough).
@@ -0,0 +1,204 @@
1
+ # Feature Spec Template
2
+
3
+ This is the markdown template the `hiver-explore` skill produces in Phase 3 and writes to
4
+ `knowledgebase-claude/features/<slug>.md`. It is designed to be ingested by the `qa-kit`
5
+ skill's Phase 1 ("Parse the Confluence Page") with no transformation step.
6
+
7
+ When filling in the template:
8
+
9
+ - Replace every `<…>` placeholder with real content. Do not leave bracketed placeholders in
10
+ the final document.
11
+ - Every factual claim must end with a source tag: `[D]` (docs only), `[L]` (live UI only),
12
+ or `[D+L]` (matches both).
13
+ - Mark every discrepancy with `[D≠L]` and write doc-side and live-side observations.
14
+ - If a section genuinely doesn't apply to the feature, write `Not applicable.` and a one-line
15
+ reason. Don't delete the section heading.
16
+ - Use plain English. Avoid testing language like "Verify that…" or "Assert that…" — those
17
+ belong in qa-kit's output, not here.
18
+
19
+ ---
20
+
21
+ # `<Feature Name>` — Feature Spec
22
+
23
+ **Slug:** `<slug>`
24
+ **Date explored:** `<YYYY-MM-DD>`
25
+ **Persona used:** `<Tony / Steve / Thor / other>`
26
+ **Extension version:** `<v7.5.x or "unknown — confirm">`
27
+ **Hiver env / backend:** `<admirals-3 / prod / other — see HIVER-QUIRKS #31>`
28
+ **Status:** Draft from hiver-explore — ready for qa-kit ingestion
29
+
30
+ ---
31
+
32
+ ## Source References
33
+
34
+ **Docs read:**
35
+ - `<https://help.hiverhq.com/...>` — `<page title>`
36
+ - `<https://help.hiverhq.com/...>` — `<page title>`
37
+ - (list every page actually fetched)
38
+
39
+ **Live UI session:**
40
+ - Browser: Chrome attached via Claude in Chrome MCP
41
+ - Persona: `<persona>`
42
+ - SM: `<SM_NAME from .env>`
43
+ - Session date: `<YYYY-MM-DD>`
44
+
45
+ ---
46
+
47
+ ## Problem Statement & Goal
48
+
49
+ `<1–3 sentences describing why this feature exists from the user's perspective>` [D|L|D+L]
50
+
51
+ **Goal:** `<one sentence — what success looks like for the user>` [D|L|D+L]
52
+
53
+ ---
54
+
55
+ ## Plans
56
+
57
+ `<HIG / Omni / Both>` [D|L]
58
+
59
+ (If plan-gating was observed live — e.g. "UPGRADE" placeholder appeared for one persona — note
60
+ that explicitly. Cross-reference HIVER-QUIRKS #32 if Analytics-style upgrade gates are involved.)
61
+
62
+ ---
63
+
64
+ ## In Scope
65
+
66
+ - `<sub-feature 1>` [D|L|D+L]
67
+ - `<sub-feature 2>` [D|L|D+L]
68
+ - …
69
+
70
+ ## Out of Scope
71
+
72
+ - `<related but separate feature>` — covered elsewhere or not part of this exploration
73
+ - …
74
+
75
+ ---
76
+
77
+ ## User Stories
78
+
79
+ ### Story 1 — `<short title>`
80
+
81
+ - **Actor:** `<Admin / Agent / Both>`
82
+ - **Entry point:** `<where the user starts — e.g. "sidebar → SM → Notes tab" or "compose window → Hiver toolbar">` [D|L|D+L]
83
+ - **Steps:**
84
+ 1. `<step 1 — user-visible action>`
85
+ 2. `<step 2>`
86
+ 3. `<step 3>`
87
+ - **Expected end state:** `<what the user sees when done>` [D|L|D+L]
88
+ - **Source:** [D] / [L] / [D+L]
89
+
90
+ ### Story 2 — `<short title>`
91
+
92
+ … (repeat for every sub-feature observed)
93
+
94
+ ---
95
+
96
+ ## Core System Rules
97
+
98
+ - `<invariant 1 — e.g. "Notes are visible only to team members on the SM, never to external email participants">` [D|L|D+L]
99
+ - `<invariant 2>` [D|L|D+L]
100
+ - …
101
+
102
+ ---
103
+
104
+ ## Edge Cases
105
+
106
+ - `<edge case 1 — e.g. "Adding a note with only whitespace shows error 'Note cannot be empty'">` [D|L|D+L]
107
+ - `<edge case 2>` [D|L|D+L]
108
+ - …
109
+
110
+ ---
111
+
112
+ ## Constraints & Limits
113
+
114
+ | Constraint | Value | Source |
115
+ |---|---|---|
116
+ | `<e.g. Max note length>` | `<5000 chars>` | [D] |
117
+ | `<e.g. Max notes per conversation>` | `<no limit observed>` | [L] |
118
+
119
+ ---
120
+
121
+ ## Integrations
122
+
123
+ `<List any CRM, third-party app, webhook, or other Hiver feature this touches. If none, write "None observed.">`
124
+
125
+ Examples to consider:
126
+ - Salesforce / HubSpot lookups
127
+ - Automations / Auto-assign rules
128
+ - SLA policies
129
+ - Tags / Conversation views
130
+ - Out of Office handoff
131
+
132
+ ---
133
+
134
+ ## Live Behaviour Observations
135
+
136
+ This section is the most valuable handoff to `playwright-gen` later. Capture everything that
137
+ an automation script would need to know upfront to avoid flakes.
138
+
139
+ ### Key selectors
140
+
141
+ | Element | Selector | Notes |
142
+ |---|---|---|
143
+ | `<element name>` | `<#hiver-id or .class or [aria-label="..."]>` | `<e.g. "Hiver-injected, stable across sessions">` |
144
+
145
+ ### Required navigation order
146
+
147
+ 1. `<e.g. "Expand SM section in sidebar — JS click required in compact mode (HIVER-QUIRKS #22)">`
148
+ 2. `<e.g. "Open Unassigned sub-view — wait for tr.zA rows to render">`
149
+ 3. `<e.g. "Open conversation — waitForRightPanel() before any feature interaction">`
150
+
151
+ ### Async timing
152
+
153
+ - `<e.g. "Right panel takes 2–5s to inject after conversation open">`
154
+ - `<e.g. "Bulk toolbar can be CSS-hidden for 5–15s after first selection — see HIVER-QUIRKS #1">`
155
+ - …
156
+
157
+ ### Known quirks that apply
158
+
159
+ Cross-reference `knowledgebase-claude/HIVER-QUIRKS.md`:
160
+
161
+ - HIVER-QUIRKS #`<N>` — `<one-line why it matters for this feature>`
162
+ - HIVER-QUIRKS #`<N>` — `<…>`
163
+
164
+ ### New quirks observed (candidate additions to HIVER-QUIRKS.md)
165
+
166
+ For each, write a complete entry the user can review and promote:
167
+
168
+ #### Candidate quirk: `<short title>`
169
+
170
+ **Symptom:** `<what fails or behaves unexpectedly>`
171
+ **Root cause (hypothesis):** `<best guess from what you observed>`
172
+ **Workaround:** `<what made it work in your live session>`
173
+ **Affected features:** `<list>`
174
+
175
+ ---
176
+
177
+ ## Doc-vs-Live Discrepancies `[D≠L]`
178
+
179
+ | Topic | Docs say | Live shows | Likely cause |
180
+ |---|---|---|---|
181
+ | `<e.g. Note pin limit>` | `<"Pin up to 3 notes" — help.hiverhq.com/…>` | `<Live UI allowed 5 pinned notes>` | `<docs may be outdated; v7.5.x may have lifted the limit>` |
182
+
183
+ (If none: write "None observed in this session.")
184
+
185
+ ---
186
+
187
+ ## Open Questions
188
+
189
+ These become qa-kit's Phase 2 clarifying questions:
190
+
191
+ - `<Q1: what was unclear from docs AND live UI>`
192
+ - `<Q2: behaviour only triggered in edge case we couldn't reproduce>`
193
+ - `<Q3: plan-gating that needs PM confirmation>`
194
+
195
+ ---
196
+
197
+ ## Handoff Notes
198
+
199
+ - This spec was generated by `hiver-explore` from docs + live UI observation. It has not been
200
+ reviewed by a PM. Any claim tagged `[L]`-only should be treated as best-effort.
201
+ - `qa-kit` should treat the `Live Behaviour Observations` section as ground truth for its
202
+ Phase 5 (browser testing) — the selectors and timing are already verified.
203
+ - `playwright-gen` should treat the `Known quirks that apply` and `New quirks observed`
204
+ subsections as required reading before generating page objects.