# chromie-tool
**Chroma** ([https://trychroma.com](https://trychroma.com)) import/export tool.
## Install
```bash
# install
pip install chromie-tool
# check chromie tool
which chromie
```
## Commands
### Help
```bash
# chromie help
chromie -h
# exp command help
chromie exp -h
```
### Export
```bash
chromie exp server://localhost:8000/tenant/db/collection file.json
```
### Import
```bash
chromie imp file.json server://localhost:8000/tenant/db/collection
```
### Copy
```bash
chromie cp server://///coll1 server://///coll2
```
### Listing the database collections
```bash
# only names
chromie ls server:////
# names and counts
chromie ls -c server:////
```
## URIs
### Server URI
Format:
```
server://host:port/tenant/database
server://host:port/tenant/database/collection
```
When a segment must take its value from the default value or an environment variable, this must be left blank.
Examples:
```
server://///
server:///tenant/db
```
Environment variables we can use for settings segments in server URIs:
- **`CHROMA_HOST`**
- **`CHROMA_PORT`**
- **`CHROMA_TENANT`**
- **`CHROMA_DATABASE`**
The default values in server URIs, when blank segments and environment variable unset, are these set in the **chromadb** package.
Right now:
- **Host**: ***localhost***
- **Port**: ***8000***
- **Tenant**: ***default_tenant***
- **Database**: ***default_database***
### Chroma Cloud URI
Format:
```
cloud:///tenant/db
cloud:///tenant/db/collection
```
Similar to the ***server*** schema but, with the ***cloud*** schema, the environment variables we can use are the following:
- **`CHROMA_TENANT`**
- **`CHROMA_DATABASE`**
Default values:
- **host:port** segment is always ***api.trychroma.com:8000***.
- Tenant and database don't have default values, these must be set explicitly or with environment variables.
### Checking and decomposing URIs
With **`chromie uri`**, we check and decompose a URI.
Examples:
```
$ chromie uri server:////
Schema: server
Host: localhost
Port: 8000
Tenant: default_tenant
Database: default_database
$ CHROMA_PORT=8888 chromie uri server:////
Schema: server
Host: localhost
Port: 8888
Tenant: default_tenant
Database: default_database
$ CHROMA_DATABASE=testdb chromie uri server://me//
Schema: server
Host: me
Port: 8000
Tenant: default_tenant
Database: testdb
```
### Pinging database instance and/or collection
Examples:
```
# database instance
chromie ping server:////
# database collection
chromie ping server://///movies
chromie ping cloud://///movies
```
## API key
When API key needed, **`--key`** or **`-k`** must be set.
We can use the **`CHROMA_API_KEY`** environment variable too.
Raw data
{
"_id": null,
"home_page": null,
"name": "chromie-tool",
"maintainer": null,
"docs_url": null,
"requires_python": "<3.14.0,>=3.12.0",
"maintainer_email": null,
"keywords": "chroma, chromadb, cli, export, import, tool, vector database",
"author": "Ra\u00fal G. Gonz\u00e1lez",
"author_email": "raul@chromio.dev",
"download_url": "https://files.pythonhosted.org/packages/d1/9c/9b3fa6df947416b1ce5dabb6f76b5fd6742c1f301de1f45c397094240679/chromie_tool-0.3.0.tar.gz",
"platform": null,
"description": "# chromie-tool\n\n**Chroma** ([https://trychroma.com](https://trychroma.com)) import/export tool.\n\n\n## Install\n\n```bash\n# install\npip install chromie-tool\n\n# check chromie tool\nwhich chromie\n```\n\n\n## Commands\n\n### Help\n\n```bash\n# chromie help\nchromie -h\n\n# exp command help\nchromie exp -h\n```\n\n### Export\n\n```bash\nchromie exp server://localhost:8000/tenant/db/collection file.json\n```\n\n### Import\n\n```bash\nchromie imp file.json server://localhost:8000/tenant/db/collection\n```\n\n### Copy\n\n```bash\nchromie cp server://///coll1 server://///coll2\n```\n\n### Listing the database collections\n\n```bash\n# only names\nchromie ls server:////\n\n# names and counts\nchromie ls -c server:////\n```\n\n\n## URIs\n\n### Server URI\n\nFormat:\n\n```\nserver://host:port/tenant/database\nserver://host:port/tenant/database/collection\n```\n\nWhen a segment must take its value from the default value or an environment variable, this must be left blank.\nExamples:\n\n```\nserver://///\nserver:///tenant/db\n```\n\nEnvironment variables we can use for settings segments in server URIs:\n\n- **`CHROMA_HOST`**\n\n- **`CHROMA_PORT`**\n\n- **`CHROMA_TENANT`**\n\n- **`CHROMA_DATABASE`**\n\nThe default values in server URIs, when blank segments and environment variable unset, are these set in the **chromadb** package.\nRight now:\n\n- **Host**: ***localhost***\n\n- **Port**: ***8000***\n\n- **Tenant**: ***default_tenant***\n\n- **Database**: ***default_database***\n\n### Chroma Cloud URI\n\nFormat:\n\n```\ncloud:///tenant/db\ncloud:///tenant/db/collection\n```\n\nSimilar to the ***server*** schema but, with the ***cloud*** schema, the environment variables we can use are the following:\n\n- **`CHROMA_TENANT`**\n\n- **`CHROMA_DATABASE`**\n\nDefault values:\n\n- **host:port** segment is always ***api.trychroma.com:8000***.\n\n- Tenant and database don't have default values, these must be set explicitly or with environment variables.\n\n### Checking and decomposing URIs\n\nWith **`chromie uri`**, we check and decompose a URI.\nExamples:\n\n```\n$ chromie uri server:////\nSchema: server\nHost: localhost\nPort: 8000\nTenant: default_tenant\nDatabase: default_database\n\n$ CHROMA_PORT=8888 chromie uri server:////\nSchema: server\nHost: localhost\nPort: 8888\nTenant: default_tenant\nDatabase: default_database\n\n$ CHROMA_DATABASE=testdb chromie uri server://me//\nSchema: server\nHost: me\nPort: 8000\nTenant: default_tenant\nDatabase: testdb\n```\n\n### Pinging database instance and/or collection\n\nExamples:\n\n```\n# database instance\nchromie ping server:////\n\n# database collection\nchromie ping server://///movies\nchromie ping cloud://///movies\n```\n\n\n## API key\n\nWhen API key needed, **`--key`** or **`-k`** must be set.\nWe can use the **`CHROMA_API_KEY`** environment variable too.\n\n",
"bugtrack_url": null,
"license": null,
"summary": "Chroma import/export tool.",
"version": "0.3.0",
"project_urls": {
"Homepage": "https://github.com/chromiodev/chromie",
"Repository": "https://github.com/chromiodev/chromie"
},
"split_keywords": [
"chroma",
" chromadb",
" cli",
" export",
" import",
" tool",
" vector database"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "6c41d2e0af126362a297079375abab750bfbf6d11da8bee535cc44d2729926c8",
"md5": "906d6afe2ded39cf803ae31f697626f8",
"sha256": "91965a9e3cd82d111a7952758e0947cc0cf786cff0ab2a974ea878154841b70f"
},
"downloads": -1,
"filename": "chromie_tool-0.3.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "906d6afe2ded39cf803ae31f697626f8",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.14.0,>=3.12.0",
"size": 21924,
"upload_time": "2025-10-06T19:11:11",
"upload_time_iso_8601": "2025-10-06T19:11:11.719164Z",
"url": "https://files.pythonhosted.org/packages/6c/41/d2e0af126362a297079375abab750bfbf6d11da8bee535cc44d2729926c8/chromie_tool-0.3.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "d19c9b3fa6df947416b1ce5dabb6f76b5fd6742c1f301de1f45c397094240679",
"md5": "87083cea41cc04c904ff13b4558af16c",
"sha256": "ff97666f62ba81b7b6e41fcac3915c2398676b6d1e1ee7e9bf6d5069015b8a45"
},
"downloads": -1,
"filename": "chromie_tool-0.3.0.tar.gz",
"has_sig": false,
"md5_digest": "87083cea41cc04c904ff13b4558af16c",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<3.14.0,>=3.12.0",
"size": 11385,
"upload_time": "2025-10-06T19:11:12",
"upload_time_iso_8601": "2025-10-06T19:11:12.808942Z",
"url": "https://files.pythonhosted.org/packages/d1/9c/9b3fa6df947416b1ce5dabb6f76b5fd6742c1f301de1f45c397094240679/chromie_tool-0.3.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-10-06 19:11:12",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "chromiodev",
"github_project": "chromie",
"github_not_found": true,
"lcname": "chromie-tool"
}