@rubytech/create-maxy-code 0.1.583 → 0.1.585

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 (82) hide show
  1. package/package.json +1 -1
  2. package/payload/platform/config/brand.json +1 -0
  3. package/payload/platform/lib/brand-templating/dist/index.d.ts +13 -7
  4. package/payload/platform/lib/brand-templating/dist/index.d.ts.map +1 -1
  5. package/payload/platform/lib/brand-templating/dist/index.js +44 -29
  6. package/payload/platform/lib/brand-templating/dist/index.js.map +1 -1
  7. package/payload/platform/lib/brand-templating/src/__tests__/brand-templating.test.ts +103 -0
  8. package/payload/platform/lib/brand-templating/src/index.ts +45 -29
  9. package/payload/platform/lib/brand-templating/tsconfig.json +2 -1
  10. package/payload/platform/lib/brand-templating/vitest.config.ts +9 -0
  11. package/payload/platform/lib/telegram-reach/dist/index.d.ts +6 -0
  12. package/payload/platform/lib/telegram-reach/dist/index.d.ts.map +1 -1
  13. package/payload/platform/lib/telegram-reach/dist/index.js +38 -3
  14. package/payload/platform/lib/telegram-reach/dist/index.js.map +1 -1
  15. package/payload/platform/lib/telegram-reach/src/__tests__/telegram-reach.test.ts +54 -2
  16. package/payload/platform/lib/telegram-reach/src/index.ts +38 -4
  17. package/payload/platform/plugins/admin/skills/platform-architecture/SKILL.md +7 -1
  18. package/payload/platform/plugins/admin/skills/whats-new/SKILL.md +12 -0
  19. package/payload/platform/plugins/docs/references/platform.md +2 -0
  20. package/payload/platform/plugins/docs/references/telegram-guide.md +4 -0
  21. package/payload/platform/plugins/telegram/.claude-plugin/plugin.json +1 -1
  22. package/payload/platform/plugins/telegram/PLUGIN.md +3 -7
  23. package/payload/platform/plugins/telegram/mcp/dist/__tests__/api-census.test.js +25 -11
  24. package/payload/platform/plugins/telegram/mcp/dist/__tests__/api-census.test.js.map +1 -1
  25. package/payload/platform/plugins/telegram/mcp/dist/__tests__/api-guard.test.js +41 -5
  26. package/payload/platform/plugins/telegram/mcp/dist/__tests__/api-guard.test.js.map +1 -1
  27. package/payload/platform/plugins/telegram/mcp/dist/__tests__/api-methods.test.js +9 -3
  28. package/payload/platform/plugins/telegram/mcp/dist/__tests__/api-methods.test.js.map +1 -1
  29. package/payload/platform/plugins/telegram/mcp/dist/__tests__/card-business.test.js +14 -3
  30. package/payload/platform/plugins/telegram/mcp/dist/__tests__/card-business.test.js.map +1 -1
  31. package/payload/platform/plugins/telegram/mcp/dist/__tests__/reach-tool.test.js +20 -7
  32. package/payload/platform/plugins/telegram/mcp/dist/__tests__/reach-tool.test.js.map +1 -1
  33. package/payload/platform/plugins/telegram/mcp/dist/__tests__/schemas.test.js +2 -31
  34. package/payload/platform/plugins/telegram/mcp/dist/__tests__/schemas.test.js.map +1 -1
  35. package/payload/platform/plugins/telegram/mcp/dist/index.js +2 -10
  36. package/payload/platform/plugins/telegram/mcp/dist/index.js.map +1 -1
  37. package/payload/platform/plugins/telegram/mcp/dist/lib/account-write.d.ts +10 -3
  38. package/payload/platform/plugins/telegram/mcp/dist/lib/account-write.d.ts.map +1 -1
  39. package/payload/platform/plugins/telegram/mcp/dist/lib/account-write.js +29 -16
  40. package/payload/platform/plugins/telegram/mcp/dist/lib/account-write.js.map +1 -1
  41. package/payload/platform/plugins/telegram/mcp/dist/lib/api-census.d.ts +11 -1
  42. package/payload/platform/plugins/telegram/mcp/dist/lib/api-census.d.ts.map +1 -1
  43. package/payload/platform/plugins/telegram/mcp/dist/lib/api-census.js +18 -4
  44. package/payload/platform/plugins/telegram/mcp/dist/lib/api-census.js.map +1 -1
  45. package/payload/platform/plugins/telegram/mcp/dist/lib/api-guard.d.ts +11 -1
  46. package/payload/platform/plugins/telegram/mcp/dist/lib/api-guard.d.ts.map +1 -1
  47. package/payload/platform/plugins/telegram/mcp/dist/lib/api-guard.js +34 -2
  48. package/payload/platform/plugins/telegram/mcp/dist/lib/api-guard.js.map +1 -1
  49. package/payload/platform/plugins/telegram/mcp/dist/lib/api-methods.d.ts +0 -3
  50. package/payload/platform/plugins/telegram/mcp/dist/lib/api-methods.d.ts.map +1 -1
  51. package/payload/platform/plugins/telegram/mcp/dist/lib/api-methods.js +0 -1
  52. package/payload/platform/plugins/telegram/mcp/dist/lib/api-methods.js.map +1 -1
  53. package/payload/platform/plugins/telegram/mcp/dist/lib/business-window-store.d.ts +7 -4
  54. package/payload/platform/plugins/telegram/mcp/dist/lib/business-window-store.d.ts.map +1 -1
  55. package/payload/platform/plugins/telegram/mcp/dist/lib/business-window-store.js +15 -6
  56. package/payload/platform/plugins/telegram/mcp/dist/lib/business-window-store.js.map +1 -1
  57. package/payload/platform/plugins/telegram/mcp/dist/lib/chat-send-policy.d.ts +3 -2
  58. package/payload/platform/plugins/telegram/mcp/dist/lib/chat-send-policy.d.ts.map +1 -1
  59. package/payload/platform/plugins/telegram/mcp/dist/lib/chat-send-policy.js +3 -2
  60. package/payload/platform/plugins/telegram/mcp/dist/lib/chat-send-policy.js.map +1 -1
  61. package/payload/platform/plugins/telegram/mcp/dist/tools/api.js +8 -0
  62. package/payload/platform/plugins/telegram/mcp/dist/tools/api.js.map +1 -1
  63. package/payload/platform/plugins/telegram/mcp/dist/tools/reach.d.ts.map +1 -1
  64. package/payload/platform/plugins/telegram/mcp/dist/tools/reach.js +6 -1
  65. package/payload/platform/plugins/telegram/mcp/dist/tools/reach.js.map +1 -1
  66. package/payload/platform/plugins/telegram/mcp/dist/tools/schemas.d.ts +0 -70
  67. package/payload/platform/plugins/telegram/mcp/dist/tools/schemas.d.ts.map +1 -1
  68. package/payload/platform/plugins/telegram/mcp/dist/tools/schemas.js +0 -105
  69. package/payload/platform/plugins/telegram/mcp/dist/tools/schemas.js.map +1 -1
  70. package/payload/platform/plugins/telegram/skills/build/SKILL.md +12 -35
  71. package/payload/platform/plugins/telegram/skills/build/references/methods.md +3 -13
  72. package/payload/platform/services/claude-session-manager/dist/canonical-tool-names.generated.d.ts.map +1 -1
  73. package/payload/platform/services/claude-session-manager/dist/canonical-tool-names.generated.js +0 -1
  74. package/payload/platform/services/claude-session-manager/dist/canonical-tool-names.generated.js.map +1 -1
  75. package/payload/platform/templates/agents/admin/IDENTITY.md +11 -5
  76. package/payload/server/{chunk-CV6AEMKH.js → chunk-34FPJYHN.js} +1 -1
  77. package/payload/server/{chunk-SKYZG6OT.js → chunk-6AQYMT6C.js} +27 -21
  78. package/payload/server/{chunk-BTXRBXMU.js → chunk-GO3EPIXU.js} +1 -1
  79. package/payload/server/{manager-FQSQSSJ3.js → manager-7BXVB76I.js} +2 -2
  80. package/payload/server/maxy-edge.js +2 -2
  81. package/payload/server/public/operator.html +1 -1
  82. package/payload/server/server.js +305 -297
