# BehaviorSpecRegistry — 行为规范确权

## 设计

* 任何 EOA 可注册 BehaviorSpec hash + 元数据
* publisher = msg.sender，永久不可改
* 引用 policyHash 形成 spec → policy 链
* deactivate 不删历史

## 接口

```solidity
function registerSpec(bytes32 specHash, bytes32 policyHash, string contentURI)
function deactivateSpec(bytes32 specHash) // only publisher
function reactivateSpec(bytes32 specHash) // only publisher
function isRegistered(bytes32 specHash) returns (bool)
function getPublisher(bytes32 specHash) returns (address)
```

## 与 PolicyRegistry 的关系

```
BehaviorSpec → policyHash → Policy → 法律法规
```

详见 [PolicyRegistry 确权](/registries-que-quan/policy-registry.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/registries-que-quan/behavior-spec-registry.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.
