Metadata-Version: 2.4
Name: anteroom
Version: 1.4.2
Summary: Anteroom - your gateway to AI conversation
License-Expression: MIT
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Operating System :: OS Independent
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: fastapi>=0.104.0
Requires-Dist: uvicorn[standard]>=0.24.0
Requires-Dist: sse-starlette>=1.8.0
Requires-Dist: openai>=1.12.0
Requires-Dist: mcp>=1.0.0
Requires-Dist: pyyaml>=6.0
Requires-Dist: filetype>=1.2.0
Requires-Dist: rich>=13.0.0
Requires-Dist: prompt-toolkit>=3.0.0
Requires-Dist: tiktoken>=0.7.0
Requires-Dist: cryptography>=42.0.0
Requires-Dist: argon2-cffi>=23.1.0
Requires-Dist: sqlite-vec>=0.1.6
Provides-Extra: dev
Requires-Dist: pytest>=7.0; extra == "dev"
Requires-Dist: pytest-asyncio>=0.23.0; extra == "dev"
Requires-Dist: pytest-cov>=4.0; extra == "dev"
Requires-Dist: httpx>=0.25.0; extra == "dev"
Requires-Dist: ruff>=0.4.0; extra == "dev"
Requires-Dist: mypy>=1.8.0; extra == "dev"
Requires-Dist: pip-audit>=2.7.0; extra == "dev"
Dynamic: license-file

  PyPI Version
  Python 3.10+
  
  License

  Anteroom Logo

Anteroom

The room before the room — a secure, private space between you and the AI.

  Self-hosted ChatGPT-style web UI and agentic CLI that connects to any OpenAI-compatible API.
  Install with pip. Run locally. Own your data.

  Documentation (https://anteroom.readthedocs.io) •
  Quick Start •
  Features •
  Security

  Anteroom - Midnight Theme

---

## Why Anteroom?

An **anteroom** is the private chamber just outside a larger hall --- a controlled space where you decide who enters and what leaves. That's exactly what this is: a secure layer on *your* machine between you and any AI, where your conversations never touch someone else's cloud.

Anteroom connects to **any** OpenAI-compatible endpoint --- your company's internal API, OpenAI, Azure, Ollama, LM Studio, or anything else that speaks the OpenAI protocol. Built to [OWASP ASVS L1](SECURITY.md) standards because your conversations deserve real security, not security theater.

> **One command. No cloud. No telemetry. No compromise.**

---

## Quick Start

```bash
pip install anteroom
aroom init         # Interactive setup wizard
```

Or create `~/.anteroom/config.yaml` manually:

```yaml
ai:
  base_url: "https://your-ai-endpoint/v1"
  api_key: "your-api-key"
  model: "gpt-4"
```

```bash
aroom --test       # Verify connection
aroom              # Web UI at http://127.0.0.1:8080
aroom chat         # Terminal CLI
aroom --version    # Show version
```

---

## Features

### Web UI

Full-featured ChatGPT-style interface with conversations, projects, folders, tags, file attachments, MCP tool integration, prompt queuing, canvas panels for AI-generated content (CodeMirror 6 editor), inline safety approvals, command palette, and four built-in themes.

  Midnight Theme
  Dawn Theme

### CLI Chat

An agentic terminal REPL with built-in tools (read/write/edit files, bash, glob, grep, canvas), MCP integration, skills system, safety approval prompts for destructive operations, and Rich markdown rendering. Type while the AI works --- messages queue automatically.

```bash
aroom chat                          # Interactive REPL
aroom chat "explain main.py"        # One-shot mode
aroom chat -c                       # Continue last conversation
aroom chat --model gpt-4o "hello"   # Override model
```

### Shared Core

Both interfaces share the same agent loop, storage layer, and SQLite database. Conversations created in the CLI show up in the web UI, and vice versa.

---

## Security

| Layer | Implementation |
|---|---|
| **Auth** | Session tokens, HttpOnly cookies, HMAC-SHA256 |
| **CSRF** | Per-session double-submit tokens |
| **Headers** | CSP, X-Frame-Options, HSTS, Referrer-Policy |
| **Database** | Parameterized queries, column allowlists, path validation |
| **Input** | DOMPurify, UUID validation, filename sanitization |
| **Rate Limiting** | 120 req/min per IP |
| **Tool Safety** | Destructive action approvals (CLI + Web UI), configurable patterns, sensitive path blocking |
| **MCP Safety** | SSRF protection, shell metacharacter rejection |

Full details in [SECURITY.md](SECURITY.md).

---

## Documentation

For complete documentation including configuration, CLI commands, API reference, themes, MCP setup, skills, and development guides, visit **[anteroom.readthedocs.io](https://anteroom.readthedocs.io)**.

---

## Development

```bash
git clone https://github.com/troylar/anteroom.git
cd anteroom
pip install -e ".[dev]"
pytest tests/ -v
```

| | |
|---|---|
| **Backend** | Python 3.10+, FastAPI, Uvicorn |
| **Frontend** | Vanilla JS, marked.js, highlight.js, KaTeX, CodeMirror 6 |
| **CLI** | Rich, prompt-toolkit, tiktoken |
| **Database** | SQLite with FTS5, WAL journaling |
| **AI** | OpenAI Python SDK (async streaming) |
| **MCP** | Model Context Protocol SDK (stdio + SSE) |

---

  MIT License
  Built for people who care about their conversations.
  anteroom.readthedocs.io (https://anteroom.readthedocs.io)

