From 149cf1052ac561b5b879bd5417cb2b1a8f9d2f02 Mon Sep 17 00:00:00 2001 From: Brendan Clement Date: Wed, 28 Oct 2026 08:16:42 -0700 Subject: [PATCH] fix(ci): bundle Vale rules to avoid private release downloads (#4707) The prose check fails because it downloads its Vale rules from the now-private docs repository. Keep the five unchanged rules from `vale-lancedb-v0.1.0` in this repository and disable `vale sync` in CI. This also works for contributors without access to the docs repository. The update instructions record the release and archive checksum. --- .github/vale/README.md | 17 ++++++++ .github/vale/styles/LanceDB/Dashes.yml | 40 +++++++++++++++++++ .github/vale/styles/LanceDB/PlainLanguage.yml | 32 +++++++++++++++ .github/vale/styles/LanceDB/ProductNames.yml | 34 ++++++++++++++++ .github/vale/styles/LanceDB/VagueHeadings.yml | 19 +++++++++ .github/vale/styles/LanceDB/VaguePhrases.yml | 31 ++++++++++++++ .github/workflows/docs-style.yml | 8 ++-- .vale.ini | 11 ++--- CONTRIBUTING.md | 9 ++--- 9 files changed, 187 insertions(+), 14 deletions(-) create mode 100644 .github/vale/README.md create mode 100644 .github/vale/styles/LanceDB/Dashes.yml create mode 100644 .github/vale/styles/LanceDB/PlainLanguage.yml create mode 100644 .github/vale/styles/LanceDB/ProductNames.yml create mode 100644 .github/vale/styles/LanceDB/VagueHeadings.yml create mode 100644 .github/vale/styles/LanceDB/VaguePhrases.yml diff --git a/.github/vale/README.md b/.github/vale/README.md new file mode 100644 index 000000000..ad0573fdb --- /dev/null +++ b/.github/vale/README.md @@ -0,0 +1,17 @@ +# LanceDB prose rules + +These five rule files are copied unchanged from the `LanceDB.zip` asset of +`lancedb/docs` release `vale-lancedb-v0.1.0`. The archive SHA-256 is +`0730a43e919774121068811d5687c61dfc7a0421cff78e1393f5e565b622cb0f`. + +Keeping the rules here lets contributors and CI run Vale without access to the +source repository. The root `.vale.ini` preserves the release's MDX settings +and built-in repeated-word check. No `vale sync` is needed. + +The rules check product names, dashes, plain language, vague headings and vague +phrases. Findings are suggestions and do not fail the CI check. + +To update, a maintainer downloads the next published package, verifies its +checksum and replaces `styles/LanceDB` with the release's files. Check the +package's `.vale.ini` for configuration changes, and update the version and +checksum here in the same PR. diff --git a/.github/vale/styles/LanceDB/Dashes.yml b/.github/vale/styles/LanceDB/Dashes.yml new file mode 100644 index 000000000..7bb10c96f --- /dev/null +++ b/.github/vale/styles/LanceDB/Dashes.yml @@ -0,0 +1,40 @@ +extends: existence +message: "Avoid '%s' in prose. Use a comma, a colon, parentheses or two sentences." +link: https://github.com/lancedb/docs/blob/main/STYLE.md#punctuation +level: warning +nonword: true +# An em dash in prose, and a double hyphen or en dash used as one, with a +# space on each side. A table cell holding only an em dash, meaning "none", +# ranges such as 1–3 and flags such as --force are left alone, and code is +# never prose. +raw: + - '(?.mdx`. -StylesPath = .vale/styles -Packages = https://github.com/lancedb/docs/releases/download/vale-lancedb-v0.1.0/LanceDB.zip +StylesPath = .github/vale/styles +MinAlertLevel = suggestion + +[*.mdx] +BasedOnStyles = LanceDB +Vale.Repetition = warning diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fa854317d..4a73f8b35 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -88,13 +88,12 @@ npm i -g mint # https://mintlify.com/docs/installation cd docs/web && mint dev ``` -Wording, names and punctuation follow the -[LanceDB style guide](https://github.com/lancedb/docs/blob/main/STYLE.md). -[Vale](https://vale.sh) checks part of it, and pull requests show its -suggestions on the lines they change. To check a page yourself: +[Vale](https://vale.sh) checks wording, names and punctuation using the +[bundled LanceDB rules](.github/vale/README.md). Pull requests show suggestions +on the lines they change. With Vale 3.24.0 installed, check a page with: ```bash -vale sync && vale docs/web/indexing/vector-index.mdx +vale docs/web/indexing/vector-index.mdx ``` This repository holds a page at every path the site publishes, so the whole