Skip to content

lancedb/docs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LanceDB Mintlify Documentation

Home of the new LanceDB documentation on Mintlify.

Development

Install the Mintlify CLI to preview the documentation changes locally. To install, use the following command

npm i -g mintlify

Run the following commands at the root of the documentation (/docs/ in this repo, where docs.json is located).

cd docs
mint dev

Generate snippets

The Python, TypeScript and Rust code snippets used in the documentation are tested prior to use in the docs. These tests are located in the examples/ directory. Run the tests locally for each language when building the docs locally.

MDX snippets are generated by running a separate script scripts/mdx_snippets_gen.py, as Mintlify cannot scan the contents of raw code files -- it requires that the snippets are in MDX files under the snippets directory.

A Makefile is provided with convience functions that run the snippet generation for each language:

# Generate snippets for each language, one by one
make py
make ts
make rs

# Or, generate them for all languages in one command
make snippets

The following sequence of steps are run:

  1. Run tests for py, ts, rs files to verify that the code works
  2. Generate MDX snippets
  3. Import MDX snippets in the corresponding documentation page
  4. Add the NDX snippet inside a <CodeBlock> component in Mintlify

This ensures that the code in the docs is in line with the latest LanceDB API

Note

Do not add code snippets manually inside triple-backticks! Write the tests to the examples directory, then generate the snippets programmatically via the Makefile commands. This helps ensure that the documentation shows code that was actually run by a human, and by CI.

About

LanceDB Documentation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •