Skip to content

Commit

Permalink
[ENH] Update client telemetry for developer cloud (#2785)
Browse files Browse the repository at this point in the history
## Description of changes

Update Posthog telemetry to indicate which events are associated with
Chroma Cloud interactions by clients.

## Test plan

- [x] Tests pass locally with `pytest` for python, `yarn test` for js,
`cargo test` for rust
- [x] Verify on Posthog that we get the new `hosted` property on events,
as well as the new `CloudError` events for errors.

## Documentation Changes
*Are all docstrings for user-facing APIs updated if required? Do we need
to make documentation changes in the [docs
repository](https://github.com/chroma-core/docs)?*

Co-authored-by: Itai Smith <itaismith@Itais-MacBook-Pro.local>
  • Loading branch information
itaismith and Itai Smith committed Sep 17, 2024
1 parent 8412076 commit d25edde
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions chromadb/telemetry/product/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,12 @@ def context(self) -> Dict[str, Any]:
for whitelisted in TELEMETRY_WHITELISTED_SETTINGS:
telemetry_settings[whitelisted] = settings[whitelisted]

hosted = self._system.settings.chroma_server_host == "api.trychroma.com"

self._context = {
"chroma_version": chroma_version,
"server_context": self.SERVER_CONTEXT.value,
"hosted": hosted,
**telemetry_settings,
}
return self._context
Expand Down
1 change: 1 addition & 0 deletions docs/docs.trychroma.com/pages/telemetry.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ We will only track usage details that help us make product decisions, specifical

- Chroma version and environment details (e.g. OS, Python version, is it running in a container, or in a jupyter notebook)
- Usage of embedding functions that ship with Chroma and aggregated usage of custom embeddings (we collect no information about the custom embeddings themselves)
- Client interactions with our hosted Chroma Cloud service.
- Collection commands. We track the anonymized uuid of a collection as well as the number of items
- `add`
- `update`
Expand Down

0 comments on commit d25edde

Please sign in to comment.