# Private Model

### 1. Upload Files

Choose your model version: You will see list model versions of your private model and need to choose one to upload files

**Step 1: Install the SDK CLI**

```
pip install https://s3-han02.fptcloud.com/aifactory-public/SDK/model_space-0.3.3-py3-none-any.whl
```

**Step 2: Set up environment variables**

```
export FPT_SPACE_URL=https://ai-api.fptcloud.com/
export FPT_TENANT_ID=
export FPT_SPACE_TOKEN=
```

***Note*****:**

*Please visit* [*https://ai.fptcloud.com/{{tenant\_name}}/user-token*](https://ai.fptcloud.com/%7B%7Btenant_name%7D%7D/user-token) *to generate your access token and paste it after FPT\_SPACE\_TOKEN= above*

*To use the SDK through a proxy (e.g., internal environments), make sure to configure **one of** the proxy environment variables (HTTP\_PROXY or HTTPS\_PROXY) in addition to the variables above.*

```
export HTTP_PROXY=
export HTTPS_PROXY=
```

**Step 3: Upload model version**

```
model_space model upload --model-id {{model_id}} --version-id {{version_id}}  --path 
```

**Optional parameters**

* -include:

Include only files that match the given regex patterns. Commas should separate multiple patterns ,.

* -exclude:

Exclude files that match the given regex patterns. You can also use commas , to separate multiple patterns.

### 2. Download Files

Choose your model version: Choose your model version: You will see list model versions of your private model and need to choose one to download files

**Step 1: Install the SDK CLI**

```
pip install https://s3-han02.fptcloud.com/aifactory-public/SDK/model_space-0.3.3-py3-none-any.whl
```

**Step 2: Set up environment variables**

```
export FPT_SPACE_URL=https://ai-api.fptcloud.com/
export FPT_TENANT_ID=
export FPT_SPACE_TOKEN=
```

***Note*****:**

*Please visit* [*https://ai.fptcloud.com/{{tenant\_name}}/user-token*](https://ai.fptcloud.com/%7B%7Btenant_name%7D%7D/user-token) *to generate your access token and paste it after FPT\_SPACE\_TOKEN= above*

*To use the SDK through a proxy (e.g., internal environments), make sure to configure **one of** the proxy environment variables (HTTP\_PROXY or HTTPS\_PROXY) in addition to the variables above.*

```
export HTTP_PROXY=
export HTTPS_PROXY=
```

**Step 3: Download model version**

```
model_space model download --model-id {{model_id}} --version-id {{version_id}} --path 
```

**Optional parameters**

* -include:

Include only files that match the given regex patterns. Multiple patterns should be separated by commas ,.

* -exclude:

Exclude files that match the given regex patterns. You can also use commas , to separate multiple patterns.

### 3. Delete File

**Purpose:** Delete the files associated with a version.

To delete files, follow these steps:

**Step 1:** Click on a model to view its details > Select the **File Browser** tab.

**Step 2:** Click the three dots in the **Action** column > Select **Delete**

<figure><img src="/files/CwFVUynJlxtyzlzCF7Bm" alt=""><figcaption></figcaption></figure>

**Step 3**: A confirmation dialog will appear. To confirm deletion, type "delete" into the text box. The **Delete** button will be enabled once the text is entered.

<figure><img src="/files/LijqtNpHbLsCkJCWExzv" alt=""><figcaption></figcaption></figure>

**Step 4**: To delete, click the **Confirm** button. To cancel the action, click **Cancel**.


---

# 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://ai-docs.fptcloud.com/fpt-ai-studio/services/model-hub/tutorials/how-to-upload-download-files-by-sdk/private-model.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.
