@aiaiai-pt/martha-cli 0.50.0 → 0.51.1

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,24 @@ All notable changes to `@aiaiai-pt/martha-cli`. Format: [Keep a Changelog](https
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.51.1] — 2026-07-17
8
+
9
+ ### Fixed — hosted embed cache migration (#955)
10
+
11
+ - Hosted bundle URLs and generated HTML snippets now use the one-time `0.3.0`
12
+ cache key needed to escape the former immutable stable-file policy.
13
+ - HTML snippets apply the same key to `stylesheet-url`, because the loader
14
+ query is not inherited by the sibling CSS request.
15
+
16
+ ## [0.51.0] — 2026-07-17
17
+
18
+ ### Added — customer-configurable agent display names (#951)
19
+
20
+ - `martha agents create --display-name <name>` sets the customer-facing chat
21
+ identity without changing the stable technical agent key.
22
+ - Agent YAML/JSON create and update files round-trip `display_name`; list and
23
+ detail output now show both the display name and technical key.
24
+
7
25
  ## [0.49.0] — 2026-07-15
8
26
 
9
27
  ### Added — UMS-gated second-party approval governance (#583 G1+G2)
package/dist/index.js CHANGED
@@ -11119,7 +11119,7 @@ init_config();
11119
11119
  init_errors();
11120
11120
 
11121
11121
  // src/version.ts
11122
- var CLI_VERSION = "0.50.0";
11122
+ var CLI_VERSION = "0.51.1";
11123
11123
 
11124
11124
  // src/commands/sessions.ts
