JSPM

  • Created
  • Published
  • Downloads 72097
  • Score
    100M100P100Q148444F
  • License Apache-2.0

A JavaScript interface for chroma

Package Exports

  • chromadb
  • chromadb/dist/main/index.js
  • chromadb/dist/module/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (chromadb) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

chromadb

Chroma is the open-source embedding database. Chroma makes it easy to build LLM apps by making knowledge, facts, and skills pluggable for LLMs.

This package gives you a JS/TS interface to talk to a backend Chroma DB over REST.

Learn more about Chroma

Getting started

Chroma needs to be running in order for this client to talk to it. Please see the ๐Ÿงช Usage Guide to learn how to quickly stand this up.

Small example

import { ChromaClient } from "chromadb"
const chroma = new ChromaClient("http://localhost:8000");
const collection = await chroma.createCollection("test-from-js");
for (let i = 0; i < 20; i++) {
    await collection.add(
      "test-id-" + i.toString(),
      [1, 2, 3, 4, 5],
      { "test": "test" }
    )
}
const queryData = await collection.query([1, 2, 3, 4, 5], 5, { "test": "test" });

Local development

View the Development Readme

License

Apache 2.0