# Rust SDK

## Workspace 结构

`baby-modules/Cargo.toml` workspace：

| Crate                       | 用途                                   |
| --------------------------- | ------------------------------------ |
| baby-pob-aggregator         | Merkle batch + ECDSA sign + 上链       |
| baby-pob-challenger         | Fraud detector + auto-open challenge |
| baby-pod-aggregator         | Receipt 提交                           |
| baby-explanation            | SLM stub explainer                   |
| baby-opa-policy             | Rego DSL evaluator                   |
| baby-zkml                   | Halo2 stub                           |
| baby-tee-attestor           | DCAP stub                            |
| baby-behavior-spec          | DSL parser                           |
| baby-credit-score           | 5-dim CSDRT                          |
| baby-bridge-enhancer        | L1↔L2 helper                         |
| baby-oracle-wiring          | Sequencer integration                |
| baby-oracle-system-contract | system contract impl                 |
| baby-did-circuits           | 6 Circom 电路                          |

## 依赖

* alloy 0.8.x — Ethereum client (rustls-webpki upgraded to 0.103.13, 0 CVE)
* tokio 1.x — async runtime
* serde 1.x — serialization
* ethers-core 2.x (legacy paths)

## 跑测试

```bash
cd baby-modules
cargo test --workspace
# 多 workspace 全绿
```

## 0 CVE

post commit `f57c7da`，`cargo audit` 0 vulnerabilities。详见 [Dependency Audit](https://github.com/leeleeEcho/babyDriver_Layer2/blob/main/docs/audit/dependency-audit-2026-05-07.md)。


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://yellowpaper.axblade.io/integration-jie-ru-fang-shi/sdk-rust.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
