All Templates / Storage
ChromaDB
The AI-native embedding database
Chroma
chroma-core/chroma:0.6.3
Just deployed
/chroma/chroma
Current Version: 0.6.3
Do you hate reading? This is for you! Here's a super quick rundown of how to use this template.
Assuming we have this template deployed and we have another NodeJS service next to it that we want to use to connect to ChromaDB. You can easily connect by doing the following:
In your service, create the following service variables:
CHROMA_TOKEN="${{Chroma.CHROMA_SERVER_AUTHN_CREDENTIALS}}"
CHROMA_URL="${{Chroma.CHROMA_PUBLIC_URL}}"
> Note: This assumes that the chroma service's name wasn't changed.
In your application, add the following code:
import { ChromaClient } from "chromadb";
const chroma = new ChromaClient({
path: process.env.CHROMA_URL,
auth: {
provider: "token",
credentials: process.env.CHROMA_TOKEN,
tokenHeaderType: "AUTHORIZATION"
}
});
> Note: This assumes that you have all necessary dependencies installed, like chromadb
.
And now you're ready to use Chroma! Of course this is just a quick example and your actual setup may vary. This quickstart did not cover how to connect over the private network, please see below.
This template is exposed publicly by default. Meaning to connect to it you can use the CHROMA_PUBLIC_URL
service variable.
However, it's recommended you use the Private Network in production. To use this template with the private network, set CHROMA_HOST_ADDR
to ::
on the Chroma service then connect through the CHROMA_PRIVATE_URL
service variable.
This Chroma DB template uses token authentication by default as specified in the CHROMA_SERVER_AUTHN_PROVIDER
service variable. A secure token is automatically created in the CHROMA_SERVER_AUTHN_CREDENTIALS
service variable.
You can change the authentication to basic or any other authentication, to do that please refer to ChromaDB's documentation (see below).
All the documentation is covered here!
Template Content
Details
ISDev
Created on May 6, 2024
94 total projects
39 active projects
84% success on recent deploys
Storage
More templates in this category
Flare
A modern, lightning-fast file sharing platform built for self-hosting
FlintSH's Projects
17
EdgeDB
EdgeDB template based on their Docker deployment guide
Ajit Krishna's Projects
41