@delta-infra/cli 1.1.19 → 1.1.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/README.md +511 -520
- package/checksums.txt +5 -5
- package/package.json +1 -1
- package/scripts/install-wizard.js +689 -688
- package/scripts/install.js +442 -442
- package/scripts/run.js +65 -65
- package/skills/delta-protein/AGENTS.md +72 -72
- package/skills/delta-protein/SKILL.md +388 -388
- package/skills/delta-protein/agents/openai.yaml +3 -3
- package/skills/delta-protein/references/bfitter.md +63 -63
- package/skills/delta-protein/references/catapro_predict.md +62 -62
- package/skills/delta-protein/references/catpred_predict.md +64 -64
- package/skills/delta-protein/references/caver_tunnel_analyze.md +62 -62
- package/skills/delta-protein/references/consensus_mutation.md +60 -60
- package/skills/delta-protein/references/consurf_predict.md +66 -66
- package/skills/delta-protein/references/crop_sequence.md +68 -68
- package/skills/delta-protein/references/dock.md +81 -81
- package/skills/delta-protein/references/dock_score.md +69 -69
- package/skills/delta-protein/references/easifa_predict_active_site.md +69 -69
- package/skills/delta-protein/references/ephod_predict_mutation.md +65 -65
- package/skills/delta-protein/references/ephod_predict_protein.md +60 -60
- package/skills/delta-protein/references/esmfold2_predict.md +66 -66
- package/skills/delta-protein/references/evcouplings_mutation.md +63 -63
- package/skills/delta-protein/references/fasta_to_sequence.md +58 -58
- package/skills/delta-protein/references/foldseek.md +60 -60
- package/skills/delta-protein/references/generate_msa.md +60 -60
- package/skills/delta-protein/references/interpro_analyze.md +62 -62
- package/skills/delta-protein/references/mpnn_design_sequence.md +70 -70
- package/skills/delta-protein/references/multievolve.md +72 -72
- package/skills/delta-protein/references/pisa_query.md +69 -69
- package/skills/delta-protein/references/plip_analyze.md +64 -64
- package/skills/delta-protein/references/pocket_prediction.md +62 -62
- package/skills/delta-protein/references/protein_design.md +64 -64
- package/skills/delta-protein/references/protein_evolution.md +76 -76
- package/skills/delta-protein/references/protein_sol_predict_mutation.md +65 -65
- package/skills/delta-protein/references/protein_sol_predict_protein.md +60 -60
- package/skills/delta-protein/references/protenix.md +65 -65
- package/skills/delta-protein/references/protrek_search.md +89 -89
- package/skills/delta-protein/references/pubchem_search.md +67 -67
- package/skills/delta-protein/references/pubmed_search.md +78 -78
- package/skills/delta-protein/references/reap_design_primer.md +68 -68
- package/skills/delta-protein/references/rfd3_design.md +64 -64
- package/skills/delta-protein/references/structure_to_sequence.md +60 -60
- package/skills/delta-protein/references/summarize_result.md +67 -67
- package/skills/delta-protein/references/surface_charge.md +83 -83
- package/skills/delta-protein/references/uniprot_batch_query.md +62 -62
- package/skills/delta-protein/references/uniprot_query.md +63 -63
- package/skills/delta-protein/references/zero_shot_mutant_candidates.md +75 -75
- package/skills/delta-protein/scripts/gen_references.py +166 -166
- package/skills/delta-protein/scripts/output_metadata.json +274 -274
- package/skills/delta-sandbox/SKILL.md +388 -388
- package/skills/delta-sandbox/agents/openai.yaml +4 -4
- package/skills/delta-sandbox/references/commands.md +71 -58
- package/skills/delta-sandbox/references/lifecycle.md +101 -100
- package/skills/delta-sandbox/references/recipes.md +138 -138
- package/skills/delta-science/AGENTS.md +47 -47
- package/skills/delta-science/SKILL.md +227 -227
- package/skills/delta-science/agents/openai.yaml +4 -4
- package/skills/delta-science/references/antbo.md +105 -105
- package/skills/delta-science/references/delta-bo.md +92 -92
- package/skills/delta-science/references/gsasii.md +118 -118
- package/skills/delta-science/references/lammps.md +68 -68
- package/skills/delta-science/references/ldm-bo.md +132 -132
- package/skills/delta-science/references/materials-design.md +130 -130
- package/skills/delta-science/references/pubchem.md +128 -128
- package/skills/delta-science/references/pymatgen.md +69 -69
- package/skills/delta-science/references/qe.md +134 -134
- package/skills/delta-science/references/rdkit.md +141 -141
- package/skills/delta-science/references/strbo.md +95 -95
- package/skills/delta-science/references/synbo.md +201 -201
- package/skills/delta-science/references/xrd.md +154 -170
- package/skills/delta-science/scripts/catalog.py +92 -92
- package/skills/delta-science/scripts/generated_catalog.py +69 -69
- package/skills/delta-science/scripts/invoke.py +346 -346
- package/skills/delta-shared/SKILL.md +115 -113
- package/skills/delta-shared/agents/openai.yaml +4 -4
- package/skills/manifest.json +20 -20
|
@@ -1,4 +1,10 @@
|
|
|
1
|
-
# XRD
|
|
1
|
+
# XRD reference
|
|
2
|
+
|
|
3
|
+
Make all online XRD calls with
|
|
4
|
+
`delta-cli science invoke --tool xrd --endpoint <operation>`.
|
|
5
|
+
Use the CLI's configured authentication and service address. Do not
|
|
6
|
+
call registry, gateway, or compute-service URLs directly, or follow returned
|
|
7
|
+
`content_url` and job `links` outside the CLI.
|
|
2
8
|
|
|
3
9
|
The OpenAPI contract version is `1.2.0`. Business requests and responses use
|
|
4
10
|
`schema_version: 1`.
|
|
@@ -8,110 +14,73 @@ sequences, refinement jobs, quality assessment, and error handling. Replace
|
|
|
8
14
|
`art_<...>`, `<sha256>`, and `refjob_<...>` placeholders with values returned by
|
|
9
15
|
the service in the same workflow.
|
|
10
16
|
|
|
11
|
-
## 1. Tool and
|
|
12
|
-
|
|
13
|
-
The registered tool is `xrd`, tool ID `30`. The
|
|
14
|
-
[tool record](http://8.141.101.94:8001/api/v1/tools/30) and
|
|
15
|
-
[endpoint catalogue](http://8.141.101.94:8001/api/v1/tools/30/endpoints)
|
|
16
|
-
identify 27 registered endpoints, all enabled. The catalogue server is a tool
|
|
17
|
-
registry and invocation proxy; it is not the compute service base URL.
|
|
17
|
+
## 1. Tool and operations
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
| `GET /api/v1/tools/30/endpoints` | All registered XRD endpoints |
|
|
25
|
-
| `GET /api/v1/tools/30/endpoints?status=true` | Enabled XRD endpoints |
|
|
26
|
-
| `GET /api/v1/tools/name/xrd/endpoints` | Endpoint lookup by tool name |
|
|
27
|
-
|
|
28
|
-
Catalogue responses use `code`, `message`, and `data`; `code=0` indicates success.
|
|
29
|
-
Endpoint records include `id`, `tool_id`, `name`, `path`, `method`, `price`,
|
|
30
|
-
`featurekey`, and `status`. Registration and enabled status do not establish
|
|
31
|
-
backend readiness. Recheck availability and prices before execution:
|
|
19
|
+
The CLI tool is `xrd`. Pass the operation names below exactly as `--endpoint`;
|
|
20
|
+
they are server catalogue contracts, not aliases. This table documents the
|
|
21
|
+
operations used by this reference, not a live inventory or price list.
|
|
22
|
+
When diagnosing availability, checking prices, or resolving a missing or
|
|
23
|
+
inconsistent contract, use CLI discovery:
|
|
32
24
|
|
|
33
25
|
```text
|
|
34
26
|
delta-cli science list
|
|
35
27
|
delta-cli science endpoints list xrd
|
|
36
28
|
```
|
|
37
29
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
field; they do not specify a currency. All listed records have `status=true`.
|
|
41
|
-
|
|
42
|
-
| Endpoint ID | CLI endpoint | HTTP method and path | Purpose / response | Price |
|
|
43
|
-
| --- | --- | --- | --- | --- |
|
|
44
|
-
| 128 | `healthz` | `GET /healthz` | Process liveness, JSON | 0 |
|
|
45
|
-
| 129 | `readyz` | `GET /readyz` | Service readiness, JSON | 0 |
|
|
46
|
-
| 130 | `capabilities` | `GET /v1/capabilities` | Components, versions, verification, modes, and limits | 0 |
|
|
47
|
-
| 131 | `xqueryer-predictions` | `POST /v1/xqueryer/predictions` | Single-phase model predictions | 3 |
|
|
48
|
-
| 132 | `xmatcher-detect-peaks` | `POST /v1/xmatcher/detect-peaks` | Observed peak detection | 4 |
|
|
49
|
-
| 133 | `xmatcher-match` | `POST /v1/xmatcher/match` | Single-phase matching | 4 |
|
|
50
|
-
| 134 | `xmatcher-multiphase-match` | `POST /v1/xmatcher/multiphase-match` | Multiphase candidate matching | 4 |
|
|
51
|
-
| 135 | `xmatcher-cif-xrd` | `POST /v1/xmatcher/cif-xrd` | Theoretical XRD simulation from CIFs | 4 |
|
|
52
|
-
| 136 | `xmatcher-pdf-peaks-xlsx` | `POST /v1/xmatcher/pdf-peaks-xlsx` | Theoretical peak tables, binary XLSX | 8 |
|
|
53
|
-
| 137 | `xmatcher-status` | `GET /v1/xmatcher/status` | XMatcher database status | 0 |
|
|
54
|
-
| 138 | `xdecomposer-predictions` | `POST /v1/xdecomposer/predictions` | Multiphase model decomposition | 2 |
|
|
55
|
-
| 139 | `xmatcher-refinement-patterns` | `POST /v1/xmatcher/refinement-patterns` | Corrected pattern and provenance manifest | 0 |
|
|
56
|
-
| 140 | `mp500-cif-exports` | `POST /v1/mp500/cif-exports` | Export a CIF by database identity | 0 |
|
|
57
|
-
| 141 | `xmatcher-artifacts` | `POST /v1/artifacts` | Upload file bytes and return an artifact reference | 0 |
|
|
58
|
-
| 143 | `xmatcher-artifact` | `GET /v1/artifacts/{artifact_id}` | Artifact metadata | 0 |
|
|
59
|
-
| 144 | `xmatcher-artifact-content` | `GET /v1/artifacts/{artifact_id}/content` | Artifact content, binary | 0 |
|
|
60
|
-
| 145 | `refinement-job` | `GET /v1/refinement-jobs/{job_id}` | Job status and results | 0 |
|
|
61
|
-
| 146 | `refinement-job-cancel` | `POST /v1/refinement-jobs/{job_id}/cancel` | Request cancellation | 0 |
|
|
62
|
-
| 147 | `refinement-job-events` | `GET /v1/refinement-jobs/{job_id}/events` | Paginated job events | 0 |
|
|
63
|
-
| 148 | `refinement-job-artifacts` | `GET /v1/refinement-jobs/{job_id}/artifacts` | Public job artifacts | 0 |
|
|
64
|
-
| 149 | `refinement-fullprof` | `POST /v1/refinement-jobs` | Submit a FullProf job, HTTP 202 | 15 |
|
|
65
|
-
| 150 | `refinement-gsasii` | `POST /v1/refinement-jobs` | Submit a GSAS-II job, HTTP 202 | 12 |
|
|
66
|
-
| 151 | `refinement-wpem` | `POST /v1/refinement-jobs` | Submit a PyXplore/WPEM job, HTTP 202 | 10 |
|
|
67
|
-
| 160 | `simulation-cif-parse` | `POST /v1/simulation/cif-parse` | Parse CIF data blocks | 1 |
|
|
68
|
-
| 161 | `simulation-cif-peaks` | `POST /v1/simulation/cif-peaks` | Simulate reflections for a selected block and wavelength | 1 |
|
|
69
|
-
| 162 | `pdfreporter-analyses` | `POST /v1/pdfreporter/analyses` | Multiphase peak assignments and charts | 8 |
|
|
70
|
-
| 163 | `pdfreporter-assignments` | `POST /v1/pdfreporter/analyses/assignments` | Recompute analysis with manual assignments | 8 |
|
|
71
|
-
|
|
72
|
-
The three refinement CLI endpoints select backend and billing entries in the
|
|
73
|
-
proxy. The compute service exposes one job submission route. HTTP `backends`
|
|
74
|
-
values are `pyxplore`, `fullprof`, and `gsasii`; `refinement-wpem` corresponds to
|
|
75
|
-
PyXplore/WPEM. Match the CLI endpoint and requested backends to the proxy configuration.
|
|
76
|
-
|
|
77
|
-
### Chemistry gateway
|
|
30
|
+
Registration and enabled status do not establish backend readiness. Do not add
|
|
31
|
+
catalogue or health calls to an ordinary workflow unless needed for the task.
|
|
78
32
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
-
|
|
91
|
-
|
|
92
|
-
|
|
33
|
+
| Operation (`--endpoint`) | Purpose / response |
|
|
34
|
+
| --- | --- |
|
|
35
|
+
| `healthz` | Process liveness, JSON |
|
|
36
|
+
| `readyz` | Service readiness, JSON |
|
|
37
|
+
| `capabilities` | Components, versions, verification, modes, and limits |
|
|
38
|
+
| `xqueryer-predictions` | Single-phase model predictions |
|
|
39
|
+
| `xmatcher-detect-peaks` | Observed peak detection |
|
|
40
|
+
| `xmatcher-match` | Single-phase matching |
|
|
41
|
+
| `xmatcher-multiphase-match` | Multiphase candidate matching |
|
|
42
|
+
| `xmatcher-cif-xrd` | Theoretical XRD simulation from CIFs |
|
|
43
|
+
| `xmatcher-pdf-peaks-xlsx` | Theoretical peak tables, binary XLSX |
|
|
44
|
+
| `xmatcher-status` | XMatcher database status |
|
|
45
|
+
| `xdecomposer-predictions` | Multiphase model decomposition |
|
|
46
|
+
| `xmatcher-refinement-patterns` | Corrected pattern and provenance manifest |
|
|
47
|
+
| `mp500-cif-exports` | Export a CIF by database identity |
|
|
48
|
+
| `xmatcher-artifacts` | Upload file bytes and return an artifact reference |
|
|
49
|
+
| `xmatcher-artifact` | Artifact metadata |
|
|
50
|
+
| `xmatcher-artifact-content` | Artifact content, binary |
|
|
51
|
+
| `refinement-job` | Job status and results |
|
|
52
|
+
| `refinement-job-cancel` | Request cancellation |
|
|
53
|
+
| `refinement-job-events` | Paginated job events |
|
|
54
|
+
| `refinement-job-artifacts` | Public job artifacts |
|
|
55
|
+
| `refinement-fullprof` | Submit a FullProf job |
|
|
56
|
+
| `refinement-gsasii` | Submit a GSAS-II job |
|
|
57
|
+
| `refinement-wpem` | Submit a PyXplore/WPEM job |
|
|
58
|
+
| `simulation-cif-parse` | Parse CIF data blocks |
|
|
59
|
+
| `simulation-cif-peaks` | Simulate reflections for a selected block and wavelength |
|
|
60
|
+
| `pdfreporter-analyses` | Multiphase peak assignments and charts |
|
|
61
|
+
| `pdfreporter-assignments` | Recompute analysis with manual assignments |
|
|
62
|
+
|
|
63
|
+
The refinement operations select backend and billing entries. Request `backends`
|
|
64
|
+
values are `pyxplore`, `fullprof`, and `gsasii`; `refinement-wpem` corresponds to
|
|
65
|
+
PyXplore/WPEM. Match the operation and requested backends to the catalogue contract.
|
|
93
66
|
|
|
94
67
|
## 2. Request conventions and CLI argument mapping
|
|
95
68
|
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
69
|
+
Pass business JSON through `--data`. For file uploads, pass local bytes through
|
|
70
|
+
`--file` and set `--content-type application/octet-stream`; uploads are not
|
|
71
|
+
multipart requests. Authentication is handled by the CLI, not business JSON or
|
|
72
|
+
manually supplied service tokens. Business request models reject unknown fields.
|
|
99
73
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
Uploads are not multipart requests.
|
|
74
|
+
An optional `X-Request-ID` in `--headers` accepts 1–128 characters from letters,
|
|
75
|
+
digits, and `._:-`. Preserve the returned request ID for diagnostics.
|
|
103
76
|
|
|
104
|
-
|
|
105
|
-
and `._:-`. Responses also return this header. Business request models reject
|
|
106
|
-
unknown fields.
|
|
107
|
-
|
|
108
|
-
| CLI argument | Upstream meaning |
|
|
77
|
+
| CLI argument | Meaning for XRD calls |
|
|
109
78
|
| --- | --- |
|
|
110
79
|
| `--data` | JSON request body |
|
|
111
80
|
| `--params` | URL query parameters, including upload metadata and event pagination |
|
|
112
|
-
| `--path-params` |
|
|
81
|
+
| `--path-params` | Artifact or job identity: `artifact_id` or `job_id` |
|
|
113
82
|
| `--headers` | Additional headers, such as `Idempotency-Key` and `X-Content-SHA256` |
|
|
114
|
-
| `--file` | Upload a local file through the
|
|
83
|
+
| `--file` | Upload a local file through the CLI |
|
|
115
84
|
| `--content-type` | Upload body Content-Type; use `application/octet-stream` |
|
|
116
85
|
|
|
117
86
|
`--params` cannot replace `--path-params`. Keep local paths, base64 content, and
|
|
@@ -119,17 +88,23 @@ idempotency keys out of business JSON. Use `science invoke --file` for XRD uploa
|
|
|
119
88
|
The `media_type` query parameter describes the stored file format separately
|
|
120
89
|
from the upload body Content-Type.
|
|
121
90
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
91
|
+
All operations in this reference, including uploads, binary responses, and XRD
|
|
92
|
+
refinement jobs, use `science invoke`. The `science file` and `science task`
|
|
93
|
+
adapters documented for QE/Materials Design do not replace these XRD operations.
|
|
94
|
+
|
|
95
|
+
```text
|
|
96
|
+
delta-cli science invoke --tool xrd --endpoint <operation> `
|
|
97
|
+
[--data JSON] [--params JSON] [--path-params JSON] [--headers JSON]
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Pass each JSON object as one safely quoted argument. The examples below use
|
|
101
|
+
PowerShell continuation syntax. A call succeeds only when the CLI exits with
|
|
102
|
+
code 0 and its top-level JSON has `ok:true`; read business fields from `data`.
|
|
129
103
|
|
|
130
104
|
## 3. Call sequence
|
|
131
105
|
|
|
132
|
-
1.
|
|
106
|
+
1. Select the documented operation; inspect the CLI catalogue, readiness, or
|
|
107
|
+
required capabilities only when the task or diagnosis requires it.
|
|
133
108
|
2. Upload observed patterns, model inputs, CIFs, or instrument files. Save the
|
|
134
109
|
returned `artifact_id` and `sha256` together.
|
|
135
110
|
3. Use XMatcher or XDecomposer for observed data. XQueryer requires a prepared
|
|
@@ -149,13 +124,17 @@ invocation selects `tool_name="xrd"` and a registered endpoint name.
|
|
|
149
124
|
delta-cli science invoke --tool xrd --endpoint healthz
|
|
150
125
|
delta-cli science invoke --tool xrd --endpoint readyz
|
|
151
126
|
delta-cli science invoke --tool xrd --endpoint capabilities
|
|
127
|
+
delta-cli science invoke --tool xrd --endpoint xmatcher-status
|
|
152
128
|
```
|
|
153
129
|
|
|
154
|
-
`
|
|
155
|
-
`
|
|
156
|
-
an unready service
|
|
130
|
+
`healthz` returns business `{"ok":true}` for process liveness.
|
|
131
|
+
`readyz` checks authentication configuration and required components;
|
|
132
|
+
an unready service fails the call. Keep probe business `ok` distinct from the
|
|
133
|
+
CLI envelope's top-level `ok`.
|
|
157
134
|
|
|
158
|
-
`
|
|
135
|
+
`xmatcher-status` queries XMatcher database status without a request body.
|
|
136
|
+
|
|
137
|
+
`capabilities` returns `components.<name>.available`, component `details`,
|
|
159
138
|
`limits`, and build information. Check the components required for the workflow,
|
|
160
139
|
checksums, asset release approval, and mode availability. Report GPU use only when
|
|
161
140
|
the returned device or backend explicitly supports that conclusion.
|
|
@@ -176,16 +155,17 @@ described in its detailed contract; consult the deployed capability for its limi
|
|
|
176
155
|
|
|
177
156
|
### Upload
|
|
178
157
|
|
|
179
|
-
`
|
|
180
|
-
|
|
158
|
+
Operation: `xmatcher-artifacts`. Pass the local file with `--file`; read the
|
|
159
|
+
returned `ArtifactRef` from CLI `data`. Query its identity with
|
|
160
|
+
`xmatcher-artifact` and `--path-params`, rather than a returned URL.
|
|
181
161
|
|
|
182
|
-
| Parameter |
|
|
162
|
+
| Parameter | CLI argument | Requirement |
|
|
183
163
|
| --- | --- | --- |
|
|
184
|
-
| `filename` |
|
|
185
|
-
| `kind` |
|
|
186
|
-
| `media_type` |
|
|
187
|
-
| `preserve_source` |
|
|
188
|
-
| `X-Content-SHA256` |
|
|
164
|
+
| `filename` | `--params` | Required; 1–255 characters; no `/` or `\` |
|
|
165
|
+
| `kind` | `--params` | Required; accepted kinds are listed below |
|
|
166
|
+
| `media_type` | `--params` | Required; 1–255 characters; no line breaks |
|
|
167
|
+
| `preserve_source` | `--params` | Default false; preserve original observed text pattern bytes |
|
|
168
|
+
| `X-Content-SHA256` | `--headers` | Optional; 64 lowercase hexadecimal characters, hashing the upload bytes |
|
|
189
169
|
|
|
190
170
|
| Accepted upload kind | File and processing rules |
|
|
191
171
|
| --- | --- |
|
|
@@ -239,14 +219,15 @@ delta-cli science invoke --tool xrd --endpoint xmatcher-artifact-content `
|
|
|
239
219
|
--path-params '{"artifact_id":"art_<returned-id>"}'
|
|
240
220
|
```
|
|
241
221
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
`
|
|
245
|
-
|
|
222
|
+
Read binary content from the documented CLI response fields. The tool proxy may
|
|
223
|
+
wrap it as `data._binary`, `data.content_base64`, `data.media_type`, and
|
|
224
|
+
`data.content_length`. Decode `content_base64` only when the response declares
|
|
225
|
+
that representation. Verify saved content against the artifact's returned
|
|
226
|
+
SHA-256, and determine its format from the media type and content.
|
|
246
227
|
|
|
247
228
|
## 6. Phase identification and matching
|
|
248
229
|
|
|
249
|
-
### XQueryer: `
|
|
230
|
+
### XQueryer: `xqueryer-predictions`
|
|
250
231
|
|
|
251
232
|
`pattern` must reference a `model_input_pattern` containing exactly 3,500 points
|
|
252
233
|
on a uniform 10–90° 2theta grid. Maximum grid error is `1e-6`. Intensities must be
|
|
@@ -270,7 +251,7 @@ softmax probability.
|
|
|
270
251
|
|
|
271
252
|
### Peak detection and single-phase XMatcher
|
|
272
253
|
|
|
273
|
-
`
|
|
254
|
+
`xmatcher-detect-peaks` accepts `schema_version`, `pattern`, `params`,
|
|
274
255
|
and optional `expected_xmatcher_database_sha256`. XMatcher accepts
|
|
275
256
|
`observed_pattern` or `model_input_pattern` artifacts.
|
|
276
257
|
|
|
@@ -293,7 +274,7 @@ peak_match_score values and include calibration_adjusted_score. Interpret ranks
|
|
|
293
274
|
using `ranking` and `effective_settings`. Learned mode explicitly reports
|
|
294
275
|
`score_is_probability=false`; do not average these scores with XQueryer probabilities.
|
|
295
276
|
|
|
296
|
-
### Multiphase XMatcher: `
|
|
277
|
+
### Multiphase XMatcher: `xmatcher-multiphase-match`
|
|
297
278
|
|
|
298
279
|
```text
|
|
299
280
|
delta-cli science invoke --tool xrd --endpoint xmatcher-multiphase-match `
|
|
@@ -337,7 +318,7 @@ effective settings.
|
|
|
337
318
|
| `multiphase_missing_peak_weight` / `multiphase_phase_penalty` | 0.5 / 3.0 | ≥0 |
|
|
338
319
|
| `multiphase_minimum_phase_contribution_percent` | 8.0 | [0,100) |
|
|
339
320
|
|
|
340
|
-
### XDecomposer: `
|
|
321
|
+
### XDecomposer: `xdecomposer-predictions`
|
|
341
322
|
|
|
342
323
|
```text
|
|
343
324
|
delta-cli science invoke --tool xrd --endpoint xdecomposer-predictions `
|
|
@@ -354,7 +335,7 @@ map them to unique indices in 1–3 when constructing refinement requests.
|
|
|
354
335
|
|
|
355
336
|
### XMatcher simulation and XLSX export
|
|
356
337
|
|
|
357
|
-
`
|
|
338
|
+
Operations: `xmatcher-cif-xrd` and `xmatcher-pdf-peaks-xlsx`; they share a request model.
|
|
358
339
|
|
|
359
340
|
```text
|
|
360
341
|
delta-cli science invoke --tool xrd --endpoint xmatcher-cif-xrd `
|
|
@@ -365,14 +346,16 @@ delta-cli science invoke --tool xrd --endpoint xmatcher-cif-xrd `
|
|
|
365
346
|
nonnegative weight defaulting to 1. `two_theta_range` must be finite and
|
|
366
347
|
increasing. `min_intensity` defaults to 0 and must be nonnegative; fwhm and step
|
|
367
348
|
must be positive. `wavelength` is a string, separate from the numeric `lambda`
|
|
368
|
-
field in
|
|
349
|
+
field in `simulation-cif-peaks` below. `expected_xmatcher_database_sha256` is optional.
|
|
369
350
|
|
|
370
|
-
|
|
371
|
-
|
|
351
|
+
For peak-table export, use the same `--data` shape with
|
|
352
|
+
`--endpoint xmatcher-pdf-peaks-xlsx`. The response contains XLSX bytes with media
|
|
353
|
+
type `application/vnd.openxmlformats-officedocument.spreadsheetml.sheet`; decode
|
|
354
|
+
the CLI binary response as described in section 5.
|
|
372
355
|
|
|
373
356
|
### MP500, RRUFF, and OPXRD CIF export
|
|
374
357
|
|
|
375
|
-
`
|
|
358
|
+
Operation: `mp500-cif-exports`. It requires both the candidate entry_id and its identity:
|
|
376
359
|
|
|
377
360
|
```text
|
|
378
361
|
delta-cli science invoke --tool xrd --endpoint mp500-cif-exports `
|
|
@@ -391,7 +374,7 @@ MP500 or RRUFF mismatch errors; do not substitute guessed identifiers.
|
|
|
391
374
|
|
|
392
375
|
### CIF block parsing and reflection simulation
|
|
393
376
|
|
|
394
|
-
|
|
377
|
+
Operation: `simulation-cif-parse`. Pass this request through `--data`:
|
|
395
378
|
|
|
396
379
|
```json
|
|
397
380
|
{"schema_version":1,"cif":{"artifact_id":"art_<cif>","sha256":"<sha256>"}}
|
|
@@ -404,10 +387,10 @@ delta-cli science invoke --tool xrd --endpoint simulation-cif-parse `
|
|
|
404
387
|
|
|
405
388
|
The response contains `blocks[]`. Successful blocks include block_index,
|
|
406
389
|
block_name, formula, cell, volume, site_count, spacegroup, and warnings. Failed
|
|
407
|
-
blocks include block_index and error. Inspect individual blocks even when
|
|
408
|
-
|
|
390
|
+
blocks include block_index and error. Inspect individual blocks even when the
|
|
391
|
+
CLI invocation succeeds.
|
|
409
392
|
|
|
410
|
-
|
|
393
|
+
Operation: `simulation-cif-peaks`. Pass this request through `--data`:
|
|
411
394
|
|
|
412
395
|
```json
|
|
413
396
|
{"schema_version":1,"cif":{"artifact_id":"art_<cif>","sha256":"<sha256>"},"block":0,"lambda":1.5406,"min_angle":5.0,"max_angle":90.0}
|
|
@@ -427,7 +410,7 @@ Neither simulation endpoint depends on XMatcher search assets.
|
|
|
427
410
|
|
|
428
411
|
## 8. PDF Reporter peak assignments
|
|
429
412
|
|
|
430
|
-
|
|
413
|
+
Operation: `pdfreporter-analyses`. Pass this request through `--data`:
|
|
431
414
|
|
|
432
415
|
```json
|
|
433
416
|
{
|
|
@@ -462,9 +445,8 @@ The response includes per-phase theory tables in `phases`, flattened theory in
|
|
|
462
445
|
rasterization dependencies are unavailable.
|
|
463
446
|
Peak statuses are `unmatched`, `unique`, `ambiguous`, and `manual`.
|
|
464
447
|
|
|
465
|
-
|
|
466
|
-
`
|
|
467
|
-
and add this field:
|
|
448
|
+
Operation: `pdfreporter-assignments`. Resubmit the complete analysis input through
|
|
449
|
+
`--data` and add this field:
|
|
468
450
|
|
|
469
451
|
```json
|
|
470
452
|
{"selections":{"38.45|0":"0:0","30.05|0":"none"}}
|
|
@@ -500,7 +482,11 @@ processing settings, not additional request fields.
|
|
|
500
482
|
|
|
501
483
|
### Basic job submission
|
|
502
484
|
|
|
503
|
-
`
|
|
485
|
+
Operations: `refinement-fullprof`, `refinement-gsasii`, or `refinement-wpem`.
|
|
486
|
+
Pass `Idempotency-Key` through `--headers`, with 8–200 characters. The example
|
|
487
|
+
submits GSAS-II; select the corresponding operation and explicit `backends`
|
|
488
|
+
value for FullProf or PyXplore. Submission and cancellation require the user's
|
|
489
|
+
authorisation for that action.
|
|
504
490
|
|
|
505
491
|
```text
|
|
506
492
|
delta-cli science invoke --tool xrd --endpoint refinement-gsasii `
|
|
@@ -568,24 +554,20 @@ in `summary.wpem_evidence`.
|
|
|
568
554
|
preserve_source=true. This mode prohibits corrected_pattern,
|
|
569
555
|
provenance_manifest, and basic-mode cycles/refine switches.
|
|
570
556
|
|
|
571
|
-
|
|
557
|
+
Submit with `--endpoint refinement-gsasii`, business JSON in `--data`, and the
|
|
558
|
+
idempotency key in `--headers`:
|
|
572
559
|
|
|
573
|
-
```
|
|
574
|
-
|
|
575
|
-
"schema_version":1,
|
|
576
|
-
"
|
|
577
|
-
"refinement_pattern":{"observed_pattern":{"artifact_id":"art_<original>","sha256":"<sha256>"}},
|
|
578
|
-
"phases":[{"phase_index":1,"name":"phase","cif":{"artifact_id":"art_<cif>","sha256":"<sha256>"}}],
|
|
579
|
-
"wavelengths_angstrom":[1.540593,1.544414],
|
|
580
|
-
"backends":["gsasii"],
|
|
581
|
-
"options":{"timeout_seconds":900,"gsasii":{"workflow_mode":"gsas-report-initial-v1"}}
|
|
582
|
-
}
|
|
560
|
+
```text
|
|
561
|
+
delta-cli science invoke --tool xrd --endpoint refinement-gsasii `
|
|
562
|
+
--data '{"schema_version":1,"radiation_profile":"CuKa","refinement_pattern":{"observed_pattern":{"artifact_id":"art_<original>","sha256":"<sha256>"}},"phases":[{"phase_index":1,"name":"phase","cif":{"artifact_id":"art_<cif>","sha256":"<sha256>"}}],"wavelengths_angstrom":[1.540593,1.544414],"backends":["gsasii"],"options":{"timeout_seconds":900,"gsasii":{"workflow_mode":"gsas-report-initial-v1"}}}' `
|
|
563
|
+
--headers '{"Idempotency-Key":"<stable-unique-key>"}'
|
|
583
564
|
```
|
|
584
565
|
|
|
585
566
|
Optional `recipe` controls single-phase baseline/candidates, multiphase baseline,
|
|
586
567
|
physical bounds, selection rules, and residual peak definitions. Omission uses
|
|
587
|
-
the backend default recipe.
|
|
588
|
-
|
|
568
|
+
the backend default recipe. Only supply a custom recipe when the current
|
|
569
|
+
service schema defines its fields; do not guess nested recipe fields.
|
|
570
|
+
The official scoring implementation is pinned by version
|
|
589
571
|
and module SHA-256; callers cannot replace it.
|
|
590
572
|
|
|
591
573
|
Report mode accepts a finite nonnegative `ka2_ka1_intensity_ratio` for doublets.
|
|
@@ -608,12 +590,13 @@ establish calibration.
|
|
|
608
590
|
|
|
609
591
|
### Acceptance, queries, and cancellation
|
|
610
592
|
|
|
611
|
-
Successful submission returns
|
|
612
|
-
status=queued
|
|
613
|
-
|
|
593
|
+
Successful submission returns business `schema_version`, `job_id`,
|
|
594
|
+
`status=queued`, `submitted_at`, and `links.self/events/artifacts` in CLI `data`.
|
|
595
|
+
This means accepted/queued, not convergence or scientific acceptance. Use the
|
|
596
|
+
returned `job_id` with CLI query operations; do not follow the link URLs directly.
|
|
614
597
|
|
|
615
598
|
The same idempotency key and canonical request reuse the original job.
|
|
616
|
-
The same key with a different request returns
|
|
599
|
+
The same key with a different request returns IDEMPOTENCY_CONFLICT.
|
|
617
600
|
Use a new key for an intentional new calculation. After a timeout or disconnect,
|
|
618
601
|
retain the original key and investigate whether a job exists before resubmitting.
|
|
619
602
|
|
|
@@ -635,7 +618,8 @@ delta-cli science invoke --tool xrd --endpoint refinement-job-cancel `
|
|
|
635
618
|
Job IDs contain `refjob_` followed by 32 lowercase hexadecimal characters.
|
|
636
619
|
Event after_seq defaults to 0 and must be nonnegative; limit defaults to 100
|
|
637
620
|
and accepts 1–500. Pass response next_after_seq for the next page.
|
|
638
|
-
Artifact lists are deduplicated by artifact_id; download through
|
|
621
|
+
Artifact lists are deduplicated by artifact_id; download through
|
|
622
|
+
`xmatcher-artifact-content` with `--path-params '{"artifact_id":"art_<returned-id>"}'`.
|
|
639
623
|
|
|
640
624
|
Cancellation returns the job's current state. Continue querying until a terminal
|
|
641
625
|
state is reached. Cancelling completed or failed jobs returns JOB_STATE_CONFLICT.
|
|
@@ -653,14 +637,14 @@ validity, or scientific acceptance. Preserve null or unknown values for unavaila
|
|
|
653
637
|
|
|
654
638
|
## 10. Responses and errors
|
|
655
639
|
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
640
|
+
A successful Delta CLI invocation requires exit code 0 and top-level `ok:true`;
|
|
641
|
+
business results are in `data`. XRD business JSON generally has no additional
|
|
642
|
+
common `ok`/`data` envelope. Read the fields documented for the selected operation;
|
|
643
|
+
health probes have their own business `ok`. Decode binary responses using the
|
|
644
|
+
CLI representation and returned media type described in section 5.
|
|
659
645
|
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
Compute error response:
|
|
646
|
+
The CLI reports failures in its top-level `error`. Native business-error details,
|
|
647
|
+
when exposed by the CLI, may have this shape:
|
|
664
648
|
|
|
665
649
|
```json
|
|
666
650
|
{
|
|
@@ -670,7 +654,9 @@ Compute error response:
|
|
|
670
654
|
}
|
|
671
655
|
```
|
|
672
656
|
|
|
673
|
-
Gateway-generated errors
|
|
657
|
+
Gateway-generated business errors may omit schema_version. Preserve the CLI's
|
|
658
|
+
error classification and any returned native details; do not infer success from
|
|
659
|
+
a nested field or bypass the CLI to retrieve an upstream response.
|
|
674
660
|
|
|
675
661
|
| Common error | Meaning / action |
|
|
676
662
|
| --- | --- |
|
|
@@ -683,22 +669,20 @@ Gateway-generated errors include error and request_id but may omit schema_versio
|
|
|
683
669
|
| REFINEMENT_LINEAGE_INVALID / INSTRUMENT_INVALID | Invalid provenance, source preservation, or instrument data |
|
|
684
670
|
| IDEMPOTENCY_CONFLICT / JOB_NOT_FOUND / JOB_STATE_CONFLICT | Conflicting key, missing job, or operation incompatible with job state |
|
|
685
671
|
| REDIS_UNAVAILABLE / XMATCHER_TIMEOUT | Queue unavailable or matching wait timeout |
|
|
686
|
-
| UPSTREAM_UNAVAILABLE / NOT_FOUND |
|
|
672
|
+
| UPSTREAM_UNAVAILABLE / NOT_FOUND | Upstream unavailable or operation not exposed; report the original CLI error |
|
|
687
673
|
|
|
688
|
-
|
|
674
|
+
Rate-limit failures may include Retry-After. Proxy errors such as Endpoint is
|
|
689
675
|
disabled and TIER_CONCURRENCY_EXCEEDED are separate from native compute errors.
|
|
690
676
|
Preserve returned code, message, details, warnings, and request_id. Do not switch
|
|
691
677
|
endpoints, guess parameters, or replace failed business results with local algorithms.
|
|
692
678
|
|
|
693
|
-
## 11.
|
|
694
|
-
|
|
695
|
-
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
-
|
|
702
|
-
|
|
703
|
-
- [GSAS-II reference](xrd-cloud-compute-handoff/docs/GSASII_REFINEMENT_API_20261012.md)
|
|
704
|
-
- [PyXplore reference](xrd-cloud-compute-handoff/docs/PYXPLORE_API_20261010.md)
|
|
679
|
+
## 11. Contract discovery
|
|
680
|
+
|
|
681
|
+
Use `delta-cli science endpoints list xrd` when this reference is missing an
|
|
682
|
+
operation or conflicts with the deployed catalogue. Use only exact returned
|
|
683
|
+
names. If the catalogue does not provide enough schema to construct a request,
|
|
684
|
+
report the missing contract rather than guessing parameters or service paths.
|
|
685
|
+
|
|
686
|
+
See [Delta Science](../SKILL.md) for shared CLI authentication, response,
|
|
687
|
+
retry, and cross-tool rules. The direct `gsasii` tool is a separate contract;
|
|
688
|
+
its operation names must not be substituted for `xrd` refinement operations.
|