@@ -1,6 +1,6 @@
1
- # Business Assistant
1
+ # {{productName}}
2
2
 
3
- Your job is to do useful work for the operator. How useful you can be depends on what you know about them and their business; both grow together, and every interaction is a chance to learn more.
3
+ Your job is to do useful work for the operator. How useful you can be depends on what you know about them and their work; both grow together, and every interaction is a chance to learn more.
4
4
 
5
5
  ## Prime directives
6
6
 
@@ -8,9 +8,15 @@ Your job is to do useful work for the operator. How useful you can be depends on
8
8
  2. Be concise. Three sentences or fewer. If you cannot answer in three, ask in five words.
9
9
  3. Show your evidence. Gather it before forming a hypothesis. Never speculate.
10
10
 
11
+ ## Your purpose
12
+
13
+ {{productMandate}}
14
+
15
+ When a request falls outside that purpose, say so before you start it. Name what you are for, name the closest thing you do own, and put the request back to the operator. If they ask again, the decision is theirs and you do it. That is one exchange, not a refusal and not a negotiation.
16
+
11
17
  ## Before you speak
12
18
 
13
- If more than one admin works on this account, identify which one you are speaking with this session, purely as a convenience so you load the right person's profile and history. This is never a gate and never blocks any tool; with a single admin, skip it. Then, before your first message, do reconnaissance: read what is known about the operator and their business, today's calendar, active projects, open work, recent conversations. Infer the domain from the plugins and skills available. Then lead with what you found, and follow with a proposal suited to where the operator is in their day. Ask only the questions you could not answer through investigation. You are expected to drive the day, not solicit instructions for it.
19
+ If more than one admin works on this account, identify which one you are speaking with this session, purely as a convenience so you load the right person's profile and history. This is never a gate and never blocks any tool; with a single admin, skip it. Then, before your first message, do reconnaissance: read what is known about the operator and their work, today's calendar, active projects, open work, recent conversations. Infer the domain from the plugins and skills available. Then lead with what you found, and follow with a proposal suited to where the operator is in their day. Ask only the questions you could not answer through investigation. You are expected to drive the day, not solicit instructions for it.
14
20
 
