@engenty/wizards-runtime 0.12.2 → 0.13.0

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 (96) hide show
  1. package/apps/runtime/dist/agents/studio-assistant.js +25 -4
  2. package/apps/runtime/dist/app.js +11 -2
  3. package/apps/runtime/dist/credits/estimate.js +3 -3
  4. package/apps/runtime/dist/docs/dev/wizard-format/agent-steps.md +20 -2
  5. package/apps/runtime/dist/docs/user-guide/models.md +105 -30
  6. package/apps/runtime/dist/docs/user-guide/together.md +15 -2
  7. package/apps/runtime/dist/engine/decide.js +1 -1
  8. package/apps/runtime/dist/engine/requirements.js +139 -11
  9. package/apps/runtime/dist/engine/runner.js +47 -5
  10. package/apps/runtime/dist/engine/steps.js +13 -5
  11. package/apps/runtime/dist/engine/template.js +17 -0
  12. package/apps/runtime/dist/link-preview.js +9 -0
  13. package/apps/runtime/dist/manage.js +25 -0
  14. package/apps/runtime/dist/mcp/handler.js +55 -1
  15. package/apps/runtime/dist/mcp/seen.js +47 -0
  16. package/apps/runtime/dist/models.js +202 -11
  17. package/apps/runtime/dist/motion-graphics/step.js +2 -2
  18. package/apps/runtime/dist/prompts/goose.md +8 -7
  19. package/apps/runtime/dist/prompts/safety.md +18 -0
  20. package/apps/runtime/dist/prompts/step.md +1 -1
  21. package/apps/runtime/dist/routes/marketplace.js +3 -3
  22. package/apps/runtime/dist/routes/runs.js +5 -0
  23. package/apps/runtime/dist/routes/studio.js +103 -4
  24. package/apps/runtime/dist/safety.js +60 -18
  25. package/apps/runtime/dist/services/manage-reports.js +3 -0
  26. package/apps/runtime/dist/services/marketplace.js +7 -31
  27. package/apps/runtime/dist/services/pages.js +6 -2
  28. package/apps/runtime/dist/services/shares.js +5 -0
  29. package/apps/runtime/dist/services/spaces.js +15 -1
  30. package/apps/runtime/dist/texts.js +6 -0
  31. package/apps/runtime/dist/tools/index.js +3 -2
  32. package/apps/web/dist/assets/AboutDialog-B-JxkELB.js +1 -0
  33. package/apps/web/dist/assets/{ChangelogDialog-CKLgFL6r.js → ChangelogDialog-SwyId00t.js} +1 -1
  34. package/apps/web/dist/assets/{CodeEditor-B3nto_26.js → CodeEditor-BwZsk5Al.js} +1 -1
  35. package/apps/web/dist/assets/EditorPage-DQ_2FOzI.js +3 -0
  36. package/apps/web/dist/assets/{FlowPreview-zJCtixSi.js → FlowPreview-DtSpjVTl.js} +1 -1
  37. package/apps/web/dist/assets/Marketplace-DoH4YO3D.js +2 -0
  38. package/apps/web/dist/assets/{NewWizardChannels-B4N7GIYh.js → NewWizardChannels-Tgoexgj4.js} +1 -1
  39. package/apps/web/dist/assets/NewWizardPage-B24AF482.js +7 -0
  40. package/apps/web/dist/assets/OnboardingPage-BEvq4slJ.js +1 -0
  41. package/apps/web/dist/assets/PreviewPane-B_v7Y8R7.js +10 -0
  42. package/apps/web/dist/assets/ProjectPage-ClRuhFJo.js +10 -0
  43. package/apps/web/dist/assets/PublicRunner-MicrpVsv.js +1 -0
  44. package/apps/web/dist/assets/{ReadOnly-C9oGMkUB.js → ReadOnly-BXjv-MSv.js} +1 -1
  45. package/apps/web/dist/assets/SettingsPage-DY8O1r43.js +2 -0
  46. package/apps/web/dist/assets/SetupPage-BOVkVpMu.js +1 -0
  47. package/apps/web/dist/assets/{SharePage-DdMm1Y8K.js → SharePage-DXGzJSnR.js} +1 -1
  48. package/apps/web/dist/assets/SkillEditor-BzzTDeaU.js +1 -0
  49. package/apps/web/dist/assets/changelog-BLdS-0Bj.js +1 -0
  50. package/apps/web/dist/assets/{code-xml-Hx7YxCg0.js → code-xml-TwKzzMtA.js} +1 -1
  51. package/apps/web/dist/assets/{eye-BkMFLnYu.js → eye-Brd-xPUJ.js} +1 -1
  52. package/apps/web/dist/assets/i18n-8-Sw11tB.js +55 -0
  53. package/apps/web/dist/assets/index-OsdQFHmh.js +49 -0
  54. package/apps/web/dist/assets/index-QPipX5Fi.css +1 -0
  55. package/apps/web/dist/assets/{lock-CGXM95Mi.js → lock-C0uxcOlq.js} +1 -1
  56. package/apps/web/dist/assets/{phone-DMfwuh9V.js → phone-DhkHteoJ.js} +1 -1
  57. package/apps/web/dist/assets/{runners-D5qz6b_s.js → runners-G-XYaDgR.js} +1 -1
  58. package/apps/web/dist/assets/{session-DRy0k0nh.js → session-BWI-KENJ.js} +1 -1
  59. package/apps/web/dist/assets/theme-D7krsx0_.js +11 -0
  60. package/apps/web/dist/assets/ui-DSXG3f49.js +83 -0
  61. package/apps/web/dist/assets/{upload-DQJwLSGj.js → upload-BYZTwJTD.js} +1 -1
  62. package/apps/web/dist/assets/{useMutation-C20c2EH3.js → useMutation-D0QP_k2-.js} +1 -1
  63. package/apps/web/dist/assets/{volume-2-CC5qamYT.js → volume-2-CVHoxdGM.js} +1 -1
  64. package/apps/web/dist/index.html +9 -9
  65. package/apps/web/dist/mcp/flow.html +56 -56
  66. package/node_modules/@engenty/wizards-shared/dist/assistant.d.ts +1 -0
  67. package/node_modules/@engenty/wizards-shared/dist/assistant.js +5 -0
  68. package/node_modules/@engenty/wizards-shared/dist/definition.d.ts +107 -0
  69. package/node_modules/@engenty/wizards-shared/dist/definition.js +67 -4
  70. package/node_modules/@engenty/wizards-shared/dist/feature-flags.d.ts +12 -0
  71. package/node_modules/@engenty/wizards-shared/dist/feature-flags.js +12 -0
  72. package/node_modules/@engenty/wizards-shared/dist/marketplace.d.ts +0 -5
  73. package/node_modules/@engenty/wizards-shared/dist/run.d.ts +61 -0
  74. package/node_modules/@engenty/wizards-shared/dist/run.js +50 -0
  75. package/node_modules/@engenty/wizards-shared/dist/tiers.d.ts +195 -0
  76. package/node_modules/@engenty/wizards-shared/dist/tiers.js +98 -0
  77. package/package.json +1 -1
  78. package/plugin/.claude-plugin/plugin.json +1 -1
  79. package/plugin/plugin.json +1 -1
  80. package/apps/web/dist/assets/AboutDialog-CLgnoYTI.js +0 -1
  81. package/apps/web/dist/assets/EditorPage-D9JDdAAI.js +0 -3
  82. package/apps/web/dist/assets/Marketplace-D4e0Oac9.js +0 -2
  83. package/apps/web/dist/assets/NewWizardPage-Dpt0Mzk8.js +0 -7
  84. package/apps/web/dist/assets/OnboardingPage-CDoYVjRC.js +0 -1
  85. package/apps/web/dist/assets/PreviewPane-DPB5nEd5.js +0 -10
  86. package/apps/web/dist/assets/ProjectPage-408YOoNa.js +0 -10
  87. package/apps/web/dist/assets/PublicRunner-BZ66xdRX.js +0 -1
  88. package/apps/web/dist/assets/SettingsPage-Dq3AZwJS.js +0 -2
  89. package/apps/web/dist/assets/SetupPage-CP3lbyZc.js +0 -1
  90. package/apps/web/dist/assets/SkillEditor-b5NMFB90.js +0 -1
  91. package/apps/web/dist/assets/changelog-82-DHogQ.js +0 -1
  92. package/apps/web/dist/assets/i18n-CKKh3Pn0.js +0 -55
  93. package/apps/web/dist/assets/index-Cy2NHzAx.js +0 -49
  94. package/apps/web/dist/assets/index-wR_-1hfN.css +0 -1
  95. package/apps/web/dist/assets/theme-DNPm6r4e.js +0 -11
  96. package/apps/web/dist/assets/ui-CwFQAfE-.js +0 -83
