@amityco/social-plus-vise 0.14.24 → 0.14.26

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.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,26 @@ All notable changes to `@amityco/social-plus-vise` are documented in this file.
4
4
 
5
5
  The format is loosely based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## 0.14.26 — 2026-06-06
8
+
9
+ ### Added
10
+ - **Creative selection bridge:** `vise creative accept --variant <id>` / MCP `creative_accept` now persists `sp-vise/creative-selection.json` from a chosen creative brief candidate.
11
+ - **Plan/init/workplan feed-forward:** matching `vise plan`, `vise init`, and `vise workplan next/status` runs now read accepted creative selections, add a `creativeContext` block, prepend a selected-variant implementation step, mirror the selection into `sp-vise/intake.json`, and derive multi-surface workplan order from selected experience objects.
12
+
13
+ ### Verified
14
+ - Expanded `test:creative` to cover creative accept, selection sidecar writes, plan feed-forward, creative-derived workplan ordering, init sidecar mirroring, and MCP `creative_accept` smoke coverage.
15
+
16
+ ## 0.14.25 — 2026-06-06
17
+
18
+ ### Added
19
+ - **Engagement Intelligence creative brief:** `vise creative` / MCP `creative_brief` now produces an advisory pre-planning brief from a customer request plus optional requirements document and optional prototype HTML. If requirements are absent or explicitly set to `none`, Vise enters exploratory mode instead of blocking.
20
+ - **Creative sidecars:** `vise creative` writes `sp-vise/creative-brief.json` and `sp-vise/creative-brief.md` with inferred goals, archetypes, candidate variants, feasibility summaries, a blocking `preferred_solution` question, and next `vise plan` / `vise workplan` commands.
21
+ - **Runtime intelligence catalog packaging:** the shipped npm tarball now includes `packages/intelligence` so installed CLIs can load the seeded goals, archetypes, objects, relationships, patterns, UX patterns, and variants catalog.
22
+
23
+ ### Verified
24
+ - Added `test:creative` for requirements-driven mode, exploratory mode, sidecar writes, conflicting flag handling, and MCP smoke coverage.
25
+ - Packed-package E2E now runs `vise creative --no-requirements --no-write` after installing the npm tarball, proving the runtime catalog is present in the package.
26
+
7
27
  ## 0.14.24 — 2026-06-06
8
28
 
9
29
  ### Changed
package/README.md CHANGED
@@ -81,6 +81,10 @@ Vise validates on three layers, and the layer is set by the *kind of claim* —
81
81
 
82
82
  Correctness is gated by deterministic rules or attestations. Baseline completeness is gated by explicit scope decisions: if a baseline capability is legitimately out of scope, record `// vise: scope-omit <id> — <reason>` and it no longer blocks. Optional feed capabilities such as image upload, poll creation, and edit post are offered during planning and become checked only after the user opts in. Conformance remains advisory because "matches the brand" is legitimately subjective. See [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md).
83
83
 
84
+ ### Engagement Intelligence roadmap
85
+
86
+ Vise's next architecture track is the social.plus **Engagement Intelligence System**: an outcome-to-experience layer that maps customer goals, archetypes, solution patterns, experience objects, UX patterns, and variants before normal implementation planning. The first advisory runtime slice is `vise creative`: it consumes a request plus optional requirements/prototype inputs, or runs in exploratory mode when requirements are absent, writes a local creative brief for user variant selection, and records the accepted variant so `vise plan`, `vise init`, and `vise workplan` can carry that product/UX direction forward. See [docs/ENGAGEMENT_INTELLIGENCE_SYSTEM.md](docs/ENGAGEMENT_INTELLIGENCE_SYSTEM.md), [docs/MONOREPO_ARCHITECTURE.md](docs/MONOREPO_ARCHITECTURE.md), and [packages/intelligence](packages/intelligence).
87
+
84
88
  ### Relationship to social.plus Block Factory
