> For the complete documentation index, see [llms.txt](https://mikefarah.gitbook.io/yq/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mikefarah.gitbook.io/yq/operators.md).

# Operators

- [Add](https://mikefarah.gitbook.io/yq/operators/add.md)
- [Alternative (Default value)](https://mikefarah.gitbook.io/yq/operators/alternative-default-value.md)
- [Anchor and Alias Operators](https://mikefarah.gitbook.io/yq/operators/anchor-and-alias-operators.md)
- [Array to Map](https://mikefarah.gitbook.io/yq/operators/array-to-map.md)
- [Assign (Update)](https://mikefarah.gitbook.io/yq/operators/assign-update.md)
- [Boolean Operators](https://mikefarah.gitbook.io/yq/operators/boolean-operators.md)
- [Collect into Array](https://mikefarah.gitbook.io/yq/operators/collect-into-array.md)
- [Column](https://mikefarah.gitbook.io/yq/operators/column.md)
- [Comment Operators](https://mikefarah.gitbook.io/yq/operators/comment-operators.md)
- [Compare Operators](https://mikefarah.gitbook.io/yq/operators/compare.md)
- [Contains](https://mikefarah.gitbook.io/yq/operators/contains.md)
- [Create, Collect into Object](https://mikefarah.gitbook.io/yq/operators/create-collect-into-object.md)
- [Date Time](https://mikefarah.gitbook.io/yq/operators/datetime.md)
- [Delete](https://mikefarah.gitbook.io/yq/operators/delete.md)
- [Divide](https://mikefarah.gitbook.io/yq/operators/divide.md)
- [Document Index](https://mikefarah.gitbook.io/yq/operators/document-index.md)
- [Encode / Decode](https://mikefarah.gitbook.io/yq/operators/encode-decode.md)
- [Entries](https://mikefarah.gitbook.io/yq/operators/entries.md)
- [Env Variable Operators](https://mikefarah.gitbook.io/yq/operators/env-variable-operators.md)
- [Equals](https://mikefarah.gitbook.io/yq/operators/equals.md)
- [Eval](https://mikefarah.gitbook.io/yq/operators/eval.md)
- [File Operators](https://mikefarah.gitbook.io/yq/operators/file-operators.md)
- [Filter Operator](https://mikefarah.gitbook.io/yq/operators/filter.md)
- [First Operator](https://mikefarah.gitbook.io/yq/operators/first.md)
- [Flatten](https://mikefarah.gitbook.io/yq/operators/flatten.md)
- [Group By](https://mikefarah.gitbook.io/yq/operators/group-by.md)
- [Has](https://mikefarah.gitbook.io/yq/operators/has.md)
- [Keys](https://mikefarah.gitbook.io/yq/operators/keys.md)
- [Kind](https://mikefarah.gitbook.io/yq/operators/kind.md)
- [Length](https://mikefarah.gitbook.io/yq/operators/length.md)
- [Line](https://mikefarah.gitbook.io/yq/operators/line.md)
- [Load](https://mikefarah.gitbook.io/yq/operators/load.md)
- [Min](https://mikefarah.gitbook.io/yq/operators/min.md)
- [Map](https://mikefarah.gitbook.io/yq/operators/map.md)
- [Max](https://mikefarah.gitbook.io/yq/operators/max.md)
- [Modulo](https://mikefarah.gitbook.io/yq/operators/modulo.md)
- [Multiply (Merge)](https://mikefarah.gitbook.io/yq/operators/multiply-merge.md)
- [Omit](https://mikefarah.gitbook.io/yq/operators/omit.md)
- [Parent](https://mikefarah.gitbook.io/yq/operators/parent.md)
- [Path](https://mikefarah.gitbook.io/yq/operators/path.md)
- [Pick](https://mikefarah.gitbook.io/yq/operators/pick.md)
- [Pipe](https://mikefarah.gitbook.io/yq/operators/pipe.md)
- [Pivot](https://mikefarah.gitbook.io/yq/operators/pivot.md)
- [Recursive Descent (Glob)](https://mikefarah.gitbook.io/yq/operators/recursive-descent-glob.md)
- [Reduce](https://mikefarah.gitbook.io/yq/operators/reduce.md)
- [Reverse](https://mikefarah.gitbook.io/yq/operators/reverse.md)
- [Select](https://mikefarah.gitbook.io/yq/operators/select.md)
- [Shuffle](https://mikefarah.gitbook.io/yq/operators/shuffle.md)
- [Slice Array](https://mikefarah.gitbook.io/yq/operators/slice-array.md)
- [Sort](https://mikefarah.gitbook.io/yq/operators/sort.md)
- [Sort Keys](https://mikefarah.gitbook.io/yq/operators/sort-keys.md)
- [Split into Documents](https://mikefarah.gitbook.io/yq/operators/split-into-documents.md)
- [String Operators](https://mikefarah.gitbook.io/yq/operators/string-operators.md)
- [Style](https://mikefarah.gitbook.io/yq/operators/style.md)
- [Subtract](https://mikefarah.gitbook.io/yq/operators/subtract.md)
- [System](https://mikefarah.gitbook.io/yq/operators/system-operators.md)
- [Tag](https://mikefarah.gitbook.io/yq/operators/tag.md)
- [To Number](https://mikefarah.gitbook.io/yq/operators/to_number.md)
- [Traverse (Read)](https://mikefarah.gitbook.io/yq/operators/traverse-read.md)
- [Union](https://mikefarah.gitbook.io/yq/operators/union.md)
- [Unique](https://mikefarah.gitbook.io/yq/operators/unique.md)
- [Variable Operators](https://mikefarah.gitbook.io/yq/operators/variable-operators.md)
- [With](https://mikefarah.gitbook.io/yq/operators/with.md)


---

# 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://mikefarah.gitbook.io/yq/operators.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.
