@getmagical/cli 0.10.1 → 0.11.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.
package/README.md CHANGED
@@ -24,6 +24,9 @@ mgcl org list
24
24
  mgcl automations list --limit 10
25
25
  mgcl automations update --id ... --input-json ...
26
26
  mgcl automation-runs list --automation-id ...
27
+ mgcl work-items list --automation-id ... --status FAILED,STOPPED
28
+ mgcl work-items get --id ...
29
+ mgcl automation-runs list-page --work-item-id ...
27
30
  mgcl automations run-draft --draft-automation-id ... --agent-id ... --idempotency-key ... --config-json '{"startInTakeOverMode":true,"captureActions":true,"approvalMode":"HUMAN_APPROVAL","consistencyCheckCount":3}'
28
31
  mgcl automations publish --draft-automation-id ... # non-production only: mgcl refuses against the production API, and the API rejects it too
29
32
  ```
@@ -49,42 +52,43 @@ The count applies only when creating a regression test. Repeating the command
49
52
  for the same automation and agent version pair returns the existing test;
50
53
  changing the count does not expand or rerun it.
51
54
 
52
- `mgcl pathway-regression preview --runs-per-path <count>` remains a historical
53
- coverage lookup, accepting 1–50 with a default of 2. It does not configure a
54
- later regression test.
55
-
56
55
  ## Typed classification
57
56
 
58
57
  Use `mgcl classify` for focused typed judgments over context you already have.
59
- The request uses TypeSafe-shaped JSON with one shared `state` and a map of
60
- named `questions`. Version 1 supports `noul`, `choice`, and `score` questions.
61
- The backend uses `jev-latest` by default. Add `model` to the request to select
62
- an explicit supported model; the response reports the model actually used.
63
- Instructions, choice descriptions, rubric levels, and score legends may be
64
- structured JSON and are passed through without narrowing.
65
- The backend applies a 30-second total deadline, including bounded transient
66
- retries. Access is employee-only through normal CLI credentials or an allowed
67
- Magical runtime identity.
58
+ The request has one shared `context` (text or JSON), optional `images`, and a
59
+ map of named `questions`. Question types are `predicate`, `choice`, and
60
+ `score`, and every question needs `instructions`. Choices are a map of value to
61
+ description; score `levels` are an ordered list of `{label, description?}`.
62
+
63
+ `--provider` selects `openai` (the default, OpenAI Decisions `gpt-6-luna`) or
64
+ `typesafe` (TypeSafe `jev-latest`) and overrides `provider` in the request. Add
65
+ `model` to select an explicit model for that provider; the response reports the
66
+ provider and model actually used. Images must be base64 data URLs and are only
67
+ supported by `openai`; `typesafe` rejects them with an input error. The backend
68
+ applies a 30-second total deadline. Access is employee-only through normal CLI
69
+ credentials or an allowed Magical runtime identity.
68
70
 
69
71
  ```bash
70
72
  mgcl classify --input-file request.json
71
- mgcl classify --input-json '{"state":"Please refund the duplicate charge.","questions":{"refund_requested":{"type":"noul","instructions":"Does the message explicitly request a refund?"}}}'
73
+ mgcl classify --provider typesafe --input-file request.json
74
+ mgcl classify --input-json '{"context":"Please refund the duplicate charge.","questions":{"refund_requested":{"type":"predicate","instructions":"Does the message explicitly request a refund?"}}}'
72
75
  cat request.json | mgcl classify --input-file -
73
76
  ```
74
77
 
75
78
  Pass exactly one input source. Questions in one batch are independent and
76
79
  cannot consume sibling answers. Split dependent judgments into separate calls.
77
- `noul` is a probability rather than a boolean; choice results retain the full
78
- option distribution; scores may be fractional. Confidence represents the
79
- returned distribution, not correctness, so include an `insufficient_evidence`
80
- choice when the supplied context may not establish an answer.
81
-
82
- The command evaluates only supplied text and JSON. It does not fetch URLs,
83
- files named in the request, run records, or media. Output is always the full
84
- parseable JSON response, including model, usage, probability distributions,
85
- score legends, and additive fields. A valid negative or uncertain answer exits
86
- successfully. Invalid input and backend or provider failures use the normal
87
- nonzero CLI error path and write diagnostics to stderr.
80
+ Every provider returns the same answer shape: predicates return a
81
+ `probability`; choices return the `choice`, `confidence`, and the full option
82
+ `probabilities`; scores return a possibly fractional `score`, `confidence`, and
83
+ per-level probabilities. Confidence represents the returned distribution, not
84
+ correctness, so include an `insufficient_evidence` choice when the supplied
85
+ context may not establish an answer.
86
+
87
+ The command does not fetch URLs, files named in the request, run records, or
88
+ hosted media. Output is always the full parseable JSON response, including
89
+ provider, model, usage, and probability distributions. A valid negative or
90
+ uncertain answer exits successfully. Invalid input and backend or provider
91
+ failures use the normal nonzero CLI error path and write diagnostics to stderr.
88
92
 
89
93
  ## Publish checks after saving
90
94