> ## Documentation Index
> Fetch the complete documentation index at: https://docs.opennous.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

# train_icp_model

> Build or train the ICP model from real closed-won and closed-lost deals via contrastive lift. The strongest way to build the playbook.

Builds (or sharpens) the ICP scoring model from the user's **real** closed deals. Pass closed-won customer domains and closed-lost domains. Nous enriches each, links the contacts you already have there, and runs contrastive lift (what's true of winners but not losers) to discover the signals that actually predict revenue, then re-scores open accounts.

<Note>This is the strongest way to build the playbook, because a model trained on who actually bought beats one inferred from a description. Even a handful of each helps (3 to 5 won and 3 to 5 lost). After it runs, call [`export_icp_model`](/mcp/tools/export-icp-model) to write the sharpened model back into the ICP file.</Note>

## Parameters

| Name   | Type      | Required | Description                                                                             |
| ------ | --------- | -------- | --------------------------------------------------------------------------------------- |
| `won`  | string\[] |          | Closed-won customer domains, e.g. `["acme.com","globex.com"]`. Domains only, no scheme. |
| `lost` | string\[] |          | Closed-lost domains, e.g. `["tinyco.io"]`. Domains only, no scheme.                     |

Pass at least one won or lost domain. With both sides the model runs in contrastive-lift mode (winners against losers). With only winners it falls back to winner-signal mode.

## Returns

```
Learned from 5 won + 4 lost deals (8 enriched, contrastive-lift mode).

Signals discovered:
  • Company is B2B SaaS (weight 10), true of 5/5 winners, 1/4 losers
  • Company has 11-50 employees (weight 8)
  • Lead is a RevOps leader (weight 7)

The model updated and open accounts were re-scored. See the GTM Context page.
```

If you pass nothing to learn from:

```
Give me at least one closed-won or closed-lost domain to learn from.
```

## When to call it

* **After [`sync_icp`](/mcp/tools/sync-icp)** → sharpen the seeded model on real outcomes when the user can name a few closed deals
* **Whenever new deals close** → re-run with the latest won and lost domains so the model tracks reality

Follow it with [`export_icp_model`](/mcp/tools/export-icp-model) to write the trained model back into the user's ICP file.

## Backed by

`POST /v2/workspace/closed-deals`. The agent setup surface. Enriches each domain and runs contrastive lift, then re-scores open accounts.
