pontus-x_cli 1.1.4 → 1.2.5

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 (38) hide show
  1. package/README.md +71 -41
  2. package/dist/commands/compute.d.ts +3 -2
  3. package/dist/commands/compute.js +125 -71
  4. package/dist/commands/compute.js.map +1 -1
  5. package/dist/commands/edit-trusted-algos.d.ts +5 -4
  6. package/dist/commands/edit-trusted-algos.js +132 -21
  7. package/dist/commands/edit-trusted-algos.js.map +1 -1
  8. package/dist/commands/edit-trusted-publishers.d.ts +13 -0
  9. package/dist/commands/edit-trusted-publishers.js +132 -0
  10. package/dist/commands/edit-trusted-publishers.js.map +1 -0
  11. package/dist/commands/publish.js +28 -28
  12. package/dist/commands/publish.js.map +1 -1
  13. package/dist/commands/render.js +5 -1
  14. package/dist/commands/render.js.map +1 -1
  15. package/dist/commands/revoke.js +1 -1
  16. package/dist/commands/revoke.js.map +1 -1
  17. package/dist/lib/aquarius.d.ts +25 -3
  18. package/dist/lib/aquarius.js +161 -20
  19. package/dist/lib/aquarius.js.map +1 -1
  20. package/dist/lib/manifest.d.ts +1 -0
  21. package/dist/lib/manifest.js +4 -0
  22. package/dist/lib/manifest.js.map +1 -1
  23. package/dist/lib/spec.js +1 -1
  24. package/dist/lib/spec.js.map +1 -1
  25. package/dist/lib/wallet.d.ts +2 -1
  26. package/dist/lib/wallet.js +7 -2
  27. package/dist/lib/wallet.js.map +1 -1
  28. package/dist/utils/account.d.ts +2 -0
  29. package/dist/utils/account.js +41 -0
  30. package/dist/utils/account.js.map +1 -0
  31. package/dist/utils/asset.d.ts +25 -0
  32. package/dist/utils/asset.js +108 -0
  33. package/dist/utils/asset.js.map +1 -0
  34. package/dist/utils/login.d.ts +14 -0
  35. package/dist/utils/login.js +99 -0
  36. package/dist/utils/login.js.map +1 -0
  37. package/oclif.manifest.json +137 -33
  38. package/package.json +3 -1
package/README.md CHANGED
@@ -22,7 +22,7 @@ $ npm install -g pontus-x_cli
22
22
  $ pontus-x_cli COMMAND
23
23
  running command...
24
24
  $ pontus-x_cli (--version)
25
- pontus-x_cli/1.1.4 linux-x64 node-v25.6.1
25
+ pontus-x_cli/1.2.5 linux-x64 node-v25.6.1
26
26
  $ pontus-x_cli --help [COMMAND]
27
27
  USAGE
28
28
  $ pontus-x_cli COMMAND
