@lark-project/meegle 1.0.21 → 1.0.23

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
@@ -8,6 +8,23 @@ versioned section on each npm release.
8
8
 
9
9
  ## [Unreleased]
10
10
 
11
+ ## [v1.0.23] - 2026-09-08
12
+
13
+ ### Changed
14
+
15
+ - Numeric `--set` inference, schema-declared scalar numeric parameters from named flags, `--params`, or `--set`, and batch numeric IDs now follow JSON number syntax. Non-JSON spellings such as `+1` and `01` remain strings for `--set`; non-numeric values are rejected before transport where a typed scalar number or integer is required, including batch shared parameters.
16
+
17
+ ### Fixed
18
+
19
+ - Preserve the exact type and lexical form of JSON numbers across CLI and SDK inputs, MCP/HTTP/local responses, JSON/NDJSON/table output, batch IDs, fixed parameters, and output-to-input reuse. Values beyond JavaScript's safe-integer range or Go's `int64` range, high-precision decimals, and exponent notation no longer pass through `float64`; only explicit local control values such as pagination indexes are range-checked.
20
+ - Report the lexicographically first invalid schema-declared numeric parameter consistently when `--params` or `--set` supplies multiple invalid values, for both single and batch commands.
21
+
22
+ ## [v1.0.22] - 2026-08-27
23
+
24
+ ### Fixed
25
+
26
+ - Restored the Facade command-string Go SDK to its MCP-only contract: local CLI API commands such as `ai-handoff` and `preference handoff` remain available in the npm-distributed `meegle` CLI but are no longer registered or routed by the remote RPC SDK.
27
+
11
28
  ## [v1.0.21] - 2026-08-26
12
29
 
13
30
  ### Added
package/README.md CHANGED
@@ -615,17 +615,25 @@ missing required parameters: --user-key, --work-item-type
615
615
 
616
616
  ### --set key=value (Generic)
617
617
 
618
- `--set` is an alternate syntax for writing **top-level** parameters `--set key=value` is equivalent to typing `--key value`. Useful when scripting with a uniform `key=value` form, or for writing nested top-level params via dot-path. Values are auto-typed (int / float / bool / string).
618
+ `--set` is an alternate syntax for writing **top-level** parameters. For values whose inferred type matches the command schema, `--set key=value` is equivalent to typing `--key value`. It is useful when scripting with a uniform `key=value` form, or for writing nested top-level params via dot-path. Valid JSON numbers are kept as exact numbers (including large integers, high-precision decimals, and exponent notation), `true` / `false` become booleans, and other values remain strings.
619
619
 
620
620
  ```bash
621
621
  # These two are equivalent:
622
622
  meegle mywork todo --action this_week --page-num 1
623
623
  meegle mywork todo --set action=this_week --set page_num=1
624
624
 
625
+ # Exact JSON number; no float64 or int64 conversion:
626
+ --set work_item_id=9007199254740993
627
+
628
+ # Not a valid JSON number, so it remains the string "01":
629
+ --set external_id=01
630
+
625
631
  # Dot-path builds nested maps (rarely used in Meegle, but supported):
626
632
  --set extra.flag=true # becomes {"extra":{"flag":true}}
627
633
  ```
628
634
 
635
+ Schema-declared scalar numeric parameters use the same exact representation whether supplied through a named flag, `--params`, or `--set`. `number` accepts any valid JSON number; `integer` additionally requires an integral value but is not limited to Go's `int64` range. Non-JSON spellings such as `+1` and `01`, as well as non-numeric JSON values, are rejected before the request is sent when the schema requires a scalar number or integer. Explicit CLI control flags such as pagination indexes remain range-checked where required.
636
+
629
637
  `--set` only writes **top-level** parameters. To write a work item's `fields[]`, use `--params '{"fields":[...]}'` (see below).
630
638
 
631
639
  ### --params JSON
@@ -849,9 +857,10 @@ escape sequences retain their backslash.
849
857
  This decoding only applies to programmatic command-string entry points such as
850
858
  `CommandClient.Execute` and `ExecuteCommandString`. The `meegle` binary receives
851
859
  an argument array from the shell, so normal shell quoting rules apply there.