11125
11125
  function relativeTime(iso) {
@@ -11549,12 +11549,19 @@ var agentsConfig = {
11549
11549
  },
11550
11550
  normalizeBody: normalizeAgentBody,
11551
11551
  extraCreateOptions: (cmd) => {
11552
- cmd.option("--name <name>", "Agent name").option("--reasoning <mode>", "Where the agent reasons: 'martha' (Martha-hosted, default) or " + "'self-hosted' (your service; reached via webhook)").option("--enable-host-runner", "Enable a host runner + mint a runner key: attach `martha runner` as this " + "agent's host executor (channel tool.* only). Alias: --runner-key").option("--runner-key", "Alias for --enable-host-runner").option("--model <model>", "LLM model (e.g. anthropic/claude-sonnet-4-6)").option("--provider <provider>", "LLM provider (anthropic, openai)").option("--prompt <text>", "System prompt").option("--description <text>", "Agent description").option("--temperature <n>", "Temperature (0-1)").option("--max-tokens <n>", "Max output tokens").option("--tags <tags>", "Capability domains (comma-separated)").option("--local-tools <tools>", "Local tools (comma-separated)").option("--type <type>", "Deprecated: use --reasoning. cloud=Martha-hosted, external=self-hosted").option("--auth <method>", "Deprecated: use --enable-host-runner. service-account (self-hosted only) or api-key");
11552
+ cmd.option("--name <name>", "Stable technical agent key").option("--display-name <name>", "Customer-facing name shown in chat").option("--reasoning <mode>", "Where the agent reasons: 'martha' (Martha-hosted, default) or " + "'self-hosted' (your service; reached via webhook)").option("--enable-host-runner", "Enable a host runner + mint a runner key: attach `martha runner` as this " + "agent's host executor (channel tool.* only). Alias: --runner-key").option("--runner-key", "Alias for --enable-host-runner").option("--model <model>", "LLM model (e.g. anthropic/claude-sonnet-4-6)").option("--provider <provider>", "LLM provider (anthropic, openai)").option("--prompt <text>", "System prompt").option("--description <text>", "Agent description").option("--temperature <n>", "Temperature (0-1)").option("--max-tokens <n>", "Max output tokens").option("--tags <tags>", "Capability domains (comma-separated)").option("--local-tools <tools>", "Local tools (comma-separated)").option("--type <type>", "Deprecated: use --reasoning. cloud=Martha-hosted, external=self-hosted").option("--auth <method>", "Deprecated: use --enable-host-runner. service-account (self-hosted only) or api-key");
11553
11553
  },
11554
11554
  buildInlineBody: (opts) => {
11555
11555
  if (!opts.name)
11556
11556
  return null;
11557
11557
  const body = { name: opts.name };
11558
+ if (opts.displayName !== undefined) {
11559
+ const displayName = String(opts.displayName).trim();
11560
+ if (!displayName) {
11561
+ throw new CLIError("--display-name must contain visible text", 4 /* Validation */);
11562
+ }
11563
+ body.display_name = displayName;
11564
+ }
11558
11565
  if (opts.description)
11559
11566
  body.description = opts.description;
11560
11567
  if (opts.prompt)
@@ -11607,6 +11614,10 @@ var agentsConfig = {
11607
11614
  },
11608
11615
  listColumns: [
11609
11616
  { header: "NAME", accessor: (item) => String(item.name ?? "") },
11617
+ {
11618
+ header: "DISPLAY NAME",
11619
+ accessor: (item) => String(item.display_name ?? "-")
11620
+ },
11610
11621
  {
11611
11622
  header: "MODEL",
11612
11623
  accessor: (item) => {
@@ -11621,8 +11632,11 @@ var agentsConfig = {
11621
11632
  { header: "VER", accessor: (item) => String(item.version ?? 1) }
11622
11633
  ],
11623
11634
  renderDetail: (agent) => {
11624
- console.log(source_default.bold(`Agent: ${agent.name}
11635
+ console.log(source_default.bold(`Agent: ${agent.display_name ?? agent.name}
11625
11636
  `));
11637
+ console.log(` Technical key: ${agent.name}`);
11638
+ if (agent.display_name)
11639
+ console.log(` Display name: ${agent.display_name}`);
11626
11640
  if (agent.description)
11627
11641
  console.log(` ${agent.description}
11628
11642
  `);
@@ -18877,6 +18891,7 @@ init_errors();
18877
18891
 
18878
18892
  // src/lib/embed.ts
18879
18893
  init_errors();
18894
+ var HOSTED_EMBED_CACHE_KEY = "0.3.0";
18880
18895
  var EMBED_FEATURE_KEYS = [
18881
18896
  "uploads",
18882
18897
  "history",
@@ -18943,12 +18958,13 @@ function getEmbedAssetBaseUrl(apiUrl, override) {
18943
18958
  }
18944
18959
  function bundleUrls(assetBaseUrl) {
18945
18960
  const base = normalizeAssetBaseUrl(assetBaseUrl);
18961
+ const asset = (filename) => `${base}${filename}?v=${HOSTED_EMBED_CACHE_KEY}`;
18946
18962
  return {
18947
- webComponent: `${base}martha-chat.ce.js`,
18948
- esm: `${base}martha-chat.es.js`,
18949
- react: `${base}martha-chat.react.js`,
18950
- svelte: `${base}martha-chat.svelte.js`,
18951
- css: `${base}martha-chat.css`
18963
+ webComponent: asset("martha-chat.ce.js"),
18964
+ esm: asset("martha-chat.es.js"),
18965
+ react: asset("martha-chat.react.js"),
18966
+ svelte: asset("martha-chat.svelte.js"),
18967
+ css: asset("martha-chat.css")
18952
18968
  };
18953
18969
  }
18954
18970
  function normalizeOrigin(input) {
@@ -19130,7 +19146,8 @@ function renderHtmlSnippet(options) {
19130
19146
  const urls = bundleUrls(options.assetBaseUrl);
19131
19147
  const attrs = [
19132
19148
  `api-url=${jsString(options.apiUrl)}`,
19133
- `client-key=${jsString(options.clientKey)}`
19149
+ `client-key=${jsString(options.clientKey)}`,
19150
+ `stylesheet-url=${jsString(urls.css)}`
19134
19151
  ];
19135
19152
  if (options.mode === "launcher")
19136
19153
  attrs.push("launcher");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aiaiai-pt/martha-cli",
3
- "version": "0.50.0",
3
+ "version": "0.51.1",
4
4
  "description": "Terminal-first client for the Martha AI platform",
5
5
  "homepage": "https://docs.martha.nomadriver.co",
6
6
  "repository": {