chromadb 3.2.2 → 3.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/dist/chromadb.d.ts +45 -8
- package/dist/chromadb.legacy-esm.js +404 -177
- package/dist/chromadb.mjs +404 -177
- package/dist/chromadb.mjs.map +1 -1
- package/dist/cjs/chromadb.cjs +404 -177
- package/dist/cjs/chromadb.cjs.map +1 -1
- package/dist/cjs/chromadb.d.cts +45 -8
- package/package.json +6 -6
- package/src/admin-client.ts +7 -7
- package/src/api/sdk.gen.ts +360 -135
- package/src/api/types.gen.ts +152 -58
- package/src/chroma-client.ts +18 -13
- package/src/collection.ts +18 -18
- package/src/execution/expression/key.ts +27 -6
- package/src/types.ts +28 -5
- package/src/utils.ts +72 -17
package/dist/cjs/chromadb.cjs
CHANGED
|
@@ -484,27 +484,170 @@ var client = J(w({
|
|
|
484
484
|
}));
|
|
485
485
|
|
|
486
486
|
// src/api/sdk.gen.ts
|
|
487
|
-
var
|
|
487
|
+
var AuthenticationService = class {
|
|
488
488
|
/**
|
|
489
|
-
*
|
|
489
|
+
* Get user identity
|
|
490
|
+
* Returns the current user's identity, tenant, and databases.
|
|
490
491
|
*/
|
|
491
492
|
static getUserIdentity(options) {
|
|
492
493
|
return (options?.client ?? client).get({
|
|
494
|
+
security: [
|
|
495
|
+
{
|
|
496
|
+
name: "x-chroma-token",
|
|
497
|
+
type: "apiKey"
|
|
498
|
+
}
|
|
499
|
+
],
|
|
493
500
|
url: "/api/v2/auth/identity",
|
|
494
501
|
...options
|
|
495
502
|
});
|
|
496
503
|
}
|
|
504
|
+
};
|
|
505
|
+
var CollectionService = class {
|
|
497
506
|
/**
|
|
498
|
-
*
|
|
507
|
+
* Get collection by CRN
|
|
508
|
+
* Returns a collection by Chroma Resource Name.
|
|
499
509
|
*/
|
|
500
510
|
static getCollectionByCrn(options) {
|
|
501
511
|
return (options.client ?? client).get({
|
|
512
|
+
security: [
|
|
513
|
+
{
|
|
514
|
+
name: "x-chroma-token",
|
|
515
|
+
type: "apiKey"
|
|
516
|
+
}
|
|
517
|
+
],
|
|
502
518
|
url: "/api/v2/collections/{crn}",
|
|
503
519
|
...options
|
|
504
520
|
});
|
|
505
521
|
}
|
|
506
522
|
/**
|
|
507
|
-
*
|
|
523
|
+
* List collections
|
|
524
|
+
* Lists all collections in a database.
|
|
525
|
+
*/
|
|
526
|
+
static listCollections(options) {
|
|
527
|
+
return (options.client ?? client).get({
|
|
528
|
+
security: [
|
|
529
|
+
{
|
|
530
|
+
name: "x-chroma-token",
|
|
531
|
+
type: "apiKey"
|
|
532
|
+
}
|
|
533
|
+
],
|
|
534
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections",
|
|
535
|
+
...options
|
|
536
|
+
});
|
|
537
|
+
}
|
|
538
|
+
/**
|
|
539
|
+
* Create collection
|
|
540
|
+
* Creates a new collection in a database.
|
|
541
|
+
*/
|
|
542
|
+
static createCollection(options) {
|
|
543
|
+
return (options.client ?? client).post({
|
|
544
|
+
security: [
|
|
545
|
+
{
|
|
546
|
+
name: "x-chroma-token",
|
|
547
|
+
type: "apiKey"
|
|
548
|
+
}
|
|
549
|
+
],
|
|
550
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections",
|
|
551
|
+
...options,
|
|
552
|
+
headers: {
|
|
553
|
+
"Content-Type": "application/json",
|
|
554
|
+
...options?.headers
|
|
555
|
+
}
|
|
556
|
+
});
|
|
557
|
+
}
|
|
558
|
+
/**
|
|
559
|
+
* Delete collection
|
|
560
|
+
* Deletes a collection in a database.
|
|
561
|
+
*/
|
|
562
|
+
static deleteCollection(options) {
|
|
563
|
+
return (options.client ?? client).delete({
|
|
564
|
+
security: [
|
|
565
|
+
{
|
|
566
|
+
name: "x-chroma-token",
|
|
567
|
+
type: "apiKey"
|
|
568
|
+
}
|
|
569
|
+
],
|
|
570
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}",
|
|
571
|
+
...options
|
|
572
|
+
});
|
|
573
|
+
}
|
|
574
|
+
/**
|
|
575
|
+
* Get collection
|
|
576
|
+
* Returns a collection by ID or name.
|
|
577
|
+
*/
|
|
578
|
+
static getCollection(options) {
|
|
579
|
+
return (options.client ?? client).get({
|
|
580
|
+
security: [
|
|
581
|
+
{
|
|
582
|
+
name: "x-chroma-token",
|
|
583
|
+
type: "apiKey"
|
|
584
|
+
}
|
|
585
|
+
],
|
|
586
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}",
|
|
587
|
+
...options
|
|
588
|
+
});
|
|
589
|
+
}
|
|
590
|
+
/**
|
|
591
|
+
* Update collection
|
|
592
|
+
* Updates an existing collection's name or metadata.
|
|
593
|
+
*/
|
|
594
|
+
static updateCollection(options) {
|
|
595
|
+
return (options.client ?? client).put({
|
|
596
|
+
security: [
|
|
597
|
+
{
|
|
598
|
+
name: "x-chroma-token",
|
|
599
|
+
type: "apiKey"
|
|
600
|
+
}
|
|
601
|
+
],
|
|
602
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}",
|
|
603
|
+
...options,
|
|
604
|
+
headers: {
|
|
605
|
+
"Content-Type": "application/json",
|
|
606
|
+
...options?.headers
|
|
607
|
+
}
|
|
608
|
+
});
|
|
609
|
+
}
|
|
610
|
+
/**
|
|
611
|
+
* Fork collection
|
|
612
|
+
* Creates a fork of an existing collection.
|
|
613
|
+
*/
|
|
614
|
+
static forkCollection(options) {
|
|
615
|
+
return (options.client ?? client).post({
|
|
616
|
+
security: [
|
|
617
|
+
{
|
|
618
|
+
name: "x-chroma-token",
|
|
619
|
+
type: "apiKey"
|
|
620
|
+
}
|
|
621
|
+
],
|
|
622
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/fork",
|
|
623
|
+
...options,
|
|
624
|
+
headers: {
|
|
625
|
+
"Content-Type": "application/json",
|
|
626
|
+
...options?.headers
|
|
627
|
+
}
|
|
628
|
+
});
|
|
629
|
+
}
|
|
630
|
+
/**
|
|
631
|
+
* Get number of collections
|
|
632
|
+
* Returns the total number of collections in a database.
|
|
633
|
+
*/
|
|
634
|
+
static countCollections(options) {
|
|
635
|
+
return (options.client ?? client).get({
|
|
636
|
+
security: [
|
|
637
|
+
{
|
|
638
|
+
name: "x-chroma-token",
|
|
639
|
+
type: "apiKey"
|
|
640
|
+
}
|
|
641
|
+
],
|
|
642
|
+
url: "/api/v2/tenants/{tenant}/databases/{database}/collections_count",
|
|
643
|
+
...options
|
|
644
|
+
});
|
|
645
|
+
}
|
|
646
|
+
};
|
|
647
|
+
var SystemService = class {
|
|
648
|
+
/**
|
|
649
|
+
* Healthcheck
|
|
650
|
+
* Returns the health status of the service.
|
|
508
651
|
*/
|
|
509
652
|
static healthcheck(options) {
|
|
510
653
|
return (options?.client ?? client).get({
|
|
@@ -513,7 +656,8 @@ var DefaultService = class {
|
|
|
513
656
|
});
|
|
514
657
|
}
|
|
515
658
|
/**
|
|
516
|
-
* Heartbeat
|
|
659
|
+
* Heartbeat
|
|
660
|
+
* Returns a nanosecond timestamp of the current time.
|
|
517
661
|
*/
|
|
518
662
|
static heartbeat(options) {
|
|
519
663
|
return (options?.client ?? client).get({
|
|
@@ -522,7 +666,8 @@ var DefaultService = class {
|
|
|
522
666
|
});
|
|
523
667
|
}
|
|
524
668
|
/**
|
|
525
|
-
* Pre-flight checks
|
|
669
|
+
* Pre-flight checks
|
|
670
|
+
* Returns basic readiness information.
|
|
526
671
|
*/
|
|
527
672
|
static preFlightChecks(options) {
|
|
528
673
|
return (options?.client ?? client).get({
|
|
@@ -531,19 +676,45 @@ var DefaultService = class {
|
|
|
531
676
|
});
|
|
532
677
|
}
|
|
533
678
|
/**
|
|
534
|
-
* Reset
|
|
679
|
+
* Reset database
|
|
680
|
+
* Resets the database. Requires authorization.
|
|
535
681
|
*/
|
|
536
682
|
static reset(options) {
|
|
537
683
|
return (options?.client ?? client).post({
|
|
684
|
+
security: [
|
|
685
|
+
{
|
|
686
|
+
name: "x-chroma-token",
|
|
687
|
+
type: "apiKey"
|
|
688
|
+
}
|
|
689
|
+
],
|
|
538
690
|
url: "/api/v2/reset",
|
|
539
691
|
...options
|
|
540
692
|
});
|
|
541
693
|
}
|
|
542
694
|
/**
|
|
695
|
+
* Get version
|
|
696
|
+
* Returns the version of the server.
|
|
697
|
+
*/
|
|
698
|
+
static version(options) {
|
|
699
|
+
return (options?.client ?? client).get({
|
|
700
|
+
url: "/api/v2/version",
|
|
701
|
+
...options
|
|
702
|
+
});
|
|
703
|
+
}
|
|
704
|
+
};
|
|
705
|
+
var TenantService = class {
|
|
706
|
+
/**
|
|
707
|
+
* Create tenant
|
|
543
708
|
* Creates a new tenant.
|
|
544
709
|
*/
|
|
545
710
|
static createTenant(options) {
|
|
546
711
|
return (options.client ?? client).post({
|
|
712
|
+
security: [
|
|
713
|
+
{
|
|
714
|
+
name: "x-chroma-token",
|
|
715
|
+
type: "apiKey"
|
|
716
|
+
}
|
|
717
|
+
],
|
|
547
718
|
url: "/api/v2/tenants",
|
|
548
719
|
...options,
|
|
549
720
|
headers: {
|
|
@@ -553,19 +724,33 @@ var DefaultService = class {
|
|
|
553
724
|
});
|
|
554
725
|
}
|
|
555
726
|
/**
|
|
727
|
+
* Get tenant
|
|
556
728
|
* Returns an existing tenant by name.
|
|
557
729
|
*/
|
|
558
730
|
static getTenant(options) {
|
|
559
731
|
return (options.client ?? client).get({
|
|
732
|
+
security: [
|
|
733
|
+
{
|
|
734
|
+
name: "x-chroma-token",
|
|
735
|
+
type: "apiKey"
|
|
736
|
+
}
|
|
737
|
+
],
|
|
560
738
|
url: "/api/v2/tenants/{tenant_name}",
|
|
561
739
|
...options
|
|
562
740
|
});
|
|
563
741
|
}
|
|
564
742
|
/**
|
|
743
|
+
* Update tenant
|
|
565
744
|
* Updates an existing tenant by name.
|
|
566
745
|
*/
|
|
567
746
|
static updateTenant(options) {
|
|
568
747
|
return (options.client ?? client).patch({
|
|
748
|
+
security: [
|
|
749
|
+
{
|
|
750
|
+
name: "x-chroma-token",
|
|
751
|
+
type: "apiKey"
|
|
752
|
+
}
|
|
753
|
+
],
|
|
569
754
|
url: "/api/v2/tenants/{tenant_name}",
|
|
570
755
|
...options,
|
|
571
756
|
headers: {
|
|
@@ -574,20 +759,36 @@ var DefaultService = class {
|
|
|
574
759
|
}
|
|
575
760
|
});
|
|
576
761
|
}
|
|
762
|
+
};
|
|
763
|
+
var DatabaseService = class {
|
|
577
764
|
/**
|
|
578
|
-
*
|
|
765
|
+
* List databases
|
|
766
|
+
* Lists all databases for a tenant.
|
|
579
767
|
*/
|
|
580
768
|
static listDatabases(options) {
|
|
581
769
|
return (options.client ?? client).get({
|
|
770
|
+
security: [
|
|
771
|
+
{
|
|
772
|
+
name: "x-chroma-token",
|
|
773
|
+
type: "apiKey"
|
|
774
|
+
}
|
|
775
|
+
],
|
|
582
776
|
url: "/api/v2/tenants/{tenant}/databases",
|
|
583
777
|
...options
|
|
584
778
|
});
|
|
585
779
|
}
|
|
586
780
|
/**
|
|
587
|
-
*
|
|
781
|
+
* Create database
|
|
782
|
+
* Creates a new database for a tenant.
|
|
588
783
|
*/
|
|
589
784
|
static createDatabase(options) {
|
|
590
785
|
return (options.client ?? client).post({
|
|
786
|
+
security: [
|
|
787
|
+
{
|
|
788
|
+
name: "x-chroma-token",
|
|
789
|
+
type: "apiKey"
|
|
790
|
+
}
|
|
791
|
+
],
|
|
591
792
|
url: "/api/v2/tenants/{tenant}/databases",
|
|
592
793
|
...options,
|
|
593
794
|
headers: {
|
|
@@ -597,81 +798,51 @@ var DefaultService = class {
|
|
|
597
798
|
});
|
|
598
799
|
}
|
|
599
800
|
/**
|
|
600
|
-
*
|
|
801
|
+
* Delete database
|
|
802
|
+
* Deletes a database by name.
|
|
601
803
|
*/
|
|
602
804
|
static deleteDatabase(options) {
|
|
603
805
|
return (options.client ?? client).delete({
|
|
806
|
+
security: [
|
|
807
|
+
{
|
|
808
|
+
name: "x-chroma-token",
|
|
809
|
+
type: "apiKey"
|
|
810
|
+
}
|
|
811
|
+
],
|
|
604
812
|
url: "/api/v2/tenants/{tenant}/databases/{database}",
|
|
605
813
|
...options
|
|
606
814
|
});
|
|
607
815
|
}
|
|
608
816
|
/**
|
|
609
|
-
*
|
|
817
|
+
* Get database
|
|
818
|
+
* Returns a database by name.
|
|
610
819
|
*/
|
|
611
820
|
static getDatabase(options) {
|
|
612
821
|
return (options.client ?? client).get({
|
|
822
|
+
security: [
|
|
823
|
+
{
|
|
824
|
+
name: "x-chroma-token",
|
|
825
|
+
type: "apiKey"
|
|
826
|
+
}
|
|
827
|
+
],
|
|
613
828
|
url: "/api/v2/tenants/{tenant}/databases/{database}",
|
|
614
829
|
...options
|
|
615
830
|
});
|
|
616
831
|
}
|
|
832
|
+
};
|
|
833
|
+
var RecordService = class {
|
|
617
834
|
/**
|
|
618
|
-
*
|
|
619
|
-
*/
|
|
620
|
-
static listCollections(options) {
|
|
621
|
-
return (options.client ?? client).get({
|
|
622
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections",
|
|
623
|
-
...options
|
|
624
|
-
});
|
|
625
|
-
}
|
|
626
|
-
/**
|
|
627
|
-
* Creates a new collection under the specified database.
|
|
628
|
-
*/
|
|
629
|
-
static createCollection(options) {
|
|
630
|
-
return (options.client ?? client).post({
|
|
631
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections",
|
|
632
|
-
...options,
|
|
633
|
-
headers: {
|
|
634
|
-
"Content-Type": "application/json",
|
|
635
|
-
...options?.headers
|
|
636
|
-
}
|
|
637
|
-
});
|
|
638
|
-
}
|
|
639
|
-
/**
|
|
640
|
-
* Deletes a collection in a given database.
|
|
641
|
-
*/
|
|
642
|
-
static deleteCollection(options) {
|
|
643
|
-
return (options.client ?? client).delete({
|
|
644
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}",
|
|
645
|
-
...options
|
|
646
|
-
});
|
|
647
|
-
}
|
|
648
|
-
/**
|
|
649
|
-
* Retrieves a collection by ID or name.
|
|
650
|
-
*/
|
|
651
|
-
static getCollection(options) {
|
|
652
|
-
return (options.client ?? client).get({
|
|
653
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}",
|
|
654
|
-
...options
|
|
655
|
-
});
|
|
656
|
-
}
|
|
657
|
-
/**
|
|
658
|
-
* Updates an existing collection's name or metadata.
|
|
659
|
-
*/
|
|
660
|
-
static updateCollection(options) {
|
|
661
|
-
return (options.client ?? client).put({
|
|
662
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}",
|
|
663
|
-
...options,
|
|
664
|
-
headers: {
|
|
665
|
-
"Content-Type": "application/json",
|
|
666
|
-
...options?.headers
|
|
667
|
-
}
|
|
668
|
-
});
|
|
669
|
-
}
|
|
670
|
-
/**
|
|
835
|
+
* Add records
|
|
671
836
|
* Adds records to a collection.
|
|
672
837
|
*/
|
|
673
838
|
static collectionAdd(options) {
|
|
674
839
|
return (options.client ?? client).post({
|
|
840
|
+
security: [
|
|
841
|
+
{
|
|
842
|
+
name: "x-chroma-token",
|
|
843
|
+
type: "apiKey"
|
|
844
|
+
}
|
|
845
|
+
],
|
|
675
846
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/add",
|
|
676
847
|
...options,
|
|
677
848
|
headers: {
|
|
@@ -681,32 +852,33 @@ var DefaultService = class {
|
|
|
681
852
|
});
|
|
682
853
|
}
|
|
683
854
|
/**
|
|
684
|
-
*
|
|
685
|
-
|
|
686
|
-
static detachFunction(options) {
|
|
687
|
-
return (options.client ?? client).post({
|
|
688
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/attached_functions/{name}/detach",
|
|
689
|
-
...options,
|
|
690
|
-
headers: {
|
|
691
|
-
"Content-Type": "application/json",
|
|
692
|
-
...options?.headers
|
|
693
|
-
}
|
|
694
|
-
});
|
|
695
|
-
}
|
|
696
|
-
/**
|
|
697
|
-
* Retrieves the number of records in a collection.
|
|
855
|
+
* Get number of records
|
|
856
|
+
* Returns the number of records in a collection.
|
|
698
857
|
*/
|
|
699
858
|
static collectionCount(options) {
|
|
700
859
|
return (options.client ?? client).get({
|
|
860
|
+
security: [
|
|
861
|
+
{
|
|
862
|
+
name: "x-chroma-token",
|
|
863
|
+
type: "apiKey"
|
|
864
|
+
}
|
|
865
|
+
],
|
|
701
866
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/count",
|
|
702
867
|
...options
|
|
703
868
|
});
|
|
704
869
|
}
|
|
705
870
|
/**
|
|
871
|
+
* Delete records
|
|
706
872
|
* Deletes records in a collection. Can filter by IDs or metadata.
|
|
707
873
|
*/
|
|
708
874
|
static collectionDelete(options) {
|
|
709
875
|
return (options.client ?? client).post({
|
|
876
|
+
security: [
|
|
877
|
+
{
|
|
878
|
+
name: "x-chroma-token",
|
|
879
|
+
type: "apiKey"
|
|
880
|
+
}
|
|
881
|
+
],
|
|
710
882
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/delete",
|
|
711
883
|
...options,
|
|
712
884
|
headers: {
|
|
@@ -716,45 +888,17 @@ var DefaultService = class {
|
|
|
716
888
|
});
|
|
717
889
|
}
|
|
718
890
|
/**
|
|
719
|
-
*
|
|
720
|
-
|
|
721
|
-
static forkCollection(options) {
|
|
722
|
-
return (options.client ?? client).post({
|
|
723
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/fork",
|
|
724
|
-
...options,
|
|
725
|
-
headers: {
|
|
726
|
-
"Content-Type": "application/json",
|
|
727
|
-
...options?.headers
|
|
728
|
-
}
|
|
729
|
-
});
|
|
730
|
-
}
|
|
731
|
-
/**
|
|
732
|
-
* Attach a function to a collection
|
|
733
|
-
*/
|
|
734
|
-
static attachFunction(options) {
|
|
735
|
-
return (options.client ?? client).post({
|
|
736
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/functions/attach",
|
|
737
|
-
...options,
|
|
738
|
-
headers: {
|
|
739
|
-
"Content-Type": "application/json",
|
|
740
|
-
...options?.headers
|
|
741
|
-
}
|
|
742
|
-
});
|
|
743
|
-
}
|
|
744
|
-
/**
|
|
745
|
-
* Get an attached function by name
|
|
746
|
-
*/
|
|
747
|
-
static getAttachedFunction(options) {
|
|
748
|
-
return (options.client ?? client).get({
|
|
749
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/functions/{function_name}",
|
|
750
|
-
...options
|
|
751
|
-
});
|
|
752
|
-
}
|
|
753
|
-
/**
|
|
754
|
-
* Retrieves records from a collection by ID or metadata filter.
|
|
891
|
+
* Get records
|
|
892
|
+
* Returns records from a collection by ID or metadata filter.
|
|
755
893
|
*/
|
|
756
894
|
static collectionGet(options) {
|
|
757
895
|
return (options.client ?? client).post({
|
|
896
|
+
security: [
|
|
897
|
+
{
|
|
898
|
+
name: "x-chroma-token",
|
|
899
|
+
type: "apiKey"
|
|
900
|
+
}
|
|
901
|
+
],
|
|
758
902
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/get",
|
|
759
903
|
...options,
|
|
760
904
|
headers: {
|
|
@@ -764,19 +908,33 @@ var DefaultService = class {
|
|
|
764
908
|
});
|
|
765
909
|
}
|
|
766
910
|
/**
|
|
767
|
-
*
|
|
911
|
+
* Get indexing status
|
|
912
|
+
* Returns the indexing status of a collection.
|
|
768
913
|
*/
|
|
769
914
|
static indexingStatus(options) {
|
|
770
915
|
return (options.client ?? client).get({
|
|
916
|
+
security: [
|
|
917
|
+
{
|
|
918
|
+
name: "x-chroma-token",
|
|
919
|
+
type: "apiKey"
|
|
920
|
+
}
|
|
921
|
+
],
|
|
771
922
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/indexing_status",
|
|
772
923
|
...options
|
|
773
924
|
});
|
|
774
925
|
}
|
|
775
926
|
/**
|
|
776
|
-
* Query
|
|
927
|
+
* Query collection
|
|
928
|
+
* Queries a collection using dense vector search with metadata and full-text search filtering.
|
|
777
929
|
*/
|
|
778
930
|
static collectionQuery(options) {
|
|
779
931
|
return (options.client ?? client).post({
|
|
932
|
+
security: [
|
|
933
|
+
{
|
|
934
|
+
name: "x-chroma-token",
|
|
935
|
+
type: "apiKey"
|
|
936
|
+
}
|
|
937
|
+
],
|
|
780
938
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/query",
|
|
781
939
|
...options,
|
|
782
940
|
headers: {
|
|
@@ -786,10 +944,17 @@ var DefaultService = class {
|
|
|
786
944
|
});
|
|
787
945
|
}
|
|
788
946
|
/**
|
|
789
|
-
* Search records
|
|
947
|
+
* Search records
|
|
948
|
+
* Searches records from a collection with dense, sparse, or hybrid vector search.
|
|
790
949
|
*/
|
|
791
950
|
static collectionSearch(options) {
|
|
792
951
|
return (options.client ?? client).post({
|
|
952
|
+
security: [
|
|
953
|
+
{
|
|
954
|
+
name: "x-chroma-token",
|
|
955
|
+
type: "apiKey"
|
|
956
|
+
}
|
|
957
|
+
],
|
|
793
958
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/search",
|
|
794
959
|
...options,
|
|
795
960
|
headers: {
|
|
@@ -799,10 +964,17 @@ var DefaultService = class {
|
|
|
799
964
|
});
|
|
800
965
|
}
|
|
801
966
|
/**
|
|
967
|
+
* Update records
|
|
802
968
|
* Updates records in a collection by ID.
|
|
803
969
|
*/
|
|
804
970
|
static collectionUpdate(options) {
|
|
805
971
|
return (options.client ?? client).post({
|
|
972
|
+
security: [
|
|
973
|
+
{
|
|
974
|
+
name: "x-chroma-token",
|
|
975
|
+
type: "apiKey"
|
|
976
|
+
}
|
|
977
|
+
],
|
|
806
978
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/update",
|
|
807
979
|
...options,
|
|
808
980
|
headers: {
|
|
@@ -812,10 +984,17 @@ var DefaultService = class {
|
|
|
812
984
|
});
|
|
813
985
|
}
|
|
814
986
|
/**
|
|
987
|
+
* Upsert records
|
|
815
988
|
* Upserts records in a collection (create if not exists, otherwise update).
|
|
816
989
|
*/
|
|
817
990
|
static collectionUpsert(options) {
|
|
818
991
|
return (options.client ?? client).post({
|
|
992
|
+
security: [
|
|
993
|
+
{
|
|
994
|
+
name: "x-chroma-token",
|
|
995
|
+
type: "apiKey"
|
|
996
|
+
}
|
|
997
|
+
],
|
|
819
998
|
url: "/api/v2/tenants/{tenant}/databases/{database}/collections/{collection_id}/upsert",
|
|
820
999
|
...options,
|
|
821
1000
|
headers: {
|
|
@@ -824,24 +1003,6 @@ var DefaultService = class {
|
|
|
824
1003
|
}
|
|
825
1004
|
});
|
|
826
1005
|
}
|
|
827
|
-
/**
|
|
828
|
-
* Retrieves the total number of collections in a given database.
|
|
829
|
-
*/
|
|
830
|
-
static countCollections(options) {
|
|
831
|
-
return (options.client ?? client).get({
|
|
832
|
-
url: "/api/v2/tenants/{tenant}/databases/{database}/collections_count",
|
|
833
|
-
...options
|
|
834
|
-
});
|
|
835
|
-
}
|
|
836
|
-
/**
|
|
837
|
-
* Returns the version of the server.
|
|
838
|
-
*/
|
|
839
|
-
static version(options) {
|
|
840
|
-
return (options?.client ?? client).get({
|
|
841
|
-
url: "/api/v2/version",
|
|
842
|
-
...options
|
|
843
|
-
});
|
|
844
|
-
}
|
|
845
1006
|
};
|
|
846
1007
|
|
|
847
1008
|
// src/errors.ts
|
|
@@ -1109,11 +1270,39 @@ var validateMetadata = (metadata) => {
|
|
|
1109
1270
|
if (Object.keys(metadata).length === 0) {
|
|
1110
1271
|
throw new ChromaValueError("Expected metadata to be non-empty");
|
|
1111
1272
|
}
|
|
1112
|
-
|
|
1113
|
-
(v
|
|
1114
|
-
|
|
1273
|
+
const validateMetadataListValue = (key, v) => {
|
|
1274
|
+
if (v.length === 0) {
|
|
1275
|
+
throw new ChromaValueError(
|
|
1276
|
+
`Expected metadata list value for key '${key}' to be non-empty`
|
|
1277
|
+
);
|
|
1278
|
+
}
|
|
1279
|
+
const firstType = typeof v[0];
|
|
1280
|
+
for (const item of v) {
|
|
1281
|
+
if (typeof item !== "string" && typeof item !== "number" && typeof item !== "boolean") {
|
|
1282
|
+
throw new ChromaValueError(
|
|
1283
|
+
`Expected metadata list value for key '${key}' to contain only strings, numbers, or booleans, got ${typeof item}`
|
|
1284
|
+
);
|
|
1285
|
+
}
|
|
1286
|
+
if (typeof item !== firstType) {
|
|
1287
|
+
throw new ChromaValueError(
|
|
1288
|
+
`Expected metadata list value for key '${key}' to contain only the same type, got mixed types`
|
|
1289
|
+
);
|
|
1290
|
+
}
|
|
1291
|
+
}
|
|
1292
|
+
};
|
|
1293
|
+
for (const [key, v] of Object.entries(metadata)) {
|
|
1294
|
+
if (v === null || v === void 0 || typeof v === "string" || typeof v === "number" || typeof v === "boolean") {
|
|
1295
|
+
continue;
|
|
1296
|
+
}
|
|
1297
|
+
if (validateSparseVector(v)) {
|
|
1298
|
+
continue;
|
|
1299
|
+
}
|
|
1300
|
+
if (Array.isArray(v)) {
|
|
1301
|
+
validateMetadataListValue(key, v);
|
|
1302
|
+
continue;
|
|
1303
|
+
}
|
|
1115
1304
|
throw new ChromaValueError(
|
|
1116
|
-
|
|
1305
|
+
`Expected metadata value for key '${key}' to be a string, number, boolean, SparseVector, typed array (string[], number[], boolean[]), or null`
|
|
1117
1306
|
);
|
|
1118
1307
|
}
|
|
1119
1308
|
};
|
|
@@ -1132,10 +1321,13 @@ var serializeMetadata = (metadata) => {
|
|
|
1132
1321
|
}
|
|
1133
1322
|
const result = {};
|
|
1134
1323
|
Object.entries(metadata).forEach(([key, value]) => {
|
|
1324
|
+
if (value === null || value === void 0) {
|
|
1325
|
+
return;
|
|
1326
|
+
}
|
|
1135
1327
|
if (validateSparseVector(value)) {
|
|
1136
1328
|
result[key] = toSerializedSparseVector(value);
|
|
1137
1329
|
} else {
|
|
1138
|
-
result[key] = value
|
|
1330
|
+
result[key] = value;
|
|
1139
1331
|
}
|
|
1140
1332
|
});
|
|
1141
1333
|
return result;
|
|
@@ -1288,11 +1480,25 @@ var validateWhere = (where) => {
|
|
|
1288
1480
|
`Expected operand value to be an array for ${operator}, but got ${operand}`
|
|
1289
1481
|
);
|
|
1290
1482
|
}
|
|
1291
|
-
if (
|
|
1292
|
-
|
|
1293
|
-
|
|
1483
|
+
if (["$contains", "$not_contains"].includes(operator) && !["string", "number", "boolean"].includes(typeof operand)) {
|
|
1484
|
+
throw new ChromaValueError(
|
|
1485
|
+
`Expected operand value to be a string, number, or boolean for ${operator}, but got ${typeof operand}`
|
|
1486
|
+
);
|
|
1487
|
+
}
|
|
1488
|
+
if (![
|
|
1489
|
+
"$gt",
|
|
1490
|
+
"$gte",
|
|
1491
|
+
"$lt",
|
|
1492
|
+
"$lte",
|
|
1493
|
+
"$ne",
|
|
1494
|
+
"$eq",
|
|
1495
|
+
"$in",
|
|
1496
|
+
"$nin",
|
|
1497
|
+
"$contains",
|
|
1498
|
+
"$not_contains"
|
|
1499
|
+
].includes(operator)) {
|
|
1294
1500
|
throw new ChromaValueError(
|
|
1295
|
-
`Expected operator to be one of $gt, $gte, $lt, $lte, $ne, $eq, $in, $nin, but got ${operator}`
|
|
1501
|
+
`Expected operator to be one of $gt, $gte, $lt, $lte, $ne, $eq, $in, $nin, $contains, $not_contains, but got ${operator}`
|
|
1296
1502
|
);
|
|
1297
1503
|
}
|
|
1298
1504
|
if (!["string", "number", "boolean"].includes(typeof operand) && !Array.isArray(operand)) {
|
|
@@ -1966,15 +2172,36 @@ var _Key = class _Key {
|
|
|
1966
2172
|
assertNonEmptyArray(array, "$nin requires at least one value");
|
|
1967
2173
|
return createComparisonWhere(this.name, "$nin", array);
|
|
1968
2174
|
}
|
|
2175
|
+
/**
|
|
2176
|
+
* Contains filter.
|
|
2177
|
+
*
|
|
2178
|
+
* On `Key.DOCUMENT`: substring search (value must be a string).
|
|
2179
|
+
* On metadata fields: checks if the array field contains the scalar value.
|
|
2180
|
+
*
|
|
2181
|
+
* @example
|
|
2182
|
+
* K.DOCUMENT.contains("machine learning") // document substring
|
|
2183
|
+
* K("tags").contains("action") // metadata array contains
|
|
2184
|
+
* K("scores").contains(42) // metadata array contains
|
|
2185
|
+
*/
|
|
1969
2186
|
contains(value) {
|
|
1970
|
-
if (typeof value !== "string") {
|
|
1971
|
-
throw new TypeError("
|
|
2187
|
+
if (this.name === "#document" && typeof value !== "string") {
|
|
2188
|
+
throw new TypeError("K.DOCUMENT.contains requires a string value");
|
|
1972
2189
|
}
|
|
1973
2190
|
return createComparisonWhere(this.name, "$contains", value);
|
|
1974
2191
|
}
|
|
2192
|
+
/**
|
|
2193
|
+
* Not-contains filter.
|
|
2194
|
+
*
|
|
2195
|
+
* On `Key.DOCUMENT`: excludes documents containing the substring.
|
|
2196
|
+
* On metadata fields: checks that the array field does not contain the scalar value.
|
|
2197
|
+
*
|
|
2198
|
+
* @example
|
|
2199
|
+
* K.DOCUMENT.notContains("deprecated") // document substring exclusion
|
|
2200
|
+
* K("tags").notContains("draft") // metadata array not-contains
|
|
2201
|
+
*/
|
|
1975
2202
|
notContains(value) {
|
|
1976
|
-
if (typeof value !== "string") {
|
|
1977
|
-
throw new TypeError("
|
|
2203
|
+
if (this.name === "#document" && typeof value !== "string") {
|
|
2204
|
+
throw new TypeError("K.DOCUMENT.notContains requires a string value");
|
|
1978
2205
|
}
|
|
1979
2206
|
return createComparisonWhere(this.name, "$not_contains", value);
|
|
1980
2207
|
}
|
|
@@ -4161,7 +4388,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4161
4388
|
if (whereDocument) validateWhereDocument(whereDocument);
|
|
4162
4389
|
}
|
|
4163
4390
|
async count() {
|
|
4164
|
-
const { data } = await
|
|
4391
|
+
const { data } = await RecordService.collectionCount({
|
|
4165
4392
|
client: this.apiClient,
|
|
4166
4393
|
path: await this.path()
|
|
4167
4394
|
});
|
|
@@ -4182,7 +4409,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4182
4409
|
uris
|
|
4183
4410
|
};
|
|
4184
4411
|
const preparedRecordSet = await this.prepareRecords({ recordSet });
|
|
4185
|
-
await
|
|
4412
|
+
await RecordService.collectionAdd({
|
|
4186
4413
|
client: this.apiClient,
|
|
4187
4414
|
path: await this.path(),
|
|
4188
4415
|
body: {
|
|
@@ -4204,7 +4431,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4204
4431
|
include = ["documents", "metadatas"]
|
|
4205
4432
|
} = args;
|
|
4206
4433
|
this.validateGet(include, ids, where, whereDocument);
|
|
4207
|
-
const { data } = await
|
|
4434
|
+
const { data } = await RecordService.collectionGet({
|
|
4208
4435
|
client: this.apiClient,
|
|
4209
4436
|
path: await this.path(),
|
|
4210
4437
|
body: {
|
|
@@ -4252,7 +4479,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4252
4479
|
whereDocument,
|
|
4253
4480
|
nResults
|
|
4254
4481
|
);
|
|
4255
|
-
const { data } = await
|
|
4482
|
+
const { data } = await RecordService.collectionQuery({
|
|
4256
4483
|
client: this.apiClient,
|
|
4257
4484
|
path: await this.path(),
|
|
4258
4485
|
body: {
|
|
@@ -4288,7 +4515,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4288
4515
|
return this.embedSearchPayload(payload);
|
|
4289
4516
|
})
|
|
4290
4517
|
);
|
|
4291
|
-
const { data } = await
|
|
4518
|
+
const { data } = await RecordService.collectionSearch({
|
|
4292
4519
|
client: this.apiClient,
|
|
4293
4520
|
path: await this.path(),
|
|
4294
4521
|
body: {
|
|
@@ -4325,7 +4552,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4325
4552
|
embeddingFunction: updateConfiguration.embedding_function
|
|
4326
4553
|
};
|
|
4327
4554
|
}
|
|
4328
|
-
await
|
|
4555
|
+
await CollectionService.updateCollection({
|
|
4329
4556
|
client: this.apiClient,
|
|
4330
4557
|
path: await this.path(),
|
|
4331
4558
|
body: {
|
|
@@ -4336,7 +4563,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4336
4563
|
});
|
|
4337
4564
|
}
|
|
4338
4565
|
async fork({ name }) {
|
|
4339
|
-
const { data } = await
|
|
4566
|
+
const { data } = await CollectionService.forkCollection({
|
|
4340
4567
|
client: this.apiClient,
|
|
4341
4568
|
path: await this.path(),
|
|
4342
4569
|
body: { new_name: name }
|
|
@@ -4371,7 +4598,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4371
4598
|
recordSet,
|
|
4372
4599
|
update: true
|
|
4373
4600
|
});
|
|
4374
|
-
await
|
|
4601
|
+
await RecordService.collectionUpdate({
|
|
4375
4602
|
client: this.apiClient,
|
|
4376
4603
|
path: await this.path(),
|
|
4377
4604
|
body: {
|
|
@@ -4400,7 +4627,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4400
4627
|
const preparedRecordSet = await this.prepareRecords({
|
|
4401
4628
|
recordSet
|
|
4402
4629
|
});
|
|
4403
|
-
await
|
|
4630
|
+
await RecordService.collectionUpsert({
|
|
4404
4631
|
client: this.apiClient,
|
|
4405
4632
|
path: await this.path(),
|
|
4406
4633
|
body: {
|
|
@@ -4418,7 +4645,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4418
4645
|
whereDocument
|
|
4419
4646
|
}) {
|
|
4420
4647
|
this.validateDelete(ids, where, whereDocument);
|
|
4421
|
-
await
|
|
4648
|
+
await RecordService.collectionDelete({
|
|
4422
4649
|
client: this.apiClient,
|
|
4423
4650
|
path: await this.path(),
|
|
4424
4651
|
body: {
|
|
@@ -4429,7 +4656,7 @@ var CollectionImpl = class _CollectionImpl {
|
|
|
4429
4656
|
});
|
|
4430
4657
|
}
|
|
4431
4658
|
async getIndexingStatus() {
|
|
4432
|
-
const { data } = await
|
|
4659
|
+
const { data } = await RecordService.indexingStatus({
|
|
4433
4660
|
client: this.apiClient,
|
|
4434
4661
|
path: await this.path()
|
|
4435
4662
|
});
|
|
@@ -4563,7 +4790,7 @@ var AdminClient = class {
|
|
|
4563
4790
|
name,
|
|
4564
4791
|
tenant
|
|
4565
4792
|
}) {
|
|
4566
|
-
await
|
|
4793
|
+
await DatabaseService.createDatabase({
|
|
4567
4794
|
client: this.apiClient,
|
|
4568
4795
|
path: { tenant },
|
|
4569
4796
|
body: { name }
|
|
@@ -4580,7 +4807,7 @@ var AdminClient = class {
|
|
|
4580
4807
|
name,
|
|
4581
4808
|
tenant
|
|
4582
4809
|
}) {
|
|
4583
|
-
const { data } = await
|
|
4810
|
+
const { data } = await DatabaseService.getDatabase({
|
|
4584
4811
|
client: this.apiClient,
|
|
4585
4812
|
path: { tenant, database: name }
|
|
4586
4813
|
});
|
|
@@ -4597,7 +4824,7 @@ var AdminClient = class {
|
|
|
4597
4824
|
name,
|
|
4598
4825
|
tenant
|
|
4599
4826
|
}) {
|
|
4600
|
-
await
|
|
4827
|
+
await DatabaseService.deleteDatabase({
|
|
4601
4828
|
client: this.apiClient,
|
|
4602
4829
|
path: { tenant, database: name }
|
|
4603
4830
|
});
|
|
@@ -4609,7 +4836,7 @@ var AdminClient = class {
|
|
|
4609
4836
|
*/
|
|
4610
4837
|
async listDatabases(args) {
|
|
4611
4838
|
const { limit = 100, offset = 0, tenant } = args;
|
|
4612
|
-
const { data } = await
|
|
4839
|
+
const { data } = await DatabaseService.listDatabases({
|
|
4613
4840
|
client: this.apiClient,
|
|
4614
4841
|
path: { tenant },
|
|
4615
4842
|
query: { limit, offset }
|
|
@@ -4622,7 +4849,7 @@ var AdminClient = class {
|
|
|
4622
4849
|
* @param options.name - Name of the tenant to create
|
|
4623
4850
|
*/
|
|
4624
4851
|
async createTenant({ name }) {
|
|
4625
|
-
await
|
|
4852
|
+
await TenantService.createTenant({
|
|
4626
4853
|
client: this.apiClient,
|
|
4627
4854
|
body: { name }
|
|
4628
4855
|
});
|
|
@@ -4634,7 +4861,7 @@ var AdminClient = class {
|
|
|
4634
4861
|
* @returns Promise resolving to the tenant name
|
|
4635
4862
|
*/
|
|
4636
4863
|
async getTenant({ name }) {
|
|
4637
|
-
const { data } = await
|
|
4864
|
+
const { data } = await TenantService.getTenant({
|
|
4638
4865
|
client: this.apiClient,
|
|
4639
4866
|
path: { tenant_name: name }
|
|
4640
4867
|
});
|
|
@@ -4760,7 +4987,7 @@ var ChromaClient = class {
|
|
|
4760
4987
|
* @returns Promise resolving to user identity data
|
|
4761
4988
|
*/
|
|
4762
4989
|
async getUserIdentity() {
|
|
4763
|
-
const { data } = await
|
|
4990
|
+
const { data } = await AuthenticationService.getUserIdentity({
|
|
4764
4991
|
client: this.apiClient
|
|
4765
4992
|
});
|
|
4766
4993
|
return data;
|
|
@@ -4770,7 +4997,7 @@ var ChromaClient = class {
|
|
|
4770
4997
|
* @returns Promise resolving to the server's nanosecond heartbeat timestamp
|
|
4771
4998
|
*/
|
|
4772
4999
|
async heartbeat() {
|
|
4773
|
-
const { data } = await
|
|
5000
|
+
const { data } = await SystemService.heartbeat({
|
|
4774
5001
|
client: this.apiClient
|
|
4775
5002
|
});
|
|
4776
5003
|
return data["nanosecond heartbeat"];
|
|
@@ -4784,7 +5011,7 @@ var ChromaClient = class {
|
|
|
4784
5011
|
*/
|
|
4785
5012
|
async listCollections(args) {
|
|
4786
5013
|
const { limit = 100, offset = 0 } = args || {};
|
|
4787
|
-
const { data } = await
|
|
5014
|
+
const { data } = await CollectionService.listCollections({
|
|
4788
5015
|
client: this.apiClient,
|
|
4789
5016
|
path: await this._path(),
|
|
4790
5017
|
query: { limit, offset }
|
|
@@ -4821,7 +5048,7 @@ var ChromaClient = class {
|
|
|
4821
5048
|
* @returns Promise resolving to the collection count
|
|
4822
5049
|
*/
|
|
4823
5050
|
async countCollections() {
|
|
4824
|
-
const { data } = await
|
|
5051
|
+
const { data } = await CollectionService.countCollections({
|
|
4825
5052
|
client: this.apiClient,
|
|
4826
5053
|
path: await this._path()
|
|
4827
5054
|
});
|
|
@@ -4850,7 +5077,7 @@ var ChromaClient = class {
|
|
|
4850
5077
|
metadata,
|
|
4851
5078
|
schema
|
|
4852
5079
|
});
|
|
4853
|
-
const { data } = await
|
|
5080
|
+
const { data } = await CollectionService.createCollection({
|
|
4854
5081
|
client: this.apiClient,
|
|
4855
5082
|
path: await this._path(),
|
|
4856
5083
|
body: {
|
|
@@ -4896,7 +5123,7 @@ var ChromaClient = class {
|
|
|
4896
5123
|
name,
|
|
4897
5124
|
embeddingFunction
|
|
4898
5125
|
}) {
|
|
4899
|
-
const { data } = await
|
|
5126
|
+
const { data } = await CollectionService.getCollection({
|
|
4900
5127
|
client: this.apiClient,
|
|
4901
5128
|
path: { ...await this._path(), collection_id: name }
|
|
4902
5129
|
});
|
|
@@ -4927,7 +5154,7 @@ var ChromaClient = class {
|
|
|
4927
5154
|
* @throws Error if the collection does not exist
|
|
4928
5155
|
*/
|
|
4929
5156
|
async getCollectionByCrn(crn) {
|
|
4930
|
-
const { data } = await
|
|
5157
|
+
const { data } = await CollectionService.getCollectionByCrn({
|
|
4931
5158
|
client: this.apiClient,
|
|
4932
5159
|
path: { crn }
|
|
4933
5160
|
});
|
|
@@ -4993,7 +5220,7 @@ var ChromaClient = class {
|
|
|
4993
5220
|
metadata,
|
|
4994
5221
|
schema
|
|
4995
5222
|
});
|
|
4996
|
-
const { data } = await
|
|
5223
|
+
const { data } = await CollectionService.createCollection({
|
|
4997
5224
|
client: this.apiClient,
|
|
4998
5225
|
path: await this._path(),
|
|
4999
5226
|
body: {
|
|
@@ -5033,7 +5260,7 @@ var ChromaClient = class {
|
|
|
5033
5260
|
* @param options.name - The name of the collection to delete
|
|
5034
5261
|
*/
|
|
5035
5262
|
async deleteCollection({ name }) {
|
|
5036
|
-
await
|
|
5263
|
+
await CollectionService.deleteCollection({
|
|
5037
5264
|
client: this.apiClient,
|
|
5038
5265
|
path: { ...await this._path(), collection_id: name }
|
|
5039
5266
|
});
|
|
@@ -5044,7 +5271,7 @@ var ChromaClient = class {
|
|
|
5044
5271
|
* @warning This operation is irreversible and will delete all data
|
|
5045
5272
|
*/
|
|
5046
5273
|
async reset() {
|
|
5047
|
-
await
|
|
5274
|
+
await SystemService.reset({
|
|
5048
5275
|
client: this.apiClient
|
|
5049
5276
|
});
|
|
5050
5277
|
}
|
|
@@ -5053,7 +5280,7 @@ var ChromaClient = class {
|
|
|
5053
5280
|
* @returns Promise resolving to the server version string
|
|
5054
5281
|
*/
|
|
5055
5282
|
async version() {
|
|
5056
|
-
const { data } = await
|
|
5283
|
+
const { data } = await SystemService.version({
|
|
5057
5284
|
client: this.apiClient
|
|
5058
5285
|
});
|
|
5059
5286
|
return data;
|
|
@@ -5064,7 +5291,7 @@ var ChromaClient = class {
|
|
|
5064
5291
|
*/
|
|
5065
5292
|
async getPreflightChecks() {
|
|
5066
5293
|
if (!this.preflightChecks) {
|
|
5067
|
-
const { data } = await
|
|
5294
|
+
const { data } = await SystemService.preFlightChecks({
|
|
5068
5295
|
client: this.apiClient
|
|
5069
5296
|
});
|
|
5070
5297
|
this.preflightChecks = data;
|