diff --git a/.changeset/filtered-generate-includes.md b/.changeset/filtered-generate-includes.md deleted file mode 100644 index 2fc64bbe..00000000 --- a/.changeset/filtered-generate-includes.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"leadtype": patch ---- - -`generate` with `--include`/`--exclude`, or with a collection's `include`/`exclude`, now resolves `` partials that the filters leave out. Before, the filtered temp mirror held only the matched pages, so these includes failed with `ENOENT` and left an `[Error: Could not include file ...]` marker in the page. Relative includes in a staged page now resolve next to the original source file, and the partials are still not output as pages. A missing include still warns, and the warning now names the real source file instead of the temp mirror. diff --git a/.changeset/search-ranking-page-match.md b/.changeset/search-ranking-page-match.md deleted file mode 100644 index 452cee51..00000000 --- a/.changeset/search-ranking-page-match.md +++ /dev/null @@ -1,11 +0,0 @@ ---- -"leadtype": minor ---- - -Rank docs search results by the page they come from, not only by term counts. Regenerate search artifacts with this release: the index format is now version 4. The browser search client, MCP artifact loading and NLWeb `/ask` reject a version 3 index with an error that says to regenerate, instead of searching it with the new tokenizer and quietly missing matches. - -- A chunk's score is multiplied by how much of the query its page title, URL path and own heading cover. A page titled "Consent categories" now outranks a release note that repeats both words, and `vue quickstart` finds `/docs/frameworks/vue/quickstart` when the title is only "Quickstart". URL path words a page doesn't already use are indexed once, so a page that matches only through its URL is still found. -- Camel-case names index their parts and short dotted or hyphenated names index their joined form, so `consent banner` matches a page titled `ConsentBanner` and `nextjs` matches "Next.js". -- A page's description is indexed with its first chunk only. Repeating it in every chunk let pages with long descriptions outrank the sections that answer the query. The index is also smaller. -- `searchDocs` returns at most two chunks per page before applying `limit`. Set `maxResultsPerPage` to change this. NLWeb `/ask` uses `maxResultsPerPage: 1`, so it now fills its result limit instead of returning fewer results after removing duplicate pages. -- Queries with two or more words skip phrase matching for chunks that cannot reach the results, which makes broad queries several times faster on large indexes. diff --git a/packages/leadtype/CHANGELOG.md b/packages/leadtype/CHANGELOG.md index 98668cdd..bf5c758d 100644 --- a/packages/leadtype/CHANGELOG.md +++ b/packages/leadtype/CHANGELOG.md @@ -1,5 +1,21 @@ # leadtype +## 0.6.0 + +### Minor Changes + +- 993a4af: Rank docs search results by the page they come from, not only by term counts. Regenerate search artifacts with this release: the index format is now version 4. The browser search client, MCP artifact loading and NLWeb `/ask` reject a version 3 index with an error that says to regenerate, instead of searching it with the new tokenizer and quietly missing matches. + + - A chunk's score is multiplied by how much of the query its page title, URL path and own heading cover. A page titled "Consent categories" now outranks a release note that repeats both words, and `vue quickstart` finds `/docs/frameworks/vue/quickstart` when the title is only "Quickstart". URL path words a page doesn't already use are indexed once, so a page that matches only through its URL is still found. + - Camel-case names index their parts and short dotted or hyphenated names index their joined form, so `consent banner` matches a page titled `ConsentBanner` and `nextjs` matches "Next.js". + - A page's description is indexed with its first chunk only. Repeating it in every chunk let pages with long descriptions outrank the sections that answer the query. The index is also smaller. + - `searchDocs` returns at most two chunks per page before applying `limit`. Set `maxResultsPerPage` to change this. NLWeb `/ask` uses `maxResultsPerPage: 1`, so it now fills its result limit instead of returning fewer results after removing duplicate pages. + - Queries with two or more words skip phrase matching for chunks that cannot reach the results, which makes broad queries several times faster on large indexes. + +### Patch Changes + +- 00f55ce: `generate` with `--include`/`--exclude`, or with a collection's `include`/`exclude`, now resolves `` partials that the filters leave out. Before, the filtered temp mirror held only the matched pages, so these includes failed with `ENOENT` and left an `[Error: Could not include file ...]` marker in the page. Relative includes in a staged page now resolve next to the original source file, and the partials are still not output as pages. A missing include still warns, and the warning now names the real source file instead of the temp mirror. + ## 0.5.0 ### Minor Changes diff --git a/packages/leadtype/package.json b/packages/leadtype/package.json index 35f14372..0ba8b3bc 100644 --- a/packages/leadtype/package.json +++ b/packages/leadtype/package.json @@ -1,6 +1,6 @@ { "name": "leadtype", - "version": "0.5.0", + "version": "0.6.0", "description": "Framework-neutral docs pipeline tooling for MDX, LLM bundles, and search", "type": "module", "license": "MIT",