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

# 架构总览

> BlockX 如何连接输入、运行时读取和输出，执行 EVM 派生计算。

BlockX 将 EVM 数据语义连接到任务执行系统。Call Builder 选择输入，Python Executor 运行用户函数，Worker IO 路由依赖读取，Writer Plugin 提交派生输出。

## 职责与数据路径

```mermaid theme={null}
flowchart LR
    client["调用方：链、区块与任务配置"] --> worker["Worker"]
    client --> coordinator["Coordinator：预占容量"]
    coordinator --> worker
    worker --> builder["Call Builder"]
    builder --> executor["Python Executor"]
    executor --> writer["Writer Plugin"]
    builder --> io["Worker IO"]
    executor --> io
    writer --> io
    io --> db["BlockDB：输入与派生记录"]
    io --> evm["EVM 节点：状态读取与合约查询"]
```

调用方提供预期的输入与输出上下文。函数显式选择 EVM 读取所需的链与区块。BlockDB 处理数据存储，节点能力执行合约查询，BlockX 调度并运行外围函数计算。

## 执行流程

1. 调用方通过 Coordinator 预占容量，或直接向 Worker 提交。
2. Worker 受理任务并激活执行上下文。
3. Call Builder 读取或展开配置的输入，生成函数调用。
4. Python Executor 运行函数，后端操作经 Worker IO 处理。
5. Writer Plugin 处理收集到的输出，Worker 记录终态结果。

处理大量 bundle 输入时，调用生产与执行可以重叠。输出阶段仍在收集计算结果之后执行。[Task 生命周期](/zh/architecture/task-lifecycle)说明状态转换。

## 组件索引

| 职责 | 组件 |
| - | - |
| 资源选址 | [Coordinator](/zh/components/coordinator) |
| 任务状态与准入 | [Worker](/zh/components/worker) |
| Call 调度 | [Call 执行子系统](/zh/components/call-execution) |
| 函数定义与版本 | [Function Code View](/zh/components/function-code) |
| 表与 EVM 读取路由 | [IO 访问子系统](/zh/components/io-subsystem)、[后端适配器](/zh/components/backend-adapter) |
| 输入输出扩展 | [Plugin 系统](/zh/components/plugins) |
| Python 函数执行 | [Python Executor](/zh/components/python-executor) |
| 单次调用请求与响应 | [Sync Invoker](/zh/components/sync-invoker) |
| 历史输入与批量写入 | [Bundle 集群](/zh/components/bundle) |
| 诊断 | [可观测性](/zh/components/observability) |

## 完成边界

Worker 报告任务的结果处理状态。区块写入异步提交，bundle 写入在 BatchWrite 提交后返回。下游消费者单独检查存储就绪条件。共同契约见[执行语义](/zh/concepts/execution-semantics)。

## 贡献者阅读顺序

* 在[仓库结构](/zh/architecture/repository-layout)中找到相关模块。
* 阅读[设计原则](/zh/architecture/design-principles)与组件边界。
* 遵循[测试](/zh/development/testing)和[贡献流程](/zh/development/contributing)。

理解产品词汇从 [EVM 计算模型](/zh/concepts/evm-computation)开始，查询请求字段使用[服务 API](/zh/reference/service-api)。


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.