> For the complete documentation index, see [llms.txt](https://support.backpack.exchange/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.backpack.exchange/support-docs/cn/jiao-yi-suo/jiao-yi/jiao-yi-ji-qi-ren/he-yue-wang-ge.md).

# 合约网格

## 网格方向（仅限永续合约）

每个网格均可设置方向偏好：

* 中性（默认）\
  标准网格行为——低买高卖，无方向偏好
* 做多（Long）\
  启动时在所有层级买入 → 建立多头敞口 → 随后以多头偏向运行网格（低买高卖）
* 做空（Short）\
  启动时在所有层级卖出 → 建立空头敞口 → 随后以空头偏向运行网格（低买高卖）

更改方向将触发**部分重置**：

* 敞口和盈亏保持不变
* 订单重新计算

## 向上追踪与向下追踪

追踪功能会在价格突破网格范围时自动移动网格区间。

#### **工作原理**

当价格超出范围超过一个网格步长时：

* 整个范围向该方向移动
* 向上和向下方向均适用相同逻辑

#### **边界设置**

* 上界：向上追踪（Trailing Up）
* 下界：向下追踪（Trailing Down）

#### **示例**

* 初始范围：\[90, 110]，网格步长为 2
* 向上追踪：130
* 价格 → 120 → 新范围：\[100, 120]
* 价格 → 135 → 上限封顶于 \[110, 130]

#### **校验规则**

* 向下追踪必须至少低于价格下限（Price Lower Limit）一个网格步长
* 向上追踪必须至少高于价格上限（Price Upper Limit）一个网格步长
* 如果设置了价格止停：
  * 下限止停（Lower Stop）必须低于向下追踪
  * 上限止停（Upper Stop）必须高于向上追踪


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://support.backpack.exchange/support-docs/cn/jiao-yi-suo/jiao-yi/jiao-yi-ji-qi-ren/he-yue-wang-ge.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