85
89
 
86
90
  Vise has two deliberately separate roles:
@@ -161,10 +165,12 @@ Aggregate: **98/99 expected feed capabilities** and **27/27 selected optional ca
161
165
 
162
166
  ### Current Release Validation
163
167
 
164
- Version 0.14.24 carries current release proof around the full feed-forward, product-expectation, and validation flow:
168
+ Version 0.14.26 carries current release proof around the full feed-forward, product-expectation, creative pre-planning, and validation flow:
165
169
 
166
170
  | Surface | What was validated |
167
171
  |---|---|
172
+ | **Creative pre-planning** | `vise creative` produces requirements-driven or exploratory Engagement Intelligence briefs, writes `sp-vise/creative-brief.json` / `.md`, asks for `preferred_solution`, and survives packed-package installation with the intelligence catalog bundled. |
173
+ | **Creative selection bridge** | `vise creative accept --variant <id>` writes `sp-vise/creative-selection.json`; matching `vise plan`, `vise init`, and `vise workplan next` runs surface the accepted variant, derive workplan surfaces from its experience objects, and mirror the selection into `sp-vise/intake.json`. |
168
174
  | **Product flow** | Local end-to-end smoke covers design extraction, plan feed-forward, blocking intake, answered init, capability check, design conformance, and sensor discovery. |
169
175
  | **Multi-surface planning** | Broad social requests are decomposed into a `socialWorkplan` sequence for feed, comments, chat, and profile work instead of forcing a single top-level surface choice. `vise workplan next` tells the host agent which surface to implement next, and `vise workplan complete` records green-check progress in `sp-vise/workplan.json` with per-surface snapshots under `sp-vise/workplan-snapshots/<surface>/`. |
170
176
  | **Plan questions** | Plans surface blocking questions such as `design_contract_confirmation`, product-scope questions such as `feed_post_type_scope`, `feed_composer_type_scope`, `comment_tray_scope`, `chat_inbox_scope`, and `profile_identity_scope`, plus optional choices such as `feed_optional_capabilities`. Focused plans still accept `feature_surface` answers when the agent is ready to implement one surface. |
@@ -298,6 +304,8 @@ The flow above is what the skill teaches your AI agent. You — the human — dr
298
304
  |---|---|
299
305
  | `vise doctor` | Verify install; print version, install path, docs source |
300
306
  | `vise inspect [path]` | Detect platform, monorepo surfaces, design signals, available sensors |
307
+ | `vise creative [path] --request "..." [--requirements <path\|none>] [--prototype <html>]` | Produce an advisory Engagement Intelligence brief with 2-3 solution variants before normal implementation planning; writes `sp-vise/creative-brief.json` and `.md` unless `--no-write` is set |
308
+ | `vise creative accept [path] --variant <id>` | Accept a creative variant and write `sp-vise/creative-selection.json` so subsequent `plan`, `init`, and `workplan` runs include the selected product/UX direction |
301
309
  | `vise plan [path] --request "..."` | Produce a grounded implementation plan with intake questions and docs citations |
302
310
  | `vise plan-harness [path] --request "..."` | (Pre-planning step) Build the harness around the request |
303
311
  | `vise workplan next [path] --request "..."` | For broad social requests, print the next uncompleted surface plus focused `plan` / `init` / verification commands |
@@ -402,7 +410,7 @@ MCP-capable hosts can call Vise as structured tool calls instead of shell comman
402
410
 
403
411
  ### Tool names (snake_case per MCP convention)
404
412
 
405
- `inspect_project`, `plan_harness`, `plan_integration`, `init_compliance`, `check_compliance`, `sync_compliance`, `attest_rule`, `explain_rule`, `init_engagement`, `show_engagement`, `resolve_request`, `search_docs`, `get_doc_page`, `debug_issue`, `validate_setup`, `run_sensors`, `suggest_patch`, `design_extract`, `design_check`, `design_preview`, `design_reference`, `design_init_tokens`.
413
+ `inspect_project`, `creative_brief`, `creative_accept`, `plan_harness`, `plan_integration`, `init_compliance`, `check_compliance`, `sync_compliance`, `attest_rule`, `explain_rule`, `init_engagement`, `show_engagement`, `resolve_request`, `search_docs`, `get_doc_page`, `debug_issue`, `validate_setup`, `run_sensors`, `suggest_patch`, `design_extract`, `design_check`, `design_preview`, `design_reference`, `design_init_tokens`.
406
414
 
407
415
  These are the same operations as the CLI commands above, exposed as MCP tools.
408
416
 
@@ -450,12 +458,15 @@ jobs:
450
458
 
451
459
  ## Compliance Contract
452
460
 
453
- After a successful `vise init`, your project gets a `sp-vise/` directory. If init returns `needs-clarification`, no compliance sidecar is written; answer the blocking questions and run init again. These files become part of your repo and travel through code review:
461
+ Vise writes local planning, compliance, design, and evidence artifacts under `sp-vise/`. `vise creative` can create advisory creative-brief files before implementation; after a successful `vise init`, the compliance contract files are added. If init returns `needs-clarification`, no compliance sidecar is written; answer the blocking questions and run init again. These files become part of your repo and travel through code review:
454
462
 
455
463
  | File | Created by | What it contains |
456
464
  |---|---|---|
457
465
  | `sp-vise/compliance.json` | `vise init` | The rules selected for this integration, the Vise version, the ruleset digest, the target app surface, selected optional capabilities, optional engagement link, and an accepted design-contract digest when confirmed. |
458
- | `sp-vise/intake.json` | `vise init` | The request, outcome, intake answers, remaining blocking count, design-review status (`absent`, `needs-confirmation`, `accepted`, or `rejected`), and any retrospective `--allow-unresolved-intake` acknowledgement. |
466
+ | `sp-vise/intake.json` | `vise init` | The request, outcome, intake answers, remaining blocking count, optional creative-selection mirror, design-review status (`absent`, `needs-confirmation`, `accepted`, or `rejected`), and any retrospective `--allow-unresolved-intake` acknowledgement. |
467
+ | `sp-vise/creative-brief.json` | `vise creative` | Advisory Engagement Intelligence brief: mode, objective, inferred goals/archetypes, candidate solution variants, feasibility summary, preferred-solution question, and next plan/workplan commands. |
468
+ | `sp-vise/creative-brief.md` | `vise creative` | Human-readable version of the creative brief for review with the user before selecting a variant. |
469
+ | `sp-vise/creative-selection.json` | `vise creative accept` | Accepted creative variant: source brief, selected goals/archetypes/patterns/objects/UX patterns, surface hints, feasibility notes, and plan/workplan feed-forward context. |
459
470
  | `sp-vise/attestations/*.json` | `vise sync` (deterministic) or `vise attest` (host-agent / human) | Per-rule evidence: signer, confidence, rationale, cited files (with source fingerprints for drift detection). |
460
471
  | `sp-vise/inspection.json` | `vise init` | The platform, monorepo surface, and design-token signals detected at init time. |
461
472
  | `sp-vise/workplan.json` | `vise workplan complete` | Local progress for broad social workplans: request, completed surface IDs, outcomes, timestamps, green-check evidence, snapshot paths, and optional host-agent notes. |
package/dist/server.js CHANGED
@@ -17,11 +17,14 @@ import { runSensorsTool } from "./tools/sensors.js";
17
17
  import { getSdkFactsTool } from "./tools/sdkFacts.js";
18
18
  import { addBlockInstall, listRegistryBlocks, planBlockInstall, validateBlockInstall } from "./tools/blocks.js";
19
19
  import { debugIssueTool, debugIssue } from "./tools/debug.js";
20
+ import { creativeAcceptTool, creativeBriefTool } from "./tools/creative.js";
20
21
  import { packageName, packageVersion } from "./version.js";
21
22
  const tools = new Map([
22
23
  searchDocsTool,
23
24
  getDocPageTool,
24
25
  inspectProjectTool,
26
+ creativeBriefTool,
27
+ creativeAcceptTool,
25
28
  planHarnessTool,
26
29
  planIntegrationTool,
27
30
  initComplianceTool,
@@ -134,6 +137,31 @@ async function handleCli(args) {
134
137
  });
135
138
  return "exit";
136
139
  }
140
+ if (command === "creative") {
141
+ if (args[1] === "accept") {
142
+ const subArgs = args.slice(2);
143
+ assertOnlyKnownFlags(subArgs, ["variant", "brief", "brief-path"], "creative accept");
144
+ await printToolResult(creativeAcceptTool, {
145
+ repoPath: positionalRepoPath(subArgs),
146
+ variantId: requiredFlagValue(subArgs, "variant", "creative accept requires --variant <id>."),
147
+ briefPath: flagValue(subArgs, "brief") ?? flagValue(subArgs, "brief-path"),
148
+ });
149
+ return "exit";
150
+ }
151
+ assertOnlyKnownFlags(args, ["request", "requirements", "prototype", "surface", "surface-path", "no-requirements", "no-write"], "creative");
152
+ if (hasFlag(args, "no-requirements") && flagValue(args, "requirements")) {
153
+ throw new Error("creative accepts either --requirements <path> or --no-requirements, not both.");
154
+ }
155
+ await printToolResult(creativeBriefTool, {
156
+ repoPath: positionalRepoPath(args.slice(1)),
157
+ request: requiredFlagValue(args, "request", "creative requires --request."),
158
+ surfacePath: flagValue(args, "surface") ?? flagValue(args, "surface-path"),
159
+ requirementsPath: hasFlag(args, "no-requirements") ? "none" : flagValue(args, "requirements"),
160
+ prototypePath: flagValue(args, "prototype"),
161
+ write: !hasFlag(args, "no-write"),
162
+ });
163
+ return "exit";
164
+ }
137
165
  if (command === "debug") {
138
166
  assertOnlyKnownFlags(args, ["error", "error-file", "brief"], "debug");
139
167
  let errorMessage = flagValue(args, "error");
@@ -450,6 +478,25 @@ Re-plan with collected answers (repeat --answer for each intake question):
450
478
  --answer feed_scope=community \\
451
479
  --answer feed_target=existing\\ communityId \\
452
480
  --answer target_screen_or_route=app/feed/page.tsx`;
481
+ }
482
+ if (command === "creative") {
483
+ return `${packageName} creative
484
+
485
+ Create an advisory Engagement Intelligence brief before normal Vise planning.
486
+
487
+ Usage:
488
+ vise creative [repoPath] --request "Make this app more social"
489
+ vise creative [repoPath] --request "Add retention loops" --requirements ./requirements.md
490
+ vise creative [repoPath] --request "Add engagement" --requirements none
491
+ vise creative [repoPath] --request "Add engagement" --no-requirements
492
+ vise creative [repoPath] --request "Add engagement" --prototype ./prototype.html
493
+ vise creative [repoPath] --request "Add engagement" --no-write
494
+ vise creative accept [repoPath] --variant community-first
495
+
496
+ Output:
497
+ Writes sp-vise/creative-brief.json and sp-vise/creative-brief.md unless --no-write is set.
498
+ Requirements are optional; absence or explicit none switches creative mode to exploratory.
499
+ creative accept writes sp-vise/creative-selection.json for plan/init/workplan feed-forward.`;
453
500
  }
454
501
  if (command === "plan-harness") {
455
502
  return `${packageName} plan-harness
@@ -697,6 +744,8 @@ Usage:
697
744
  vise install-skill --target codex Install bundled skill guidance
698
745
  vise print-skill Print bundled skill markdown
699
746
  vise inspect [repoPath] Inspect platform and design signals
747
+ vise creative [repoPath] --request "..." Create an Engagement Intelligence brief
748
+ vise creative accept [repoPath] --variant <id> Accept a creative variant
700
749
  vise debug [repoPath] --error ... Debug an SDK-specific runtime error and emit a repair brief
701
750
  vise plan [repoPath] --request "..." Create an implementation plan
702
751
  vise workplan next [repoPath] --request "..." Get the next broad-social surface to implement
@@ -971,6 +1020,7 @@ async function workplanStatus(args) {
971
1020
  status: nextSurface ? "next-surface" : "complete",
972
1021
  request,
973
1022
  progressPath: workplanProgressPath(repoRoot),
1023
+ creativeContext: plan.socialWorkplan?.creativeContext ?? plan.creativeContext,
974
1024
  completed,
975
1025
  sequence: sequence.map((surface) => ({
976
1026
  id: surface.id,
@@ -1172,7 +1222,7 @@ function ciCheckResult(result) {
1172
1222
  };
1173
1223
  }
1174
1224
  function positionalRepoPath(args) {
1175
- const flagsWithValues = new Set(["request", "surface", "surface-path", "platform", "capability", "surface-dir", "format", "include", "timeout-ms", "query", "path", "limit", "answer", "target", "dest", "destination", "rule", "confidence", "signer", "identity", "evidence-file", "rationale", "repo", "reference", "registry", "block", "package-source", "note"]);
1225
+ const flagsWithValues = new Set(["request", "requirements", "prototype", "variant", "brief", "brief-path", "surface", "surface-path", "platform", "capability", "surface-dir", "format", "include", "timeout-ms", "query", "path", "limit", "answer", "target", "dest", "destination", "rule", "confidence", "signer", "identity", "evidence-file", "rationale", "repo", "reference", "registry", "block", "package-source", "note"]);
1176
1226
  for (let index = 0; index < args.length; index += 1) {
1177
1227
  const arg = args[index];
1178
1228
  if (!arg) {
@@ -1194,7 +1244,7 @@ function positionalRepoPath(args) {
1194
1244
  }
1195
1245
  function requiredPositionalText(args, message) {
1196
1246
  const values = [];
1197
- const flagsWithValues = new Set(["request", "surface", "surface-path", "platform", "capability", "surface-dir", "format", "include", "timeout-ms", "query", "path", "limit", "answer", "target", "dest", "destination", "rule", "confidence", "signer", "identity", "evidence-file", "rationale", "repo", "reference", "registry", "block", "package-source", "note"]);
1247
+ const flagsWithValues = new Set(["request", "requirements", "prototype", "variant", "brief", "brief-path", "surface", "surface-path", "platform", "capability", "surface-dir", "format", "include", "timeout-ms", "query", "path", "limit", "answer", "target", "dest", "destination", "rule", "confidence", "signer", "identity", "evidence-file", "rationale", "repo", "reference", "registry", "block", "package-source", "note"]);
1198
1248
  for (let index = 0; index < args.length; index += 1) {
1199
1249
  const arg = args[index];
1200
1250
  if (!arg) {
@@ -9,6 +9,7 @@ import { objectInput, optionalBooleanField, optionalStringField, stringField, te
9
9
  import { packageVersion } from "../version.js";
10
10
  import { DESIGN_CONTRACT_CONFIRMATION_ANSWER_ID, buildDesignBrief, designContractConfirmationFromAnswers, designPreviewPath, readDesignContract, } from "./design.js";
11
11
  import { inspectProject, validateSetup } from "./project.js";
12
+ import { readCreativeSelection } from "./creative.js";
12
13
  const complianceDirName = "sp-vise";
13
14
  const attestationsDirName = "attestations";
14
15
  const schemaVersion = 1;
@@ -298,6 +299,10 @@ export async function initCompliance(repoPath, request, surfacePath, answers = {
298
299
  const designContract = await readDesignContract(repoRoot);
299
300
  const designReview = designReviewFor(repoRoot, designContract, answers);
300
301
  const acceptedDesignContract = designReview.status === "accepted" ? designContract : null;
302
+ const storedCreativeSelection = await readCreativeSelection(repoRoot);
303
+ const creativeSelection = storedCreativeSelection && creativeSelectionAppliesToRequest(storedCreativeSelection, request)
304
+ ? storedCreativeSelection
305
+ : undefined;
301
306
  const intake = intakeAuditFor({
302
307
  request,
303
308
  outcome,
@@ -346,6 +351,7 @@ export async function initCompliance(repoPath, request, surfacePath, answers = {
346
351
  generated_at: compliance.generated_at,
347
352
  request,
348
353
  outcome,
354
+ ...(creativeSelection ? { creative_selection: creativeSelectionSummary(creativeSelection) } : {}),
349
355
  design_review: designReview,
350
356
  ...intake,
351
357
  });
@@ -373,6 +379,7 @@ export async function initCompliance(repoPath, request, surfacePath, answers = {
373
379
  surfacePath: inspection.selectedSurface?.path,
374
380
  rules: refs.length,
375
381
  engagement_id: engagement?.engagement_id,
382
+ ...(creativeSelection ? { creative_selection: creativeSelectionSummary(creativeSelection) } : {}),
376
383
  ...(compliance.design_contract && { design_contract: compliance.design_contract }),
377
384
  ...(selectedOptionalCapabilities.length > 0 && { selected_optional_capabilities: selectedOptionalCapabilities }),
378
385
  intake: {
@@ -469,6 +476,41 @@ function intakeAuditFor(args) {
469
476
  acknowledged_unresolved_blocking: args.allowUnresolvedIntake && remainingBlocking > 0,
470
477
  };
471
478
  }
479
+ function creativeSelectionSummary(selection) {
480
+ return {
481
+ status: selection.status,
482
+ selection_path: "sp-vise/creative-selection.json",
483
+ source_brief: selection.source.brief,
484
+ mode: selection.source.mode,
485
+ original_request: selection.source.request,
486
+ plan_request: selection.implementationContext.planRequest,
487
+ selected_variant: {
488
+ id: selection.selectedVariant.id,
489
+ title: selection.selectedVariant.title,
490
+ businessGoalIds: selection.selectedVariant.businessGoalIds,
491
+ archetypeIds: selection.selectedVariant.archetypeIds,
492
+ solutionPatternIds: selection.selectedVariant.solutionPatternIds,
493
+ experienceObjectIds: selection.selectedVariant.experienceObjectIds,
494
+ uxPatternIds: selection.selectedVariant.uxPatternIds,
495
+ feasibilitySupport: selection.selectedVariant.feasibility.support,
496
+ },
497
+ };
498
+ }
499
+ function creativeSelectionAppliesToRequest(selection, request) {
500
+ const normalizedRequest = normalizeCreativeRequest(request);
501
+ const original = normalizeCreativeRequest(selection.source.request);
502
+ const planRequest = normalizeCreativeRequest(selection.implementationContext.planRequest);
503
+ if (!normalizedRequest || !original) {
504
+ return false;
505
+ }
506
+ return (normalizedRequest === original ||
507
+ normalizedRequest === planRequest ||
508
+ normalizedRequest.includes(original) ||
509
+ original.includes(normalizedRequest));
510
+ }
511
+ function normalizeCreativeRequest(value) {
512
+ return value.toLowerCase().replace(/[^a-z0-9\s]+/g, " ").replace(/\s+/g, " ").trim();
513
+ }
472
514
  function preferredPlatform(platforms) {
473
515
  const order = ["flutter", "android", "typescript", "react-native", "ios"];
474
516
  return order.find((platform) => platforms.includes(platform)) ?? platforms[0] ?? "unknown";