@alicloud/bailian20231229 1.2.0 → 1.3.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/src/client.ts CHANGED
@@ -363,9 +363,358 @@ export class CreateIndexResponse extends $tea.Model {
363
363
  }
364
364
  }
365
365
 
366
+ export class DeleteIndexRequest extends $tea.Model {
367
+ indexId?: string;
368
+ static names(): { [key: string]: string } {
369
+ return {
370
+ indexId: 'IndexId',
371
+ };
372
+ }
373
+
374
+ static types(): { [key: string]: any } {
375
+ return {
376
+ indexId: 'string',
377
+ };
378
+ }
379
+
380
+ constructor(map?: { [key: string]: any }) {
381
+ super(map);
382
+ }
383
+ }
384
+
385
+ export class DeleteIndexResponseBody extends $tea.Model {
386
+ code?: string;
387
+ message?: string;
388
+ requestId?: string;
389
+ status?: string;
390
+ success?: boolean;
391
+ static names(): { [key: string]: string } {
392
+ return {
393
+ code: 'Code',
394
+ message: 'Message',
395
+ requestId: 'RequestId',
396
+ status: 'Status',
397
+ success: 'Success',
398
+ };
399
+ }
400
+
401
+ static types(): { [key: string]: any } {
402
+ return {
403
+ code: 'string',
404
+ message: 'string',
405
+ requestId: 'string',
406
+ status: 'string',
407
+ success: 'boolean',
408
+ };
409
+ }
410
+
411
+ constructor(map?: { [key: string]: any }) {
412
+ super(map);
413
+ }
414
+ }
415
+
416
+ export class DeleteIndexResponse extends $tea.Model {
417
+ headers?: { [key: string]: string };
418
+ statusCode?: number;
419
+ body?: DeleteIndexResponseBody;
420
+ static names(): { [key: string]: string } {
421
+ return {
422
+ headers: 'headers',
423
+ statusCode: 'statusCode',
424
+ body: 'body',
425
+ };
426
+ }
427
+
428
+ static types(): { [key: string]: any } {
429
+ return {
430
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
431
+ statusCode: 'number',
432
+ body: DeleteIndexResponseBody,
433
+ };
434
+ }
435
+
436
+ constructor(map?: { [key: string]: any }) {
437
+ super(map);
438
+ }
439
+ }
440
+
441
+ export class DeleteIndexDocumentRequest extends $tea.Model {
442
+ documentIds?: string[];
443
+ indexId?: string;
444
+ static names(): { [key: string]: string } {
445
+ return {
446
+ documentIds: 'DocumentIds',
447
+ indexId: 'IndexId',
448
+ };
449
+ }
450
+
451
+ static types(): { [key: string]: any } {
452
+ return {
453
+ documentIds: { 'type': 'array', 'itemType': 'string' },
454
+ indexId: 'string',
455
+ };
456
+ }
457
+
458
+ constructor(map?: { [key: string]: any }) {
459
+ super(map);
460
+ }
461
+ }
462
+
463
+ export class DeleteIndexDocumentShrinkRequest extends $tea.Model {
464
+ documentIdsShrink?: string;
465
+ indexId?: string;
466
+ static names(): { [key: string]: string } {
467
+ return {
468
+ documentIdsShrink: 'DocumentIds',
469
+ indexId: 'IndexId',
470
+ };
471
+ }
472
+
473
+ static types(): { [key: string]: any } {
474
+ return {
475
+ documentIdsShrink: 'string',
476
+ indexId: 'string',
477
+ };
478
+ }
479
+
480
+ constructor(map?: { [key: string]: any }) {
481
+ super(map);
482
+ }
483
+ }
484
+
485
+ export class DeleteIndexDocumentResponseBody extends $tea.Model {
486
+ code?: string;
487
+ data?: DeleteIndexDocumentResponseBodyData;
488
+ message?: string;
489
+ requestId?: string;
490
+ status?: string;
491
+ success?: boolean;
492
+ static names(): { [key: string]: string } {
493
+ return {
494
+ code: 'Code',
495
+ data: 'Data',
496
+ message: 'Message',
497
+ requestId: 'RequestId',
498
+ status: 'Status',
499
+ success: 'Success',
500
+ };
501
+ }
502
+
503
+ static types(): { [key: string]: any } {
504
+ return {
505
+ code: 'string',
506
+ data: DeleteIndexDocumentResponseBodyData,
507
+ message: 'string',
508
+ requestId: 'string',
509
+ status: 'string',
510
+ success: 'boolean',
511
+ };
512
+ }
513
+
514
+ constructor(map?: { [key: string]: any }) {
515
+ super(map);
516
+ }
517
+ }
518
+
519
+ export class DeleteIndexDocumentResponse extends $tea.Model {
520
+ headers?: { [key: string]: string };
521
+ statusCode?: number;
522
+ body?: DeleteIndexDocumentResponseBody;
523
+ static names(): { [key: string]: string } {
524
+ return {
525
+ headers: 'headers',
526
+ statusCode: 'statusCode',
527
+ body: 'body',
528
+ };
529
+ }
530
+
531
+ static types(): { [key: string]: any } {
532
+ return {
533
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
534
+ statusCode: 'number',
535
+ body: DeleteIndexDocumentResponseBody,
536
+ };
537
+ }
538
+
539
+ constructor(map?: { [key: string]: any }) {
540
+ super(map);
541
+ }
542
+ }
543
+
366
544
  export class DescribeFileResponseBody extends $tea.Model {
367
545
  code?: string;
368
- data?: DescribeFileResponseBodyData;
546
+ data?: DescribeFileResponseBodyData;
547
+ message?: string;
548
+ requestId?: string;
549
+ status?: string;
550
+ success?: boolean;
551
+ static names(): { [key: string]: string } {
552
+ return {
553
+ code: 'Code',
554
+ data: 'Data',
555
+ message: 'Message',
556
+ requestId: 'RequestId',
557
+ status: 'Status',
558
+ success: 'Success',
559
+ };
560
+ }
561
+
562
+ static types(): { [key: string]: any } {
563
+ return {
564
+ code: 'string',
565
+ data: DescribeFileResponseBodyData,
566
+ message: 'string',
567
+ requestId: 'string',
568
+ status: 'string',
569
+ success: 'boolean',
570
+ };
571
+ }
572
+
573
+ constructor(map?: { [key: string]: any }) {
574
+ super(map);
575
+ }
576
+ }
577
+
578
+ export class DescribeFileResponse extends $tea.Model {
579
+ headers?: { [key: string]: string };
580
+ statusCode?: number;
581
+ body?: DescribeFileResponseBody;
582
+ static names(): { [key: string]: string } {
583
+ return {
584
+ headers: 'headers',
585
+ statusCode: 'statusCode',
586
+ body: 'body',
587
+ };
588
+ }
589
+
590
+ static types(): { [key: string]: any } {
591
+ return {
592
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
593
+ statusCode: 'number',
594
+ body: DescribeFileResponseBody,
595
+ };
596
+ }
597
+
598
+ constructor(map?: { [key: string]: any }) {
599
+ super(map);
600
+ }
601
+ }
602
+
603
+ export class GetIndexJobStatusRequest extends $tea.Model {
604
+ indexId?: string;
605
+ jobId?: string;
606
+ static names(): { [key: string]: string } {
607
+ return {
608
+ indexId: 'IndexId',
609
+ jobId: 'JobId',
610
+ };
611
+ }
612
+
613
+ static types(): { [key: string]: any } {
614
+ return {
615
+ indexId: 'string',
616
+ jobId: 'string',
617
+ };
618
+ }
619
+
620
+ constructor(map?: { [key: string]: any }) {
621
+ super(map);
622
+ }
623
+ }
624
+
625
+ export class GetIndexJobStatusResponseBody extends $tea.Model {
626
+ code?: string;
627
+ data?: GetIndexJobStatusResponseBodyData;
628
+ message?: string;
629
+ requestId?: string;
630
+ status?: string;
631
+ success?: boolean;
632
+ static names(): { [key: string]: string } {
633
+ return {
634
+ code: 'Code',
635
+ data: 'Data',
636
+ message: 'Message',
637
+ requestId: 'RequestId',
638
+ status: 'Status',
639
+ success: 'Success',
640
+ };
641
+ }
642
+
643
+ static types(): { [key: string]: any } {
644
+ return {
645
+ code: 'string',
646
+ data: GetIndexJobStatusResponseBodyData,
647
+ message: 'string',
648
+ requestId: 'string',
649
+ status: 'string',
650
+ success: 'boolean',
651
+ };
652
+ }
653
+
654
+ constructor(map?: { [key: string]: any }) {
655
+ super(map);
656
+ }
657
+ }
658
+
659
+ export class GetIndexJobStatusResponse extends $tea.Model {
660
+ headers?: { [key: string]: string };
661
+ statusCode?: number;
662
+ body?: GetIndexJobStatusResponseBody;
663
+ static names(): { [key: string]: string } {
664
+ return {
665
+ headers: 'headers',
666
+ statusCode: 'statusCode',
667
+ body: 'body',
668
+ };
669
+ }
670
+
671
+ static types(): { [key: string]: any } {
672
+ return {
673
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
674
+ statusCode: 'number',
675
+ body: GetIndexJobStatusResponseBody,
676
+ };
677
+ }
678
+
679
+ constructor(map?: { [key: string]: any }) {
680
+ super(map);
681
+ }
682
+ }
683
+
684
+ export class ListChunksRequest extends $tea.Model {
685
+ fields?: string[];
686
+ filed?: string;
687
+ indexId?: string;
688
+ pageNum?: number;
689
+ pageSize?: number;
690
+ static names(): { [key: string]: string } {
691
+ return {
692
+ fields: 'Fields',
693
+ filed: 'Filed',
694
+ indexId: 'IndexId',
695
+ pageNum: 'PageNum',
696
+ pageSize: 'PageSize',
697
+ };
698
+ }
699
+
700
+ static types(): { [key: string]: any } {
701
+ return {
702
+ fields: { 'type': 'array', 'itemType': 'string' },
703
+ filed: 'string',
704
+ indexId: 'string',
705
+ pageNum: 'number',
706
+ pageSize: 'number',
707
+ };
708
+ }
709
+
710
+ constructor(map?: { [key: string]: any }) {
711
+ super(map);
712
+ }
713
+ }
714
+
715
+ export class ListChunksResponseBody extends $tea.Model {
716
+ code?: string;
717
+ data?: ListChunksResponseBodyData;
369
718
  message?: string;
370
719
  requestId?: string;
371
720
  status?: string;
@@ -384,7 +733,7 @@ export class DescribeFileResponseBody extends $tea.Model {
384
733
  static types(): { [key: string]: any } {
385
734
  return {
386
735
  code: 'string',
387
- data: DescribeFileResponseBodyData,
736
+ data: ListChunksResponseBodyData,
388
737
  message: 'string',
389
738
  requestId: 'string',
390
739
  status: 'string',
@@ -397,10 +746,10 @@ export class DescribeFileResponseBody extends $tea.Model {
397
746
  }
398
747
  }
399
748
 
400
- export class DescribeFileResponse extends $tea.Model {
749
+ export class ListChunksResponse extends $tea.Model {
401
750
  headers?: { [key: string]: string };
402
751
  statusCode?: number;
403
- body?: DescribeFileResponseBody;
752
+ body?: ListChunksResponseBody;
404
753
  static names(): { [key: string]: string } {
405
754
  return {
406
755
  headers: 'headers',
@@ -413,7 +762,7 @@ export class DescribeFileResponse extends $tea.Model {
413
762
  return {
414
763
  headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
415
764
  statusCode: 'number',
416
- body: DescribeFileResponseBody,
765
+ body: ListChunksResponseBody,
417
766
  };
418
767
  }
419
768
 
@@ -422,20 +771,29 @@ export class DescribeFileResponse extends $tea.Model {
422
771
  }
423
772
  }
424
773
 
425
- export class GetIndexJobStatusRequest extends $tea.Model {
774
+ export class ListIndexDocumentsRequest extends $tea.Model {
775
+ documentName?: string;
776
+ documentStatus?: string;
426
777
  indexId?: string;
427
- jobId?: string;
778
+ pageNumber?: number;
779
+ pageSize?: number;
428
780
  static names(): { [key: string]: string } {
429
781
  return {
782
+ documentName: 'DocumentName',
783
+ documentStatus: 'DocumentStatus',
430
784
  indexId: 'IndexId',
431
- jobId: 'JobId',
785
+ pageNumber: 'PageNumber',
786
+ pageSize: 'PageSize',
432
787
  };
433
788
  }
434
789
 
435
790
  static types(): { [key: string]: any } {
436
791
  return {
792
+ documentName: 'string',
793
+ documentStatus: 'string',
437
794
  indexId: 'string',
438
- jobId: 'string',
795
+ pageNumber: 'number',
796
+ pageSize: 'number',
439
797
  };
440
798
  }
441
799
 
@@ -444,9 +802,9 @@ export class GetIndexJobStatusRequest extends $tea.Model {
444
802
  }
445
803
  }
446
804
 
447
- export class GetIndexJobStatusResponseBody extends $tea.Model {
805
+ export class ListIndexDocumentsResponseBody extends $tea.Model {
448
806
  code?: string;
449
- data?: GetIndexJobStatusResponseBodyData;
807
+ data?: ListIndexDocumentsResponseBodyData;
450
808
  message?: string;
451
809
  requestId?: string;
452
810
  status?: string;
@@ -465,7 +823,7 @@ export class GetIndexJobStatusResponseBody extends $tea.Model {
465
823
  static types(): { [key: string]: any } {
466
824
  return {
467
825
  code: 'string',
468
- data: GetIndexJobStatusResponseBodyData,
826
+ data: ListIndexDocumentsResponseBodyData,
469
827
  message: 'string',
470
828
  requestId: 'string',
471
829
  status: 'string',
@@ -478,10 +836,10 @@ export class GetIndexJobStatusResponseBody extends $tea.Model {
478
836
  }
479
837
  }
480
838
 
481
- export class GetIndexJobStatusResponse extends $tea.Model {
839
+ export class ListIndexDocumentsResponse extends $tea.Model {
482
840
  headers?: { [key: string]: string };
483
841
  statusCode?: number;
484
- body?: GetIndexJobStatusResponseBody;
842
+ body?: ListIndexDocumentsResponseBody;
485
843
  static names(): { [key: string]: string } {
486
844
  return {
487
845
  headers: 'headers',
@@ -494,7 +852,91 @@ export class GetIndexJobStatusResponse extends $tea.Model {
494
852
  return {
495
853
  headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
496
854
  statusCode: 'number',
497
- body: GetIndexJobStatusResponseBody,
855
+ body: ListIndexDocumentsResponseBody,
856
+ };
857
+ }
858
+
859
+ constructor(map?: { [key: string]: any }) {
860
+ super(map);
861
+ }
862
+ }
863
+
864
+ export class ListIndicesRequest extends $tea.Model {
865
+ indexName?: string;
866
+ pageNumber?: string;
867
+ pageSize?: string;
868
+ static names(): { [key: string]: string } {
869
+ return {
870
+ indexName: 'IndexName',
871
+ pageNumber: 'PageNumber',
872
+ pageSize: 'PageSize',
873
+ };
874
+ }
875
+
876
+ static types(): { [key: string]: any } {
877
+ return {
878
+ indexName: 'string',
879
+ pageNumber: 'string',
880
+ pageSize: 'string',
881
+ };
882
+ }
883
+
884
+ constructor(map?: { [key: string]: any }) {
885
+ super(map);
886
+ }
887
+ }
888
+
889
+ export class ListIndicesResponseBody extends $tea.Model {
890
+ code?: string;
891
+ data?: ListIndicesResponseBodyData;
892
+ message?: string;
893
+ requestId?: string;
894
+ status?: string;
895
+ success?: boolean;
896
+ static names(): { [key: string]: string } {
897
+ return {
898
+ code: 'Code',
899
+ data: 'Data',
900
+ message: 'Message',
901
+ requestId: 'RequestId',
902
+ status: 'Status',
903
+ success: 'Success',
904
+ };
905
+ }
906
+
907
+ static types(): { [key: string]: any } {
908
+ return {
909
+ code: 'string',
910
+ data: ListIndicesResponseBodyData,
911
+ message: 'string',
912
+ requestId: 'string',
913
+ status: 'string',
914
+ success: 'boolean',
915
+ };
916
+ }
917
+
918
+ constructor(map?: { [key: string]: any }) {
919
+ super(map);
920
+ }
921
+ }
922
+
923
+ export class ListIndicesResponse extends $tea.Model {
924
+ headers?: { [key: string]: string };
925
+ statusCode?: number;
926
+ body?: ListIndicesResponseBody;
927
+ static names(): { [key: string]: string } {
928
+ return {
929
+ headers: 'headers',
930
+ statusCode: 'statusCode',
931
+ body: 'body',
932
+ };
933
+ }
934
+
935
+ static types(): { [key: string]: any } {
936
+ return {
937
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
938
+ statusCode: 'number',
939
+ body: ListIndicesResponseBody,
498
940
  };
499
941
  }
500
942
 
@@ -975,6 +1417,25 @@ export class CreateIndexResponseBodyData extends $tea.Model {
975
1417
  }
976
1418
  }
977
1419
 
1420
+ export class DeleteIndexDocumentResponseBodyData extends $tea.Model {
1421
+ deletedDocument?: string[];
1422
+ static names(): { [key: string]: string } {
1423
+ return {
1424
+ deletedDocument: 'DeletedDocument',
1425
+ };
1426
+ }
1427
+
1428
+ static types(): { [key: string]: any } {
1429
+ return {
1430
+ deletedDocument: { 'type': 'array', 'itemType': 'string' },
1431
+ };
1432
+ }
1433
+
1434
+ constructor(map?: { [key: string]: any }) {
1435
+ super(map);
1436
+ }
1437
+ }
1438
+
978
1439
  export class DescribeFileResponseBodyData extends $tea.Model {
979
1440
  categoryId?: string;
980
1441
  createTime?: string;
@@ -1023,21 +1484,225 @@ export class GetIndexJobStatusResponseBodyDataDocuments extends $tea.Model {
1023
1484
  status?: string;
1024
1485
  static names(): { [key: string]: string } {
1025
1486
  return {
1026
- code: 'Code',
1027
- docId: 'DocId',
1028
- docName: 'DocName',
1029
- message: 'Message',
1030
- status: 'Status',
1487
+ code: 'Code',
1488
+ docId: 'DocId',
1489
+ docName: 'DocName',
1490
+ message: 'Message',
1491
+ status: 'Status',
1492
+ };
1493
+ }
1494
+
1495
+ static types(): { [key: string]: any } {
1496
+ return {
1497
+ code: 'string',
1498
+ docId: 'string',
1499
+ docName: 'string',
1500
+ message: 'string',
1501
+ status: 'string',
1502
+ };
1503
+ }
1504
+
1505
+ constructor(map?: { [key: string]: any }) {
1506
+ super(map);
1507
+ }
1508
+ }
1509
+
1510
+ export class GetIndexJobStatusResponseBodyData extends $tea.Model {
1511
+ documents?: GetIndexJobStatusResponseBodyDataDocuments[];
1512
+ jobId?: string;
1513
+ status?: string;
1514
+ static names(): { [key: string]: string } {
1515
+ return {
1516
+ documents: 'Documents',
1517
+ jobId: 'JobId',
1518
+ status: 'Status',
1519
+ };
1520
+ }
1521
+
1522
+ static types(): { [key: string]: any } {
1523
+ return {
1524
+ documents: { 'type': 'array', 'itemType': GetIndexJobStatusResponseBodyDataDocuments },
1525
+ jobId: 'string',
1526
+ status: 'string',
1527
+ };
1528
+ }
1529
+
1530
+ constructor(map?: { [key: string]: any }) {
1531
+ super(map);
1532
+ }
1533
+ }
1534
+
1535
+ export class ListChunksResponseBodyDataNodes extends $tea.Model {
1536
+ metadata?: any;
1537
+ score?: number;
1538
+ text?: string;
1539
+ static names(): { [key: string]: string } {
1540
+ return {
1541
+ metadata: 'Metadata',
1542
+ score: 'Score',
1543
+ text: 'Text',
1544
+ };
1545
+ }
1546
+
1547
+ static types(): { [key: string]: any } {
1548
+ return {
1549
+ metadata: 'any',
1550
+ score: 'number',
1551
+ text: 'string',
1552
+ };
1553
+ }
1554
+
1555
+ constructor(map?: { [key: string]: any }) {
1556
+ super(map);
1557
+ }
1558
+ }
1559
+
1560
+ export class ListChunksResponseBodyData extends $tea.Model {
1561
+ nodes?: ListChunksResponseBodyDataNodes[];
1562
+ total?: number;
1563
+ static names(): { [key: string]: string } {
1564
+ return {
1565
+ nodes: 'Nodes',
1566
+ total: 'Total',
1567
+ };
1568
+ }
1569
+
1570
+ static types(): { [key: string]: any } {
1571
+ return {
1572
+ nodes: { 'type': 'array', 'itemType': ListChunksResponseBodyDataNodes },
1573
+ total: 'number',
1574
+ };
1575
+ }
1576
+
1577
+ constructor(map?: { [key: string]: any }) {
1578
+ super(map);
1579
+ }
1580
+ }
1581
+
1582
+ export class ListIndexDocumentsResponseBodyDataDocuments extends $tea.Model {
1583
+ code?: string;
1584
+ documentType?: string;
1585
+ id?: string;
1586
+ message?: string;
1587
+ name?: string;
1588
+ size?: number;
1589
+ sourceId?: string;
1590
+ status?: string;
1591
+ static names(): { [key: string]: string } {
1592
+ return {
1593
+ code: 'Code',
1594
+ documentType: 'DocumentType',
1595
+ id: 'Id',
1596
+ message: 'Message',
1597
+ name: 'Name',
1598
+ size: 'Size',
1599
+ sourceId: 'SourceId',
1600
+ status: 'Status',
1601
+ };
1602
+ }
1603
+
1604
+ static types(): { [key: string]: any } {
1605
+ return {
1606
+ code: 'string',
1607
+ documentType: 'string',
1608
+ id: 'string',
1609
+ message: 'string',
1610
+ name: 'string',
1611
+ size: 'number',
1612
+ sourceId: 'string',
1613
+ status: 'string',
1614
+ };
1615
+ }
1616
+
1617
+ constructor(map?: { [key: string]: any }) {
1618
+ super(map);
1619
+ }
1620
+ }
1621
+
1622
+ export class ListIndexDocumentsResponseBodyData extends $tea.Model {
1623
+ documents?: ListIndexDocumentsResponseBodyDataDocuments[];
1624
+ indexId?: string;
1625
+ pageNumber?: number;
1626
+ pageSize?: number;
1627
+ totalCount?: number;
1628
+ static names(): { [key: string]: string } {
1629
+ return {
1630
+ documents: 'Documents',
1631
+ indexId: 'IndexId',
1632
+ pageNumber: 'PageNumber',
1633
+ pageSize: 'PageSize',
1634
+ totalCount: 'TotalCount',
1635
+ };
1636
+ }
1637
+
1638
+ static types(): { [key: string]: any } {
1639
+ return {
1640
+ documents: { 'type': 'array', 'itemType': ListIndexDocumentsResponseBodyDataDocuments },
1641
+ indexId: 'string',
1642
+ pageNumber: 'number',
1643
+ pageSize: 'number',
1644
+ totalCount: 'number',
1645
+ };
1646
+ }
1647
+
1648
+ constructor(map?: { [key: string]: any }) {
1649
+ super(map);
1650
+ }
1651
+ }
1652
+
1653
+ export class ListIndicesResponseBodyDataIndices extends $tea.Model {
1654
+ chunkSize?: number;
1655
+ description?: string;
1656
+ documentIds?: string[];
1657
+ embeddingModelName?: string;
1658
+ id?: string;
1659
+ name?: string;
1660
+ overlapSize?: number;
1661
+ rerankMinScore?: string;
1662
+ rerankModelName?: string;
1663
+ separator?: string;
1664
+ sinkInstanceId?: string;
1665
+ sinkRegion?: string;
1666
+ sinkType?: string;
1667
+ sourceType?: string;
1668
+ structureType?: string;
1669
+ static names(): { [key: string]: string } {
1670
+ return {
1671
+ chunkSize: 'ChunkSize',
1672
+ description: 'Description',
1673
+ documentIds: 'DocumentIds',
1674
+ embeddingModelName: 'EmbeddingModelName',
1675
+ id: 'Id',
1676
+ name: 'Name',
1677
+ overlapSize: 'OverlapSize',
1678
+ rerankMinScore: 'RerankMinScore',
1679
+ rerankModelName: 'RerankModelName',
1680
+ separator: 'Separator',
1681
+ sinkInstanceId: 'SinkInstanceId',
1682
+ sinkRegion: 'SinkRegion',
1683
+ sinkType: 'SinkType',
1684
+ sourceType: 'SourceType',
1685
+ structureType: 'StructureType',
1031
1686
  };
1032
1687
  }
1033
1688
 
1034
1689
  static types(): { [key: string]: any } {
1035
1690
  return {
1036
- code: 'string',
1037
- docId: 'string',
1038
- docName: 'string',
1039
- message: 'string',
1040
- status: 'string',
1691
+ chunkSize: 'number',
1692
+ description: 'string',
1693
+ documentIds: { 'type': 'array', 'itemType': 'string' },
1694
+ embeddingModelName: 'string',
1695
+ id: 'string',
1696
+ name: 'string',
1697
+ overlapSize: 'number',
1698
+ rerankMinScore: 'string',
1699
+ rerankModelName: 'string',
1700
+ separator: 'string',
1701
+ sinkInstanceId: 'string',
1702
+ sinkRegion: 'string',
1703
+ sinkType: 'string',
1704
+ sourceType: 'string',
1705
+ structureType: 'string',
1041
1706
  };
1042
1707
  }
1043
1708
 
@@ -1046,23 +1711,26 @@ export class GetIndexJobStatusResponseBodyDataDocuments extends $tea.Model {
1046
1711
  }
1047
1712
  }
1048
1713
 
1049
- export class GetIndexJobStatusResponseBodyData extends $tea.Model {
1050
- documents?: GetIndexJobStatusResponseBodyDataDocuments[];
1051
- jobId?: string;
1052
- status?: string;
1714
+ export class ListIndicesResponseBodyData extends $tea.Model {
1715
+ indices?: ListIndicesResponseBodyDataIndices[];
1716
+ pageNumber?: number;
1717
+ pageSize?: number;
1718
+ totalCount?: number;
1053
1719
  static names(): { [key: string]: string } {
1054
1720
  return {
1055
- documents: 'Documents',
1056
- jobId: 'JobId',
1057
- status: 'Status',
1721
+ indices: 'Indices',
1722
+ pageNumber: 'PageNumber',
1723
+ pageSize: 'PageSize',
1724
+ totalCount: 'TotalCount',
1058
1725
  };
1059
1726
  }
1060
1727
 
1061
1728
  static types(): { [key: string]: any } {
1062
1729
  return {
1063
- documents: { 'type': 'array', 'itemType': GetIndexJobStatusResponseBodyDataDocuments },
1064
- jobId: 'string',
1065
- status: 'string',
1730
+ indices: { 'type': 'array', 'itemType': ListIndicesResponseBodyDataIndices },
1731
+ pageNumber: 'number',
1732
+ pageSize: 'number',
1733
+ totalCount: 'number',
1066
1734
  };
1067
1735
  }
1068
1736
 
@@ -1442,6 +2110,106 @@ export default class Client extends OpenApi {
1442
2110
  return await this.createIndexWithOptions(WorkspaceId, request, headers, runtime);
1443
2111
  }
1444
2112
 
2113
+ /**
2114
+ * @summary 删除Index
2115
+ *
2116
+ * @param request DeleteIndexRequest
2117
+ * @param headers map
2118
+ * @param runtime runtime options for this request RuntimeOptions
2119
+ * @return DeleteIndexResponse
2120
+ */
2121
+ async deleteIndexWithOptions(WorkspaceId: string, request: DeleteIndexRequest, headers: {[key: string ]: string}, runtime: $Util.RuntimeOptions): Promise<DeleteIndexResponse> {
2122
+ Util.validateModel(request);
2123
+ let query : {[key: string ]: any} = { };
2124
+ if (!Util.isUnset(request.indexId)) {
2125
+ query["IndexId"] = request.indexId;
2126
+ }
2127
+
2128
+ let req = new $OpenApi.OpenApiRequest({
2129
+ headers: headers,
2130
+ query: OpenApiUtil.query(query),
2131
+ });
2132
+ let params = new $OpenApi.Params({
2133
+ action: "DeleteIndex",
2134
+ version: "2023-12-29",
2135
+ protocol: "HTTPS",
2136
+ pathname: `/${OpenApiUtil.getEncodeParam(WorkspaceId)}/index/delete`,
2137
+ method: "POST",
2138
+ authType: "AK",
2139
+ style: "ROA",
2140
+ reqBodyType: "json",
2141
+ bodyType: "json",
2142
+ });
2143
+ return $tea.cast<DeleteIndexResponse>(await this.callApi(params, req, runtime), new DeleteIndexResponse({}));
2144
+ }
2145
+
2146
+ /**
2147
+ * @summary 删除Index
2148
+ *
2149
+ * @param request DeleteIndexRequest
2150
+ * @return DeleteIndexResponse
2151
+ */
2152
+ async deleteIndex(WorkspaceId: string, request: DeleteIndexRequest): Promise<DeleteIndexResponse> {
2153
+ let runtime = new $Util.RuntimeOptions({ });
2154
+ let headers : {[key: string ]: string} = { };
2155
+ return await this.deleteIndexWithOptions(WorkspaceId, request, headers, runtime);
2156
+ }
2157
+
2158
+ /**
2159
+ * @summary 删除index doc
2160
+ *
2161
+ * @param tmpReq DeleteIndexDocumentRequest
2162
+ * @param headers map
2163
+ * @param runtime runtime options for this request RuntimeOptions
2164
+ * @return DeleteIndexDocumentResponse
2165
+ */
2166
+ async deleteIndexDocumentWithOptions(WorkspaceId: string, tmpReq: DeleteIndexDocumentRequest, headers: {[key: string ]: string}, runtime: $Util.RuntimeOptions): Promise<DeleteIndexDocumentResponse> {
2167
+ Util.validateModel(tmpReq);
2168
+ let request = new DeleteIndexDocumentShrinkRequest({ });
2169
+ OpenApiUtil.convert(tmpReq, request);
2170
+ if (!Util.isUnset(tmpReq.documentIds)) {
2171
+ request.documentIdsShrink = OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.documentIds, "DocumentIds", "json");
2172
+ }
2173
+
2174
+ let query : {[key: string ]: any} = { };
2175
+ if (!Util.isUnset(request.documentIdsShrink)) {
2176
+ query["DocumentIds"] = request.documentIdsShrink;
2177
+ }
2178
+
2179
+ if (!Util.isUnset(request.indexId)) {
2180
+ query["IndexId"] = request.indexId;
2181
+ }
2182
+
2183
+ let req = new $OpenApi.OpenApiRequest({
2184
+ headers: headers,
2185
+ query: OpenApiUtil.query(query),
2186
+ });
2187
+ let params = new $OpenApi.Params({
2188
+ action: "DeleteIndexDocument",
2189
+ version: "2023-12-29",
2190
+ protocol: "HTTPS",
2191
+ pathname: `/${OpenApiUtil.getEncodeParam(WorkspaceId)}/index/delete_index_document`,
2192
+ method: "POST",
2193
+ authType: "AK",
2194
+ style: "ROA",
2195
+ reqBodyType: "json",
2196
+ bodyType: "json",
2197
+ });
2198
+ return $tea.cast<DeleteIndexDocumentResponse>(await this.callApi(params, req, runtime), new DeleteIndexDocumentResponse({}));
2199
+ }
2200
+
2201
+ /**
2202
+ * @summary 删除index doc
2203
+ *
2204
+ * @param request DeleteIndexDocumentRequest
2205
+ * @return DeleteIndexDocumentResponse
2206
+ */
2207
+ async deleteIndexDocument(WorkspaceId: string, request: DeleteIndexDocumentRequest): Promise<DeleteIndexDocumentResponse> {
2208
+ let runtime = new $Util.RuntimeOptions({ });
2209
+ let headers : {[key: string ]: string} = { };
2210
+ return await this.deleteIndexDocumentWithOptions(WorkspaceId, request, headers, runtime);
2211
+ }
2212
+
1445
2213
  /**
1446
2214
  * @summary 获取文档基本信息,包括文档名称、类型、状态等。
1447
2215
  *
@@ -1527,6 +2295,181 @@ export default class Client extends OpenApi {
1527
2295
  return await this.getIndexJobStatusWithOptions(WorkspaceId, request, headers, runtime);
1528
2296
  }
1529
2297
 
2298
+ /**
2299
+ * @summary Chunk
2300
+ *
2301
+ * @param request ListChunksRequest
2302
+ * @param headers map
2303
+ * @param runtime runtime options for this request RuntimeOptions
2304
+ * @return ListChunksResponse
2305
+ */
2306
+ async listChunksWithOptions(WorkspaceId: string, request: ListChunksRequest, headers: {[key: string ]: string}, runtime: $Util.RuntimeOptions): Promise<ListChunksResponse> {
2307
+ Util.validateModel(request);
2308
+ let body : {[key: string ]: any} = { };
2309
+ if (!Util.isUnset(request.fields)) {
2310
+ body["Fields"] = request.fields;
2311
+ }
2312
+
2313
+ if (!Util.isUnset(request.filed)) {
2314
+ body["Filed"] = request.filed;
2315
+ }
2316
+
2317
+ if (!Util.isUnset(request.indexId)) {
2318
+ body["IndexId"] = request.indexId;
2319
+ }
2320
+
2321
+ if (!Util.isUnset(request.pageNum)) {
2322
+ body["PageNum"] = request.pageNum;
2323
+ }
2324
+
2325
+ if (!Util.isUnset(request.pageSize)) {
2326
+ body["PageSize"] = request.pageSize;
2327
+ }
2328
+
2329
+ let req = new $OpenApi.OpenApiRequest({
2330
+ headers: headers,
2331
+ body: OpenApiUtil.parseToMap(body),
2332
+ });
2333
+ let params = new $OpenApi.Params({
2334
+ action: "ListChunks",
2335
+ version: "2023-12-29",
2336
+ protocol: "HTTPS",
2337
+ pathname: `/${OpenApiUtil.getEncodeParam(WorkspaceId)}/index/list_chunks`,
2338
+ method: "POST",
2339
+ authType: "AK",
2340
+ style: "ROA",
2341
+ reqBodyType: "json",
2342
+ bodyType: "json",
2343
+ });
2344
+ return $tea.cast<ListChunksResponse>(await this.callApi(params, req, runtime), new ListChunksResponse({}));
2345
+ }
2346
+
2347
+ /**
2348
+ * @summary Chunk
2349
+ *
2350
+ * @param request ListChunksRequest
2351
+ * @return ListChunksResponse
2352
+ */
2353
+ async listChunks(WorkspaceId: string, request: ListChunksRequest): Promise<ListChunksResponse> {
2354
+ let runtime = new $Util.RuntimeOptions({ });
2355
+ let headers : {[key: string ]: string} = { };
2356
+ return await this.listChunksWithOptions(WorkspaceId, request, headers, runtime);
2357
+ }
2358
+
2359
+ /**
2360
+ * @summary 查询Index文件
2361
+ *
2362
+ * @param request ListIndexDocumentsRequest
2363
+ * @param headers map
2364
+ * @param runtime runtime options for this request RuntimeOptions
2365
+ * @return ListIndexDocumentsResponse
2366
+ */
2367
+ async listIndexDocumentsWithOptions(WorkspaceId: string, request: ListIndexDocumentsRequest, headers: {[key: string ]: string}, runtime: $Util.RuntimeOptions): Promise<ListIndexDocumentsResponse> {
2368
+ Util.validateModel(request);
2369
+ let query : {[key: string ]: any} = { };
2370
+ if (!Util.isUnset(request.documentName)) {
2371
+ query["DocumentName"] = request.documentName;
2372
+ }
2373
+
2374
+ if (!Util.isUnset(request.documentStatus)) {
2375
+ query["DocumentStatus"] = request.documentStatus;
2376
+ }
2377
+
2378
+ if (!Util.isUnset(request.indexId)) {
2379
+ query["IndexId"] = request.indexId;
2380
+ }
2381
+
2382
+ if (!Util.isUnset(request.pageNumber)) {
2383
+ query["PageNumber"] = request.pageNumber;
2384
+ }
2385
+
2386
+ if (!Util.isUnset(request.pageSize)) {
2387
+ query["PageSize"] = request.pageSize;
2388
+ }
2389
+
2390
+ let req = new $OpenApi.OpenApiRequest({
2391
+ headers: headers,
2392
+ query: OpenApiUtil.query(query),
2393
+ });
2394
+ let params = new $OpenApi.Params({
2395
+ action: "ListIndexDocuments",
2396
+ version: "2023-12-29",
2397
+ protocol: "HTTPS",
2398
+ pathname: `/${OpenApiUtil.getEncodeParam(WorkspaceId)}/index/list_index_documents`,
2399
+ method: "GET",
2400
+ authType: "AK",
2401
+ style: "ROA",
2402
+ reqBodyType: "json",
2403
+ bodyType: "json",
2404
+ });
2405
+ return $tea.cast<ListIndexDocumentsResponse>(await this.callApi(params, req, runtime), new ListIndexDocumentsResponse({}));
2406
+ }
2407
+
2408
+ /**
2409
+ * @summary 查询Index文件
2410
+ *
2411
+ * @param request ListIndexDocumentsRequest
2412
+ * @return ListIndexDocumentsResponse
2413
+ */
2414
+ async listIndexDocuments(WorkspaceId: string, request: ListIndexDocumentsRequest): Promise<ListIndexDocumentsResponse> {
2415
+ let runtime = new $Util.RuntimeOptions({ });
2416
+ let headers : {[key: string ]: string} = { };
2417
+ return await this.listIndexDocumentsWithOptions(WorkspaceId, request, headers, runtime);
2418
+ }
2419
+
2420
+ /**
2421
+ * @summary 查询pipeline
2422
+ *
2423
+ * @param request ListIndicesRequest
2424
+ * @param headers map
2425
+ * @param runtime runtime options for this request RuntimeOptions
2426
+ * @return ListIndicesResponse
2427
+ */
2428
+ async listIndicesWithOptions(WorkspaceId: string, request: ListIndicesRequest, headers: {[key: string ]: string}, runtime: $Util.RuntimeOptions): Promise<ListIndicesResponse> {
2429
+ Util.validateModel(request);
2430
+ let query : {[key: string ]: any} = { };
2431
+ if (!Util.isUnset(request.indexName)) {
2432
+ query["IndexName"] = request.indexName;
2433
+ }
2434
+
2435
+ if (!Util.isUnset(request.pageNumber)) {
2436
+ query["PageNumber"] = request.pageNumber;
2437
+ }
2438
+
2439
+ if (!Util.isUnset(request.pageSize)) {
2440
+ query["PageSize"] = request.pageSize;
2441
+ }
2442
+
2443
+ let req = new $OpenApi.OpenApiRequest({
2444
+ headers: headers,
2445
+ query: OpenApiUtil.query(query),
2446
+ });
2447
+ let params = new $OpenApi.Params({
2448
+ action: "ListIndices",
2449
+ version: "2023-12-29",
2450
+ protocol: "HTTPS",
2451
+ pathname: `/${OpenApiUtil.getEncodeParam(WorkspaceId)}/index/list_indices`,
2452
+ method: "GET",
2453
+ authType: "AK",
2454
+ style: "ROA",
2455
+ reqBodyType: "json",
2456
+ bodyType: "json",
2457
+ });
2458
+ return $tea.cast<ListIndicesResponse>(await this.callApi(params, req, runtime), new ListIndicesResponse({}));
2459
+ }
2460
+
2461
+ /**
2462
+ * @summary 查询pipeline
2463
+ *
2464
+ * @param request ListIndicesRequest
2465
+ * @return ListIndicesResponse
2466
+ */
2467
+ async listIndices(WorkspaceId: string, request: ListIndicesRequest): Promise<ListIndicesResponse> {
2468
+ let runtime = new $Util.RuntimeOptions({ });
2469
+ let headers : {[key: string ]: string} = { };
2470
+ return await this.listIndicesWithOptions(WorkspaceId, request, headers, runtime);
2471
+ }
2472
+
1530
2473
  /**
1531
2474
  * @summary 召回测试
1532
2475
  *