15
21
  When a turn needs you to ground a claim about what the product is, how the platform is built, how plugins or skills or specialists work, how install or deploy runs, or any other product-architecture fact, load the platform-architecture skill and answer from its body. Cite the source URL printed above the block you drew from. The platform-architecture skill is the install catalogue, not evidence of what is installed on this account. For questions about what is enabled here — which plugins are on, which specialists you can dispatch, which models are in use — call capabilities-here and answer from its JSON; never infer install state from the catalogue body.
16
22
 
@@ -20,13 +26,13 @@ When a request needs a skill and you do not already know its exact slug, resolve
20
26
 
21
27
  You may not act on a request until you know what is being asked, what is in scope and what is out, and what rules apply. When the operator's words are precise, all three are obvious and you act. When any is imprecise, stop and ask. Insist on the operator being precise and concise.
22
28
 
23
- How you route the work is decided per turn by the routing ladder injected with each prompt: delegate to the specialist that owns the deliverable, else load an admin-usable skill, else, when the deliverable is one the business issues repeatedly and no specialist or skill owns it, author its owning skill once via skill-builder (or a worker agent via agent-builder) and produce it through that, else author it directly. Authoring directly is the last resort for a genuine one-off, never for a repeatable document or process. That ladder, not this file, carries the live roster, the admin-usable list, and the outcome-only brief contract.
29
+ How you route the work is decided per turn by the routing ladder injected with each prompt: delegate to the specialist that owns the deliverable, else load an admin-usable skill, else, when the deliverable is one that recurs and no specialist or skill owns it, author its owning skill once via skill-builder (or a worker agent via agent-builder) and produce it through that, else author it directly. Authoring directly is the last resort for a genuine one-off, never for a repeatable document or process. That ladder, not this file, carries the live roster, the admin-usable list, and the outcome-only brief contract.
24
30
 
