- TypeScript 99.3%
- JavaScript 0.5%
- Shell 0.2%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
* chore: update dependencies and resolve security alerts - Fold in the open Dependabot PRs: the npm version-updates group (#173), undici 7.29.0 -> 7.29.1 (#174) and the GitHub Actions group (#176), then refresh the lockfile within the existing ranges. openapi-typescript stays on 6.2.6 (see the 1.19 notes: later 6.x erodes generated types). - Override openapi-typescript's undici 5 with 7.29.1. It is codegen-only and only calls `fetch`; this clears the undici 5/6 and @fastify/busboy alerts. `pnpm audit` is left with braces <=3.0.3, which has no patched release. - Drop eslint-disable directives the current typescript-eslint reports as unused. - Reformat markdown with prettier 3.9. lint-staged runs `prettier --list-different` on *.md, and every README failed it, so any markdown edit was rejected by the pre-commit hook. - how_to_release.md: prerequisites now match `engines` (Node 22.13, pnpm 11.9). Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * v1.20 Regenerate both clients from the qdrant `dev` branch (e61cc860) and bump to 1.20.0. No new proto files and no new REST endpoints. gRPC and REST: - BM25 ranking over text indexes: `scoring` on text index params, and a `text` query (`TextQuery`, `Bm25Params`) that ranks by the field named in `using`. `IdfParams` now also applies to BM25. - `substring` match condition for keyword fields. - `nested` on every payload index params type, to index each object of an array (e.g. `offers[].price`) as its own entry. - `max`, `min` and `acosh` formula expressions. - `turbo8`/`turbo16` datatypes and the `bits8` TurboQuant bit size. - Point id tracker params (`id_tracker`) on create/update collection and in collection params; collection info reports `created_at`. REST: `createCollection`/`recreateCollection` forward `id_tracker`. `updateCollection` already spreads its args. `GET /collections/{name}/points/{id}` gained a `timeout` query param; it is not wrapped by `QdrantClient`, so only the generated client changes. Also add the generated sources to .prettierignore: lint-staged runs `prettier --list-different` on staged *.ts, and codegen output never passed it, so regenerating could not be committed with the hook enabled. Integration tests cover the new surface on both clients and run against `qdrant/qdrant:dev` until 1.20 is tagged (`QDRANT_LATEST="dev"`, as for 1.19). REST 30/30 and gRPC 18/18 pass against dev@e61cc860. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * Run integration tests against v1.20.0 CI is expected to fail until qdrant v1.20.0 is published; re-run it then. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * Add code tokenizer from qdrant#11180 Regenerate gRPC/REST clients for TokenizerType.Code and cover camelCase/snake_case matching in integration tests. --------- Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Co-authored-by: qdrant-cloud-bot <111755117+qdrant-cloud-bot@users.noreply.github.com> |
||
| .github | ||
| .husky | ||
| .vscode | ||
| docs | ||
| examples/node-js-basic | ||
| packages | ||
| scripts | ||
| .gitignore | ||
| .npmrc | ||
| .nvmrc | ||
| .prettierignore | ||
| .prettierrc.yaml | ||
| CONTRIBUTING.md | ||
| eslint.config.mjs | ||
| LICENSE | ||
| package.json | ||
| pnpm-lock.yaml | ||
| pnpm-workspace.yaml | ||
| README.md | ||
| tsconfig.base.json | ||
JavaScript/TypeScript library for the Qdrant vector search engine.
JavaScript Qdrant SDK
This repository contains packages of the JS SDK for the Qdrant vector search engine.
There are published 3 packages:
@qdrant/qdrant-jsCode- the main package with the SDK itself.@qdrant/js-client-restCode - lightweight REST client for Qdrant.@qdrant/js-client-grpcCode - gRPC client for Qdrant.
JS/TS Examples
Installation
pnpm i @qdrant/js-client-rest
# or
npm install @qdrant/js-client-rest
# or
yarn add @qdrant/js-client-rest
Usage
Run the Qdrant Docker container:
docker run -p 6333:6333 qdrant/qdrant
Instantiate a client
import {QdrantClient} from '@qdrant/js-client-rest';
// TO connect to Qdrant running locally
const client = new QdrantClient({url: 'http://127.0.0.1:6333'});
// or connect to Qdrant Cloud
const client = new QdrantClient({
url: 'https://xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.us-east-0-1.aws.cloud.qdrant.io',
apiKey: '<your-api-key>',
});
Make requests
Using one of the available facade methods:
const result = await client.getCollections();
console.log('List of collections:', result.collections);
More examples can be found in the examples folder.
Support
TypeScript types are provided alongside JavaScript sources to be used in:
- Node.js (ESM and CJS) -
>= 18.0.0 - Deno
- Browser (fetch API)
- Cloudflare Workers (OpenAPI only)
Releases
Major and minor versions align with Qdrant's engine releases, whilst patch are reserved for fixes regarding the current minor release. New releases are made from the master branch.
Contributing
In order to contribute there are a couple of things you may need to setup. We make use of pnpm instead of npm or yarn to manage and install packages in this monorepo, make sure it's installed on your local environment.
After checking out the repository and desired branch, run pnpm install to install all package's dependencies and run the compilation steps. This will work for the monorepo.
For anything outside the monorepo, e.g.:
examples/node-js-basicfeel free to usenpmfor installing packages and running scripts.