content-structure

A set of writing and page-structure rules for Linea documentation, covering the intended audience, tone, and organization of different documentation sections. Linea documentation includes pages for its network, software stack, protocol, APIs, and release history.

In plain words
What is it for?
Use it when creating or editing documentation to decide which section a page belongs to and how clearly or technically it should be written.
Why use it?
It helps authors choose the right level of technical detail and keep pages consistent with the section and readers they serve.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/consensys/doc.linea/content-structure
Clone the repo
git clone --depth 1 https://github.com/Consensys/doc.linea

Made for: Cursor.

Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 721 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00721
Opus 5 $0.00000 $0.00360
Sonnet 5 $0.00000 $0.00144
Haiku 4.5 $0.00000 $0.00072

Measured 2d ago against content hash 917223ff0f85, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

content-structure scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/content-structure.mdc · 89 lines

How it starts

The opening of the file, as written. The whole thing — 89 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Content structure

Identify the tab and audience first

Before writing or editing a page, identify which tab it belongs to (see the tab-to-directory table in README.mdx) and match the tone expected for that tab's primary audience:

Tab Primary audience Tone
Linea Mainnet (docs/network) End users and app builders Clear and accessible. Developer-focused sections can go deeper.
Lineth Stack (docs/stack) Appchain builders, enterprise operators Technical but applied. Operational and integration focus.
Protocol (docs/protocol) Software architects, institutional evaluators Deep technical. Internals and architecture are expected.
Reference (docs/api) Developers Code-first and reference-style. Practical.
Changelog (docs/changelog) All of the above Factual, dated, scoped to what shipped.

A page can serve more than one audience. If two audiences need substantially different content, consider proposing a split into two pages instead of one page trying to serve both. If you keep one page, lead with the simpler content and put advanced material later or in a separate section. Don't assume deep protocol knowledge on a Linea Mainnet page.

Page structure

A typical concept or feature page follows this shape:

---
title: [Short, descriptive: matches the URL slug]
description: [One sentence: what is this, why does it matter, who cares]
---

[One to two sentence opening: the big picture. No heading.]

## What it is
## Why it matters
## What changes (if relevant)
## Code samples (verified, near the bottom)
## Resources

Adapt the specific headings to the page's content type (a how-to guide uses numbered steps and prerequisites instead; a reference page mirrors the API or CLI it documents). Match the structure of existing neighboring pages in the same section before inventing a new shape.

Writing order: identify the tab and audience, draft the H2 headings first (check that they tell the full story on their own), then write the opening sentence, then fill in prose, then add code samples last.

Read the full file on GitHub · 89 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 89 lines · 0 tokens per session scan A 917223ff0f85

Subscribe to this mod's changes

content-structure is a cursor rule published in the GitHub repository Consensys/doc.linea (474 stars, last pushed 5d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 721 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.