25
31
  ## Working from the graph
26
32
 
27
33
  The graph is your brain. The first read of any turn that needs to know something is against the graph; outside lookups happen only after the graph has confirmed it does not hold the answer, and anything new an outside lookup produces is written back the same turn. Greetings and pure interaction turns do not need this loop. When something worth remembering comes out of a conversation, hand the write off to the specialist who owns graph writes; direct writes from this seat are reserved for one-line updates against a node already in context whose classification is unambiguous.
28
34
 
29
- Every factual claim you make in any turn, about the operator, their business, the product, the platform, the day, or the world, has a source you can name. The permissible sources are four: a graph read this session, a tool output returned this session, content the operator pasted into this conversation, and the body of the platform-architecture skill when it is loaded. Pretraining recall is not a source. If a claim does not trace to one of the four, you do not have it yet; read the graph, run the tool, load the skill, or ask the operator. This rule binds every factual sentence you emit, not only the ones about the graph.
35
+ Every factual claim you make in any turn, about the operator, their work, the product, the platform, the day, or the world, has a source you can name. The permissible sources are four: a graph read this session, a tool output returned this session, content the operator pasted into this conversation, and the body of the platform-architecture skill when it is loaded. Pretraining recall is not a source. If a claim does not trace to one of the four, you do not have it yet; read the graph, run the tool, load the skill, or ask the operator. This rule binds every factual sentence you emit, not only the ones about the graph.
30
36
 
31
37
  When the operator asks for a previous workflow output by name, fetch the latest matching report directly rather than searching. Searching is for questions about the contents of reports, not for the reports themselves. When the operator asks how your understanding of a person, organisation, or concept has changed over time, walk the revision history of that entity and surface the deltas yourself.
32
38
 
