From 8fe464dc70ee99aa1440dd262fb2de67286399c1 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Wed, 10 Jun 2026 20:11:27 +0000 Subject: [PATCH 1/5] feat: add llms.txt, robots.txt, and rebranding glossary for AI readability Co-Authored-By: dan.coffey --- docusaurus.config.ts | 8 +++++ package-lock.json | 74 ++++++++++++++++++++++++++++++++++++++++++++ package.json | 2 ++ static/llms.txt | 49 +++++++++++++++++++++++++++++ static/robots.txt | 19 ++++++++++++ 5 files changed, 152 insertions(+) create mode 100644 static/llms.txt create mode 100644 static/robots.txt diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 0f5464139e29..3c303615031f 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -418,6 +418,14 @@ const config: Config = { }, } satisfies ClientRedirectsPlugin.Options, ], + [ + 'docusaurus-plugin-llms-txt', + { + title: 'Dolby OptiView Documentation', + description: 'Developer documentation for Dolby OptiView streaming products.', + fullLLMsTxt: true, + }, + ], [ (_context, options: { webpack: (isServer: boolean) => WebpackConfiguration }) => ({ name: 'webpack-plugin', diff --git a/package-lock.json b/package-lock.json index ce4a545b7442..ed3fd65ca954 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,6 +19,7 @@ "ace-builds": "^1.44.0", "clsx": "^2.1.1", "docusaurus-plugin-image-zoom": "^3.0.1", + "docusaurus-plugin-llms-txt": "^0.1.3", "docusaurus-plugin-openapi-docs": "^5.0.2", "docusaurus-theme-openapi-docs": "^5.0.2", "prism-react-renderer": "^2.4.1", @@ -9797,6 +9798,60 @@ "@docusaurus/theme-classic": ">=3.0.0" } }, + "node_modules/docusaurus-plugin-llms-txt": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/docusaurus-plugin-llms-txt/-/docusaurus-plugin-llms-txt-0.1.3.tgz", + "integrity": "sha512-X/Dqf1/soHFjvELWXtfa9C023498HsWWwNPdVZEu0OoznI2Gzf+VCB/4obwpBSV9OeDeI8D94/dK/ETq534k9A==", + "license": "MIT", + "dependencies": { + "fs-extra": "^11.2.0", + "gray-matter": "^4.0.3" + }, + "engines": { + "node": ">=16.14" + }, + "peerDependencies": { + "@docusaurus/core": ">=2.0.0", + "react": ">=16.8.0" + } + }, + "node_modules/docusaurus-plugin-llms-txt/node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "license": "MIT", + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/docusaurus-plugin-llms-txt/node_modules/gray-matter": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/gray-matter/-/gray-matter-4.0.3.tgz", + "integrity": "sha512-5v6yZd4JK3eMI3FqqCouswVqwugaA9r4dNZB1wwcmrD02QkV5H0y7XBQW8QwQqEaZY1pM9aqORSORhJRdNK44Q==", + "license": "MIT", + "dependencies": { + "js-yaml": "^3.13.1", + "kind-of": "^6.0.2", + "section-matter": "^1.0.0", + "strip-bom-string": "^1.0.0" + }, + "engines": { + "node": ">=6.0" + } + }, + "node_modules/docusaurus-plugin-llms-txt/node_modules/js-yaml": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", + "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", + "license": "MIT", + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, "node_modules/docusaurus-plugin-openapi-docs": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/docusaurus-plugin-openapi-docs/-/docusaurus-plugin-openapi-docs-5.0.2.tgz", @@ -10681,6 +10736,19 @@ "url": "https://opencollective.com/eslint" } }, + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "license": "BSD-2-Clause", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, "node_modules/esquery": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.7.0.tgz", @@ -21562,6 +21630,12 @@ "wbuf": "^1.7.3" } }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "license": "BSD-3-Clause" + }, "node_modules/srcset": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/srcset/-/srcset-4.0.0.tgz", diff --git a/package.json b/package.json index c503330049fb..b998cc10dc91 100644 --- a/package.json +++ b/package.json @@ -8,6 +8,7 @@ "prestart": "npm run gen-api-docs", "build": "docusaurus build", "prebuild": "npm run gen-api-docs", + "postbuild": "cp static/llms.txt build/llms.txt", "swizzle": "docusaurus swizzle", "clear": "docusaurus clear", "serve": "node serve.js", @@ -33,6 +34,7 @@ "ace-builds": "^1.44.0", "clsx": "^2.1.1", "docusaurus-plugin-image-zoom": "^3.0.1", + "docusaurus-plugin-llms-txt": "^0.1.3", "docusaurus-plugin-openapi-docs": "^5.0.2", "docusaurus-theme-openapi-docs": "^5.0.2", "prism-react-renderer": "^2.4.1", diff --git a/static/llms.txt b/static/llms.txt new file mode 100644 index 000000000000..1ae0b27ff915 --- /dev/null +++ b/static/llms.txt @@ -0,0 +1,49 @@ +# Dolby OptiView Documentation + +> Developer documentation for Dolby OptiView streaming products. +> URL: https://optiview.dolby.com/docs/ + +## Important: Product Name Changes (Rebranding) + +All products below were rebranded under the "Dolby OptiView" umbrella. Legacy names still appear in code, npm packages, API references, CSS class names, and older documentation pages. The old and new names refer to the same products. + +| Current Name | Former Name(s) | Notes | +|---|---|---| +| Dolby OptiView Player | THEOplayer | npm: `theoplayer`, JS class: `THEOplayer.Player`, CSS: `.theoplayer-container` | +| Dolby OptiView Ads | THEOads | Server-Guided Ad Insertion (SGAI) service | +| Dolby OptiView Live Streaming | THEOlive | Low-latency HESP streaming; config key: `theoLive`, source: `TheoLiveSource` | +| Dolby OptiView Real-time Streaming | Millicast, Dolby.io Streaming | WebRTC-based sub-500ms latency; dashboard: https://streaming.dolby.io | +| Open Video UI | (same) | Open-source UI components for OptiView Player (formerly THEOplayer) | +| Dolby OptiView Ad Engine | (same) | Just-in-time ad conformance | + +Note: The GitHub organization is still named "THEOplayer", npm packages use "theoplayer", and many code-level identifiers retain the old naming. When searching for documentation or code, try both the old and new names. + +## Products + +- [OptiView Player](https://optiview.dolby.com/docs/theoplayer/): Multi-platform video player SDK (Web, Android, iOS, Roku, React Native, Flutter) +- [Open Video UI](https://optiview.dolby.com/docs/open-video-ui/): Open-source UI component library for OptiView Player +- [OptiView Ads](https://optiview.dolby.com/docs/ads/): Server-Guided Ad Insertion (SGAI) for live content +- [OptiView Ad Engine](https://optiview.dolby.com/docs/ad-engine/): Just-in-time ad conformance +- [OptiView Live](https://optiview.dolby.com/docs/theolive/): Low-latency live streaming (HESP protocol) +- [OptiView Real-time Streaming](https://optiview.dolby.com/docs/millicast/): WebRTC real-time streaming (<500ms latency) + +## Getting Started + +- [Player Web Getting Started](https://optiview.dolby.com/docs/theoplayer/getting-started/sdks/web/getting-started/) +- [Player Android Getting Started](https://optiview.dolby.com/docs/theoplayer/getting-started/sdks/android/getting-started/) +- [Player iOS Getting Started](https://optiview.dolby.com/docs/theoplayer/getting-started/sdks/ios/getting-started/) +- [Real-time Streaming Getting Started](https://optiview.dolby.com/docs/millicast/getting-started/) +- [OptiView Ads Getting Started](https://optiview.dolby.com/docs/ads/) +- [OptiView Live Getting Started](https://optiview.dolby.com/docs/theolive/) + +## Frameworks + +- [React Native](https://optiview.dolby.com/docs/theoplayer/getting-started/frameworks/react-native/) +- [Flutter](https://optiview.dolby.com/docs/theoplayer/getting-started/frameworks/flutter/getting-started/) + +## Connectors + +- [Web Connectors](https://optiview.dolby.com/docs/theoplayer/connectors/web/) +- [Android Connectors](https://optiview.dolby.com/docs/theoplayer/connectors/android/) +- [iOS Connectors](https://optiview.dolby.com/docs/theoplayer/connectors/ios/) +- [React Native Connectors](https://optiview.dolby.com/docs/theoplayer/connectors/react-native/) diff --git a/static/robots.txt b/static/robots.txt new file mode 100644 index 000000000000..3117cac148eb --- /dev/null +++ b/static/robots.txt @@ -0,0 +1,19 @@ +User-agent: * +Allow: / + +User-agent: GPTBot +Allow: / + +User-agent: ChatGPT-User +Allow: / + +User-agent: Claude-Web +Allow: / + +User-agent: Anthropic-AI +Allow: / + +User-agent: Google-Extended +Allow: / + +Sitemap: https://optiview.dolby.com/docs/sitemap.xml From 195eee64a1fd4b00ab56f590ae4d71db50bbd716 Mon Sep 17 00:00:00 2001 From: Dan Coffey Date: Wed, 10 Jun 2026 16:35:42 -0400 Subject: [PATCH 2/5] updated descriptions --- static/llms.txt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/static/llms.txt b/static/llms.txt index 1ae0b27ff915..185df59bd0be 100644 --- a/static/llms.txt +++ b/static/llms.txt @@ -21,11 +21,11 @@ Note: The GitHub organization is still named "THEOplayer", npm packages use "the ## Products - [OptiView Player](https://optiview.dolby.com/docs/theoplayer/): Multi-platform video player SDK (Web, Android, iOS, Roku, React Native, Flutter) -- [Open Video UI](https://optiview.dolby.com/docs/open-video-ui/): Open-source UI component library for OptiView Player -- [OptiView Ads](https://optiview.dolby.com/docs/ads/): Server-Guided Ad Insertion (SGAI) for live content -- [OptiView Ad Engine](https://optiview.dolby.com/docs/ad-engine/): Just-in-time ad conformance -- [OptiView Live](https://optiview.dolby.com/docs/theolive/): Low-latency live streaming (HESP protocol) -- [OptiView Real-time Streaming](https://optiview.dolby.com/docs/millicast/): WebRTC real-time streaming (<500ms latency) +- [Open Video UI](https://optiview.dolby.com/docs/open-video-ui/): Open-source UI component library for OptiView Player enabling complete customization of the player experience +- [OptiView Ads](https://optiview.dolby.com/docs/ads/): an end-to-end Server-Guided Ad Insertion and Server-Side Ad Insertion solution for live streaming content +- [OptiView Ad Engine](https://optiview.dolby.com/docs/ad-engine/): Instant virtualized or just-in-time ad creative QC, conformance/transcoding, and packaging. mp4, mov, vast, hls (any to any conversion). Includes support for Dolby Vision and Dolby Atmos encoding. Can be used for VOD transcoding/transformation in addition to ads. +- [OptiView Live](https://optiview.dolby.com/docs/theolive/): High quality live video streaming. Consistent latency with a operator settable latency from 2 to 10 seconds to keep viewers in syncLow-latency live streaming (HESP protocol) and HLS support. +- [OptiView Real-time Streaming](https://optiview.dolby.com/docs/millicast/): WebRTC real-time streaming (<500ms latency) for interactive use-cases. ## Getting Started From 7f185ccdd071e4ff5ae332bbb104cc62e5420cc3 Mon Sep 17 00:00:00 2001 From: Dan Coffey Date: Wed, 10 Jun 2026 16:47:40 -0400 Subject: [PATCH 3/5] updated llms description in docusaurus --- docusaurus.config.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 3c303615031f..9560b6855dbb 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -422,7 +422,7 @@ const config: Config = { 'docusaurus-plugin-llms-txt', { title: 'Dolby OptiView Documentation', - description: 'Developer documentation for Dolby OptiView streaming products.', + description: 'Developer documentation for Dolby OptiView products.', fullLLMsTxt: true, }, ], From ac38123faa4b41a7bf0ff3096a5175d415bd2a24 Mon Sep 17 00:00:00 2001 From: Dan Coffey Date: Wed, 10 Jun 2026 22:07:26 -0400 Subject: [PATCH 4/5] re-worked to reduce context size and separate products --- docusaurus.config.ts | 74 +++++- package-lock.json | 432 ++++++++++++++++++++++++++++------ package.json | 4 +- scripts/build-llms-header.mjs | 37 +++ 4 files changed, 467 insertions(+), 80 deletions(-) create mode 100644 scripts/build-llms-header.mjs diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 9560b6855dbb..54e63035991d 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -419,11 +419,77 @@ const config: Config = { } satisfies ClientRedirectsPlugin.Options, ], [ - 'docusaurus-plugin-llms-txt', + '@signalwire/docusaurus-plugin-llms-txt', { - title: 'Dolby OptiView Documentation', - description: 'Developer documentation for Dolby OptiView products.', - fullLLMsTxt: true, + markdown: { + enableFiles: true, + includeDocs: true, + includeBlog: false, + includePages: false, + includeVersionedDocs: false, + }, + llmsTxt: { + enableLlmsFullTxt: false, + // Header (title, description, rebranding, getting started, etc.) is sourced from + // static/llms.txt and prepended via the postbuild script (see package.json). + siteTitle: 'Dolby OptiView Documentation', + siteDescription: 'Developer documentation for Dolby OptiView streaming products.', + includeDocs: true, + includeBlog: false, + includePages: false, + includeVersionedDocs: false, + excludeRoutes: ['/docs/search', '/docs/search/**', '/search', '/search/**'], + sections: [ + { + id: 'player', + name: 'OptiView Player', + description: 'Multi-platform video player SDK (Web, Android, iOS, Roku, React Native, Flutter). Formerly THEOplayer.', + position: 1, + routes: [{ route: '/docs/theoplayer/**' }], + }, + { + id: 'open-video-ui', + name: 'Open Video UI', + description: 'Open-source UI component library for OptiView Player enabling complete customization of the player experience.', + position: 2, + routes: [{ route: '/docs/open-video-ui/**' }], + }, + { + id: 'ads', + name: 'OptiView Ads', + description: 'End-to-end Server-Guided Ad Insertion (SGAI) and Server-Side Ad Insertion solution for live streaming. Formerly THEOads.', + position: 3, + routes: [{ route: '/docs/ads/**' }], + }, + { + id: 'ad-engine', + name: 'OptiView Ad Engine', + description: 'Instant virtualized or just-in-time ad creative QC, conformance/transcoding, and packaging (mp4, mov, vast, hls). Includes Dolby Vision and Atmos encoding support.', + position: 4, + routes: [{ route: '/docs/ad-engine/**' }], + }, + { + id: 'live', + name: 'OptiView Live', + description: 'High-quality live video streaming with operator-settable latency (2-10s). HESP and HLS protocols. Formerly THEOlive.', + position: 5, + routes: [{ route: '/docs/theolive/**' }], + }, + { + id: 'real-time', + name: 'OptiView Real-time Streaming', + description: 'WebRTC real-time streaming (<500ms latency) for interactive use-cases. Formerly Millicast / Dolby.io Streaming.', + position: 6, + routes: [{ route: '/docs/millicast/**' }], + }, + { + id: 'contributing', + name: 'Contributing', + position: 99, + routes: [{ route: '/docs/contributing/**' }], + }, + ], + }, }, ], [ diff --git a/package-lock.json b/package-lock.json index ed3fd65ca954..28ef5e93c28d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,10 +16,10 @@ "@docusaurus/plugin-google-tag-manager": "^3.10.1", "@docusaurus/preset-classic": "^3.10.1", "@mdx-js/react": "^3.1.1", + "@signalwire/docusaurus-plugin-llms-txt": "^2.0.0-alpha.7", "ace-builds": "^1.44.0", "clsx": "^2.1.1", "docusaurus-plugin-image-zoom": "^3.0.1", - "docusaurus-plugin-llms-txt": "^0.1.3", "docusaurus-plugin-openapi-docs": "^5.0.2", "docusaurus-theme-openapi-docs": "^5.0.2", "prism-react-renderer": "^2.4.1", @@ -5615,6 +5615,44 @@ "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==", "license": "BSD-3-Clause" }, + "node_modules/@signalwire/docusaurus-plugin-llms-txt": { + "version": "2.0.0-alpha.7", + "resolved": "https://registry.npmjs.org/@signalwire/docusaurus-plugin-llms-txt/-/docusaurus-plugin-llms-txt-2.0.0-alpha.7.tgz", + "integrity": "sha512-v9EcYXVNvMydIWVIzI1H2iC4/BNdystE0jJAQIFu68SHy1a13dESz9hn5YJE9Izx18QPny1jhXym/3wEP9+8LA==", + "license": "MIT", + "dependencies": { + "fs-extra": "^11.0.0", + "hast-util-select": "^6.0.4", + "hast-util-to-html": "^9.0.5", + "hast-util-to-string": "^3.0.1", + "p-map": "^7.0.2", + "rehype-parse": "^9", + "rehype-remark": "^10", + "remark-gfm": "^4", + "remark-stringify": "^11", + "string-width": "^5.0.0", + "unified": "^11", + "unist-util-visit": "^5" + }, + "engines": { + "node": ">=18.0.0" + }, + "peerDependencies": { + "@docusaurus/core": "^3.0.0" + } + }, + "node_modules/@signalwire/docusaurus-plugin-llms-txt/node_modules/p-map": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/p-map/-/p-map-7.0.4.tgz", + "integrity": "sha512-tkAQEw8ysMzmkhgw8k+1U/iPhWNhykKnSk4Rd5zLoPJCuJaGRPo6YposrZgaxHKzDHdDWWZvE/Sk7hsL2X/CpQ==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/@sinclair/typebox": { "version": "0.27.10", "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.10.tgz", @@ -7877,6 +7915,16 @@ "integrity": "sha512-x+VAiMRL6UPkx+kudNvxTl6hB2XNNCG2r+7wixVfIYwu/2HKRXimwQyaumLjMveWvT2Hkd/cAJw+QBMfJ/EKVw==", "license": "MIT" }, + "node_modules/bcp-47-match": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/bcp-47-match/-/bcp-47-match-2.0.3.tgz", + "integrity": "sha512-JtTezzbAibu8G0R9op9zb3vcWZd9JF6M0xOYGPn0fNCd7wOpRB1mU2mH9T8gaBGbAAyIIVgB2G7xG0GP98zMAQ==", + "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, "node_modules/big.js": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", @@ -9246,6 +9294,22 @@ "url": "https://github.com/sponsors/fb55" } }, + "node_modules/css-selector-parser": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/css-selector-parser/-/css-selector-parser-3.3.0.tgz", + "integrity": "sha512-Y2asgMGFqJKF4fq4xHDSlFYIkeVfRsm69lQC1q9kbEsH5XtnINTMrweLkjYMeaUgiXBy/uvKeO/a1JHTNnmB2g==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/mdevils" + }, + { + "type": "patreon", + "url": "https://patreon.com/mdevils" + } + ], + "license": "MIT" + }, "node_modules/css-tree": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.3.1.tgz", @@ -9760,6 +9824,19 @@ "node": ">=8" } }, + "node_modules/direction": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/direction/-/direction-2.0.1.tgz", + "integrity": "sha512-9S6m9Sukh1cZNknO1CWAr2QAWsbKLafQiyM5gZ7VgXHeuaoUwffKN4q6NC4A/Mf9iiPlOXQEKW/Mv/mh9/3YFA==", + "license": "MIT", + "bin": { + "direction": "cli.js" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, "node_modules/dns-packet": { "version": "5.6.1", "resolved": "https://registry.npmjs.org/dns-packet/-/dns-packet-5.6.1.tgz", @@ -9798,60 +9875,6 @@ "@docusaurus/theme-classic": ">=3.0.0" } }, - "node_modules/docusaurus-plugin-llms-txt": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/docusaurus-plugin-llms-txt/-/docusaurus-plugin-llms-txt-0.1.3.tgz", - "integrity": "sha512-X/Dqf1/soHFjvELWXtfa9C023498HsWWwNPdVZEu0OoznI2Gzf+VCB/4obwpBSV9OeDeI8D94/dK/ETq534k9A==", - "license": "MIT", - "dependencies": { - "fs-extra": "^11.2.0", - "gray-matter": "^4.0.3" - }, - "engines": { - "node": ">=16.14" - }, - "peerDependencies": { - "@docusaurus/core": ">=2.0.0", - "react": ">=16.8.0" - } - }, - "node_modules/docusaurus-plugin-llms-txt/node_modules/argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "license": "MIT", - "dependencies": { - "sprintf-js": "~1.0.2" - } - }, - "node_modules/docusaurus-plugin-llms-txt/node_modules/gray-matter": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/gray-matter/-/gray-matter-4.0.3.tgz", - "integrity": "sha512-5v6yZd4JK3eMI3FqqCouswVqwugaA9r4dNZB1wwcmrD02QkV5H0y7XBQW8QwQqEaZY1pM9aqORSORhJRdNK44Q==", - "license": "MIT", - "dependencies": { - "js-yaml": "^3.13.1", - "kind-of": "^6.0.2", - "section-matter": "^1.0.0", - "strip-bom-string": "^1.0.0" - }, - "engines": { - "node": ">=6.0" - } - }, - "node_modules/docusaurus-plugin-llms-txt/node_modules/js-yaml": { - "version": "3.14.2", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.2.tgz", - "integrity": "sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg==", - "license": "MIT", - "dependencies": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, "node_modules/docusaurus-plugin-openapi-docs": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/docusaurus-plugin-openapi-docs/-/docusaurus-plugin-openapi-docs-5.0.2.tgz", @@ -10736,19 +10759,6 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "license": "BSD-2-Clause", - "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/esquery": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.7.0.tgz", @@ -11971,6 +11981,38 @@ "node": ">= 0.4" } }, + "node_modules/hast-util-embedded": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/hast-util-embedded/-/hast-util-embedded-3.0.0.tgz", + "integrity": "sha512-naH8sld4Pe2ep03qqULEtvYr7EjrLK2QHY8KJR6RJkTUjPGObe1vnx585uzem2hGra+s1q08DZZpfgDVYRbaXA==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "hast-util-is-element": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/hast-util-from-html": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/hast-util-from-html/-/hast-util-from-html-2.0.3.tgz", + "integrity": "sha512-CUSRHXyKjzHov8yKsQjGOElXy/3EKpyX56ELnkHH34vDVw1N1XSQ1ZcAvTyAPtGqLTuKP/uxM+aLkSPqF/EtMw==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "devlop": "^1.1.0", + "hast-util-from-parse5": "^8.0.0", + "parse5": "^7.0.0", + "vfile": "^6.0.0", + "vfile-message": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-from-parse5": { "version": "8.0.3", "resolved": "https://registry.npmjs.org/hast-util-from-parse5/-/hast-util-from-parse5-8.0.3.tgz", @@ -11991,6 +12033,62 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-has-property": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/hast-util-has-property/-/hast-util-has-property-3.0.0.tgz", + "integrity": "sha512-MNilsvEKLFpV604hwfhVStK0usFY/QmM5zX16bo7EjnAEGofr5YyI37kzopBlZJkHD4t887i+q/C8/tr5Q94cA==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/hast-util-is-body-ok-link": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/hast-util-is-body-ok-link/-/hast-util-is-body-ok-link-3.0.1.tgz", + "integrity": "sha512-0qpnzOBLztXHbHQenVB8uNuxTnm/QBFUOmdOSsEn7GnBtyY07+ENTWVFBAnXd/zEgd9/SUG3lRY7hSIBWRgGpQ==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/hast-util-is-element": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/hast-util-is-element/-/hast-util-is-element-3.0.0.tgz", + "integrity": "sha512-Val9mnv2IWpLbNPqc/pUem+a7Ipj2aHacCwgNfTiK0vJKl0LF+4Ba4+v1oPHFpf3bLYmreq0/l3Gud9S5OH42g==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/hast-util-minify-whitespace": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hast-util-minify-whitespace/-/hast-util-minify-whitespace-1.0.1.tgz", + "integrity": "sha512-L96fPOVpnclQE0xzdWb/D12VT5FabA7SnZOUMtL1DbXmYiHJMXZvFkIZfiMmTCNJHUeO2K9UYNXoVyfz+QHuOw==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "hast-util-embedded": "^3.0.0", + "hast-util-is-element": "^3.0.0", + "hast-util-whitespace": "^3.0.0", + "unist-util-is": "^6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-parse-selector": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/hast-util-parse-selector/-/hast-util-parse-selector-4.0.0.tgz", @@ -12004,6 +12102,23 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-phrasing": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/hast-util-phrasing/-/hast-util-phrasing-3.0.1.tgz", + "integrity": "sha512-6h60VfI3uBQUxHqTyMymMZnEbNl1XmEGtOxxKYL7stY2o601COo62AWAYBQR9lZbYXYSBoxag8UpPRXK+9fqSQ==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "hast-util-embedded": "^3.0.0", + "hast-util-has-property": "^3.0.0", + "hast-util-is-body-ok-link": "^3.0.0", + "hast-util-is-element": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-raw": { "version": "9.1.0", "resolved": "https://registry.npmjs.org/hast-util-raw/-/hast-util-raw-9.1.0.tgz", @@ -12029,6 +12144,33 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-select": { + "version": "6.0.4", + "resolved": "https://registry.npmjs.org/hast-util-select/-/hast-util-select-6.0.4.tgz", + "integrity": "sha512-RqGS1ZgI0MwxLaKLDxjprynNzINEkRHY2i8ln4DDjgv9ZhcYVIHN9rlpiYsqtFwrgpYU361SyWDQcGNIBVu3lw==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "@types/unist": "^3.0.0", + "bcp-47-match": "^2.0.0", + "comma-separated-tokens": "^2.0.0", + "css-selector-parser": "^3.0.0", + "devlop": "^1.0.0", + "direction": "^2.0.0", + "hast-util-has-property": "^3.0.0", + "hast-util-to-string": "^3.0.0", + "hast-util-whitespace": "^3.0.0", + "nth-check": "^2.0.0", + "property-information": "^7.0.0", + "space-separated-tokens": "^2.0.0", + "unist-util-visit": "^5.0.0", + "zwitch": "^2.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-to-estree": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/hast-util-to-estree/-/hast-util-to-estree-3.1.3.tgz", @@ -12057,6 +12199,29 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-to-html": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/hast-util-to-html/-/hast-util-to-html-9.0.5.tgz", + "integrity": "sha512-OguPdidb+fbHQSU4Q4ZiLKnzWo8Wwsf5bZfbvu7//a9oTYoqD/fWpe96NuHkoS9h0ccGOTe0C4NGXdtS0iObOw==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "@types/unist": "^3.0.0", + "ccount": "^2.0.0", + "comma-separated-tokens": "^2.0.0", + "hast-util-whitespace": "^3.0.0", + "html-void-elements": "^3.0.0", + "mdast-util-to-hast": "^13.0.0", + "property-information": "^7.0.0", + "space-separated-tokens": "^2.0.0", + "stringify-entities": "^4.0.0", + "zwitch": "^2.0.4" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-to-jsx-runtime": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/hast-util-to-jsx-runtime/-/hast-util-to-jsx-runtime-2.3.6.tgz", @@ -12084,6 +12249,32 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-to-mdast": { + "version": "10.1.2", + "resolved": "https://registry.npmjs.org/hast-util-to-mdast/-/hast-util-to-mdast-10.1.2.tgz", + "integrity": "sha512-FiCRI7NmOvM4y+f5w32jPRzcxDIz+PUqDwEqn1A+1q2cdp3B8Gx7aVrXORdOKjMNDQsD1ogOr896+0jJHW1EFQ==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "@types/mdast": "^4.0.0", + "@ungap/structured-clone": "^1.0.0", + "hast-util-phrasing": "^3.0.0", + "hast-util-to-html": "^9.0.0", + "hast-util-to-text": "^4.0.0", + "hast-util-whitespace": "^3.0.0", + "mdast-util-phrasing": "^4.0.0", + "mdast-util-to-hast": "^13.0.0", + "mdast-util-to-string": "^4.0.0", + "rehype-minify-whitespace": "^6.0.0", + "trim-trailing-lines": "^2.0.0", + "unist-util-position": "^5.0.0", + "unist-util-visit": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-to-parse5": { "version": "8.0.1", "resolved": "https://registry.npmjs.org/hast-util-to-parse5/-/hast-util-to-parse5-8.0.1.tgz", @@ -12103,6 +12294,35 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-to-string": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/hast-util-to-string/-/hast-util-to-string-3.0.1.tgz", + "integrity": "sha512-XelQVTDWvqcl3axRfI0xSeoVKzyIFPwsAGSLIsKdJKQMXDYJS4WYrBNF/8J7RdhIcFI2BOHgAifggsvsxp/3+A==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/hast-util-to-text": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/hast-util-to-text/-/hast-util-to-text-4.0.2.tgz", + "integrity": "sha512-KK6y/BN8lbaq654j7JgBydev7wuNMcID54lkRav1P0CaE1e47P72AWWPiGKXTJU271ooYzcvTAn/Zt0REnvc7A==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "@types/unist": "^3.0.0", + "hast-util-is-element": "^3.0.0", + "unist-util-find-after": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/hast-util-whitespace": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/hast-util-whitespace/-/hast-util-whitespace-3.0.0.tgz", @@ -20201,6 +20421,35 @@ "regjsparser": "bin/parser" } }, + "node_modules/rehype-minify-whitespace": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/rehype-minify-whitespace/-/rehype-minify-whitespace-6.0.2.tgz", + "integrity": "sha512-Zk0pyQ06A3Lyxhe9vGtOtzz3Z0+qZ5+7icZ/PL/2x1SHPbKao5oB/g/rlc6BCTajqBb33JcOe71Ye1oFsuYbnw==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "hast-util-minify-whitespace": "^1.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/rehype-parse": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/rehype-parse/-/rehype-parse-9.0.1.tgz", + "integrity": "sha512-ksCzCD0Fgfh7trPDxr2rSylbwq9iYDkSn8TCDmEJ49ljEUBxDVCzCHv7QNzZOfODanX4+bWQ4WZqLCRWYLfhag==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "hast-util-from-html": "^2.0.0", + "unified": "^11.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/rehype-raw": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/rehype-raw/-/rehype-raw-7.0.0.tgz", @@ -20231,6 +20480,23 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/rehype-remark": { + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/rehype-remark/-/rehype-remark-10.0.1.tgz", + "integrity": "sha512-EmDndlb5NVwXGfUa4c9GPK+lXeItTilLhE6ADSaQuHr4JUlKw9MidzGzx4HpqZrNCt6vnHmEifXQiiA+CEnjYQ==", + "license": "MIT", + "dependencies": { + "@types/hast": "^3.0.0", + "@types/mdast": "^4.0.0", + "hast-util-to-mdast": "^10.0.0", + "unified": "^11.0.0", + "vfile": "^6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/relateurl": { "version": "0.2.7", "resolved": "https://registry.npmjs.org/relateurl/-/relateurl-0.2.7.tgz", @@ -21630,12 +21896,6 @@ "wbuf": "^1.7.3" } }, - "node_modules/sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", - "license": "BSD-3-Clause" - }, "node_modules/srcset": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/srcset/-/srcset-4.0.0.tgz", @@ -22344,6 +22604,16 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/trim-trailing-lines": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/trim-trailing-lines/-/trim-trailing-lines-2.1.0.tgz", + "integrity": "sha512-5UR5Biq4VlVOtzqkm2AZlgvSlDJtME46uV0br0gENbwN4l5+mMKT4b9gJKqWtuL2zAIqajGJGuvbCbcAJUZqBg==", + "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, "node_modules/trough": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/trough/-/trough-2.2.0.tgz", @@ -22656,6 +22926,20 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/unist-util-find-after": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/unist-util-find-after/-/unist-util-find-after-5.0.0.tgz", + "integrity": "sha512-amQa0Ep2m6hE2g72AugUItjbuM8X8cGQnFoHk0pGfrFeT9GZhzN5SW8nRsiGKK7Aif4CrACPENkA6P/Lw6fHGQ==", + "license": "MIT", + "dependencies": { + "@types/unist": "^3.0.0", + "unist-util-is": "^6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, "node_modules/unist-util-is": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-6.0.1.tgz", diff --git a/package.json b/package.json index b998cc10dc91..a7c8219faafd 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "prestart": "npm run gen-api-docs", "build": "docusaurus build", "prebuild": "npm run gen-api-docs", - "postbuild": "cp static/llms.txt build/llms.txt", + "postbuild": "node scripts/build-llms-header.mjs", "swizzle": "docusaurus swizzle", "clear": "docusaurus clear", "serve": "node serve.js", @@ -31,10 +31,10 @@ "@docusaurus/plugin-google-tag-manager": "^3.10.1", "@docusaurus/preset-classic": "^3.10.1", "@mdx-js/react": "^3.1.1", + "@signalwire/docusaurus-plugin-llms-txt": "^2.0.0-alpha.7", "ace-builds": "^1.44.0", "clsx": "^2.1.1", "docusaurus-plugin-image-zoom": "^3.0.1", - "docusaurus-plugin-llms-txt": "^0.1.3", "docusaurus-plugin-openapi-docs": "^5.0.2", "docusaurus-theme-openapi-docs": "^5.0.2", "prism-react-renderer": "^2.4.1", diff --git a/scripts/build-llms-header.mjs b/scripts/build-llms-header.mjs new file mode 100644 index 000000000000..91430d7ab72c --- /dev/null +++ b/scripts/build-llms-header.mjs @@ -0,0 +1,37 @@ +#!/usr/bin/env node +/** + * Replaces the auto-generated header of build/llms.txt (everything before the + * first "## " section) with the hand-curated content in static/llms.txt. + * + * Keeps the curated intro (title, rebranding table, products, getting started, + * frameworks, connectors) as the editable source of truth while letting the + * @signalwire/docusaurus-plugin-llms-txt plugin own the per-product sections. + */ +import fs from 'node:fs'; +import path from 'node:path'; + +const root = process.cwd(); +const headerPath = path.join(root, 'static', 'llms.txt'); +const generatedPath = path.join(root, 'build', 'llms.txt'); + +if (!fs.existsSync(headerPath)) { + console.error(`[build-llms-header] Missing curated header: ${headerPath}`); + process.exit(1); +} +if (!fs.existsSync(generatedPath)) { + console.error(`[build-llms-header] Missing generated file: ${generatedPath}`); + process.exit(1); +} + +const header = fs.readFileSync(headerPath, 'utf8').replace(/\s+$/, ''); +const generated = fs.readFileSync(generatedPath, 'utf8'); + +const firstSection = generated.search(/^## /m); +const sections = firstSection >= 0 ? generated.slice(firstSection) : generated; + +const combined = `${header}\n\n${sections}`; +fs.writeFileSync(generatedPath, combined); + +console.log( + `[build-llms-header] Wrote ${generatedPath} (${combined.length} bytes, header ${header.length} + sections ${sections.length})` +); From a3e5950a2d99ef30c28eb36f0b88469002b22486 Mon Sep 17 00:00:00 2001 From: Dan Coffey Date: Wed, 10 Jun 2026 22:15:01 -0400 Subject: [PATCH 5/5] formatting --- docusaurus.config.ts | 3 ++- scripts/build-llms-header.mjs | 4 +--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 54e63035991d..8543f5945f0b 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -464,7 +464,8 @@ const config: Config = { { id: 'ad-engine', name: 'OptiView Ad Engine', - description: 'Instant virtualized or just-in-time ad creative QC, conformance/transcoding, and packaging (mp4, mov, vast, hls). Includes Dolby Vision and Atmos encoding support.', + description: + 'Instant virtualized or just-in-time ad creative QC, conformance/transcoding, and packaging (mp4, mov, vast, hls). Includes Dolby Vision and Atmos encoding support.', position: 4, routes: [{ route: '/docs/ad-engine/**' }], }, diff --git a/scripts/build-llms-header.mjs b/scripts/build-llms-header.mjs index 91430d7ab72c..56998f222ff6 100644 --- a/scripts/build-llms-header.mjs +++ b/scripts/build-llms-header.mjs @@ -32,6 +32,4 @@ const sections = firstSection >= 0 ? generated.slice(firstSection) : generated; const combined = `${header}\n\n${sections}`; fs.writeFileSync(generatedPath, combined); -console.log( - `[build-llms-header] Wrote ${generatedPath} (${combined.length} bytes, header ${header.length} + sections ${sections.length})` -); +console.log(`[build-llms-header] Wrote ${generatedPath} (${combined.length} bytes, header ${header.length} + sections ${sections.length})`);