dkg 1.1.1__py3-none-any.whl → 8.0.0__py3-none-any.whl

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 (45) hide show
  1. dkg/asset.py +589 -683
  2. dkg/constants.py +106 -45
  3. dkg/data/interfaces/AskStorage.json +366 -0
  4. dkg/data/interfaces/Chronos.json +202 -0
  5. dkg/data/interfaces/Hub.json +294 -2
  6. dkg/data/interfaces/IdentityStorage.json +400 -0
  7. dkg/data/interfaces/KnowledgeCollection.json +610 -0
  8. dkg/data/interfaces/KnowledgeCollectionStorage.json +2312 -0
  9. dkg/data/interfaces/Paranet.json +656 -135
  10. dkg/data/interfaces/ParanetIncentivesPoolFactory.json +18 -2
  11. dkg/data/interfaces/ParanetKnowledgeMinersRegistry.json +20 -4
  12. dkg/data/interfaces/{ParanetNeurowebIncentivesPool.json → ParanetNeuroIncentivesPool.json} +7 -7
  13. dkg/data/interfaces/ParanetsRegistry.json +844 -36
  14. dkg/data/interfaces/Token.json +146 -17
  15. dkg/dataclasses.py +11 -1
  16. dkg/exceptions.py +1 -0
  17. dkg/graph.py +55 -24
  18. dkg/main.py +18 -2
  19. dkg/network.py +2 -2
  20. dkg/node.py +7 -0
  21. dkg/paranet.py +336 -33
  22. dkg/providers/blockchain.py +23 -24
  23. dkg/providers/node_http.py +11 -9
  24. dkg/services/input_service.py +183 -0
  25. dkg/services/node_service.py +164 -0
  26. dkg/types/__init__.py +15 -3
  27. dkg/types/general.py +15 -8
  28. dkg/utils/blockchain_request.py +189 -64
  29. dkg/utils/knowledge_asset_tools.py +5 -0
  30. dkg/utils/knowledge_collection_tools.py +236 -0
  31. dkg/utils/merkle.py +1 -1
  32. dkg/utils/node_request.py +33 -33
  33. dkg/utils/rdf.py +10 -6
  34. dkg/utils/string_transformations.py +1 -0
  35. {dkg-1.1.1.dist-info → dkg-8.0.0.dist-info}/METADATA +36 -26
  36. dkg-8.0.0.dist-info/RECORD +56 -0
  37. {dkg-1.1.1.dist-info → dkg-8.0.0.dist-info}/WHEEL +1 -1
  38. dkg/data/interfaces/AssertionStorage.json +0 -229
  39. dkg/data/interfaces/ContentAsset.json +0 -801
  40. dkg/data/interfaces/ContentAssetStorage.json +0 -782
  41. dkg/data/interfaces/ServiceAgreementStorageProxy.json +0 -1314
  42. dkg/data/interfaces/UnfinalizedStateStorage.json +0 -171
  43. dkg-1.1.1.dist-info/RECORD +0 -52
  44. {dkg-1.1.1.dist-info → dkg-8.0.0.dist-info}/LICENSE +0 -0
  45. {dkg-1.1.1.dist-info → dkg-8.0.0.dist-info}/NOTICE +0 -0