852
- The command-string SDK registers both MCP-discovered commands and local CLI API
853
- commands, including `ai-handoff` and `preference handoff`; direct `CallTool`
854
- continues to address MCP tools only.
860
+ The command-string Go SDK used by Facade for remote RPC execution registers only
861
+ MCP-discovered commands. Local CLI API commands such as `ai-handoff` and
862
+ `preference handoff` are available only in the npm-distributed `meegle` CLI;
863
+ direct `CallTool` also continues to address MCP tools only.
855
864
 
856
865
  ## Authentication
857
866
 
package/README.zh-CN.md CHANGED
@@ -604,17 +604,25 @@ missing required parameters: --user-key, --work-item-type
604
604
 
605
605
  ### --set key=value(通用)
606
606
 
607
- `--set` 是普通 flag 的**替代写法**,只影响**顶层参数**:`--set key=value` 等价于 `--key value`。适合在脚本里用统一的 key=value 语法,或通过 dot-path 写嵌套顶层对象。值自动类型推断(int / float / bool / string)。
607
+ `--set` 是普通 flag 的**替代写法**,只影响**顶层参数**。当推断出的值类型与命令 schema 一致时,`--set key=value` 等价于 `--key value`。它适合在脚本里使用统一的 key=value 语法,或通过 dot-path 写嵌套顶层对象。合法 JSON 数字会作为精确数字保留(包括大整数、高精度小数和指数形式),`true` / `false` 会转为布尔值,其他值保持字符串。
608
608
 
609
609
  ```bash
610
610
  # 下面两种等价:
611
611
  meegle mywork todo --action this_week --page-num 1
612
612
  meegle mywork todo --set action=this_week --set page_num=1
613
613
 
614
+ # 精确保留的 JSON 数字,不经过 float64 或 int64 转换:
615
+ --set work_item_id=9007199254740993
616
+
617
+ # 不是合法 JSON 数字,因此保持字符串 "01":
618
+ --set external_id=01
619
+
614
620
  # dot-path 嵌套(Meegle 很少用到,但支持):
615
621
  --set extra.flag=true # 变成 {"extra":{"flag":true}}
616
622
  ```
617
623
 
624
+ 无论通过具名 flag、`--params` 还是 `--set` 提供,接口 schema 声明的标量数字参数都会使用相同的精确表示:`number` 接受任意合法 JSON 数字;`integer` 还要求值在数学上为整数,但不受 Go `int64` 范围限制。schema 要求标量数字或整数时,`+1`、`01` 等非 JSON 数字写法以及非数字 JSON 值会在请求发出前被拒绝。分页序号等明确的 CLI 控制参数仍会按需要做范围校验。
625
+
618
626
  `--set` 只写**顶层参数**,**不会**写到工作项的 `fields[]`。写 `fields[]` 请用 `--params '{"fields":[...]}'`(见下)。
619
627
 
620
628
  ### --params JSON
@@ -818,8 +826,9 @@ meegle inspect workitem.create
818
826
  该解码只作用于 `CommandClient.Execute`、`ExecuteCommandString` 等程序化
819
827
  命令字符串入口。`meegle` 二进制直接接收 shell 解析后的参数数组,因此仍遵循
820
828
  对应 shell 的引号和转义规则。
821
- 命令字符串 SDK 会同时注册 MCP 动态发现命令和本地 CLI API 命令,包括
822
- `ai-handoff` `preference handoff`;直接调用 `CallTool` 时仍然只访问 MCP tool。
829
+ Facade 远程 RPC 调用的命令字符串 Go SDK 只注册 MCP 动态发现命令。
830
+ `ai-handoff`、`preference handoff` 等本地 CLI API 命令只在 npm 分发的
831
+ `meegle` CLI 中提供;直接调用 `CallTool` 时也仍然只访问 MCP tool。
823
832
 
824
833
  ## 认证
825
834
 
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lark-project/meegle",
3
- "version": "1.0.21",
3
+ "version": "1.0.23",
4
4
  "description": "Agent-First CLI for Meegle (Lark Project)",
5
5
  "license": "MIT",
6
6
  "homepage": "https://github.com/larksuite/meegle-cli#readme",