@@ -64,13 +64,14 @@ accounts:
64
64
  * [`pontus-x_cli autocomplete [SHELL]`](#pontus-x_cli-autocomplete-shell)
65
65
  * [`pontus-x_cli change-price DID NEWPRICE`](#pontus-x_cli-change-price-did-newprice)
66
66
  * [`pontus-x_cli check-participant-compliance`](#pontus-x_cli-check-participant-compliance)
67
- * [`pontus-x_cli compute ALGO`](#pontus-x_cli-compute-algo)
67
+ * [`pontus-x_cli compute [ALGORITHM]`](#pontus-x_cli-compute-algorithm)
68
68
  * [`pontus-x_cli compute-results JOBID`](#pontus-x_cli-compute-results-jobid)
69
69
  * [`pontus-x_cli compute-status JOBID`](#pontus-x_cli-compute-status-jobid)
70
70
  * [`pontus-x_cli edit-additional-metadata DID METADATAFILE`](#pontus-x_cli-edit-additional-metadata-did-metadatafile)
71
71
  * [`pontus-x_cli edit-algo DID IMAGE TAG CHECKSUM ENTRYPOINT`](#pontus-x_cli-edit-algo-did-image-tag-checksum-entrypoint)
72
72
  * [`pontus-x_cli edit-asset-url DID URL`](#pontus-x_cli-edit-asset-url-did-url)
73
- * [`pontus-x_cli edit-trusted-algos DID`](#pontus-x_cli-edit-trusted-algos-did)
73
+ * [`pontus-x_cli edit-trusted-algos`](#pontus-x_cli-edit-trusted-algos)
74
+ * [`pontus-x_cli edit-trusted-publishers`](#pontus-x_cli-edit-trusted-publishers)
74
75
  * [`pontus-x_cli export-private-key`](#pontus-x_cli-export-private-key)
75
76
  * [`pontus-x_cli generate-asset-credentials DID`](#pontus-x_cli-generate-asset-credentials-did)
76
77
  * [`pontus-x_cli generate-did-web`](#pontus-x_cli-generate-did-web)
@@ -102,7 +103,7 @@ EXAMPLES
102
103
  $ pontus-x_cli access did:op:af3e93c4f18903f91b108e7204b8a752e7605f4547ed507212bd6aca63af5686
103
104
  ```
104
105
 
105
- _See code: [src/commands/access.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/access.ts)_
106
+ _See code: [src/commands/access.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/access.ts)_
106
107
 
107
108
  ## `pontus-x_cli autocomplete [SHELL]`
108
109
 
@@ -157,7 +158,7 @@ EXAMPLES
157
158
  $ pontus-x_cli change-price did:op:ffeee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7a 10
158
159
  ```
159
160
 
160
- _See code: [src/commands/change-price.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/change-price.ts)_
161
+ _See code: [src/commands/change-price.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/change-price.ts)_
161
162
 
162
163
  ## `pontus-x_cli check-participant-compliance`
163
164
 
@@ -178,34 +179,36 @@ EXAMPLES
178
179
  $ pontus-x_cli check-participant-compliance -p ./CEP.data.json --vp ./CEP.vp.json
179
180
  ```
180
181
 
181
- _See code: [src/commands/check-participant-compliance.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/check-participant-compliance.ts)_
182
+ _See code: [src/commands/check-participant-compliance.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/check-participant-compliance.ts)_
182
183
 
183
- ## `pontus-x_cli compute ALGO`
184
+ ## `pontus-x_cli compute [ALGORITHM]`
184
185
 
185
186
  Compute the algorithm on one or more datasets.
186
187
 
187
188
  ```
188
189
  USAGE
189
- $ pontus-x_cli compute ALGO [-d <value>...] [-t <value>...] [-y]
190
+ $ pontus-x_cli compute [ALGORITHM] [-d <value>...] [-y] [-m <value>] [-n PONTUSXDEV|PONTUSXTEST]
190
191
 
191
192
  ARGUMENTS
192
- ALGO Algorithm DID
193
+ [ALGORITHM] Algorithm DID (did:op:...)
193
194
 
194
195
  FLAGS
195
- -d, --datasets=<value>... Dataset DIDs
196
- -t, --tags=<value>... Tags to filter datasets (they must have all the provided tags)
196
+ -d, --datasets=<value>... Dataset DIDs (did:op:...)
197
+ -m, --manifest=<value> Path to manifest file with the accounts to use for authentication
198
+ -n, --network=<option> Network to use (env: NETWORK)
199
+ <options: PONTUSXDEV|PONTUSXTEST>
197
200
  -y, --yes Automatic yes to prompts
198
201
 
199
202
  DESCRIPTION
200
203
  Compute the algorithm on one or more datasets.
201
204
 
202
205
  EXAMPLES
203
- $ pontus-x_cli compute did:op:34e2f... -d did:op:d8a36... -d did:op:12b45...
206
+ $ pontus-x_cli compute <algorithmDid> -d <datasetDid1> <datasetDid2> ...
204
207
 
205
- $ pontus-x_cli compute did:op:34e2f... -t tag1 -t tag2
208
+ $ pontus-x_cli compute <algorithmDid> -t <tag1> -t <tag2> ...
206
209
  ```
207
210
 
208
- _See code: [src/commands/compute.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/compute.ts)_
211
+ _See code: [src/commands/compute.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/compute.ts)_
209
212
 
210
213
  ## `pontus-x_cli compute-results JOBID`
211
214
 
@@ -228,7 +231,7 @@ EXAMPLES
228
231
  $ pontus-x_cli compute-results 215bae450c8f40f59bfc5d1ccada3931 -p https://provider.agrospai.udl.cat
229
232
  ```
230
233
 
231
- _See code: [src/commands/compute-results.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/compute-results.ts)_
234
+ _See code: [src/commands/compute-results.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/compute-results.ts)_
232
235
 
233
236
  ## `pontus-x_cli compute-status JOBID`
234
237
 
@@ -251,7 +254,7 @@ EXAMPLES
251
254
  $ pontus-x_cli compute-status 215bae450c8f40f59bfc5d1ccada3931 -p https://provider.agrospai.udl.cat
252
255
  ```
253
256
 
254
- _See code: [src/commands/compute-status.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/compute-status.ts)_
257
+ _See code: [src/commands/compute-status.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/compute-status.ts)_
255
258
 
256
259
  ## `pontus-x_cli edit-additional-metadata DID METADATAFILE`
257
260
 
@@ -275,7 +278,7 @@ EXAMPLES
275
278
  $ pontus-x_cli edit-additional-metadata did:op:dcdb747f8feff3122c6d6c0f45a339a6e09415e721f98f61cc2c1d62ab35a21f ./metadata.json
276
279
  ```
277
280
 
278
- _See code: [src/commands/edit-additional-metadata.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/edit-additional-metadata.ts)_
281
+ _See code: [src/commands/edit-additional-metadata.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/edit-additional-metadata.ts)_
279
282
 
280
283
  ## `pontus-x_cli edit-algo DID IMAGE TAG CHECKSUM ENTRYPOINT`
281
284
 
@@ -302,7 +305,7 @@ EXAMPLES
302
305
  $ pontus-x_cli edit-algo did:op:dcdb747f8feff3122c6d6c0f45a339a6e09415e721f98f61cc2c1d62ab35a21f rogargon/pandas-profiling 4.16 sha256:81dca5439f07dff4d56097546a9fce7335be3de8e2622dc105c64e54376f86b5 "python /algorithm/src/main.py"
303
306
  ```
304
307
 
305
- _See code: [src/commands/edit-algo.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/edit-algo.ts)_
308
+ _See code: [src/commands/edit-algo.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/edit-algo.ts)_
306
309
 
307
310
  ## `pontus-x_cli edit-asset-url DID URL`
308
311
 
@@ -326,31 +329,58 @@ EXAMPLES
326
329
  $ pontus-x_cli edit-asset-url did:op:af3e93c4f18903f91b108e7204b8a752e7605f4547ed507212bd6aca63af5686 https://raw.githubusercontent.com/plotly/datasets/refs/heads/master/titanic.csv
327
330
  ```
328
331
 
329
- _See code: [src/commands/edit-asset-url.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/edit-asset-url.ts)_
332
+ _See code: [src/commands/edit-asset-url.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/edit-asset-url.ts)_
330
333
 
331
- ## `pontus-x_cli edit-trusted-algos DID`
334
+ ## `pontus-x_cli edit-trusted-algos`
332
335
 
333
- Overwrite the trusted algorithms for a data asset to the provided algorithm DIDs
336
+ Overwrite datasets trusted algorithms
334
337
 
335
338
  ```
336
339
  USAGE
337
- $ pontus-x_cli edit-trusted-algos DID --algos <value>... [-y]
340
+ $ pontus-x_cli edit-trusted-algos [-d <value>...] [-a <value>...] [-y] [-m <value>] [-p] [-n PONTUSXDEV|PONTUSXTEST]
338
341
 
339
- ARGUMENTS
340
- DID DID of the asset
342
+ FLAGS
343
+ -a, --algorithms=<value>... Trusted algorithm DIDs (did:op:...)
344
+ -d, --datasets=<value>... Dataset DIDs (did:op:...)
345
+ -m, --manifest=<value> Path to manifest file with the accounts to use for authentication
346
+ -n, --network=<option> Network to use (env: NETWORK)
347
+ <options: PONTUSXDEV|PONTUSXTEST>
348
+ -p, --public Make dataset public (set all algorithms as trusted)
349
+ -y, --yes Skip confirmation prompt
350
+
351
+ DESCRIPTION
352
+ Overwrite datasets trusted algorithms
353
+
354
+ EXAMPLES
355
+ $ pontus-x_cli edit-trusted-algos -d <datasetDid1> <datasetDid2> ... -a <algorithmDid1> <algorithmDid2> ...
356
+ ```
357
+
358
+ _See code: [src/commands/edit-trusted-algos.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/edit-trusted-algos.ts)_
359
+
360
+ ## `pontus-x_cli edit-trusted-publishers`
361
+
362
+ Overwrite datasets trusted publishers
363
+
364
+ ```
365
+ USAGE
366
+ $ pontus-x_cli edit-trusted-publishers [-d <value>...] [-p <value>...] [-y] [-m <value>] [-n PONTUSXDEV|PONTUSXTEST]
341
367
 
342
368
  FLAGS
343
- -y, --yes Skip confirmation prompt
344
- --algos=<value>... (required) Algorithm DIDs
369
+ -d, --datasets=<value>... Dataset DIDs (did:op:...)
370
+ -m, --manifest=<value> Path to manifest file with the accounts to use for authentication
371
+ -n, --network=<option> Network to use (env: NETWORK)
372
+ <options: PONTUSXDEV|PONTUSXTEST>
373
+ -p, --publishers=<value>... Trusted publisher DIDs (did:op:...)
374
+ -y, --yes Skip confirmation prompt
345
375
 
346
376
  DESCRIPTION
347
- Overwrite the trusted algorithms for a data asset to the provided algorithm DIDs
377
+ Overwrite datasets trusted publishers
348
378
 
349
379
  EXAMPLES
350
- $ pontus-x_cli edit-trusted-algos did:op:ffeee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7a --algos did:op:8f9994d01975cadd0196a2f7f811ed850e5d02a7223e7c5a31faaebe7371c81a did:op:0b970c95211cb8ef4574383386376646081bb7eb949b2a75e1e2171ea25949a7
380
+ $ pontus-x_cli edit-trusted-publishers -d <datasetDid1> <datasetDid2> ... -p <publisherDid1> <publisherDid2> ...
351
381
  ```
352
382
 
353
- _See code: [src/commands/edit-trusted-algos.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/edit-trusted-algos.ts)_
383
+ _See code: [src/commands/edit-trusted-publishers.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/edit-trusted-publishers.ts)_
354
384
 
355
385
  ## `pontus-x_cli export-private-key`
356
386
 
@@ -372,7 +402,7 @@ EXAMPLES
372
402
  $ pontus-x_cli export-private-key
373
403
  ```
374
404
 
375
- _See code: [src/commands/export-private-key.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/export-private-key.ts)_
405
+ _See code: [src/commands/export-private-key.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/export-private-key.ts)_
376
406
 
377
407
  ## `pontus-x_cli generate-asset-credentials DID`
378
408
 
@@ -398,7 +428,7 @@ EXAMPLES
398
428
  $ pontus-x_cli generate-asset-credentials -p ./CEP.data.json -d ./did.json -c certificate.key did:op:01f8bc1e797a854dc718bd7a802acb07c5fc39f706b03dd454bceb66be6828c6
399
429
  ```
400
430
 
401
- _See code: [src/commands/generate-asset-credentials.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/generate-asset-credentials.ts)_
431
+ _See code: [src/commands/generate-asset-credentials.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/generate-asset-credentials.ts)_
402
432
 
403
433
  ## `pontus-x_cli generate-did-web`
404
434
 
@@ -419,7 +449,7 @@ EXAMPLES
419
449
  $ pontus-x_cli generate-did-web -d <https://compliance.agrospai.udl.cat> -c certificate-chain.crt
420
450
  ```
421
451
 
422
- _See code: [src/commands/generate-did-web.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/generate-did-web.ts)_
452
+ _See code: [src/commands/generate-did-web.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/generate-did-web.ts)_
423
453
 
424
454
  ## `pontus-x_cli generate-participant-credentials`
425
455
 
@@ -442,7 +472,7 @@ EXAMPLES
442
472
  $ pontus-x_cli generate-participant-credentials -p ./CEP.data.json -d ./did.json -c certificate.key
443
473
  ```
444
474
 
445
- _See code: [src/commands/generate-participant-credentials.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/generate-participant-credentials.ts)_
475
+ _See code: [src/commands/generate-participant-credentials.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/generate-participant-credentials.ts)_
446
476
 
447
477
  ## `pontus-x_cli get DID`
448
478
 
@@ -462,7 +492,7 @@ EXAMPLES
462
492
  $ pontus-x_cli get did:op:ffeee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7a
463
493
  ```
464
494
 
465
- _See code: [src/commands/get.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/get.ts)_
495
+ _See code: [src/commands/get.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/get.ts)_
466
496
 
467
497
  ## `pontus-x_cli help [COMMAND]`
468
498
 
@@ -505,7 +535,7 @@ EXAMPLES
505
535
  $ pontus-x_cli login d999baae98ac5246568fd726be8832c49626867d.json
506
536
  ```
507
537
 
508
- _See code: [src/commands/login.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/login.ts)_
538
+ _See code: [src/commands/login.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/login.ts)_
509
539
 
510
540
  ## `pontus-x_cli logout`
511
541
 
@@ -522,7 +552,7 @@ EXAMPLES
522
552
  $ pontus-x_cli logout
523
553
  ```
524
554
 
525
- _See code: [src/commands/logout.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/logout.ts)_
555
+ _See code: [src/commands/logout.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/logout.ts)_
526
556
 
527
557
  ## `pontus-x_cli publish PATH`
528
558
 
@@ -554,7 +584,7 @@ EXAMPLES
554
584
  $ pontus-x_cli publish samples/publish/algo/index.ts
555
585
  ```
556
586
 
557
- _See code: [src/commands/publish.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/publish.ts)_
587
+ _See code: [src/commands/publish.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/publish.ts)_
558
588
 
559
589
  ## `pontus-x_cli render [DID]`
560
590
 
@@ -571,7 +601,7 @@ FLAGS
571
601
  -t, --tags=<value>... Tags to filter datasets (they must have all the provided tags)
572
602
  ```
573
603
 
574
- _See code: [src/commands/render.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/render.ts)_
604
+ _See code: [src/commands/render.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/render.ts)_
575
605
 
576
606
  ## `pontus-x_cli revoke`
577
607
 
@@ -592,10 +622,10 @@ DESCRIPTION
592
622
  Publisher revocation of one or more owned DIDs
593
623
 
594
624
  EXAMPLES
595
- $ pontus-x_cli revoke did:op:ffeee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7a did:op:abcee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7b
625
+ $ pontus-x_cli revoke -d did:op:ffeee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7a did:op:abcee8c8f19328985ef6743b08e61ef89d5141027fd47612e32e7900cacd2b7b
596
626
  ```
597
627
 
598
- _See code: [src/commands/revoke.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/revoke.ts)_
628
+ _See code: [src/commands/revoke.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/revoke.ts)_
599
629
 
600
630
  ## `pontus-x_cli self-description DID SDURL`
601
631
 
@@ -619,7 +649,7 @@ EXAMPLES
619
649
  $ pontus-x_cli self-description did:op:d22954f2cbf6a85c897ce605c275cc786e099592cc59e3b7dd66b93e784bed8c https://example.com/self-description.json
620
650
  ```
621
651
 
622
- _See code: [src/commands/self-description.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.1.4/src/commands/self-description.ts)_
652
+ _See code: [src/commands/self-description.ts](https://github.com/AgrospAI/pontus-x_cli/blob/v1.2.5/src/commands/self-description.ts)_
623
653
  <!-- commandsstop -->
624
654
 
625
655
  # Useful information
@@ -2,14 +2,15 @@ import type { ComputeJob } from "@oceanprotocol/lib";
2
2
  import { Command } from "@oclif/core";
3
3
  export default class Compute extends Command {
4
4
  static args: {
5
- algo: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
5
+ algorithm: import("@oclif/core/lib/interfaces").Arg<string | undefined, Record<string, unknown>>;
6
6
  };
7
7
  static description: string;
8
8
  static examples: Command.Example[];
9
9
  static flags: {
10
10
  datasets: import("@oclif/core/lib/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
11
- tags: import("@oclif/core/lib/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
12
11
  yes: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
12
+ manifest: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
13
+ network: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
13
14
  };
14
15
  run(): Promise<ComputeJob | ComputeJob[] | undefined>;
15
16
  }
@@ -3,110 +3,164 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
+ const promises_1 = require("node:timers/promises");
7
+ const prompts_1 = require("@inquirer/prompts");
6
8
  const core_1 = require("@oclif/core");
7
9
  const chalk_1 = __importDefault(require("chalk"));
8
10
  const readline_sync_1 = __importDefault(require("readline-sync"));
11
+ const config_1 = require("../config");
9
12
  const aquarius_1 = require("../lib/aquarius");
13
+ const asset_1 = require("../utils/asset");
10
14
  const connection_1 = require("../utils/connection");
15
+ const login_1 = require("../utils/login");
11
16
  class Compute extends core_1.Command {
12
17
  async run() {
13
- var _a;
14
18
  const { args, flags } = await this.parse(Compute);
15
- const { algo } = args;
16
- const { datasets, tags, yes } = flags;
17
- if (!datasets && !tags) {
18
- this.error("You must provide at least one dataset DID or tag to filter datasets.");
19
+ // Network selection
20
+ const network = flags.network || (0, login_1.getEnvNetwork)() || (await (0, login_1.askForNetwork)());
21
+ const chainId = config_1.NETWORK_CONFIGS[network].chainId;
22
+ console.log(`${chalk_1.default.green("Using network:")} ${network}\n`);
23
+ // Authentication selection
24
+ const loginInfos = await (0, login_1.getLoginInfos)(flags.manifest);
25
+ const inputLoginInfo = loginInfos.length === 1 ? loginInfos[0] : null;
26
+ if (inputLoginInfo) {
27
+ console.log(`${chalk_1.default.green("Using account:")} ${chalk_1.default.blue(inputLoginInfo.ownerAddress)} ${chalk_1.default.magenta(inputLoginInfo.ownerName)}\n`);
19
28
  }
20
- const connection = await connection_1.Connection.connect();
21
- const chainIds = [connection.networkConfig.chainId];
22
- const { metadataCacheUri } = connection.networkConfig;
23
- const algorithmName = await (0, aquarius_1.GetAssetName)(algo, chainIds, metadataCacheUri);
24
- let datasetsByTags = [];
25
- if (tags) {
26
- datasetsByTags = await (0, aquarius_1.GetDatasetsByTags)(tags, chainIds, metadataCacheUri);
27
- if (datasetsByTags.length === 0) {
28
- this.error(`No datasets found with tags ${chalk_1.default.italic(tags.join(", "))}`);
29
- }
30
- console.log(`\nFound ${datasetsByTags.length} datasets with tags ${chalk_1.default.italic(tags.join(", "))}`);
31
- for (const dataset of datasetsByTags) {
32
- console.log(`- ${dataset.did} ${chalk_1.default.blue(dataset.name)}`);
33
- }
34
- console.log();
29
+ const loginInfo = inputLoginInfo !== null && inputLoginInfo !== void 0 ? inputLoginInfo : (await askForAccountSelection(loginInfos));
30
+ // Algorithm selection
31
+ const inputAlgorithm = args.algorithm
32
+ ? await (0, aquarius_1.getAssetInfo)(args.algorithm)
33
+ : null;
34
+ if (inputAlgorithm) {
35
+ console.log(`Algorithm to run: ${chalk_1.default.blue(inputAlgorithm.name)} (${chalk_1.default.gray(inputAlgorithm.did)})\n`);
35
36
  }
36
- if (datasets) {
37
- console.log(`\nUsing ${datasets.length} provided datasets:`);
38
- const results = await Promise.all(datasets.map(async (datasetDid) => {
39
- const datasetName = await (0, aquarius_1.GetAssetName)(datasetDid, chainIds, metadataCacheUri);
40
- return { datasetDid, datasetName };
41
- }));
42
- for (const { datasetDid, datasetName } of results) {
43
- console.log(`- ${datasetDid} ${chalk_1.default.blue(datasetName)}`);
37
+ const algorithm = inputAlgorithm !== null && inputAlgorithm !== void 0 ? inputAlgorithm : (await askForAlgorithm(chainId));
38
+ // Datasets selection
39
+ const inputDatasets = flags.datasets
40
+ ? await (0, aquarius_1.getAssetsFromDids)(flags.datasets)
41
+ : null;
42
+ if (inputDatasets) {
43
+ console.log("\nThe following assets will be used:");
44
+ for (const asset of inputDatasets) {
45
+ const ownerName = await (0, aquarius_1.getOwnerName)(asset.owner);
46
+ console.log(`${chalk_1.default.blue(asset.did)} | ${chalk_1.default.green(asset.created.split("T")[0])} | ${chalk_1.default.yellow(ownerName)} | ${chalk_1.default.magenta(asset.name)}`);
44
47
  }
45
- console.log();
46
48
  }
47
- const joinedDatasets = [
48
- ...(datasets !== null && datasets !== void 0 ? datasets : []),
49
- ...((_a = datasetsByTags === null || datasetsByTags === void 0 ? void 0 : datasetsByTags.map((d) => d.did)) !== null && _a !== void 0 ? _a : []),
50
- ];
51
- if (yes ||
52
- readline_sync_1.default.keyInYNStrict(`Proceed to compute algorithm ${chalk_1.default.blue(algorithmName)} (${algo}) on ${joinedDatasets.length} datasets? `)) {
53
- try {
54
- const firstDatasetAsset = await connection.nautilus.getAquariusAsset(joinedDatasets[0]);
55
- const provider = firstDatasetAsset.services[0].serviceEndpoint;
56
- const dataset = {
57
- did: joinedDatasets[0],
58
- };
59
- const algorithm = { did: algo };
60
- const additionalDatasets = joinedDatasets
49
+ const datasets = inputDatasets !== null && inputDatasets !== void 0 ? inputDatasets : (await askForDatasets(chainId));
50
+ // Confirmation prompt
51
+ if (!flags.yes &&
52
+ !readline_sync_1.default.keyInYNStrict("\nDo you want to proceed with running the algorithm on the selected datasets?")) {
53
+ console.log("Operation cancelled by the user.");
54
+ return;
55
+ }
56
+ // Run compute
57
+ const envOverrides = {
58
+ NETWORK: network,
59
+ PRIVATE_KEY: loginInfo.privateKey,
60
+ };
61
+ const connection = await connection_1.Connection.connect(envOverrides);
62
+ try {
63
+ const computeJob = await connection.nautilus.compute({
64
+ algorithm: { did: algorithm.did },
65
+ dataset: { did: datasets[0].did },
66
+ additionalDatasets: datasets
61
67
  .filter((_, i) => i > 0)
62
- .map((dataset) => ({ did: dataset }));
63
- const computeJob = await connection.nautilus.compute({
64
- additionalDatasets,
65
- algorithm,
66
- dataset,
67
- });
68
- if (Array.isArray(computeJob)) {
69
- for (const job of computeJob)
70
- this.log(`Compute started, check status using command:\n pontus-x_cli compute-status ${job.jobId} -p ${provider}\n`);
71
- }
72
- else {
73
- this.log(`Compute started, check status using command:\n pontus-x_cli compute-status ${computeJob.jobId} -p ${provider}\n`);
74
- }
75
- return computeJob;
68
+ .map((dataset) => ({ did: dataset.did })),
69
+ });
70
+ const firstDatasetAsset = await connection.nautilus.getAquariusAsset(datasets[0].did);
71
+ const provider = firstDatasetAsset.services[0].serviceEndpoint;
72
+ if (Array.isArray(computeJob)) {
73
+ for (const job of computeJob)
74
+ this.log(`Compute started, check status using command:\n pontus-x_cli compute-status ${job.jobId} -p ${provider}\n`);
76
75
  }
77
- catch (error) {
78
- this.error(`Error starting compute: ${error}`);
76
+ else {
77
+ this.log(`Compute started, check status using command:\n pontus-x_cli compute-status ${computeJob.jobId} -p ${provider}\n`);
79
78
  }
79
+ return computeJob;
80
+ }
81
+ catch (error) {
82
+ this.error(`Error starting compute: ${error}`);
80
83
  }
81
84
  }
82
85
  }
83
86
  Compute.args = {
84
- algo: core_1.Args.string({ description: "Algorithm DID", required: true }),
87
+ algorithm: core_1.Args.string({ description: "Algorithm DID (did:op:...)" }),
85
88
  };
86
89
  Compute.description = "Compute the algorithm on one or more datasets.";
87
90
  Compute.examples = [
88
- "<%= config.bin %> <%= command.id %> did:op:34e2f... -d did:op:d8a36... -d did:op:12b45...",
89
- "<%= config.bin %> <%= command.id %> did:op:34e2f... -t tag1 -t tag2",
91
+ "<%= config.bin %> <%= command.id %> <algorithmDid> -d <datasetDid1> <datasetDid2> ...",
92
+ "<%= config.bin %> <%= command.id %> <algorithmDid> -t <tag1> -t <tag2> ...",
90
93
  ];
91
94
  Compute.flags = {
92
95
  datasets: core_1.Flags.string({
93
96
  char: "d",
94
- description: "Dataset DIDs",
95
- multiple: true,
96
- required: false,
97
- }),
98
- tags: core_1.Flags.string({
99
- char: "t",
100
- description: "Tags to filter datasets (they must have all the provided tags)",
97
+ description: "Dataset DIDs (did:op:...)",
101
98
  multiple: true,
102
- required: false,
103
99
  }),
104
100
  yes: core_1.Flags.boolean({
105
101
  char: "y",
106
102
  default: false,
107
103
  description: "Automatic yes to prompts",
108
- required: false,
104
+ }),
105
+ manifest: core_1.Flags.string({
106
+ char: "m",
107
+ description: "Path to manifest file with the accounts to use for authentication",
108
+ }),
109
+ network: core_1.Flags.string({
110
+ char: "n",
111
+ description: "Network to use (env: NETWORK)",
112
+ options: Object.keys(config_1.NETWORK_CONFIGS),
109
113
  }),
110
114
  };
111
115
  exports.default = Compute;
116
+ async function askForDatasets(chainId) {
117
+ console.log("\nSelect the filters to find the datasets you want to use:");
118
+ return (0, asset_1.PromptForAssets)({
119
+ assetTypes: ["dataset"],
120
+ accessTypes: ["compute"],
121
+ chainIds: [chainId],
122
+ });
123
+ }
124
+ async function askForAlgorithm(chainId) {
125
+ console.log("\nSelect an algorithm to run:");
126
+ const answer = await (0, prompts_1.search)({
127
+ message: "Search for an algorithm by name:",
128
+ pageSize: 10,
129
+ source: async (input, { signal }) => {
130
+ if (!input) {
131
+ return [];
132
+ }
133
+ await (0, promises_1.setTimeout)(300);
134
+ if (signal.aborted)
135
+ return [];
136
+ const assets = await (0, aquarius_1.searchAssets)({
137
+ assetTypes: ["algorithm"],
138
+ accessTypes: ["compute"],
139
+ chainIds: [chainId],
140
+ searchText: input,
141
+ signal,
142
+ });
143
+ const choices = [];
144
+ for (const asset of assets) {
145
+ const ownerName = await (0, aquarius_1.getOwnerName)(asset.owner);
146
+ choices.push({
147
+ name: `${asset.did}: ${asset.name} (${ownerName})`,
148
+ value: asset,
149
+ });
150
+ }
151
+ return choices;
152
+ },
153
+ });
154
+ return answer;
155
+ }
156
+ async function askForAccountSelection(loginInfos) {
157
+ const answer = await (0, prompts_1.select)({
158
+ message: "Select the account to use:",
159
+ choices: loginInfos.map((info) => ({
160
+ name: `${info.ownerAddress} (${info.ownerName})`,
161
+ value: info,
162
+ })),
163
+ });
164
+ return answer;
165
+ }
112
166
  //# sourceMappingURL=compute.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"compute.js","sourceRoot":"","sources":["../../src/commands/compute.ts"],"names":[],"mappings":";;;;;AACA,sCAAmD;AACnD,kDAA0B;AAC1B,kEAAyC;AACzC,6CAAiE;AACjE,mDAAgD;AAEhD,MAAqB,OAAQ,SAAQ,cAAO;IA+B1C,KAAK,CAAC,GAAG;;QACP,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAClD,MAAM,EAAE,IAAI,EAAE,GAAG,IAAI,CAAC;QACtB,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,KAAK,CAAC;QAEtC,IAAI,CAAC,QAAQ,IAAI,CAAC,IAAI,EAAE,CAAC;YACvB,IAAI,CAAC,KAAK,CACR,sEAAsE,CACvE,CAAC;QACJ,CAAC;QAED,MAAM,UAAU,GAAG,MAAM,uBAAU,CAAC,OAAO,EAAE,CAAC;QAE9C,MAAM,QAAQ,GAAG,CAAC,UAAU,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;QACpD,MAAM,EAAE,gBAAgB,EAAE,GAAG,UAAU,CAAC,aAAa,CAAC;QAEtD,MAAM,aAAa,GAAG,MAAM,IAAA,uBAAY,EAAC,IAAI,EAAE,QAAQ,EAAE,gBAAgB,CAAC,CAAC;QAE3E,IAAI,cAAc,GAAU,EAAE,CAAC;QAE/B,IAAI,IAAI,EAAE,CAAC;YACT,cAAc,GAAG,MAAM,IAAA,4BAAiB,EACtC,IAAI,EACJ,QAAQ,EACR,gBAAgB,CACjB,CAAC;YACF,IAAI,cAAc,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;gBAChC,IAAI,CAAC,KAAK,CACR,+BAA+B,eAAK,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,EAAE,CAC/D,C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clif/core";
2
2
  export default class EditTrustedAlgos extends Command {
3
- static args: {
4
- did: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
5
- };
6
3
  static description: string;
7
4
  static examples: Command.Example[];
8
5
  static flags: {
9
- algos: import("@oclif/core/lib/interfaces").OptionFlag<string[], import("@oclif/core/lib/interfaces").CustomOptions>;
6
+ datasets: import("@oclif/core/lib/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
7
+ algorithms: import("@oclif/core/lib/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
10
8
  yes: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
9
+ manifest: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
10
+ public: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
11
+ network: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
11
12
  };
12
13
  run(): Promise<void>;
13
14
  }