diff --git a/.github/workflows/docs-deploy.yml b/.github/workflows/docs-deploy.yml
index 3ee40461ea..c10a7053f5 100644
--- a/.github/workflows/docs-deploy.yml
+++ b/.github/workflows/docs-deploy.yml
@@ -23,6 +23,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+ with:
+ fetch-depth: 0
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v6.0.0
with:
node-version-file: docs/.nvmrc
diff --git a/.github/workflows/docs-test.yml b/.github/workflows/docs-test.yml
index fb979e421f..27b25731a1 100644
--- a/.github/workflows/docs-test.yml
+++ b/.github/workflows/docs-test.yml
@@ -15,6 +15,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+ with:
+ fetch-depth: 0
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v6.0.0
with:
node-version-file: docs/.nvmrc
diff --git a/docs/docs/configuring.md b/docs/docs/configuring.md
index 4fdb805609..6d19b51c52 100644
--- a/docs/docs/configuring.md
+++ b/docs/docs/configuring.md
@@ -1,5 +1,6 @@
---
title: Configuration
+description: "Juno's configuration options, settable by flag, environment variable, or YAML file, with defaults."
---
# Configuring Juno
diff --git a/docs/docs/faq.md b/docs/docs/faq.md
index ca688e100e..530a62e357 100644
--- a/docs/docs/faq.md
+++ b/docs/docs/faq.md
@@ -1,5 +1,6 @@
---
title: FAQ
+description: "Answers to common Juno questions: requirements, updating, databases, and frequent startup errors."
---
# Frequently Asked Questions
diff --git a/docs/docs/hardware-requirements.md b/docs/docs/hardware-requirements.md
index 395b69aeb1..ad102d29b4 100644
--- a/docs/docs/hardware-requirements.md
+++ b/docs/docs/hardware-requirements.md
@@ -1,5 +1,6 @@
---
title: Hardware Requirements
+description: "CPU, memory and storage needed to run Juno, for validators and dApps or as a high-traffic RPC provider."
---
# Hardware Requirements
diff --git a/docs/docs/intro.md b/docs/docs/intro.md
index fa6b914ee6..83544de729 100644
--- a/docs/docs/intro.md
+++ b/docs/docs/intro.md
@@ -1,6 +1,7 @@
---
slug: /
title: Introduction
+description: "What Juno is and where to start: hardware, running a node, snapshots, configuration, and the JSON-RPC interface."
---
# Welcome to Juno
diff --git a/docs/docs/json-rpc.md b/docs/docs/json-rpc.md
index bb5e9128ff..8bedb7d4ba 100644
--- a/docs/docs/json-rpc.md
+++ b/docs/docs/json-rpc.md
@@ -1,5 +1,6 @@
---
title: JSON-RPC
+description: "Call Juno over JSON-RPC: supported spec versions, endpoint paths, and example requests."
---
# JSON-RPC Interface
diff --git a/docs/docs/monitoring.md b/docs/docs/monitoring.md
index 3e39a6e333..50cebe4571 100644
--- a/docs/docs/monitoring.md
+++ b/docs/docs/monitoring.md
@@ -1,5 +1,6 @@
---
title: Monitoring
+description: "Monitor a Juno node with Prometheus metrics, Grafana, and the /live and /ready readiness endpoints."
---
# Metrics Monitoring
diff --git a/docs/docs/plugins.md b/docs/docs/plugins.md
index 2afdf9ba84..0719250e9c 100644
--- a/docs/docs/plugins.md
+++ b/docs/docs/plugins.md
@@ -1,5 +1,6 @@
---
title: Plugins
+description: "Extend Juno with Go plugins that receive new and reverted blocks through the JunoPlugin interface."
---
Juno supports plugins that satisfy the `JunoPlugin` interface, enabling developers to extend and customize Juno's behaviour and functionality by dynamically loading external plugins during runtime.
diff --git a/docs/docs/running-juno.md b/docs/docs/running-juno.md
index 3859551b07..1c428faef4 100644
--- a/docs/docs/running-juno.md
+++ b/docs/docs/running-juno.md
@@ -1,5 +1,6 @@
---
title: Installation
+description: "Start a Juno node with Docker, a prebuilt binary, or a source build, on mainnet or Sepolia."
---
# Running Juno
diff --git a/docs/docs/running-on-gcp.md b/docs/docs/running-on-gcp.md
index 7969c4e0c9..253c6d7ced 100644
--- a/docs/docs/running-on-gcp.md
+++ b/docs/docs/running-on-gcp.md
@@ -1,5 +1,6 @@
---
title: GCP
+description: "Run a Juno node on Google Cloud Platform."
---
# Running Juno on GCP
diff --git a/docs/docs/running-on-kubernetes.md b/docs/docs/running-on-kubernetes.md
index 5d553b1226..e004b2784b 100644
--- a/docs/docs/running-on-kubernetes.md
+++ b/docs/docs/running-on-kubernetes.md
@@ -1,5 +1,6 @@
---
title: Kubernetes
+description: "Deploy Juno on Kubernetes with the official Helm chart."
---
# Running Juno on Kubernetes
diff --git a/docs/docs/running-p2p.md b/docs/docs/running-p2p.md
index e78ec3a557..5a3e436de2 100644
--- a/docs/docs/running-p2p.md
+++ b/docs/docs/running-p2p.md
@@ -1,5 +1,6 @@
---
title: Running a Juno P2P Node
+description: "Run Juno's experimental peer-to-peer synchronisation."
---
# Running a Juno P2P Node
diff --git a/docs/docs/sequencer.md b/docs/docs/sequencer.md
index 3bd6cb1555..4658e76864 100644
--- a/docs/docs/sequencer.md
+++ b/docs/docs/sequencer.md
@@ -1,5 +1,6 @@
---
title: Juno Sequencer
+description: "Run Juno in experimental sequencer mode to build blocks on a custom network."
---
Juno can now operate as a **standalone sequencer**. When Juno is run in this experimental mode, users are able to submit transactions to the Juno client, which stores them in a mempool. Every _N_ seconds, Juno will attempt to build a new block using any transactions that are present.
diff --git a/docs/docs/snapshots.md b/docs/docs/snapshots.md
index 1f11a9b0b8..cb461067d5 100644
--- a/docs/docs/snapshots.md
+++ b/docs/docs/snapshots.md
@@ -1,5 +1,6 @@
---
title: Snapshot Sync
+description: "Download a database snapshot and start from a recent block instead of syncing from genesis, with sizes and commands per network."
---
# Sync from a Snapshot
diff --git a/docs/docs/staking-validator.md b/docs/docs/staking-validator.md
index 1daf4f8ba1..11b2afe3d7 100644
--- a/docs/docs/staking-validator.md
+++ b/docs/docs/staking-validator.md
@@ -1,5 +1,6 @@
---
title: Starknet Staking
+description: "Prerequisites and setup for using a Juno node as a Starknet staking validator."
---
# Staking with Juno
diff --git a/docs/docs/tuning.md b/docs/docs/tuning.md
index c1df68714d..c7b22c1424 100644
--- a/docs/docs/tuning.md
+++ b/docs/docs/tuning.md
@@ -1,5 +1,6 @@
---
title: Performance Tuning
+description: "Tune Juno's database and compilation settings for faster sync and lower resource use."
---
It is important for full nodes to scale accordingly to the hardware where they are being executed. To unlock this, the following are a list of configurations users can update based on their hardware specs to maximize the performance of their Juno node.
diff --git a/docs/docs/updating.md b/docs/docs/updating.md
index 7e381e297c..acd87a7901 100644
--- a/docs/docs/updating.md
+++ b/docs/docs/updating.md
@@ -1,5 +1,6 @@
---
title: Updating
+description: "Update a Juno node to a new release with Docker, a prebuilt binary, or from source."
---
# Updating Juno
diff --git a/docs/docs/websocket.md b/docs/docs/websocket.md
index 3f2c47f8ae..6260df5b5a 100644
--- a/docs/docs/websocket.md
+++ b/docs/docs/websocket.md
@@ -1,5 +1,6 @@
---
title: WebSockets
+description: "Subscribe to new blocks, events and transaction status over Juno's WebSocket interface."
---
# WebSocket Interface
diff --git a/docs/docusaurus.config.js b/docs/docusaurus.config.js
index 4c8e1d8b5f..6b116aecb8 100644
--- a/docs/docusaurus.config.js
+++ b/docs/docusaurus.config.js
@@ -47,6 +47,10 @@ const config = {
docs: {
sidebarPath: require.resolve("./sidebars.js"),
routeBasePath: "/",
+ // Edit links point at docs/ (next) so fixes land where they flow forward.
+ editUrl: "https://github.com/NethermindEth/juno/edit/main/docs/",
+ editCurrentVersion: true,
+ showLastUpdateTime: true,
},
blog: false,
theme: {
@@ -57,6 +61,7 @@ const config = {
],
plugins: [
+ require.resolve("./plugins/llms-txt.js"),
[
"@easyops-cn/docusaurus-search-local",
{
diff --git a/docs/plugins/llms-txt.js b/docs/plugins/llms-txt.js
new file mode 100644
index 0000000000..54c17a2a6f
--- /dev/null
+++ b/docs/plugins/llms-txt.js
@@ -0,0 +1,151 @@
+// Emits /llms.txt, /llms-full.txt and a raw .md route beside every page, on every build,
+// generated from the version the site root serves (versions.json[0]), never from next.
+
+const fs = require("fs");
+const path = require("path");
+
+// Strip MDX plumbing (imports, mdx-code-block fences) so agents get plain markdown.
+// dir is the page's directory, used to inline any local partial it renders.
+function cleanBody(body, dir) {
+ // Inline local partials: `import X from "./_p.md"` + `` becomes the
+ // partial's content, so a page's real table isn't left as a dangling tag.
+ if (dir) {
+ const partials = {};
+ for (const m of body.matchAll(/^import\s+(\w+)\s+from\s+["'](\.\/[\w./-]+\.md)["']/gm)) {
+ const f = path.join(dir, m[2]);
+ if (fs.existsSync(f)) partials[m[1]] = readPage(f).body;
+ }
+ for (const [name, pbody] of Object.entries(partials)) {
+ body = body.replace(new RegExp(`<${name}\\s*/>`, "g"), "\n" + pbody.trim() + "\n");
+ }
+ }
+ // Tabs are presentation only; unwrap TabItems to "###