@@ -8,7 +8,7 @@ import {
8
8
  getUserTimezone,
9
9
  isValidAccountId,
10
10
  registerLoop
11
- } from "./chunk-SKYZG6OT.js";
11
+ } from "./chunk-6AQYMT6C.js";
12
12
  import {
13
13
  __commonJS,
14
14
  __require,
@@ -115,8 +115,8 @@ import { readFileSync as readFileSync3, readdirSync, existsSync as existsSync3,
115
115
  // ../lib/brand-templating/src/index.ts
116
116
  import { join as join2 } from "path";
117
117
  import { existsSync as existsSync2, readFileSync as readFileSync2 } from "fs";
118
- var PLACEHOLDER = "{{productName}}";
119
- var cachedProductName = null;
118
+ var BRAND_FIELDS = ["productName", "productMandate"];
119
+ var cache = /* @__PURE__ */ new Map();
120
120
  function brandJsonPath() {
121
121
  const platformRoot2 = process.env.MAXY_PLATFORM_ROOT;
122
122
  if (!platformRoot2) {
@@ -126,9 +126,11 @@ function brandJsonPath() {
126
126
  }
127
127
  return join2(platformRoot2, "config", "brand.json");
128
128
  }
129
- function getBrandProductName() {
130
- if (cachedProductName !== null) return cachedProductName;
129
+ function getBrandValue(field) {
131
130
  const path = brandJsonPath();
131
+ const key = `${path}::${field}`;
132
+ const cached = cache.get(key);
133
+ if (cached !== void 0) return cached;
132
134
  if (!existsSync2(path)) {
133
135
  throw new Error(`[skill-loader] brand.json missing at ${path}`);
134
136
  }
@@ -140,32 +142,36 @@ function getBrandProductName() {
140
142
  `[skill-loader] brand.json unreadable at ${path}: ${err instanceof Error ? err.message : String(err)}`
141
143
  );
142
144
  }
143
- const value = parsed.productName;
145
+ const value = parsed[field];
144
146
  if (typeof value !== "string" || value.trim() === "") {
145
147
  throw new Error(
146
- `[skill-loader] brand.json at ${path} has missing or empty productName`
148
+ `[skill-loader] brand.json at ${path} has missing or empty ${field}`
147
149
  );
148
150
  }
149
- cachedProductName = value;
151
+ cache.set(key, value);
150
152
  return value;
151
153
  }
152
154
  function substituteBrandPlaceholders(content, sourcePath) {
153
- if (!content.includes(PLACEHOLDER)) return content;
154
- let productName;
155
- try {
156
- productName = getBrandProductName();
157
- } catch (err) {
158
- console.error(
159
- `[skill-loader] ERROR: brand.json missing \u2014 cannot resolve productName for skill ${sourcePath}`
155
+ let out = content;
156
+ for (const field of BRAND_FIELDS) {
157
+ const placeholder = `{{${field}}}`;
158
+ if (!out.includes(placeholder)) continue;
159
+ let value;
160
+ try {
161
+ value = getBrandValue(field);
162
+ } catch (err) {
163
+ console.error(
164
+ `[skill-loader] ERROR: brand.json missing \u2014 cannot resolve ${field} for skill ${sourcePath}`
165
+ );
166
+ throw err;
167
+ }
168
+ const occurrences = out.split(placeholder).length - 1;
169
+ out = out.split(placeholder).join(value);
170
+ console.log(
171
+ `[skill-loader] brand-substituted ${field}=${value} skill=${sourcePath} occurrences=${occurrences}`
160
172
  );
161
- throw err;
162
173
  }
163
- const occurrences = content.split(PLACEHOLDER).length - 1;
164
- const substituted = content.split(PLACEHOLDER).join(productName);
165
- console.log(
166
- `[skill-loader] brand-substituted productName=${productName} skill=${sourcePath} occurrences=${occurrences}`
167
- );
168
- return substituted;
174
+ return out;
169
175
  }
170
176
 
171
177
  // app/lib/claude-agent/account.ts
@@ -12,7 +12,7 @@ import {
12
12
  getConversationOwner,
13
13
  isValidAccountId,
14
14
  registerLoop
15
- } from "./chunk-SKYZG6OT.js";
15
+ } from "./chunk-6AQYMT6C.js";
16
16
 
17
17
  // node_modules/hono/dist/compose.js
18
18
  var compose = (middleware, onError, onNotFound) => {
@@ -30,8 +30,8 @@ import {
30
30
  startConnection,
31
31
  stopConnection,
32
32
  storeMessage
33
- } from "./chunk-CV6AEMKH.js";
34
- import "./chunk-SKYZG6OT.js";
33
+ } from "./chunk-34FPJYHN.js";
34
+ import "./chunk-6AQYMT6C.js";
35
35
  import "./chunk-HYQNUVGO.js";
36
36
  export {
37
37
  buildNotifyPending,
@@ -19,12 +19,12 @@ import {
19
19
  screencastLog,
20
20
  vncLog,
21
21
  websockifyLog
22
- } from "./chunk-BTXRBXMU.js";
22
+ } from "./chunk-GO3EPIXU.js";
23
23
  import {
24
24
  CDP_PORT,
25
25
  LOG_DIR,
26
26
  WEBSOCKIFY_PORT
27
- } from "./chunk-SKYZG6OT.js";
27
+ } from "./chunk-6AQYMT6C.js";
28
28
  import "./chunk-HYQNUVGO.js";
29
29
 
30
30
  // server/edge.ts
@@ -22,8 +22,8 @@
22
22
  <link rel="modulepreload" crossorigin href="/assets/wrench-Ck4phkdB.js">
23
23
  <link rel="modulepreload" crossorigin href="/assets/page-DBQLOasI.js">
24
24
  <link rel="stylesheet" crossorigin href="/assets/jsx-runtime-rMaiYjNu.css">
25
- <link rel="stylesheet" crossorigin href="/assets/AdminLoginScreens-CWMpccrR.css">
26
25
  <link rel="stylesheet" crossorigin href="/assets/useMediaQuery-DXAuc8G-.css">
26
+ <link rel="stylesheet" crossorigin href="/assets/AdminLoginScreens-CWMpccrR.css">
27
27
  <link rel="stylesheet" href="/brand-defaults.css">
28
28
  </head>
29
29
  <body>