@@ -1,782 +0,0 @@
1
- [
2
- {
3
- "inputs": [
4
- {
5
- "internalType": "address",
6
- "name": "hubAddress",
7
- "type": "address"
8
- }
9
- ],
10
- "stateMutability": "nonpayable",
11
- "type": "constructor"
12
- },
13
- {
14
- "inputs": [],
15
- "name": "NoMintedAssets",
16
- "type": "error"
17
- },
18
- {
19
- "anonymous": false,
20
- "inputs": [
21
- {
22
- "indexed": true,
23
- "internalType": "address",
24
- "name": "owner",
25
- "type": "address"
26
- },
27
- {
28
- "indexed": true,
29
- "internalType": "address",
30
- "name": "approved",
31
- "type": "address"
32
- },
33
- {
34
- "indexed": true,
35
- "internalType": "uint256",
36
- "name": "tokenId",
37
- "type": "uint256"
38
- }
39
- ],
40
- "name": "Approval",
41
- "type": "event"
42
- },
43
- {
44
- "anonymous": false,
45
- "inputs": [
46
- {
47
- "indexed": true,
48
- "internalType": "address",
49
- "name": "owner",
50
- "type": "address"
51
- },
52
- {
53
- "indexed": true,
54
- "internalType": "address",
55
- "name": "operator",
56
- "type": "address"
57
- },
58
- {
59
- "indexed": false,
60
- "internalType": "bool",
61
- "name": "approved",
62
- "type": "bool"
63
- }
64
- ],
65
- "name": "ApprovalForAll",
66
- "type": "event"
67
- },
68
- {
69
- "anonymous": false,
70
- "inputs": [
71
- {
72
- "indexed": false,
73
- "internalType": "uint256",
74
- "name": "_fromTokenId",
75
- "type": "uint256"
76
- },
77
- {
78
- "indexed": false,
79
- "internalType": "uint256",
80
- "name": "_toTokenId",
81
- "type": "uint256"
82
- }
83
- ],
84
- "name": "BatchMetadataUpdate",
85
- "type": "event"
86
- },
87
- {
88
- "anonymous": false,
89
- "inputs": [
90
- {
91
- "indexed": false,
92
- "internalType": "uint256",
93
- "name": "_tokenId",
94
- "type": "uint256"
95
- }
96
- ],
97
- "name": "MetadataUpdate",
98
- "type": "event"
99
- },
100
- {
101
- "anonymous": false,
102
- "inputs": [
103
- {
104
- "indexed": true,
105
- "internalType": "address",
106
- "name": "from",
107
- "type": "address"
108
- },
109
- {
110
- "indexed": true,
111
- "internalType": "address",
112
- "name": "to",
113
- "type": "address"
114
- },
115
- {
116
- "indexed": true,
117
- "internalType": "uint256",
118
- "name": "tokenId",
119
- "type": "uint256"
120
- }
121
- ],
122
- "name": "Transfer",
123
- "type": "event"
124
- },
125
- {
126
- "inputs": [
127
- {
128
- "internalType": "address",
129
- "name": "to",
130
- "type": "address"
131
- },
132
- {
133
- "internalType": "uint256",
134
- "name": "tokenId",
135
- "type": "uint256"
136
- }
137
- ],
138
- "name": "approve",
139
- "outputs": [],
140
- "stateMutability": "nonpayable",
141
- "type": "function"
142
- },
143
- {
144
- "inputs": [
145
- {
146
- "internalType": "bytes32",
147
- "name": "assetAssertionId",
148
- "type": "bytes32"
149
- }
150
- ],
151
- "name": "assertionExists",
152
- "outputs": [
153
- {
154
- "internalType": "bool",
155
- "name": "",
156
- "type": "bool"
157
- }
158
- ],
159
- "stateMutability": "view",
160
- "type": "function"
161
- },
162
- {
163
- "inputs": [
164
- {
165
- "internalType": "address",
166
- "name": "owner",
167
- "type": "address"
168
- }
169
- ],
170
- "name": "balanceOf",
171
- "outputs": [
172
- {
173
- "internalType": "uint256",
174
- "name": "",
175
- "type": "uint256"
176
- }
177
- ],
178
- "stateMutability": "view",
179
- "type": "function"
180
- },
181
- {
182
- "inputs": [
183
- {
184
- "internalType": "uint256",
185
- "name": "tokenId",
186
- "type": "uint256"
187
- }
188
- ],
189
- "name": "burn",
190
- "outputs": [],
191
- "stateMutability": "nonpayable",
192
- "type": "function"
193
- },
194
- {
195
- "inputs": [
196
- {
197
- "internalType": "uint256",
198
- "name": "tokenId",
199
- "type": "uint256"
200
- },
201
- {
202
- "internalType": "bytes32",
203
- "name": "assertionId",
204
- "type": "bytes32"
205
- },
206
- {
207
- "internalType": "uint256",
208
- "name": "index",
209
- "type": "uint256"
210
- }
211
- ],
212
- "name": "deleteAssertionIssuer",
213
- "outputs": [],
214
- "stateMutability": "nonpayable",
215
- "type": "function"
216
- },
217
- {
218
- "inputs": [
219
- {
220
- "internalType": "uint256",
221
- "name": "tokenId",
222
- "type": "uint256"
223
- }
224
- ],
225
- "name": "deleteAsset",
226
- "outputs": [],
227
- "stateMutability": "nonpayable",
228
- "type": "function"
229
- },
230
- {
231
- "inputs": [],
232
- "name": "generateTokenId",
233
- "outputs": [
234
- {
235
- "internalType": "uint256",
236
- "name": "",
237
- "type": "uint256"
238
- }
239
- ],
240
- "stateMutability": "nonpayable",
241
- "type": "function"
242
- },
243
- {
244
- "inputs": [
245
- {
246
- "internalType": "uint256",
247
- "name": "tokenId",
248
- "type": "uint256"
249
- }
250
- ],
251
- "name": "getApproved",
252
- "outputs": [
253
- {
254
- "internalType": "address",
255
- "name": "",
256
- "type": "address"
257
- }
258
- ],
259
- "stateMutability": "view",
260
- "type": "function"
261
- },
262
- {
263
- "inputs": [
264
- {
265
- "internalType": "uint256",
266
- "name": "tokenId",
267
- "type": "uint256"
268
- },
269
- {
270
- "internalType": "uint256",
271
- "name": "index",
272
- "type": "uint256"
273
- }
274
- ],
275
- "name": "getAssertionIdByIndex",
276
- "outputs": [
277
- {
278
- "internalType": "bytes32",
279
- "name": "",
280
- "type": "bytes32"
281
- }
282
- ],
283
- "stateMutability": "view",
284
- "type": "function"
285
- },
286
- {
287
- "inputs": [
288
- {
289
- "internalType": "uint256",
290
- "name": "tokenId",
291
- "type": "uint256"
292
- }
293
- ],
294
- "name": "getAssertionIds",
295
- "outputs": [
296
- {
297
- "internalType": "bytes32[]",
298
- "name": "",
299
- "type": "bytes32[]"
300
- }
301
- ],
302
- "stateMutability": "view",
303
- "type": "function"
304
- },
305
- {
306
- "inputs": [
307
- {
308
- "internalType": "uint256",
309
- "name": "tokenId",
310
- "type": "uint256"
311
- }
312
- ],
313
- "name": "getAssertionIdsLength",
314
- "outputs": [
315
- {
316
- "internalType": "uint256",
317
- "name": "",
318
- "type": "uint256"
319
- }
320
- ],
321
- "stateMutability": "view",
322
- "type": "function"
323
- },
324
- {
325
- "inputs": [
326
- {
327
- "internalType": "uint256",
328
- "name": "tokenId",
329
- "type": "uint256"
330
- },
331
- {
332
- "internalType": "bytes32",
333
- "name": "assertionId",
334
- "type": "bytes32"
335
- },
336
- {
337
- "internalType": "uint256",
338
- "name": "assertionIndex",
339
- "type": "uint256"
340
- }
341
- ],
342
- "name": "getAssertionIssuer",
343
- "outputs": [
344
- {
345
- "internalType": "address",
346
- "name": "",
347
- "type": "address"
348
- }
349
- ],
350
- "stateMutability": "view",
351
- "type": "function"
352
- },
353
- {
354
- "inputs": [
355
- {
356
- "internalType": "uint256",
357
- "name": "tokenId",
358
- "type": "uint256"
359
- }
360
- ],
361
- "name": "getAsset",
362
- "outputs": [
363
- {
364
- "components": [
365
- {
366
- "internalType": "bool",
367
- "name": "immutable_",
368
- "type": "bool"
369
- },
370
- {
371
- "internalType": "bytes32[]",
372
- "name": "assertionIds",
373
- "type": "bytes32[]"
374
- }
375
- ],
376
- "internalType": "struct ContentAssetStructs.Asset",
377
- "name": "",
378
- "type": "tuple"
379
- }
380
- ],
381
- "stateMutability": "view",
382
- "type": "function"
383
- },
384
- {
385
- "inputs": [
386
- {
387
- "internalType": "uint256",
388
- "name": "tokenId",
389
- "type": "uint256"
390
- }
391
- ],
392
- "name": "getLatestAssertionId",
393
- "outputs": [
394
- {
395
- "internalType": "bytes32",
396
- "name": "",
397
- "type": "bytes32"
398
- }
399
- ],
400
- "stateMutability": "view",
401
- "type": "function"
402
- },
403
- {
404
- "inputs": [],
405
- "name": "hub",
406
- "outputs": [
407
- {
408
- "internalType": "contract Hub",
409
- "name": "",
410
- "type": "address"
411
- }
412
- ],
413
- "stateMutability": "view",
414
- "type": "function"
415
- },
416
- {
417
- "inputs": [
418
- {
419
- "internalType": "address",
420
- "name": "owner",
421
- "type": "address"
422
- },
423
- {
424
- "internalType": "address",
425
- "name": "operator",
426
- "type": "address"
427
- }
428
- ],
429
- "name": "isApprovedForAll",
430
- "outputs": [
431
- {
432
- "internalType": "bool",
433
- "name": "",
434
- "type": "bool"
435
- }
436
- ],
437
- "stateMutability": "view",
438
- "type": "function"
439
- },
440
- {
441
- "inputs": [
442
- {
443
- "internalType": "uint256",
444
- "name": "tokenId",
445
- "type": "uint256"
446
- }
447
- ],
448
- "name": "isMutable",
449
- "outputs": [
450
- {
451
- "internalType": "bool",
452
- "name": "",
453
- "type": "bool"
454
- }
455
- ],
456
- "stateMutability": "view",
457
- "type": "function"
458
- },
459
- {
460
- "inputs": [
461
- {
462
- "internalType": "bytes32",
463
- "name": "",
464
- "type": "bytes32"
465
- }
466
- ],
467
- "name": "issuers",
468
- "outputs": [
469
- {
470
- "internalType": "address",
471
- "name": "",
472
- "type": "address"
473
- }
474
- ],
475
- "stateMutability": "view",
476
- "type": "function"
477
- },
478
- {
479
- "inputs": [],
480
- "name": "lastTokenId",
481
- "outputs": [
482
- {
483
- "internalType": "uint256",
484
- "name": "",
485
- "type": "uint256"
486
- }
487
- ],
488
- "stateMutability": "view",
489
- "type": "function"
490
- },
491
- {
492
- "inputs": [
493
- {
494
- "internalType": "address",
495
- "name": "to",
496
- "type": "address"
497
- },
498
- {
499
- "internalType": "uint256",
500
- "name": "tokenId",
501
- "type": "uint256"
502
- }
503
- ],
504
- "name": "mint",
505
- "outputs": [],
506
- "stateMutability": "nonpayable",
507
- "type": "function"
508
- },
509
- {
510
- "inputs": [],
511
- "name": "name",
512
- "outputs": [
513
- {
514
- "internalType": "string",
515
- "name": "",
516
- "type": "string"
517
- }
518
- ],
519
- "stateMutability": "view",
520
- "type": "function"
521
- },
522
- {
523
- "inputs": [
524
- {
525
- "internalType": "uint256",
526
- "name": "tokenId",
527
- "type": "uint256"
528
- }
529
- ],
530
- "name": "ownerOf",
531
- "outputs": [
532
- {
533
- "internalType": "address",
534
- "name": "",
535
- "type": "address"
536
- }
537
- ],
538
- "stateMutability": "view",
539
- "type": "function"
540
- },
541
- {
542
- "inputs": [
543
- {
544
- "internalType": "uint256",
545
- "name": "tokenId",
546
- "type": "uint256"
547
- },
548
- {
549
- "internalType": "bytes32",
550
- "name": "assertionId",
551
- "type": "bytes32"
552
- }
553
- ],
554
- "name": "pushAssertionId",
555
- "outputs": [],
556
- "stateMutability": "nonpayable",
557
- "type": "function"
558
- },
559
- {
560
- "inputs": [
561
- {
562
- "internalType": "address",
563
- "name": "from",
564
- "type": "address"
565
- },
566
- {
567
- "internalType": "address",
568
- "name": "to",
569
- "type": "address"
570
- },
571
- {
572
- "internalType": "uint256",
573
- "name": "tokenId",
574
- "type": "uint256"
575
- }
576
- ],
577
- "name": "safeTransferFrom",
578
- "outputs": [],
579
- "stateMutability": "nonpayable",
580
- "type": "function"
581
- },
582
- {
583
- "inputs": [
584
- {
585
- "internalType": "address",
586
- "name": "from",
587
- "type": "address"
588
- },
589
- {
590
- "internalType": "address",
591
- "name": "to",
592
- "type": "address"
593
- },
594
- {
595
- "internalType": "uint256",
596
- "name": "tokenId",
597
- "type": "uint256"
598
- },
599
- {
600
- "internalType": "bytes",
601
- "name": "data",
602
- "type": "bytes"
603
- }
604
- ],
605
- "name": "safeTransferFrom",
606
- "outputs": [],
607
- "stateMutability": "nonpayable",
608
- "type": "function"
609
- },
610
- {
611
- "inputs": [
612
- {
613
- "internalType": "address",
614
- "name": "operator",
615
- "type": "address"
616
- },
617
- {
618
- "internalType": "bool",
619
- "name": "approved",
620
- "type": "bool"
621
- }
622
- ],
623
- "name": "setApprovalForAll",
624
- "outputs": [],
625
- "stateMutability": "nonpayable",
626
- "type": "function"
627
- },
628
- {
629
- "inputs": [
630
- {
631
- "internalType": "uint256",
632
- "name": "tokenId",
633
- "type": "uint256"
634
- },
635
- {
636
- "internalType": "bytes32",
637
- "name": "assertionId",
638
- "type": "bytes32"
639
- },
640
- {
641
- "internalType": "address",
642
- "name": "issuer",
643
- "type": "address"
644
- }
645
- ],
646
- "name": "setAssertionIssuer",
647
- "outputs": [],
648
- "stateMutability": "nonpayable",
649
- "type": "function"
650
- },
651
- {
652
- "inputs": [
653
- {
654
- "internalType": "string",
655
- "name": "baseURI",
656
- "type": "string"
657
- }
658
- ],
659
- "name": "setBaseURI",
660
- "outputs": [],
661
- "stateMutability": "nonpayable",
662
- "type": "function"
663
- },
664
- {
665
- "inputs": [
666
- {
667
- "internalType": "uint256",
668
- "name": "tokenId",
669
- "type": "uint256"
670
- },
671
- {
672
- "internalType": "bool",
673
- "name": "immutable_",
674
- "type": "bool"
675
- }
676
- ],
677
- "name": "setMutability",
678
- "outputs": [],
679
- "stateMutability": "nonpayable",
680
- "type": "function"
681
- },
682
- {
683
- "inputs": [
684
- {
685
- "internalType": "bytes4",
686
- "name": "interfaceId",
687
- "type": "bytes4"
688
- }
689
- ],
690
- "name": "supportsInterface",
691
- "outputs": [
692
- {
693
- "internalType": "bool",
694
- "name": "",
695
- "type": "bool"
696
- }
697
- ],
698
- "stateMutability": "view",
699
- "type": "function"
700
- },
701
- {
702
- "inputs": [],
703
- "name": "symbol",
704
- "outputs": [
705
- {
706
- "internalType": "string",
707
- "name": "",
708
- "type": "string"
709
- }
710
- ],
711
- "stateMutability": "view",
712
- "type": "function"
713
- },
714
- {
715
- "inputs": [],
716
- "name": "tokenBaseURI",
717
- "outputs": [
718
- {
719
- "internalType": "string",
720
- "name": "",
721
- "type": "string"
722
- }
723
- ],
724
- "stateMutability": "view",
725
- "type": "function"
726
- },
727
- {
728
- "inputs": [
729
- {
730
- "internalType": "uint256",
731
- "name": "tokenId",
732
- "type": "uint256"
733
- }
734
- ],
735
- "name": "tokenURI",
736
- "outputs": [
737
- {
738
- "internalType": "string",
739
- "name": "",
740
- "type": "string"
741
- }
742
- ],
743
- "stateMutability": "view",
744
- "type": "function"
745
- },
746
- {
747
- "inputs": [
748
- {
749
- "internalType": "address",
750
- "name": "from",
751
- "type": "address"
752
- },
753
- {
754
- "internalType": "address",
755
- "name": "to",
756
- "type": "address"
757
- },
758
- {
759
- "internalType": "uint256",
760
- "name": "tokenId",
761
- "type": "uint256"
762
- }
763
- ],
764
- "name": "transferFrom",
765
- "outputs": [],
766
- "stateMutability": "nonpayable",
767
- "type": "function"
768
- },
769
- {
770
- "inputs": [],
771
- "name": "version",
772
- "outputs": [
773
- {
774
- "internalType": "string",
775
- "name": "",
776
- "type": "string"
777
- }
778
- ],
779
- "stateMutability": "pure",
780
- "type": "function"
781
- }
782
- ]