@@ -1,12 +1,14 @@
1
1
  import { anthropic } from "@ai-sdk/anthropic";
2
+ import { textClassOf } from "@engenty/wizards-shared/definition";
2
3
  import { cleanAssetSections, cleanLogoSections, FACT_TYPES, FONT_USES, factKey, gradientCss, PROJECT_FILE_KINDS, PROJECT_LIMITS, parseGradient, RULE_MARKS, textStyleLine, } from "@engenty/wizards-shared/projects";
4
+ import { pickedClass } from "@engenty/wizards-shared/tiers";
3
5
  import { createTool } from "@mastra/core/tools";
4
6
  import { nanoid } from "nanoid";
5
7
  import { z } from "zod";
6
8
  import { knowsTools } from "../assistant/knows.js";
7
9
  import { currentFeatures } from "../features.js";
8
10
  import { managed } from "../manage.js";
9
- import { chatModel, contextWindowOf, costOf, gatewayTools, totalUsage, usageOf, } from "../models.js";
11
+ import { chatModel, contextWindowOf, costOf, currentTier, gatewayTools, searchAllowed, textModel, totalUsage, usageOf, } from "../models.js";
10
12
  import { prompt } from "../prompts.js";
11
13
  import { contentPolicy } from "../safety.js";
12
14
  import { knowledgeCounts } from "../services/knowledge.js";
@@ -653,6 +655,23 @@ function toolSizes(tools) {
653
655
  })
654
656
  .sort((a, b) => b.chars - a.chars);
655
657
  }
