### Local Development Setup
Source: https://github.com/llm-d/llm-d.github.io/blob/main/CONTRIBUTING.md
Steps to set up the project locally for development, including cloning, installing dependencies, and starting the development server.
```bash
git clone https://github.com/YOUR-USERNAME/llm-d.github.io.git
cd llm-d.github.io
npm install
```
```bash
npm start
```
```bash
git add .
git commit -s -m "docs: your change description"
git push origin docs/your-change-description
```
--------------------------------
### Install and Start Local Development Server
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/README.md
Installs project dependencies and starts a local development server for previewing documentation changes.
```bash
npm install
npm start
```
--------------------------------
### Start Local Development Server
Source: https://github.com/llm-d/llm-d.github.io/blob/main/CONTRIBUTING.md
Run this command to start the local development server. It opens a browser with live reload, reflecting most changes immediately.
```bash
npm start
```
--------------------------------
### Install Project Dependencies
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Run this command to install all necessary Node.js dependencies for the project.
```bash
npm install
```
--------------------------------
### Run Link Checker Commands
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Build the site and then run the link checker. The checker starts a local server, crawls pages, checks links, generates a report, and stops the server.
```bash
# 1. Build the site first
npm run build:all
# 2. Run the link checker
npm run check-links
```
--------------------------------
### Custom Tabs with Bash Example
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/scripts/test-fixtures/transformation-test.md
Demonstrates the transformation of custom tabs, including a default tab with a bash code block.
```bash
echo "First tab code block"
```
--------------------------------
### Nested Content in Tabs: Google GKE Example
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/scripts/test-fixtures/transformation-test.md
Shows a bash command within the Google GKE tab, demonstrating nested content transformation.
```bash
gcloud container clusters create my-cluster
```
--------------------------------
### Single Tab Example
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/scripts/test-fixtures/transformation-test.expected.md
Illustrates a Tabs component with a single tab. This tests the rendering of a minimal tab configuration.
```jsx
This is the only tab.
```
--------------------------------
### Empty Tab Example
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/scripts/test-fixtures/transformation-test.expected.md
Demonstrates an empty tab within a Tabs component. This tests how the system handles tabs with no content.
```jsx
```
--------------------------------
### Install llm-d Skills for AI Coding Agents
Source: https://github.com/llm-d/llm-d.github.io/blob/main/blog/2026-06-23_networking-for-distributed-inference-llm-d.md
Clone the llm-d-pd-utils repository and copy the skills into your AI agent's skill directory to enable functionalities like running preflight checks and networking tests.
```bash
AGENT_SKILLS_DIR=~/.claude/skills/
git clone https://github.com/llm-d/llm-d-pd-utils.git /tmp/llmd-skills-repo
cp -r /tmp/llmd-skills-repo/skills/* $AGENT_SKILLS_DIR
rm -rf /tmp/llmd-skills-repo
```
--------------------------------
### Get Session Start Epoch Time
Source: https://github.com/llm-d/llm-d.github.io/blob/main/community/events.md
This JavaScript function parses date and time strings from session data to calculate the session's start time as an epoch timestamp. It handles various date and time formats and returns a large integer if parsing fails.
```javascript
const getSessionStartEpoch = (s) => {
try {
const monthMap = {
Jan: 0, Feb: 1, Mar: 2, Apr: 3, May: 4, Jun: 5,
Jul: 6, Aug: 7, Sep: 8, Oct: 9, Nov: 10, Dec: 11,
};
const dateText = String(s.date || '');
const timeText = String(s.time || '');
const dateMatch = dateText.match(/([A-Za-z]{3})\\\s+(\\\d{1,2}),\\s*(\\\d{4})/);
if (!dateMatch) return Number.MAX_SAFE_INTEGER;
const monthIdx = monthMap[dateMatch[1]];
const day = parseInt(dateMatch[2], 10);
const year = parseInt(dateMatch[3], 10);
const timeMatch = timeText.match(/(\\\d{1,2})(?::(\\\d{2}))?\\\s*(am|pm)/i);
const hour12 = timeMatch ? parseInt(timeMatch[1] || '0', 10) : 0;
const minute = timeMatch && timeMatch[2] ? parseInt(timeMatch[2], 10) : 0;
const meridiem = timeMatch ? (timeMatch[3] || '').toLowerCase() : 'am';
let hour24 = hour12 % 12;
if (meridiem === 'pm') hour24 += 12;
```
--------------------------------
### Local Testing Workflow: Build and Serve
Source: https://github.com/llm-d/llm-d.github.io/blob/main/scripts/README.md
This command builds the entire site and serves it locally for testing. Open your browser to http://localhost:3000 for the main site and http://localhost:3000/docs for the docs site.
```bash
npm run serve:production
```
--------------------------------
### Build Documentation with Local Clone and Fetch Latest
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/README.md
Builds documentation using a local llm-d clone, pulling the latest changes from the origin before building.
```bash
# Use local clone but pull latest from origin first
LLMD_REPO=~/repos/llm-d LLMD_FETCH=1 npm run build:all
```
--------------------------------
### Link Checker Report Example
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
An example of the broken links report format. It lists broken links grouped by source page, indicating the type of issue and the repository to fix.
```markdown
### /videos
**Source:** Local (this repository)
- 🔗 `/docs/guide` → **HTTP 404** (link)
```
--------------------------------
### Sync Documentation and Build
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Syncs documentation from the llm-d repository and then builds the project. This is an alternative to `build:all` when you want to sync separately before building.
```bash
# Or sync only, then build
cd preview
LLMD_REPO=~/repos/llm-d bash scripts/sync-docs.sh
npm run build
```
--------------------------------
### Build All Content for Full Site Preview
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Builds the entire site, including all synced documentation from the llm-d GitHub repository. This command clones the repository if LLMD_REPO is not set.
```bash
npm run build:all
```
--------------------------------
### Perform Full Project Build
Source: https://github.com/llm-d/llm-d.github.io/blob/main/CONTRIBUTING.md
Execute this command to generate static content into the `build` directory. This command tests the complete build process, including the main site, preview docs sync, and merging.
```bash
npm run build
```
--------------------------------
### Build All Project Assets
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Builds all project assets, including documentation, using a local clone of the llm-d repository. This is recommended for testing sync scripts without network access.
```bash
# Using a local llm-d clone (recommended — no network required)
LLMD_REPO=~/repos/llm-d npm run build:all
```
--------------------------------
### Send SLO-Aware Request to Inference Gateway
Source: https://github.com/llm-d/llm-d.github.io/blob/main/blog/2026-03-13_predicted-latency-based-scheduling-for-llms.md
Send a completion request to the Inference Gateway with custom headers for prediction-based scheduling and SLOs. This example demonstrates how to set time-to-first-byte (TTFT) and time-to-process-all-output (TPOT) targets.
```bash
curl -v $GW_IP/v1/completions \
-H 'Content-Type: application/json' \
-H 'x-prediction-based-scheduling: true' \
-H 'x-slo-ttft-ms: 200' \
-H 'x-slo-tpot-ms: 50' \
-d '{
"model": "Qwen/Qwen3-32B",
"prompt": "what is the difference between Franz and Apache Kafka?",
"max_tokens": 200,
"temperature": 0,
"stream_options": {"include_usage": "true"},
"stream": "true"
}'
```
--------------------------------
### Build Documentation with Local llm-d Clone
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/README.md
Builds documentation using a local clone of the llm-d repository, which is faster and does not require a network connection.
```bash
# Use a local llm-d clone (fast, no network required)
LLMD_REPO=~/repos/llm-d npm run build:all
```
--------------------------------
### Sync Documentation Only
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/README.md
Syncs documentation from the upstream llm-d repository without performing a full build. Run this command from the preview/ directory.
```bash
# From the preview/ directory
LLMD_REPO=~/repos/llm-d bash scripts/sync-docs.sh
```
--------------------------------
### Nested Content in Tabs: AWS EKS Example
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/scripts/test-fixtures/transformation-test.md
Illustrates nested markdown elements within tabs, specifically a YAML code block, link, and note callout within the AWS EKS tab.
```yaml
apiVersion: v1
kind: Service
metadata:
name: test-service
```
--------------------------------
### Configure Container Startup with Preflight Checks
Source: https://github.com/llm-d/llm-d.github.io/blob/main/blog/2026-06-23_networking-for-distributed-inference-llm-d.md
Modify the container's startup arguments to include a preflight check script that runs before vLLM. The `&&` operator ensures that `vllm serve` only executes if the preflight checks pass.
```yaml
containers:
- args:
- "... python3 llm-d-preflight-checks.py && vllm serve /model-cache/models/…"
```
--------------------------------
### Set Environment Variable to Pause Execution for Complex Tests
Source: https://github.com/llm-d/llm-d.github.io/blob/main/blog/2026-06-23_networking-for-distributed-inference-llm-d.md
Use the `LLMD_PREFLIGHT_CHECKS` environment variable set to `pause` to halt execution before vLLM starts, allowing for more complex networking tests with full GPU memory availability.
```yaml
env:
- name: LLMD_PREFLIGHT_CHECKS
value: pause
```
--------------------------------
### Build All Content Using Local llm-d Clone with Fetch
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Builds the entire site using a local clone of the llm-d repository and fetches the latest changes from origin first. Set LLMD_REPO to the local path and LLMD_FETCH to 1.
```bash
LLMD_REPO=~/repos/llm-d LLMD_FETCH=1 npm run build:all
```
--------------------------------
### Create Version Snapshot Script
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/VERSIONING.md
Execute this script in the 'preview' directory to create a new version snapshot. This syncs documentation from the release branch and updates versioning files.
```bash
cd preview
./scripts/create-version.sh 0.7
```
--------------------------------
### Build All Documentation from Upstream Repo
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/README.md
Builds all documentation, syncing from the upstream llm-d repository. This is suitable for CI/production environments.
```bash
# Clone from GitHub and build everything (CI/production)
npm run build:all
```
--------------------------------
### Commit and Deploy Documentation Changes
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/VERSIONING.md
After updating the configuration and creating the version snapshot, stage, commit, and push the changes to deploy the new documentation version.
```bash
git add versioned_docs/ versioned_sidebars/ versions.json preview/docusaurus.config.ts
git commit -m "Add v0.7 documentation version"
git push
```
--------------------------------
### Build All Content Using Local llm-d Clone
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Builds the entire site using a local clone of the llm-d repository, skipping network operations. Set the LLMD_REPO environment variable to the path of your local clone.
```bash
LLMD_REPO=~/repos/llm-d npm run build:all
```
--------------------------------
### Troubleshooting: Sync Docs Manually
Source: https://github.com/llm-d/llm-d.github.io/blob/main/scripts/README.md
To resolve issues with stale docs content or build failures in the preview step, you can manually sync the docs. Navigate to the preview directory and run the sync script.
```bash
cd preview && bash scripts/sync-docs.sh main
```
--------------------------------
### Serve the Built Site
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Serves the static site that has been generated by the build process. This is typically used after running a build command.
```bash
npm run serve
```
--------------------------------
### Run Create Release Branch Workflow
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/RELEASE-BRANCH-SYNC.md
Manually trigger the creation of a new release branch for documentation. Specify the full version number and the source branch from the main llm-d repository.
```bash
gh workflow run create-release-branch.yml \
--repo llm-d/llm-d.github.io \
--field version=0.7.0 \
--field source_branch=release-0.7
```
--------------------------------
### Create Additional Version Snapshots
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/VERSIONING.md
To create snapshots for older versions (e.g., 0.6, 0.5), ensure the corresponding release branches exist in the main repository and then run the 'create-version.sh' script with the desired version number.
```bash
# Requires release-0.6, release-0.5 branches in llm-d/llm-d
./scripts/create-version.sh 0.6
./scripts/create-version.sh 0.5
```
--------------------------------
### Create Remote Source Configuration
Source: https://github.com/llm-d/llm-d.github.io/blob/main/CONTRIBUTING.md
Define a new JavaScript configuration file for community content, specifying source URL, output directory, and content transformation.
```javascript
import { createContentWithSource, createStandardTransform, getLlmdRepoConfig } from '../utils.js';
const { sourceBaseUrl } = getLlmdRepoConfig();
const contentTransform = createStandardTransform();
export default [
'docusaurus-plugin-remote-content',
{
name: 'governance',
sourceBaseUrl,
outDir: 'community',
documents: ['GOVERNANCE.md'],
noRuntimeDownloads: false,
performCleanup: true,
modifyContent(filename, content) {
if (filename === 'GOVERNANCE.md') {
return createContentWithSource({
title: 'Project Governance',
description: 'Governance structure for the llm-d project',
sidebarLabel: 'Governance',
sidebarPosition: 6,
filename: 'GOVERNANCE.md',
newFilename: 'governance.md',
content,
contentTransform
});
}
return undefined;
},
},
];
```
--------------------------------
### Run Transformation Tests
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/scripts/test-fixtures/README.md
Execute the transformation tests from the root or preview directory. These commands are used to verify the markdown transformation scripts.
```bash
# From root directory
npm run test:transformations
# Or from preview directory
cd preview && npm run test:transformations
# Run all tests (Jest + transformations)
npm test
```
--------------------------------
### List Sync Release Docs Workflow Runs
Source: https://github.com/llm-d/llm-d.github.io/blob/main/preview/RELEASE-BRANCH-SYNC.md
Check the logs for the sync-release-docs.yml workflow to troubleshoot sync failures. This command lists recent runs of the specified workflow for the llm-d/llm-d.github.io repository.
```bash
gh run list --workflow=sync-release-docs.yml --repo llm-d/llm-d.github.io
```
--------------------------------
### JavaScript Configuration for Contributing File
Source: https://github.com/llm-d/llm-d.github.io/blob/main/README.md
Configuration file for syncing the CONTRIBUTING.md file from the main repository to the website's community documentation section.
```javascript
remote-content/remote-sources/community/contribute.js
```