# Applying a mapping (Deprecated)

In case a mapping was previously created, it can be applied to the same architecture using the [code integration](/user-interface/project/network/code-integration.md) panel.&#x20;

### When is the mapping automatically applied

* The mapping is automatically applied when using the [CLI to upload a new model](/tensorleap-integration/uploading-with-cli/cli-assets-upload.md) to a project that has leap\_mapping.yaml in its root directory
* The mapping is being directly supplied to the [leap projects push](/tensorleap-integration/uploading-with-cli/cli-assets-upload.md#uploading-both-a-code-and-model) command using the `--leap-mapping`  flag

### How to manually apply a mapping

1. Ensure the current integration script has a [leap\_mapping.yaml](broken://pages/3rU3R1SpB0X70g2DUoJ3) within the selected script version
2. Verify that that the option to "Apply" the mapping appear in the code integration view and click it

<figure><img src="/files/o3qBd6SiZBLGThdE6HT5" alt=""><figcaption><p>The option to "Apply" a previously defined leap mapping</p></figcaption></figure>

3. [Validate](/user-interface/project/network/network-mapping/validate-mapping.md) the mapping you applied
4. In case the validation is successful - save the changes made to the current configuration by clicking the "save changes" in the left hand side controller

<figure><img src="/files/QsPT4uguDf5fUFp3WDf1" alt=""><figcaption><p>A node is added to the graph after applying a previously defined mapping</p></figcaption></figure>

{% hint style="warning" %}
If after applying a mapping to an architecture validate assets fail - it means that either the architecture is not the same (layers could be added if the export process was different), or the server had a major upgrade.

For both cases, we advise to not save the change to the configuration that were applied by the mapping, but to create a new mapping
{% endhint %}


---

# Agent Instructions: 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:

```
GET https://docs.tensorleap.ai/user-interface/project/network/network-mapping/applying-a-mapping-deprecated.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
