# Open WebUI

Connect Open WebUI to Tensorix.ai and get a feature-rich, self-hosted ChatGPT-style interface with access to all our models.

***

## What is Open WebUI?

[Open WebUI](https://openwebui.com/) is an open-source, self-hosted ChatGPT alternative with a beautiful interface and powerful features. With Tensorix, you get automatic model discovery - all models are instantly available.

{% hint style="success" %}
**Why Open WebUI + Tensorix?**

* 🔒 **Self-hosted** - Your conversations stay on your infrastructure
* 🌍 **EU-hosted models** - Privacy-focused European hosting
* 🔄 **Auto-discovery** - All Tensorix models automatically available
* 📁 **Document chat** - Upload and chat with your files
* 👥 **Multi-user** - Create accounts for your team
  {% endhint %}

***

## Prerequisites

* Docker installed on your system
* A Tensorix API key ([sign up here](https://app.tensorix.ai))
* At least 2GB RAM and 10GB disk space
* Port 8080 available

***

## Quick Start

Deploy Open WebUI with Tensorix in **one command**:

```bash
docker run -d \
  --name open-webui \
  --restart always \
  -p 8080:8080 \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-tensorix-api-key-here \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

{% hint style="warning" %}
**Replace** `your-tensorix-api-key-here` with your actual Tensorix API key!
{% endhint %}

Then open `http://localhost:8080` in your browser.

***

## Setup Guide

### Step 1: Deploy Open WebUI

```bash
docker run -d \
  --name open-webui \
  --restart always \
  -p 8080:8080 \
  -e ENABLE_SIGNUP=true \
  -e WEBUI_AUTH=true \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-tensorix-api-key-here \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

### Step 2: Access Open WebUI

Open your browser and navigate to:

```
http://localhost:8080
```

Or if running on a server: `http://YOUR_SERVER_IP:8080`

### Step 3: Create Your Admin Account

1. On first visit, you'll see a signup form
2. **The first user to sign up automatically becomes admin**
3. Enter your name, email, and a strong password
4. Click **Sign Up**

### Step 4: Start Chatting

1. All Tensorix models are automatically available
2. Click the model selector dropdown at the top
3. Choose any model and start chatting!

***

## Available Models

Open WebUI automatically discovers all models from your Tensorix API.

| Model                         | Features             | Best For                       |
| ----------------------------- | -------------------- | ------------------------------ |
| `z-ai/glm-5.1` ⭐              | Functions, Reasoning | Coding, reasoning, general use |
| `minimax/minimax-m2.5`        | Functions, Reasoning | Reasoning, general purpose     |
| `moonshotai/kimi-k2.5`        | Vision, Functions    | Vision, long context           |
| `deepseek/deepseek-chat-v3.1` | Functions, Reasoning | General chat, fast reasoning   |
| `deepseek/deepseek-r1-0528`   | Functions, Reasoning | Complex reasoning tasks        |
| `minimax/minimax-m2`          | Coding, Functions    | Coding, fast responses         |
| `meta-llama/llama-4-maverick` | Functions            | Long context, multimodal       |
| `openai/gpt-oss-120b`         | Functions, Reasoning | GPT-4 alternative              |

{% hint style="info" %}
**View full model list and pricing**: [tensorix.ai/models](https://tensorix.ai/models)
{% endhint %}

***

## Model Recommendations

| Task                  | Recommended Models                                                 |
| --------------------- | ------------------------------------------------------------------ |
| **General chat**      | `deepseek/deepseek-chat-v3.1`, `meta-llama/llama-3.3-70b-instruct` |
| **Complex reasoning** | `deepseek/deepseek-r1-0528`, `openai/gpt-oss-120b`                 |
| **Coding**            | `z-ai/glm-5.1`, `minimax/minimax-m2`                               |
| **Vision tasks**      | `moonshotai/kimi-k2.5`, `meta-llama/llama-4-maverick`              |
| **Long context**      | `moonshotai/kimi-k2.5`, `meta-llama/llama-4-maverick`              |
| **Multilingual**      | `z-ai/glm-5.1`                                                     |

***

## Features

Open WebUI includes powerful features out of the box:

* 📁 **Document Upload** - Chat with PDFs, docs, and more
* 🔍 **Web Search** - Real-time web search integration
* 💾 **Conversation History** - All chats saved automatically
* 📂 **Folders** - Organize your conversations
* ⚙️ **Model Parameters** - Adjust temperature, top\_p, etc.
* 👥 **Multi-User Support** - Create accounts for your team
* 🔌 **API Access** - Use Open WebUI as an API gateway

***

## Docker Compose Setup

For easier management, create a `docker-compose.yml`:

```yaml
version: '3.8'

services:
  open-webui:
    image: ghcr.io/open-webui/open-webui:main
    container_name: open-webui
    restart: always
    ports:
      - "8080:8080"
    environment:
      - OPENAI_API_BASE_URL=https://api.tensorix.ai/v1
      - OPENAI_API_KEY=your-tensorix-api-key-here
      - ENABLE_SIGNUP=true
      - WEBUI_AUTH=true
      - DEFAULT_USER_ROLE=user
    volumes:
      - open-webui:/app/backend/data

volumes:
  open-webui:
```

Deploy with:

```bash
docker compose up -d
```

***

## Configuration Options

### Change Port

Use port 3000 instead of 8080:

```bash
docker run -d \
  --name open-webui \
  -p 3000:8080 \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-api-key \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

### Disable Signups (After Creating Admin)

```bash
docker stop open-webui && docker rm open-webui

docker run -d \
  --name open-webui \
  -p 8080:8080 \
  -e ENABLE_SIGNUP=false \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-api-key \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

### Enable All Features

```bash
docker run -d \
  --name open-webui \
  --restart always \
  -p 8080:8080 \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-tensorix-api-key \
  -e ENABLE_SIGNUP=true \
  -e WEBUI_AUTH=true \
  -e ENABLE_API_KEY=true \
  -e ENABLE_IMAGE_GENERATION=true \
  -e ENABLE_RAG_WEB_SEARCH=true \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

***

## Environment Variables

| Variable                | Default | Description                  |
| ----------------------- | ------- | ---------------------------- |
| `OPENAI_API_BASE_URL`   | -       | `https://api.tensorix.ai/v1` |
| `OPENAI_API_KEY`        | -       | Your Tensorix API key        |
| `ENABLE_SIGNUP`         | `true`  | Allow new user registration  |
| `WEBUI_AUTH`            | `true`  | Enable authentication        |
| `DEFAULT_USER_ROLE`     | `user`  | Default role for new users   |
| `ENABLE_API_KEY`        | `false` | Enable API key generation    |
| `ENABLE_RAG_WEB_SEARCH` | `false` | Enable web search            |

***

## Maintenance

### Update Open WebUI

```bash
docker pull ghcr.io/open-webui/open-webui:main
docker stop open-webui && docker rm open-webui

docker run -d \
  --name open-webui \
  -p 8080:8080 \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-api-key \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

Your data persists in the Docker volume.

### Backup Data

```bash
docker run --rm \
  -v open-webui:/data \
  -v $(pwd):/backup \
  alpine tar czf /backup/open-webui-backup-$(date +%Y%m%d).tar.gz /data
```

***

## Troubleshooting

### Models Not Loading

1. Check your API key is correct
2. Verify base URL: `https://api.tensorix.ai/v1`
3. Restart: `docker restart open-webui`
4. Check logs: `docker logs open-webui`

### Test Your API Key

```bash
curl https://api.tensorix.ai/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "model": "deepseek/deepseek-chat-v3.1",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'
```

### Update API Key

```bash
docker stop open-webui && docker rm open-webui

docker run -d \
  --name open-webui \
  -p 8080:8080 \
  -e OPENAI_API_BASE_URL=https://api.tensorix.ai/v1 \
  -e OPENAI_API_KEY=your-new-api-key \
  -v open-webui:/app/backend/data \
  ghcr.io/open-webui/open-webui:main
```

### Check Logs

```bash
docker logs open-webui
docker logs -f open-webui  # Follow in real-time
```

***

## Security Best Practices

1. **Disable signup** after creating admin: `ENABLE_SIGNUP=false`
2. **Use strong passwords** for all accounts
3. **Enable HTTPS** via reverse proxy (nginx/Caddy)
4. **Keep updated** - pull latest images regularly
5. **Backup regularly** - schedule automatic backups
6. **Firewall** - only expose to trusted networks

***

## Resources

* [Open WebUI Documentation](https://docs.openwebui.com/)
* [Open WebUI GitHub](https://github.com/open-webui/open-webui)
* [Tensorix Models & Pricing](https://tensorix.ai/models)
* [Tensorix API Examples](https://github.com/Tensorix-ai/tensorix-docs/blob/main/api-examples/README.md)

***

## Need Help?

* 📧 **Email**: <support@tensorix.ai>
* 💬 **Contact Support**: [Contact page](https://github.com/Tensorix-ai/tensorix-docs/blob/main/support/support/README.md)


---

# 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.tensorix.ai/chat-interfaces/openwebui.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.
