Add vibe-aware playlists with CLAP text embeddings
Blend taste profile with text-embedded mood descriptions (e.g. "chill ambient lo-fi") using pre-blended vector search against the existing HNSW index. New optional `vibe` and `alpha` params on playlist generate and recommendations endpoints. Backward compatible — no vibe = pure taste profile (alpha=1.0). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -94,6 +94,8 @@ class Playlist(Base):
|
||||
name: Mapped[str | None] = mapped_column(Text)
|
||||
known_pct: Mapped[int] = mapped_column(Integer, nullable=False)
|
||||
total_tracks: Mapped[int] = mapped_column(Integer, nullable=False)
|
||||
vibe: Mapped[str | None] = mapped_column(Text)
|
||||
alpha: Mapped[float | None] = mapped_column(REAL)
|
||||
created_at: Mapped[datetime] = mapped_column(DateTime(timezone=True), server_default=func.now())
|
||||
|
||||
tracks: Mapped[list["PlaylistTrack"]] = relationship(back_populates="playlist", cascade="all, delete-orphan")
|
||||
|
||||
Reference in New Issue
Block a user