fix: brain service — pgvector extension init, meili key length
Brain service fully operational: - All 6 containers running - API responds on /api/health - Worker processes items (fetch, screenshot, classify, index) - Tested: link creation, background processing, asset archival Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -27,11 +27,13 @@ app.include_router(router)
|
||||
|
||||
@app.on_event("startup")
|
||||
async def startup():
|
||||
from sqlalchemy import text as sa_text
|
||||
from app.database import engine, Base
|
||||
from app.models.item import Item, ItemAsset, AppLink # noqa: import to register models
|
||||
|
||||
# Create tables if they don't exist
|
||||
# Enable pgvector extension before creating tables
|
||||
async with engine.begin() as conn:
|
||||
await conn.execute(sa_text("CREATE EXTENSION IF NOT EXISTS vector"))
|
||||
await conn.run_sync(Base.metadata.create_all)
|
||||
|
||||
# Ensure Meilisearch index exists
|
||||
|
||||
Reference in New Issue
Block a user