> For the complete documentation index, see [llms.txt](https://docs.biodock.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.biodock.ai/start/path-2-train-a-fully-automated-ai-model/train-check-and-improve.md).

# Train, check and improve

*What you'll get: a trained model version, a clear idea of how good it is, and a better version after one round of corrections.*

You need some tiles marked **Fully labeled** (see [Label and train](https://docs.biodock.ai/start/path-2-train-a-fully-automated-ai-model/label-and-train.md)).

## 1. Train your first model

1. In the labeler's top bar, click **Train**.
2. Under **Train a new model**, click **Get started**. If it is greyed out, the card tells you why, for example that no tile is marked **Fully labeled** yet.
3. The **Configure and submit** screen opens. For a first model the defaults are good. Two things are worth doing:
   * **Hold some tiles back for testing.** The size group's card reads, for example, "Using 18/18 fully labeled tiles for training." Click **Customize** and drag the slider down a little. The remaining tiles are used to test your model on work it has never seen.
   * **Describe this version** under **Add a description**, so you can tell versions apart later.
4. Click **Start training**.

<figure><img src="https://3806122466-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fk3DfNQKoMy1JXdaDLvpG%2Fuploads%2Fgit-blob-b7d284733eb4246dc2e709f2315c53723b155cac%2Fdocs-start-configure-and-submit.png?alt=media" alt="The Configure and submit screen with one size group, its Customize slider open showing 15 of 18 fully labeled tiles used for training, the class list, a description, and the Start training button"><figcaption><p><strong>Configure and submit</strong>: hold tiles back with <strong>Customize</strong>, add a description, then <strong>Start training</strong>.</p></figcaption></figure>

What else is on the screen:

* **Classes in this group**: keep every class ticked that you want the model to find.
* The transforms and **Advanced settings**: fine as they are. See [Training a model](https://docs.biodock.ai/projects-and-models/training-a-model.md).
* **Errors and recommendations** appears when Biodock finds a problem with your labels. An error must be fixed before you can train; a recommendation is only advice.
* **Size group hierarchy**: only for projects with more than one size group. See [Configuring your model](https://docs.biodock.ai/projects-and-models/configuring-your-model.md).
* **Channel settings for training**: what the model will see.

Only a project owner can start a training, and your email address must be verified. Training uses credits; see [Credits, storage and limits](https://docs.biodock.ai/account/credits-storage-and-limits.md).

## 2. Wait for it to train

The new version appears under **Current versions** on the Train page, as **v1** with your description.

* Click **View details** to follow it. It first reads **Spinning up** while Biodock starts a machine for you, which can take a while. Then it reads **Training**, with a percentage.
* You don't need to watch. Close the tab: Biodock emails you when the training has finished. A first model often takes about an hour from start to finish.
* When it is done, the version reads **Active**: trained and ready to use. If a training fails, it reads **Failed**.

Every training makes a new version. It never overwrites an old one.

## 3. Check how good it is

On the Train page, click **View** next to your version. Its page opens on the project, with these sections:

* **Predictions**: the model's outlines (**AI predictions**) next to yours (**Your labels**), tile by tile. Look hardest at the test tiles: did it miss objects, outline things that aren't there, or draw loose borders? This is the best check.
* **Training statistics**: the scores. Trust the **Test** columns, not the **Training** ones: test tiles are the ones the model never studied. Below the table, **Correct**, **Missed** and **Spurious** count what the model found, missed and made up.

How to read each number is in [Evaluating performance](https://docs.biodock.ai/projects-and-models/evaluating-performance.md).

To try the model on new tiles yourself, click **Evaluate** next to the version on the Train page. It takes you back to the labeler.

Your first model will almost always make some mistakes: it learned from only a few tiles. That's expected. Improve it as below.

## 4. Improve it: prelabel, correct, retrain

<figure><img src="https://3806122466-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fk3DfNQKoMy1JXdaDLvpG%2Fuploads%2Fgit-blob-9bc9b7419862b943575d7b641061c452d60c4078%2Fdocs-start-prelabel-correct.gif?alt=media" alt="AI Prelabel is clicked on the size group, an unlabeled tile is clicked and fills with outlines and a purple border, Stop prelabeling is clicked, a wrong outline is deleted and a missed nucleus is added, then Corrected is ticked in the tile&#x27;s corner"><figcaption><p><strong>AI Prelabel</strong> → click a tile → <strong>Stop prelabeling</strong> → fix the mistakes → tick <strong>Corrected</strong>.</p></figcaption></figure>

Instead of labeling from scratch, let your model label new tiles and fix only its mistakes. It is much faster, and the mistakes you fix are exactly what the model needs to learn.

1. **Prelabel.** In the labeler, click **AI Prelabel** on your size group's card. The line "Using model Version 1, …" says which version labels for you; click it to pick another **Trained version** or to **Select classes**. Open an image the model hasn't seen, and click unlabeled tiles. Each one fills with the model's outlines, gets a purple border and is marked **Needs correction**. You can't prelabel a fully labeled tile. Prelabeling uses credits.
2. **Correct.** Click **Stop prelabeling**. In each prelabeled tile, delete wrong outlines, fix rough ones and add any the model missed. When the tile is completely right, tick **Corrected** in its corner. A tile is not used for training until you tick it.
3. **Train again.** Click **Train** → **Get started**, as before. Your corrected tiles are added to the count by themselves. Leave the size group's **Retrain** switch on, so the group learns again from everything. Hold some tiles back with **Customize**, describe the version, and click **Start training**.

Then compare the new version with the old one, by its scores and by eye. Repeat until you're happy: two or three rounds usually make a great model.

{% hint style="info" %}
Once you have a first model, AI Prelabel followed by AI Select for corrections is usually faster than AI Detect.
{% endhint %}

## Next: run your model

{% content-ref url="/pages/W5WL60shRCynwhnmH4KV" %}
[Run your AI model](https://docs.biodock.ai/start/path-2-train-a-fully-automated-ai-model/run-your-ai-model.md)
{% endcontent-ref %}


---

# 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.biodock.ai/start/path-2-train-a-fully-automated-ai-model/train-check-and-improve.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.
