Ankk98/maml-api

★ 0Forks 0PythonGitHub ↗Compare

README

maml-api

API service for Mind and Motion Labs APIs. Currently, focused on Action100M like automatic video action annotation API.

  • Base path: /v1
  • Docs: Served at /api/docs
  • Auth: Bearer token or X-API-Key header

Features

  • POST /v1/action-annotations/video — Synchronous video action annotations (multipart: video_file or video_url, segment length bounds, hierarchy flag). Pipeline: V-JEPA → PLM → Llama → GPT-OSS (always via gptoss service).
  • GET /v1/health — Health check for API and model services (vjepa, plm, llama, gptoss).

Stateless, no database. Request timeout 45 minutes. Structured logging with request_id.

Quick start

# Use uv (do not pollute host; run in venv/container only)
uv sync
source .venv/bin/activate   # or .venv\Scripts\activate on Windows
uv run uvicorn api.main:app --host 0.0.0.0 --port 8000

With Docker Compose (recommended):

docker compose up --build

OpenRouter mode (configure gptoss-reasoner to call OpenRouter):

export OPENROUTER_API_KEY=your-openrouter-key
docker compose -f docker-compose.openrouter.yml up --build

See docs/SETUP.md for step-by-step setup.

Repo layout

maml-api/
├── api/
│   ├── main.py           # FastAPI app
│   ├── config.py         # Settings
│   ├── auth.py           # Bearer / X-API-Key
│   ├── models/           # Pydantic request/response
│   ├── routes/           # Endpoints
│   ├── services/         # vjepa, plm, llama, gptoss clients
│   └── core/             # Logging, exceptions
├── docs/
│   └── SETUP.md
├── docker-compose.yml
├── Dockerfile
├── pyproject.toml
└── README.md

License

Proprietary — Mind and Motion Labs.

Contributors

Ankk98

Issues