---
title: Manage custom model dependencies
description: Describes how to manage these dependencies from the Workshop and update the base drop-in environments to support your model code.
---

#  Manage custom model dependencies {: #manage-custom-model-dependencies }

Custom models can contain various machine learning libraries in the model code, but not every [drop-in environment](drop-in-environments) provided by DataRobot natively supports all libraries. However, you can manage these dependencies from the Workshop and update the base drop-in environments to support your model code. To manage model dependencies, you must include a `requirements.txt` file uploaded as part of your custom model. The text file must indicate the machine learning libraries used in the model code.

For example, consider a custom R model that uses Caret and XGBoost libraries. If this model is added to the Workshop and the R drop-in environment is selected, the base environment will only support Caret, not XGBoost. To address this, edit `requirements.txt` to include the Caret and XGBoost dependencies. After editing and re-uploading the requirements file, the base environment includes XGBoost, making the model available within the environment.

!!! important
    Custom model dependencies aren't applied when testing a model locally with [DRUM](custom-model-drum).

List the following, depending on the model language, in `requirements.txt`:

* For R models, list the machine learning library dependencies.

    ![](images/depend-3.png)

* For Python models, list the dependencies <em>and</em> any version constraints for the libraries. Supported constraint types include `<`, `<=`, `==`, `>=`, `>`, and multiple constraints can be issued in a single entry (for example, `pandas >= 0.24, < 1.0`).

    ![](images/depend-4.png)

Once the requirements file is updated to include dependencies and constraints, navigate to your custom model's **Assemble** tab. Upload the file under the **Model > Content** header. The **Model Dependencies** field updates to display the dependencies and constraints listed in the file.

![](images/depend-1.png)

From the **Assemble** tab, select a base drop-in environment under the **Model Environment** header. DataRobot warns you that a new environment must be built to account for the model dependencies. Select **Build environment**, and DataRobot installs the required libraries and constraints to the base environment.

![](images/depend-2.png)

Once the base environment is updated, your custom model will be usable with the environment, allowing you to test, deploy, or register it.