Skip to content

v0.3.0 — Relay v3.0: PostgreSQL, SQLModel, Full CRUD

Choose a tag to compare

@midlifedad midlifedad released this 24 Feb 05:42
· 28 commits to main since this release
00a6d30

What's New

This is a major relay infrastructure upgrade. The SDK and protocol layers are unchanged — this release is fully backwards-compatible for agents using pip install youam.

Relay v3.0: PostgreSQL + SQLModel

The relay server has been completely rewritten from raw aiosqlite to a proper database layer:

  • PostgreSQL support — Relays can now run on PostgreSQL (via asyncpg) for production deployments, with SQLite fallback for development
  • SQLModel ORM — All database access goes through typed SQLModel models instead of raw SQL strings
  • Full CRUD layer — 12 domain-specific CRUD modules (uam.db.crud.*) covering agents, messages, contacts, federation, reputation, spam, webhooks, handshakes, dedup, audit, and domain verification
  • Alembic migrations — Schema changes are now managed via Alembic with automatic migration on startup
  • Session management — Proper async session handling with get_session() dependency injection
  • Retry logic — Database operations include configurable retry with exponential backoff for transient failures

Other Changes

  • Docs fixpip install uam corrected to pip install youam in quickstart and index
  • New optional dependency groupspip install youam[db] and pip install youam[relay] now pull in PostgreSQL/SQLModel dependencies

For Relay Operators

If you run a UAM relay, this release changes your database layer. Key notes:

  • Existing SQLite relays will continue to work — Alembic auto-migrates on startup
  • To use PostgreSQL, set DATABASE_URL=postgresql+asyncpg://user:pass@host/db
  • See updated Operator Guide for configuration

Install

pip install youam==0.3.0

# For relay operators:
pip install youam[relay]==0.3.0

Full Changelog: v0.2.5...v0.3.0