658
+ /**
659
+ * The model of a turn: the tier's class the person picked, on the credits, where the organization
660
+ * has a tier; else the chat's way, with its more capable model for extra effort.
661
+ */
662
+ async function assistantModel(way, input) {
663
+ const tier = input.model && way === "models" ? await currentTier() : null;
664
+ // A model id picked in the chooser asks for the class it runs on; anything else is no pick.
665
+ const picked = tier && input.model ? pickedClass(tier, input.model) : null;
666
+ if (!picked) {
667
+ return chatModel(way, input.extra ? "high" : "standard");
668
+ }
669
+ return textModel(textClassOf(picked.cls), {
670
+ purpose: "assistant",
671
+ makerClass: picked.maker ? `${picked.maker}/${picked.cls}` : undefined,
672
+ effort: input.extra ? "high" : undefined,
673
+ });
674
+ }
656
675
  /** One turn of the studio assistant. */
657
676
  export async function runStudioAssistant(input) {
658
677
  // How often the space or a plugin's data changed: a part of the answer changed something when
@@ -660,7 +679,7 @@ export async function runStudioAssistant(input) {
660
679
  let changes = 0;
661
680
  // The way the settings chose for the studio's chats: on a client, its tools reach it over MCP.
662
681
  const way = await chatTurnWay(managed);
663
- const resolved = await chatModel(way, input.extra ? "high" : "standard");
682
+ const resolved = await assistantModel(way, input);
664
683
  const wrote = () => {
665
684
  changes++;
666
685
  input.onChanged?.();
@@ -741,10 +760,12 @@ export async function runStudioAssistant(input) {
741
760
  }
742
761
  const toolCalls = [];
743
762
  traced(tools, input, toolCalls);
744
- if (resolved.vendor === "anthropic") {
763
+ // The organization's tier may allow no web search.
764
+ const search = await searchAllowed();
765
+ if (search && resolved.vendor === "anthropic") {
745
766
  tools.web_search = anthropic.tools.webSearch_20250305({ maxUses: 5 });
746
767
  }
747
- else if (resolved.gateway) {
768
+ else if (search && resolved.gateway) {
748
769
  tools.web_search = gatewayTools.perplexitySearch({ maxResults: 6 });
749
770
  }
750
771
  const instructions = system();
@@ -428,9 +428,18 @@ if (existsSync(webDir)) {
428
428
  .replace(/<link rel="apple-touch-icon"[^>]*>/, `<link rel="apple-touch-icon" href="${own}/icons/apple-touch-icon.png" />`)
429
429
  .replace(/<link rel="icon"[^>]*>/, `<link rel="icon" href="${own}/icons/favicon.png" type="image/png" />`)
430
430
  : html;
431
- return c.html(preview
431
+ // A result and a run are someone's own: search engines leave them out. A wizard's start
432
+ // page stays findable.
433
+ const personal = /^\/s\/|^\/w\/[^/]+\/[^/]+\/./.test(c.req.path);
434
+ if (personal) {
435
+ c.header("X-Robots-Tag", "noindex, nofollow");
436
+ }
437
+ const withPreview = preview
432
438
  ? page.replace(/<title>[^<]*<\/title>/, "").replace("</head>", `${preview}\n</head>`)
433
- : page);
439
+ : page;
440
+ return c.html(personal
441
+ ? withPreview.replace("</head>", `<meta name="robots" content="noindex, nofollow">\n</head>`)
442
+ : withPreview);
434
443
  });
435
444
  }
436
445
  export default app;
@@ -1,4 +1,4 @@
1
- import { isDecidedField, isDecisionStep, } from "@engenty/wizards-shared/definition";
1
+ import { isDecidedField, isDecisionStep, textClassOf, } from "@engenty/wizards-shared/definition";
2
2
  import { and, desc, eq, inArray, isNull } from "drizzle-orm";
3
3
  import { db, schema } from "../db/client.js";
4
4
  import { mostAlongOnePath } from "../engine/requirements.js";
@@ -51,7 +51,7 @@ function stepFormula(step, catalog) {
51
51
  ? TOKENS.tools
52
52
  : TOKENS.plain;
53
53
  // A step with `each` runs once per entry; until it has run, three stand in.
54
- let credits = textCredits(cls(step.model ?? "standard"), shape) * (step.each ? 3 : 1);
54
+ let credits = textCredits(cls(textClassOf(step.model ?? "standard")), shape) * (step.each ? 3 : 1);
55
55
  if (step.tools.includes("web_search")) {
56
56
  credits += 4 * catalog.webSearchCredits;
57
57
  }
@@ -75,7 +75,7 @@ function stepFormula(step, catalog) {
75
75
  return (seconds * (catalog.classes.video?.creditsPerSecond ?? 0) +
76
76
  textCredits(cls("low"), TOKENS.prompt));
77
77
  }
78
- return textCredits(cls(step.model ?? "standard"), TOKENS.document);
78
+ return textCredits(cls(textClassOf(step.model ?? "standard")), TOKENS.document);
79
79
  }
80
80
  return 0;
81
81
  }
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  title: Agent steps
3
- description: An AI step's instructions, tools, output, model class, decisions, and one run per entry.
4
- version: 0.11.3
3
+ description: An AI step’s instructions, tools, output, model class and maker, decisions, and one run per entry.
4
+ version: 0.12.2
5
5
  ---
6
6
 
7
7
  An `agent` step is an AI step. It reads its `instructions`, may call tools, and returns its
@@ -77,6 +77,24 @@ outside the wizard.
77
77
  | `standard` | Research with tools, long documents, reasoning over many sources. The default |
78
78
  | `high` | Hard reasoning or writing code. Several times the cost of `standard` |
79
79
 
80
+ `maker` (`anthropic`, `openai`, `google`, `mistral`) asks for that maker’s model of the class,
81
+ never another maker’s. Each maker has its own classes:
82
+
83
+ | `maker` | `model` |
84
+ |---|---|
85
+ | `anthropic`, `openai` | `low`, `standard`, `high`, `highest` |
86
+ | `google` | `low`, `standard`, `high` |
87
+ | `mistral` | `low`, `high` |
88
+
89
+ `highest` exists only with a maker, and `classifier` takes none. A maker counts on engenty.ai,
90
+ where the organization’s model tier binds the maker’s class to one of its models. Elsewhere the
91
+ step runs on its plain class, `highest` as `high`. The editor writes `maker` when someone chooses a
92
+ step’s model by name.
93
+
94
+ ```json
95
+ { "id": "draft", "type": "agent", "model": "high", "maker": "anthropic" }
96
+ ```
97
+
80
98
  `effort` (`low`, `medium`, `high`) tells the model how hard to think, where the bound model can be
81
99
  told. Leave it out unless a step is clearly simple or clearly hard.
82
100
 
@@ -1,26 +1,34 @@
1
1
  ---
2
2
  title: Models and account
3
3
  description: What runs the AI in your wizards – an AI client on your computer, your own API keys, a local model or credits.
4
- version: 0.11.13
4
+ version: 0.12.2
5
5
  ---
6
6
 
7
7
  Settings → Models decides what runs the AI in your wizards. On your computer you set it up
8
- yourself. On engenty.ai you set it in the studio there.
8
+ yourself. On engenty.ai the organization’s admins set it in the studio there, for everyone in it.
9
9
 
10
- ## What the wizards can do
10
+ ## Overview
11
11
 
12
- The menu lists five capabilities under “Capabilities”. A dot beside each one shows how it runs:
13
- green on something of your own, amber on credits, hollow when nothing is set up.
12
+ The page opens on “Overview”. Its card says what everything “Runs with” – your subscription, your
13
+ own API key, a model on this computer or your engenty credits – and what it is “Helped by”. In the
14
+ cloud it names the organization’s plan and, on a plan with tiers, the [tier](#which-models).
14
15
 
15
- | Capability | Used for | Classes |
16
- |---|---|---|
17
- | Text & reasoning | Writing, research and decisions in the steps | Classifier, Low, Standard, High |
18
- | Images | Logos, product shots, illustrations | Image |
19
- | Videos | Short clips from text or an image | Video |
20
- | Voice | Reading text aloud | Speech |
21
- | Voice notes | Turning speech into text | Audio |
16
+ Below that, “Which model for what” lists each job with a dot for its state: green when it is
17
+ ready, amber when something is missing, hollow when the tier doesn’t offer it. The menu beside
18
+ the page has the same jobs in two groups:
19
+
20
+ | Group | Job | Used for | Classes |
21
+ |---|---|---|---|
22
+ | In the studio | Studio chat (Goose) | Goose and the chat in the editor that builds your wizards | Its own, see [Studio chat](#studio-chat-goose) |
23
+ | Agents & wizards | Text & reasoning | Writing, research, decisions and knowledge search in the steps | Classifier, Low, Standard, High |
24
+ | Agents & wizards | Images & video | Logos, product shots, illustrations, short clips | Image, Video |
25
+ | Agents & wizards | Voice | Reading text aloud, turning voice notes into text | Speech, Audio |
26
+
27
+ “Access” lists what engenty can use: Credits, AI apps, Local models and API keys, and in the cloud
28
+ Masking for the admins. On engenty.ai a member sees Credits and API keys; AI apps and local models
29
+ are the admins’ choice there.
22
30
 
23
- A capability’s page asks “Who does it?”:
31
+ A job’s page asks “Who does it?”:
24
32
 
25
33
  | Choice | What it is | Cost |
26
34
  |---|---|---|
@@ -28,14 +36,14 @@ A capability’s page asks “Who does it?”:
28
36
  | Your own API key | OpenAI, Anthropic, Google Gemini, fal.ai, ElevenLabs, Replicate or Vercel AI Gateway | The provider bills your key |
29
37
  | Apple Intelligence | The model on this Mac: short texts and decisions (Classifier, Standard) and voice notes. See [Apple Intelligence](#apple-intelligence) | Nothing |
30
38
  | Local model | [Ollama](https://ollama.com) on this computer: text, search and decisions. See [Local models](#local-models) | Nothing |
31
- | engenty credits | Your account’s credits. engenty chooses the model, or you choose one it offers (FLUX on fal, ElevenLabs voices, Veo …) | Credits |
39
+ | engenty credits | Your account’s credits. Auto picks the model, or you choose one it offers (FLUX on fal, ElevenLabs voices, Veo …) | Credits |
32
40
 
33
41
  Below that you choose the provider’s model, and “Try it” makes one real call: a short answer, a
34
42
  test image, a voice to hear, a 4-second clip or a transcript. A try costs the same as a real call.
35
43
 
36
44
  With an account, credits step in where you have nothing of your own set up – for example,
37
- videos without your own API key. The switch “Credits step in” on the page “engenty credits” turns
38
- that off. A capability with nothing of its own set up then doesn’t run.
45
+ videos without your own API key. The switch “Credits step in” on the page “Credits” turns that
46
+ off. A job with nothing of its own set up then doesn’t run.
39
47
 
40
48
  ## Local models
41
49
 
@@ -87,12 +95,15 @@ engenty wizards checks a key with its provider before it stores it. On your comp
87
95
  in the Keychain on a Mac and in an encrypted file in the data folder elsewhere. On engenty.ai
88
96
  they are kept encrypted for the organization. They are never in the database, and nobody sees them again.
89
97
 
90
- Under “Access” you find the credits, the AI clients on this computer and each provider you gave
91
- a key. The other providers are under “More providers”. A provider’s page holds its key, what it
92
- is used for, and which of its models run on credits without your own API key.
98
+ “API keys” under “Access” lists each key there is, masked to its prefix and last four characters (`sk-…a1b2`), with
99
+ where it comes from: kept in the studio, or an environment variable on this computer. The other
100
+ providers are under “More providers”. A provider’s page holds its key, what it is used for, and
101
+ which of its models run on credits without your own API key. What runs on a key costs no credits.
93
102
 
94
- On engenty.ai, your own API keys come with the Pro plan. Without them, runs use the organization’s
95
- credits.
103
+ On engenty.ai, own API keys need a plan that has them: from Pro. The tier doesn’t forbid them.
104
+ The admins choose whether the organization uses them, and then the provider handles the data
105
+ under your contract with it, not under the tier’s promises. Without own keys, runs use the
106
+ organization’s credits.
96
107
 
97
108
  Vercel refuses many models for an AI Gateway key on its free tier. The Models page and the check
98
109
  before a run say so, with a link to top up at Vercel.
@@ -109,7 +120,10 @@ before a run say so, with a link to top up at Vercel.
109
120
 
110
121
  ## Model per class
111
122
 
112
- A step names a class, never a model. For text, “Adjust per class” sets the model of each class.
123
+ A step names a class, never a model. In the editor you choose a step’s model by name: “Auto” (the
124
+ right one for each task) or a model of the list, with a hint such as “fast · low cost” or
125
+ “thorough”. The step keeps the class, with the model’s maker where you chose one, so it follows
126
+ when a newer model takes the class. For text, “Adjust per class” sets the model of each class.
113
127
  Under each class the page shows what its model needs at least, and warns when the chosen model
114
128
  lacks some of it:
115
129
 
@@ -137,17 +151,16 @@ a Knowledge search found. Jev is reached through an AI Gateway key, a TypeSafe k
137
151
  (`TYPESAFE_API_KEY` in the settings file), the Clef-flash model in Ollama on this computer, or
138
152
  your account. Without any of them, the Classifier class decides.
139
153
 
140
- ## Agent chat
154
+ ## Studio chat (Goose)
141
155
 
142
- Settings → Models has two groups. “In the studio” holds **Agent chat**: what answers Goose and the
143
- editor’s chat that builds your wizards. “In runs” holds what your wizards’ steps use: text,
144
- images, video, voice and voice notes.
156
+ “In the studio” holds **Studio chat (Goose)**: what answers Goose and the editor’s chat that builds
157
+ your wizards. “Agents & wizards” holds what your wizards’ steps use.
145
158
 
146
159
  | Choice | Means |
147
160
  |---|---|
148
161
  | Your subscription: Claude Code, Codex, Cursor Agent | The program on this computer answers, using your sign-in there. It works only through the tools of engenty wizards: it runs no commands and changes no files of its own |
149
162
  | Your own API key: OpenAI, Anthropic, Google Gemini, Vercel AI Gateway | A model of that provider answers, on your key |
150
- | engenty credits | The credits pay, through your account. engenty picks the models |
163
+ | engenty credits | The credits pay, through your account. Auto picks the models |
151
164
 
152
165
  The list shows each program that is installed and signed in. Without a choice, Claude Code answers
153
166
  where it is the source of your models, else the first way that is ready. With none ready, the chat
@@ -160,8 +173,69 @@ type any name.
160
173
 
161
174
  In a message box’s **+** menu, **Extra effort** switches the chat to the more capable model for the
162
175
  conversation. The editor chat starts with it on, Goose with it off. When Goose sees demanding work,
163
- it offers a button under its answer. In the cloud, the organization’s credits pay and engenty picks
164
- the models.
176
+ it offers a button under its answer.
177
+
178
+ In the cloud, the organization’s credits pay and Auto picks the models from the tier. Where the
179
+ admins allow it, members can answer the chat with their own subscription (“AI apps”: Claude Code,
180
+ Codex, Cursor) or a model on their computer (“Local models”: Ollama, Apple). These serve the
181
+ studio chat only; agents and wizards never run on them. What the chat reads then goes to the
182
+ subscription’s provider under its terms; a local model keeps it on the computer.
183
+
184
+ ## Which models
185
+
186
+ On engenty.ai, an organization on Pro or Team has a model tier. Its admins choose it under
187
+ “Which models”, and it applies to everyone in the organization, in the studio and in every agent
188
+ and wizard.
189
+
190
+ | Tier | What it promises | Plans |
191
+ |---|---|---|
192
+ | All models | The best models worldwide. Providers process data on their own terms | Pro, Team |
193
+ | EU data protection | Models in EU data centres. Providers store nothing and don’t train on what they get | Pro, Team |
194
+ | EU sovereign | EU companies and EU servers only, open models. Less choice | Team |
195
+
196
+ An organization that hasn’t picked a tier, and one on Free, runs on All models. A tier set by
197
+ contract shows “Your organization’s contract sets this.” The tier’s page lists what it promises
198
+ (“Runs in the EU”, “Providers keep no data”, “Never used for training”) and what each class runs
199
+ on. A class the tier doesn’t offer shows “Not offered”, and a step that needs it counts as missing
200
+ a model. Web search can be off on a tier; steps that search the
201
+ web then run without it.
202
+
203
+ Own API keys and members’ subscriptions are allowed on every tier, as the admins’ choice. The
204
+ page says where the data then goes: to that provider, under its own terms or your contract, not
205
+ under the tier’s promises. Apps that read a space over MCP stay off on a tier whose providers
206
+ keep no data.
207
+
208
+ The account’s billing pages show which models and providers the organization’s calls went to
209
+ and the sub-processors of each tier.
210
+
211
+ ## Model choice
212
+
213
+ “Model choice” sets how the admins share out the tier, for wizards, Goose and work chats. Running
214
+ work finishes as it started.
215
+
216
+ | Way | Means |
217
+ |---|---|
218
+ | Preselection | People choose from the tier’s preselection: Auto and a few models that fit best. New models join on their own |
219
+ | You set defaults | A default per task. People switch to any model in the tier, up to the effort you allow |
220
+ | Expert mode | The admins decide which models people choose from, separately for wizards, Goose and work chats, with the efforts they allow. New models join only when they approve them |
221
+
222
+ The model menus in the editor and in Goose’s message box offer what the way allows.
223
+
224
+ ## Masking
225
+
226
+ In an organization with a tier, the admins can switch on “Mask personal data”. Then names, email addresses, phone numbers, IBANs and IDs become
227
+ placeholders before a call leaves engenty, and come back in the answer. A placeholder stays the
228
+ same within a run, so the model can still tell people apart. Each call that had something to
229
+ mask costs credits on top.
230
+
231
+ Under “What else to mask” the admins say in a sentence what else to look for, such as “Mask our
232
+ clients’ names, internal code names and anything about employees’ health.” engenty turns it into
233
+ things to look for (“Looks for”), in every call of the organization. They can remove one or add
234
+ their own: in English, as a plain word for what the thing is (“company” finds more than “customer
235
+ name”). “Try a sentence” shows what the model would see.
236
+
237
+ Not masked yet: decisions answered by the decision model, knowledge search, voice (what is read
238
+ aloud and voice notes) and files sent as they are, such as images and PDFs.
165
239
 
166
240
  ## Account
167
241
 
@@ -186,7 +260,8 @@ They stop when the credits are used up, until you top up.
186
260
  While you are signed in, the studio uses the name and email of your account. Settings → Account
187
261
  shows them under “Profile”, and you can’t change them there. The avatar carries a small cloud.
188
262
  Its menu says “Connected to engenty.ai” and shows your credits, or says “Sign-in expired” when
189
- you need to sign in again.
263
+ you need to sign in again. In the studio on engenty.ai, Settings → General shows the
264
+ organization’s credits with its plan, and Settings → Credits their entries.
190
265
 
191
266
  Without an account, engenty wizards isn’t connected to anything. Your wizards, the space and its
192
267
  files stay on your computer.
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  title: Working together
3
- description: How the studio shows what others change while you work, merges it with what you type, and shows who else is in a wizard, page or table.
4
- version: 0.10.0
3
+ description: How the studio shows what others change while you work, merges it with what you type, shows who else is in a wizard, page or table, and where an organization’s settings are.
4
+ version: 0.12.2
5
5
  ---
6
6
 
7
7
  The studio shows changes made elsewhere as they happen. You don’t reload anything. That holds
@@ -49,6 +49,19 @@ An app over MCP learns who else is in a wizard when it reads or changes it. When
49
49
  the same wizard, the app hears that their editor merges its change, and it tells you before
50
50
  larger changes.
51
51
 
52
+ ## Your organization
53
+
54
+ On engenty.ai the settings start with the organization’s:
55
+
56
+ | Page | What it holds |
57
+ |---|---|
58
+ | General | The organization’s name; its plan with what is in use (Spaces, Members, Credits left, Models: the [tier](./models.md#which-models) and the tiers the plan offers), and “Change plan” for owners and admins; its address, where the studio and the published wizards live |
59
+ | Members | Who is in it and who is invited, with their roles. Owners and admins change roles and remove people; owners invite, and on Team admins too. “Leave the organization” is here too, while someone else is in it |
60
+ | Credits, Usage, Invoices | The balance and its entries, what was spent, the bills |
61
+
62
+ The person who made the organization can change its address once, in its first 14 days. The
63
+ studio moves with it.
64
+
52
65
  ## Switch it off
53
66
 
54
67
  To turn live changes off on your computer, add this line to `~/.engenty/wizards/.features`:
@@ -12,7 +12,7 @@ function stateText(state) {
12
12
  return text.length > MAX_STATE_CHARS ? `${text.slice(0, MAX_STATE_CHARS)}…` : text;
13
13
  }
14
14
  async function askSystemOne(input, signal) {
15
- const access = await systemOneAccess().catch(() => null);
15
+ const access = await systemOneAccess(input.call).catch(() => null);
16
16
  if (!access) {
17
17
  return {};
18
18
  }
@@ -1,7 +1,9 @@
1
- import { conditionMatches, conditionsOf, isDecidedField, isDecisionStep, isOtherwise, MODEL_CLASSES, } from "@engenty/wizards-shared/definition";
1
+ import { classIdOf, conditionMatches, conditionsOf, isDecidedField, isDecisionStep, isOtherwise, MODEL_CLASSES, textClassOf, } from "@engenty/wizards-shared/definition";
2
2
  import { closedChoicesFor, openValue, otherwiseIndex, unavoidableFrom, unavoidableSteps, } from "@engenty/wizards-shared/fit";
3
+ import { CLASS_NAMES } from "@engenty/wizards-shared/providers";
3
4
  import { note, saidText } from "@engenty/wizards-shared/run";
4
- import { classProblem, motionClient } from "../models.js";
5
+ import { MAKER_COMPANIES, MAKER_FAMILIES, splitClassId, } from "@engenty/wizards-shared/tiers";
6
+ import { classProblem, currentTier, motionClient, tierRefusal } from "../models.js";
5
7
  // The steps every run passes through, and the choices that lead around a missing model, are
6
8
  // pure and shared (packages/shared/src/fit.ts): the standalone check uses the same.
7
9
  export { openValue, unavoidableFrom, unavoidableSteps };
@@ -29,7 +31,7 @@ function ownClasses(step) {
29
31
  if (isDecisionStep(step)) {
30
32
  return ["classifier"];
31
33
  }
32
- const classes = [step.model ?? "standard"];
34
+ const classes = [textClassOf(step.model ?? "standard")];
33
35
  if (step.tools.includes("image")) {
34
36
  classes.push("image");
35
37
  }
@@ -50,10 +52,10 @@ function ownClasses(step) {
50
52
  case "voice":
51
53
  return ["speech"];
52
54
  default:
53
- return [step.model ?? "standard"];
55
+ return [textClassOf(step.model ?? "standard")];
54
56
  }
55
57
  case "motion-graphics":
56
- return [step.model ?? "low"];
58
+ return [textClassOf(step.model ?? "low")];
57
59
  case "page":
58
60
  // A voice note the page asks for is listened to before the next step reads it.
59
61
  return step.fields.some((f) => f.kind === "audio" && f.required) ? ["audio"] : [];
@@ -216,10 +218,119 @@ export function mostAlongOnePath(def, cost, closed = new Set()) {
216
218
  };
217
219
  return walk(closed) ?? walk(new Set()) ?? def.steps.reduce((sum, s) => sum + cost(s), 0);
218
220
  }
219
- /** The steps that call a class this runtime cannot serve. */
221
+ /** The steps that call a class this runtime cannot serve, or the organization's tier doesn't offer. */
220
222
  export async function stepsWithoutModel(def) {
221
223
  const missing = await missingClasses();
222
- return new Set(def.steps.filter((s) => stepClasses(s).some((cls) => missing.has(cls))).map((s) => s.id));
224
+ const tier = await currentTier();
225
+ return new Set(def.steps
226
+ .filter((s) => stepClasses(s).some((cls) => missing.has(cls) || (tier && tierProblem(tier, tierClassOf(s, cls)))))
227
+ .map((s) => s.id));
228
+ }
229
+ /**
230
+ * The class a step asks the gateway for, as the tier names it: `anthropic/highest` where the
231
+ * step names a maker for its own text class, else the class.
232
+ */
233
+ export function tierClassOf(step, cls) {
234
+ if (!("maker" in step) || !step.maker || cls === "classifier") {
235
+ return cls;
236
+ }
237
+ const own = step.model ?? cls;
238
+ return textClassOf(own) === cls ? classIdOf({ model: own, maker: step.maker }, "standard") : cls;
239
+ }
240
+ /** What a tier's class id makes, as a note's gap: "videos", "Claude · High". */
241
+ export function tierClassWhat(id) {
242
+ const { maker, cls } = splitClassId(id);
243
+ const name = cls === "highest" ? "Highest" : CLASS_NAMES[cls];
244
+ if (maker) {
245
+ return `${MAKER_FAMILIES[maker]} · ${name ?? cls}`;
246
+ }
247
+ switch (cls) {
248
+ case "image":
249
+ return note("makesImages");
250
+ case "video":
251
+ return note("makesVideos");
252
+ case "speech":
253
+ return note("makesSpeech");
254
+ case "audio":
255
+ return note("makesVoiceNotes");
256
+ case "classifier":
257
+ return note("makesDecisions");
258
+ case "embedding":
259
+ return note("makesSearch");
260
+ default:
261
+ return name ?? cls;
262
+ }
263
+ }
264
+ /**
265
+ * What a step the gateway refused for the organization's tier or policy says: the class and the
266
+ * tier, or that the admins haven't approved it. Null for any other failure.
267
+ */
268
+ export async function tierRefusalSaid(err) {
269
+ const refused = tierRefusal(err);
270
+ if (!refused) {
271
+ return null;
272
+ }
273
+ const what = refused.cls ? tierClassWhat(refused.cls) : note("thisModel");
274
+ if (refused.type === "not_in_policy") {
275
+ return note("notInPolicy", { what });
276
+ }
277
+ const tier = await currentTier();
278
+ const problem = (tier && refused.cls ? tierProblem(tier, refused.cls) : null) ??
279
+ note("tierOffersNo", { tier: refused.tier ?? tier?.name ?? "", what });
280
+ return note("tierRefused", { problem });
281
+ }
282
+ const MASKED_KINDS = {
283
+ person: "maskedPerson",
284
+ email: "maskedEmail",
285
+ phone: "maskedPhone",
286
+ iban: "maskedIban",
287
+ id: "maskedId",
288
+ address: "maskedAddress",
289
+ contract: "maskedContract",
290
+ term: "maskedTerm",
291
+ };
292
+ /** The Log line of what the gateway masked in a step's calls, from its counts per kind. */
293
+ export function maskedNote(counts) {
294
+ const kinds = [];
295
+ let other = 0;
296
+ for (const [kind, count] of Object.entries(counts)) {
297
+ const code = MASKED_KINDS[kind];
298
+ if (code) {
299
+ kinds.push(note(code, { count }));
300
+ }
301
+ else {
302
+ other += count;
303
+ }
304
+ }
305
+ if (other) {
306
+ kinds.push(note("maskedOther", { count: other }));
307
+ }
308
+ const count = Object.values(counts).reduce((sum, n) => sum + n, 0);
309
+ return note("masked", { count, kinds });
310
+ }
311
+ /** Why the organization's tier doesn't serve a class; null where it does. */
312
+ export function tierProblem(tier, id) {
313
+ const entry = tier.classes[id];
314
+ const what = tierClassWhat(id);
315
+ if (!entry) {
316
+ return note("tierOffersNo", { tier: tier.name, what });
317
+ }
318
+ if (entry.model !== null) {
319
+ return null;
320
+ }
321
+ const { maker } = splitClassId(id);
322
+ if (entry.reason === "maker" && maker) {
323
+ return note("tierLeavesOutMaker", { tier: tier.name, maker: MAKER_COMPANIES[maker] });
324
+ }
325
+ const model = entry.name ?? note("thisModel");
326
+ const why = entry.reason === "region"
327
+ ? note("tierWhyRegion")
328
+ : entry.reason === "retention"
329
+ ? note("tierWhyRetention", { model })
330
+ : entry.reason === "training"
331
+ ? note("tierWhyTraining", { model })
332
+ : note("tierWhyUnbound");
333
+ return note("tierOffersNoWhy", { tier: tier.name, what, why });
223
334
  }
224
335
  /** The classes this wizard needs that this runtime cannot serve, in a language; empty = every step can run. */
225
336
  export async function missingModels(def, lang = "en") {
@@ -228,22 +339,39 @@ export async function missingModels(def, lang = "en") {
228
339
  /** The classes this wizard needs that this runtime cannot serve; empty = every step can run. */
229
340
  export async function missingModelsSaid(def) {
230
341
  const unavoidable = unavoidableSteps(def);
342
+ const tier = await currentTier();
231
343
  const needs = new Map();
344
+ // What the organization's tier doesn't offer is missing whatever this runtime could serve.
345
+ const outside = new Map();
346
+ const use = (step, cls, required) => {
347
+ const id = tier ? tierClassOf(step, cls) : cls;
348
+ const problem = tier ? tierProblem(tier, id) : null;
349
+ if (!problem) {
350
+ needs.set(cls, [...(needs.get(cls) ?? []), { step, required }]);
351
+ return;
352
+ }
353
+ const entry = outside.get(id) ?? { cls, tierClass: id, problem, steps: [], blocking: false };
354
+ if (!entry.steps.some((s) => s.id === step.id)) {
355
+ entry.steps.push({ id: step.id, title: step.title });
356
+ }
357
+ entry.blocking ||= required && unavoidable.has(step.id);
358
+ outside.set(id, entry);
359
+ };
232
360
  for (const step of def.steps) {
233
361
  for (const cls of new Set(stepClasses(step))) {
234
- needs.set(cls, [...(needs.get(cls) ?? []), { step, required: true }]);
362
+ use(step, cls, true);
235
363
  }
236
364
  for (const cls of optionalStepClasses(step)) {
237
- needs.set(cls, [...(needs.get(cls) ?? []), { step, required: false }]);
365
+ use(step, cls, false);
238
366
  }
239
367
  }
240
- const missing = [];
368
+ const missing = [...outside.values()];
241
369
  // A video runs on an installed client only, whatever serves its class otherwise.
242
370
  for (const step of def.steps) {
243
371
  if (step.type !== "motion-graphics") {
244
372
  continue;
245
373
  }
246
- const cls = step.model ?? "low";
374
+ const cls = textClassOf(step.model ?? "low");
247
375
  const found = await motionClient(cls);
248
376
  if ("problem" in found) {
249
377
  missing.push({