# Installation & Integration

Virtual Try On is an AI-based project that allows the customer to try on the relevant product on a photo they have uploaded. The flow is completed through 3 core applications:

* Virtual Try On Extension
* Frontend (Next or Python)
* Mobile App

***

### 1. Installation

#### Extension

| Variable                            | Value / Description                                                                                  |
| ----------------------------------- | ---------------------------------------------------------------------------------------------------- |
| `DB_SSL`                            | `true`                                                                                               |
| `DB_SCHEMA`                         | `.public`                                                                                            |
| `APP_TEST_MODE`                     | `false`                                                                                              |
| `APP_SERVER_PORT`                   | `:8008`                                                                                              |
| `SEC_API_AUTH_PASSWORD`             | 20-character combination of uppercase, lowercase letters and numbers *(must be entered as a secret)* |
| `API_AUTH_USERNAME`                 | 15-character combination of uppercase, lowercase letters and numbers                                 |
| `PROCESS_MONITORING`                | `false`                                                                                              |
| `GOOGLE_OAUTH_ADDRESS`              | `https://oauth2.googleapis.com/token`                                                                |
| `APP_LIMITED_CATEGORIES`            | Comma-separated FE category IDs for categories where try-on should be disabled                       |
| `APP_SERVER_ACCESS_LOGS`            | `true`                                                                                               |
| `VERTEX_AI_IMAGE_FORMAT`            | `base64`                                                                                             |
| `INF_TRY_ON_RATE_LIMITER`           | `250-M`                                                                                              |
| `API_ALLOWED_IMAGE_DOMAINS`         | Root domain names of the CDNs where product images are hosted (e.g. `akinoncloud.com`)               |
| `DB_CONNECTION_POOL_MAX_SIZE`       | `20`                                                                                                 |
| `DB_CONNECTION_POOL_MIN_SIZE`       | `10`                                                                                                 |
| `TOGGLE_IMAGE_GENERATION_ENABLED`   | `true`                                                                                               |
| `S3_PRESIGN_EXPIRE_MINUTES`         | `30`                                                                                                 |
| `S3_PRESIGN_LISTING_EXPIRE_MINUTES` | `300`                                                                                                |

#### FE-Next

*(To be filled)*

#### FE-Python

*(To be filled)*

#### Mobile App

*(To be filled)*

***

### 2. Observation Mode Controls

Before the application is fully released to end customers, controls must be performed in observation mode. In a deployment made in this mode, end customers cannot directly see the new features. However, the features become accessible when `enable_virtual_try_on=true` is added to the browser's local storage.

Comprehensive controls must be performed including:

* Query speed for both direct queries using the product's existing image and queries made with cropping
* Similar product checks
* Error checks

> **The product must NEVER be released directly to the end customer without these controls being completed.**

***

### 3. Release to End Customer

Once the controls are completed, the FE applications must make the feature available to end customers either by deploying a new release or by making a parameter change.


---

# 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.akinon.com/technical-guides/virtual-try-on-vto/installation-and-integration.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.
