Files
lancedb/CONTRIBUTING.md
T
Brendan Clement 486f6c66bb docs: revise getting started and concepts (#4491)
This PR is part of the documentation revamp. Once the full set of PRs is
merged, we’ll publish the combined site to staging for review before
updating docs.lancedb.com.

The introductory pages are inconsistent, and the old PR split asked
reviewers to review some pages twice.

This brings the final quickstart, connection guide, architecture and
Concepts pages together. It clarifies OSS and Enterprise, simplifies
naming rules and includes the navigation and diagram fixes from #4489.

Function and Secret details on the Concepts pages are MDX comments until
their release, and CONTRIBUTING.md explains how to write docs before a
release.

Includes #4532. Ingestion, search and integrations are in #4533; data
workflows, SQL and operations are in #4534. Each MDX file has one PR
owner.

Local assembly, Mint validation and link checks pass. The Function pages
stay published from `main` until #4534 hides them, so hold publication
until the complete stack is integrated.
2026-10-15 14:50:47 -07:00

7.1 KiB

Contributing to LanceDB

LanceDB is an open-source project and we welcome contributions from the community. This document outlines the process for contributing to LanceDB.

Reporting Issues

If you encounter a bug or have a feature request, please open an issue on the GitHub issue tracker.

Picking an issue

We track issues on the GitHub issue tracker. If you are looking for something to work on, check the good first issue label. These issues are typically the best described and have the smallest scope.

If there's an issue you are interested in working on, please leave a comment on the issue. This will help us avoid duplicate work. Additionally, if you have questions about the issue, please ask them in the issue comments. We are happy to provide guidance on how to approach the issue.

Configuring Git

First, fork the repository on GitHub, then clone your fork:

git clone https://github.com/<username>/lancedb.git
cd lancedb

Then add the main repository as a remote:

git remote add upstream https://github.com/lancedb/lancedb.git
git fetch upstream

Setting up your development environment

We have development environments for Python, Typescript, and Java. Each environment has its own setup instructions.

Best practices for pull requests

For the best chance of having your pull request accepted, please follow these guidelines:

  1. Unit test all bug fixes and new features. Your code will not be merged if it doesn't have tests.
  2. If you change the public API, update the documentation in the docs directory.
  3. Aim to minimize the number of changes in each pull request. Keep to solving one problem at a time, when possible.
  4. Before marking a pull request ready-for-review, do a self review of your code. Is it clear why you are making the changes? Are the changes easy to understand?
  5. Use conventional commit messages as pull request titles. Examples:
    • New feature: feat: adding foo API
    • Bug fix: fix: issue with foo API
    • Documentation change: docs: adding foo API documentation
  6. If your pull request is a work in progress, leave the pull request as a draft. We will assume the pull request is ready for review when it is opened.
  7. When writing tests, test the error cases. Make sure they have understandable error messages.

Project structure

The core library is written in Rust. The Python, Typescript, and Java libraries are wrappers around the Rust library.

  • src/lancedb: Rust library source code
  • python: Python package source code
  • nodejs: Typescript package source code
  • node: Deprecated Typescript package source code
  • java: Java package source code
  • docs/src: SDK reference, built with mkdocs
  • docs/web: the open-source pages of docs.lancedb.com
  • docs/web-tests: the tests the documentation's code examples are extracted from

Documentation

The open-source pages of docs.lancedb.com live in docs/web, so a change to behaviour and the change to the page describing it belong in the same pull request.

Preview them locally — this serves docs/web on its own, with no other checkout:

npm i -g mint      # https://mintlify.com/docs/installation
cd docs/web && mint dev

This repository holds a page at every path the site publishes, so the whole navigation resolves locally. Enterprise pages exist here as open-source pages -- what the capability is, and what the embedded form does instead. A separate private repository supplies the fuller version of each, which replaces the page at the same path when the published site is assembled.

Four things to know before editing:

Code examples are not written into the pages. They live in real tests under docs/web-tests/{py,ts,rs}, are extracted into docs/web/snippets/, and are imported by the pages. Edit the test, then regenerate from the repository root:

uv run docs/web-tests/mdx_snippets_gen.py -s docs/web-tests/py -s docs/web-tests/ts -s docs/web-tests/rs -o docs/web/snippets

Review the diff before committing: a few modules currently regenerate with unrelated changes, so commit only the snippets for the examples you changed.

Run the Python, TypeScript and Rust examples in docs/web-tests/{py,ts,rs} locally before submitting the change. These examples are not yet wired into pull-request CI; that integration remains follow-up work.

Every heading carries an explicit {#anchor}. Those anchors are how the Enterprise pages attach their additions to the right section, so they are assigned once and never regenerated. Leave an existing anchor alone even when you reword the heading above it; only new headings need a new one.

A page can declare where it applies. Its frontmatter says whether LanceDB OSS and LanceDB Enterprise support the feature: use only available or unavailable, and one sentence that explains its scope. Availability describes product support, not whether a particular deployment has enabled or configured the feature. A supported feature stays available when it requires setup, a supported SDK or server version, or has differences between offerings. State those requirements in the summary or the relevant section, including unsupported subfeatures. Do not use varies, infer support from an unknown status, or mark an absent capability available. Narrow a page to the capability it actually covers when necessary. For example:

availability:
  oss: unavailable
  enterprise: available
  summary: >-
    Requests to a deployment carry an API key or an OAuth token. Embedded
    LanceDB has no server to sign in to.

The assembled site renders this as a label above the page's content and as a sidebar tag when only one offering has the feature. Do not also open the page with a badge of its own, and keep a qualification that only one section needs in that section's text. A mint dev preview of docs/web alone renders neither the labels nor the tags.

A feature can be documented before its release. List a draft page in docs/web/.mintignore, keep it out of the navigation in docs.json, and do not link to it from published pages. Wrap a draft section in an MDX comment, {/* ... */}, whose first line names the release, such as Draft for the Feature X release. Keep draft table rows and list items in a comment below the table or list, since a comment between rows or items breaks it. Drafts are hidden from readers but stay in the source, and availability does not change what is published. At release, remove the comments and the .mintignore entries, and restore the navigation and links. See Writing docs before release in the documentation repository's README for previews and release checks.

Release process

For information on the release process, see: release_process.md