Frontend Build Variables
VITE_* variables are read only when you build the frontend yourself, and they are written into the build output. The official published Aivory application image already includes the frontend, so adding or changing VITE_* in a running Docker .env file will not change web behavior; you must set them in the build environment and rebuild the image/static files.
Do not put API keys, JWTs, database passwords, OAuth client secrets, payment keys, or internal addresses into any VITE_*. After the build, these values can be read by users' browsers.
Keep the defaults unless you are maintaining a custom frontend, hit a clearly identified UI performance problem, and have a rollback plan. Most variables only affect pagination, polling, frontend timeouts, or client-side display limits; they do not relax server-side security limits.
API and development proxy
| Variable | Default | Purpose and values |
|---|---|---|
VITE_API_BASE | /api | Base path the browser uses to request the API. Keep the default for the official same-origin deployment; use a controlled HTTPS address or path only when the frontend and API are separated. |
VITE_API_TARGET | http://localhost:8787 | Proxy target for the local development server; it only applies to development builds/dev servers and is not written into production browser requests. |
Pagination, lists, and polling
| Variable | Default | Purpose and values |
|---|---|---|
VITE_AIVORY_CONV_PAGE | 200 | Page size for the initial load and scroll loading of the left-side conversation list. |
VITE_AIVORY_MSG_PAGE | 40 | Number of items requested per page when opening a conversation and loading older history messages. |
VITE_AIVORY_CONVERSATIONS_API_LIST_LIMIT | 200 | Default request limit for regular conversation API lists. |
VITE_AIVORY_CONVERSATIONS_API_LIST_ARCHIVED_LIMIT | 200 | Default request limit for archived conversation API lists. |
VITE_AIVORY_PROJECT_CONVERSATIONS_API_LIST_LIMIT | 500 | Default request limit for loading conversations in project details. |
VITE_AIVORY_WORKSPACES_API_ADMIN_LIST_LIMIT | 200 | Default request limit for the administrator workspace list. |
VITE_AIVORY_IMAGE_API_MY_IMAGES_LIMIT | 60 | Per-page request count for the current user's generated image gallery. |
VITE_AIVORY_ADMIN_API_USERS_LIMIT | 50 | Default request limit for the administrator user list API. |
VITE_AIVORY_ADMIN_API_USER_IMAGES_LIMIT | 60 | Per-page request count when an administrator views a single user's image gallery. |
VITE_AIVORY_ADMIN_API_ANALYTICS | 30 | Default lookback days requested by the admin analytics page. |
VITE_AIVORY_PAGE_SIZE | 50 | General table page size for user files, admin files, and usage records. |
VITE_AIVORY_PAGE_SIZE_2 | 20 | Page size for the admin redemption code table. |
VITE_AIVORY_PAGE_SIZE_3 | 20 | Page size for the admin user table. |
VITE_AIVORY_IMAGES_PAGE | 60 | Per-page count for infinite scrolling of an admin user's image gallery. |
VITE_AIVORY_PAGE | 30 | Per-page count for the user's personal generated image gallery. |
VITE_AIVORY_KB_DOC_STATUS_POLL_INTERVAL | 2200 | Status polling interval when a knowledge base still has documents being parsed/indexed, in milliseconds. |
VITE_AIVORY_INGEST_POLL_MS | 1200 | Polling interval while the chat editor waits for attachment ingestion, in milliseconds. |
VITE_AIVORY_ADMIN_BACKUP_EXPORT_JOB_POLL_INTERVAL | 2500 | Polling interval for admin backup export job status, in milliseconds. |
VITE_AIVORY_ADMIN_VECTOR_MAINTENANCE_JOB_POLL_INTERVAL | 2500 | Polling interval for admin vector maintenance job status, in milliseconds. |
VITE_AIVORY_REALTIME_SYNC_THROTTLE_MS | 800 | Frontend sync throttle duration triggered by multi-device realtime events, in milliseconds. |
VITE_AIVORY_ONLINE_WINDOW_S | 300 | Last-activity window used to mark users as "online" in the admin user list, in seconds. |
Lowering polling intervals or raising list limits increases database/API load and browser memory; larger values entered in the frontend may also be rejected or clamped by server-side pagination, rate limiting, and permission rules.
Input, uploads, and browser Python
| Variable | Default | Purpose and values |
|---|---|---|
VITE_AIVORY_MAX_LEN | 12000 | Maximum characters per message in the chat editor. The server may still impose separate request-body limits. |
VITE_AIVORY_MAX_BYTES | 262144 | Browser-side maximum bytes for admin icon uploads, default 256 KiB. |
VITE_AIVORY_RUN_TIMEOUT_MS | 120000 | Hard timeout for a single in-browser Pyodide Python run, in milliseconds. Unrelated to the server sandbox. |
VITE_AIVORY_MAX_STREAM_CHARS | 200000 | Maximum cumulative characters of stdout/stderr in an in-browser Pyodide run. |
VITE_AIVORY_MAX_RESULT_CHARS | 20000 | Maximum characters displayed for the final expression result in an in-browser Pyodide run. |
In-browser Pyodide only affects the local frontend experience; it is not the server Python sandbox. When models need to call python_execute, you must still configure a controlled SANDBOX_* sidecar and follow the permission and resource limits in Tools, MCP, and the Sandbox.