> ## Documentation Index
> Fetch the complete documentation index at: https://docs.leafage.chaintable.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Leafage

> Leafage architecture and component documentation: a project guide for developers and AI agents

Leafage splits a monolithic EVM full node into a distributed pipeline: **one** write node handles P2P sync and block execution, execution data is distributed through Kafka + S3 to **any number** of lightweight query nodes, and structured block data (transactions, call traces, event logs) is delivered to external consumers at the same time.

Query capacity therefore scales horizontally: adding a query node needs only \~90GB of disk and a snapshot restore that takes minutes, instead of 1.3TB+ of disk and hours of full-chain sync.

## The five components

| Component                                                 | Language | Role                                                                           | Repository                                                                          |
| --------------------------------------------------------- | -------- | ------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------- |
| [Write node](/en/components/go-ethereum-x)                | Go       | Execution client + pipeline integration, exports execution data                | [Chaintable/go-ethereum](https://github.com/Chaintable/go-ethereum)                 |
| [pipeline](/en/components/pipeline)                       | Go       | Tracing and distribution library embedded in the write node, writes S3 + Kafka | [Chaintable/pipeline](https://github.com/Chaintable/pipeline)                       |
| [leafage-evm](/en/components/leafage-evm)                 | Rust     | Lightweight EVM executor, consumes state changes and serves RPC queries        | [Chaintable/leafage-evm](https://github.com/Chaintable/leafage-evm)                 |
| [consistency-checker](/en/components/consistency-checker) | Go       | Checks replica consistency, marks forks, maintains node state in etcd          | [Chaintable/consistency-checker](https://github.com/Chaintable/consistency-checker) |
| [nodex-proxy](/en/components/nodex-proxy)                 | Go       | JSON-RPC gateway: service discovery, routing, load balancing                   | [Chaintable/nodex-proxy](https://github.com/Chaintable/nodex-proxy)                 |

## Where to start

<Columns cols={2}>
  <Card title="Core concepts" icon="book-open" href="/en/concepts/overview">
    What Leafage is, the role of each of the five components, and the terms used across this site.
  </Card>

  <Card title="Architecture overview" icon="layers" href="/en/architecture/overview">
    Component responsibilities, runtime topology, and the split between data plane and control plane.
  </Card>

  <Card title="Data flow" icon="git-branch" href="/en/architecture/data-flow">
    The full path of a block from execution to queryable, including reorg and catch-up.
  </Card>

  <Card title="Interface contracts" icon="plug" href="/en/architecture/interfaces">
    Exact definitions of Kafka topics, S3 keys, the etcd key space, and RPC conventions.
  </Card>

  <Card title="Sending RPC requests" icon="send" href="/en/guides/rpc-requests">
    Endpoints, request headers, and copy-and-paste examples for `eth_call`, batch calls, and `blockCtx`.
  </Card>

  <Card title="Contributing" icon="git-pull-request" href="/en/guides/contributing">
    Repository map, build and test commands, commit conventions, and where to start contributing.
  </Card>
</Columns>

## Suggested reading order

<Steps>
  <Step title="Start with the core concepts">
    One page to learn what Leafage is and the terms used across this site: write node, query node, state diff, block context.
  </Step>

  <Step title="Then read the architecture overview">
    Learn why the full node is split and which segment each of the five components owns.
  </Step>

  <Step title="Next, read the data flow">
    Follow one block end to end; this is the shortest path to understanding how the components work together.
  </Step>

  <Step title="Read component docs as needed">
    Each component page covers the directory layout, key mechanisms, configuration, and code entry points, so you can go straight to the source files.
  </Step>

  <Step title="Read the interface contracts before making changes">
    When you change cross-component behavior, Kafka messages, S3 keys, and etcd keys are the parts that must stay compatible.
  </Step>
</Steps>

<Note>
  This site describes the current `main` branch implementation of each repository. The component repositories also contain more detailed design documents (such as leafage-evm's `docs/StateManage.md` and pipeline's `docs/protocol.md`); this site links to them in the relevant sections.
</Note>
