> For the complete documentation index, see [llms.txt](https://docs.zingg.ai/zingg/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.zingg.ai/zingg/running-zingg/generate-model-documentation.md).

# Generate Model Documentation

Generate readable documentation of your labeled training data to inspect quality before committing to the train phase.

{% hint style="success" icon="right-long" %}
Run this BETWEEN `label` and `train`. Do not skip - it lets you inspect training data quality before the model is built.
{% endhint %}

The `generateDocs` phase produces readable documentation of the records you have marked during the label phase, including both matches and non-matches. Use this to review training data quality, understand what Zingg has learned, and share results with subject matter experts before training begins.

The documentation is written to the `zinggDir/modelId` folder and can be viewed in a browser.

### Run generateDocs

{% tabs %}
{% tab title="Community" %}

### **Python**

```python
options = ClientOptions([ClientOptions.PHASE, "generateDocs"])
zingg = Zingg(args, options)
zingg.initAndExecute()
```

### **CLI**

```bash
./scripts/zingg.sh --phase generateDocs --conf <location to conf.json>
```

{% endtab %}

{% tab title="Enterprise" %}

### **Python**

{% hint style="info" icon="right-long" %}
Enterprise uses `EZingg` instead of `Zingg`.
{% endhint %}

```python
options = ClientOptions([ClientOptions.PHASE, "generateDocs"])
zingg = EZingg(args, options)
zingg.initAndExecute()
```

### CLI

```bash
./scripts/zingg.sh --phase generateDocs --conf <location to conf.json> \
```

{% endtab %}

{% tab title="Enterprise Snowflake" %}

### CLI

```bash
./scripts/zingg.sh --phase generateDocs --conf <location to conf.json> \
  --properties-file <location to snowflake.properties>
```

{% endtab %}
{% endtabs %}

{% hint style="success" icon="right-long" %}
The generated documentation is viewable in a browser. It shows all pairs you labelled as matches and non-matches in a readable format. Share this with subject matter experts to validate training data quality before running `train`.

[Build and Save the Model ](/zingg/running-zingg/build-and-save-the-model.md)→ run `train` once you are satisfied with the training data quality.
{% endhint %}


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.zingg.ai/zingg/running-zingg/generate-model-documentation.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
