Skip to content

backroot/genai-labs

Repository files navigation

GenAI Labs App

A web application for comparing and evaluating generative AI models. Built as a monorepo using React + Hono + PostgreSQL.

Structure

  • apps/web: Frontend (React + Vite + Tailwind + shadcn/ui)
  • apps/api: Backend API (Hono + Onion Architecture)
  • packages/shared: Shared types & schemas

Quick Start

pnpm install
cp .env.example .env
pnpm --filter @app/api prisma:generate
pnpm --filter @app/api prisma:migrate
pnpm dev

Docker Compose

docker compose up --build

DevContainer

  • API development: .devcontainer/devcontainer.json or .devcontainer/api/devcontainer.json
  • Frontend development: .devcontainer/web/devcontainer.json
  • Both use runServices to start postgres/redis/litellm/api/web

Key Features

  • Side-by-side comparison chat
  • Streaming responses
  • Conversation history / rename / delete / export
  • Prompt template management
  • Model settings, tag management, token/response time tracking
  • OAuth2 + JWT + RBAC
  • OpenAPI documentation

API Documentation

  • Swagger UI: http://localhost:8787/swagger
  • OpenAPI JSON: http://localhost:8787/openapi.json

Notes

  • For development purposes, /api/v1/auth/oauth/callback is implemented as a simple endpoint that receives the result after an OAuth code exchange.
  • For production use, implement the Authorization Code Flow for each IdP (Google/GitHub/Microsoft) separately.

About

GenAI Labs WebApp

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors