> For the complete documentation index, see [llms.txt](https://xiaoxiami.gitbook.io/elasticsearch/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://xiaoxiami.gitbook.io/elasticsearch/ji-chu/mapping/322meta-fieldsff08-yuan-zi-duan-ff09.md).

# 3.2.2.Meta-Fields（元字段）

每个文档都有与之关联的元数据，比如 `_index`，`_type` 和 `_id` 元字段。当创建 mapping type（映射类型）时，可以自定义一些这些元字段的行为。

## Identity meta-fields（身份的元字段） <a href="#metafields-yuan-zi-duan-identitymetafields-shen-fen-de-yuan-zi-duan" id="metafields-yuan-zi-duan-identitymetafields-shen-fen-de-yuan-zi-duan"></a>

| [\_index](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-index-field.html) | 文档所属的索引。                                                                                                             |
| --------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- |
| [\_uid](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-uid-field.html)     | 复合字段包含&#x4E86;**\_type** &#x548C;**\_id**。                                                                           |
| [\_type](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-type-field.html)   | 文档的[mapping type（映射类型 ）](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping.html#mapping-type)。 |
| [\_id](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-id-field.html)       | 文档 ID。                                                                                                               |

## Document source meta-fields（文档源的元字段） <a href="#metafields-yuan-zi-duan-documentsourcemetafields-wen-dang-yuan-de-yuan-zi-duan" id="metafields-yuan-zi-duan-documentsourcemetafields-wen-dang-yuan-de-yuan-zi-duan"></a>

| \_source | 原始的JSON 字符串表示文档的正文。                                                                                                      |
| -------- | ------------------------------------------------------------------------------------------------------------------------ |
| \_size   | \_source 字段的大小（以字节为单位），由[ mapper-size](https://www.elastic.co/guide/en/elasticsearch/plugins/5.3/mapper-size.html) 插件提供。 |

## Indexing meta-fields（索引的元字段） <a href="#metafields-yuan-zi-duan-indexingmetafields-suo-yin-de-yuan-zi-duan" id="metafields-yuan-zi-duan-indexingmetafields-suo-yin-de-yuan-zi-duan"></a>

| \_all          | 一个索引其他全部字段值的全能字段。 |
| -------------- | ----------------- |
| \_field\_names | 文档中包含非空值的所有字段。    |

## Routing meta-fields（路由的元字段） <a href="#metafields-yuan-zi-duan-routingmetafields-lu-you-de-yuan-zi-duan" id="metafields-yuan-zi-duan-routingmetafields-lu-you-de-yuan-zi-duan"></a>

| \_parent  | 用于创建两个映射类型之间的父子关系。 |
| --------- | ------------------ |
| \_routing | 将文档路由到特定分片的自定义路由值。 |

## Other meta-field（其他的元字段） <a href="#metafields-yuan-zi-duan-othermetafield-qi-ta-de-yuan-zi-duan" id="metafields-yuan-zi-duan-othermetafield-qi-ta-de-yuan-zi-duan"></a>

| \_meta | 特定应用的元数据。 |
| ------ | --------- |


---

# 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://xiaoxiami.gitbook.io/elasticsearch/ji-chu/mapping/322meta-fieldsff08-yuan-zi-duan-ff09.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.
