import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; # Quick Start Guide ### 1. Create a Model Repository - Navigate to **Inference → Model Repository** in the TIR Dashboard - Click **CREATE REPOSITORY** - Enter a **repository name** (e.g., `my-llm-model`) - Select **model type**: - **PyTorch** - For PyTorch models (`.pth`, `.pt`, Hugging Face models) - **Triton** - For Triton Inference Server model repositories - **Custom** - For other model formats - Choose **storage type**: - **New EOS Bucket** - Automatically provisions a new bucket (recommended) - **Existing EOS Bucket** - Use an existing bucket - **External EOS Bucket** - Connect to an external bucket with credentials - Click **Create** ### 2: Configure Access After creation, you'll receive: - **Bucket name** - **Access key** - **Secret key** - **Endpoint URL** (typically `https://objectstore.e2enetworks.net`) :::tip Model Repositories are backed by E2E Object Storage (EOS). If you have not used EOS storage before, please read [Object Storage](/docs/myaccount/storage/object_storage/) first. ::: ### 3: Upload Model Files #### Method 1: Using Minio CLI (Recommended) Install Minio CLI: ```bash # macOS brew install minio/stable/mc # Linux wget https://dl.min.io/client/mc/release/linux-amd64/mc chmod +x mc sudo mv mc /usr/local/bin/ ``` Configure the client: ```bash mc config host add https://objectstore.e2enetworks.net ``` Upload model files: ```bash # Upload entire directory mc cp -r /path/to/model/* // # Upload specific version mc cp -r /path/to/model/* //v1/ # Upload Hugging Face model snapshot mc cp -r ~/.cache/huggingface/hub//* // ``` #### Method 2: Using Python SDK Step 1: Install the SDK ```python pip install e2enetworks ``` Step 2: Initialize the SDK ```python from e2enetworks.cloud import tir from e2enetworks.constants import DELHI_LOCATION, CHENNAI_LOCATION # Choose the required location location = DELHI_LOCATION # Initialize TIR SDK # Get API Key and Access Token from Projects → API Tokens tir.init( api_key="", access_token="", location=location ) ``` Step 3: Create a Model Repository client ```python model_repo_client = tir.Models( project= ) ``` Step 4: Upload a model ```python # Upload all files from a local directory to the model repository model_repo_client.push_model( model_path="./model-dir", prefix="v1", model_id= ) ``` #### Method 3: Using TIR Notebooks In a TIR Notebook, use the SDK or CLI directly: Step 1: Install the SDK ```python pip install e2enetworks ``` Step 2: Run commands in a TIR Notebook ```python from e2enetworks.cloud import tir # Set location location = "Delhi" # Create model repository client model_repo_client = tir.Models(location=location) # Upload a model version from a local directory model_repo_client.push_model( model_path="", prefix="", model_id=2297 ) # Download model files from the repository model_repo_client.download_model( model_id=2297, local_path="", prefix="" ) ``` ### 4: Verify Upload 1. Navigate to your Model Repository in the dashboard 2. Click on the **Model Files** tab 3. Verify your files are uploaded correctly ### 5: Use with Model Endpoints 1. Create a **Model Endpoint** (Inference → Model Endpoints) 2. Select **Link with Model Repository** 3. Choose your repository from the list 4. Configure the model path (e.g., `/` for root, `/v1` for versioned models) 5. Launch the endpoint The model files will be automatically downloaded to the endpoint container during startup. --- ## Supported Frameworks Model Repositories support storing models from various ML frameworks: | Framework | File Formats | Use Case | |-----------|-------------|----------| | **PyTorch** | `.pth`, `.pt`, `.pkl` | PyTorch checkpoints, Hugging Face models, custom PyTorch models | | **TensorFlow** | SavedModel, `.h5`, `.pb` | TensorFlow SavedModels, Keras models | | **Triton Inference Server** | Triton model repository structure | Triton models with configuration files | | **Custom Formats** | Any file structure | ONNX models, TensorRT engines, or any custom format | ### Example Directory Structures ``` my-pytorch-model/ ├── config.json ├── pytorch_model.bin ├── tokenizer.json └── tokenizer_config.json ``` ``` my-tensorflow-model/ ├── saved_model.pb ├── variables/ │ ├── variables.data-00000-of-00001 │ └── variables.index └── assets/ ``` ``` my-triton-model/ ├── config.pbtxt └── 1/ └── model.graphdef ``` ``` my-custom-model/ ├── model.onnx ├── config.yaml └── assets/ ``` --- ---