feat(search): add hybrid search with Reciprocal Rank Fusion #31
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| backend: | |
| name: Go | |
| runs-on: ubuntu-latest | |
| services: | |
| postgres: | |
| image: pgvector/pgvector:pg16 | |
| env: | |
| POSTGRES_USER: mycelium | |
| POSTGRES_PASSWORD: mycelium | |
| POSTGRES_DB: mycelium | |
| ports: | |
| - 5433:5432 | |
| options: >- | |
| --health-cmd="pg_isready -U mycelium" | |
| --health-interval=5s | |
| --health-timeout=5s | |
| --health-retries=5 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| - name: Apply schema | |
| run: psql $DATABASE_URL -f internal/db/schema.sql | |
| env: | |
| DATABASE_URL: postgres://mycelium:mycelium@localhost:5433/mycelium?sslmode=disable | |
| - name: Vet | |
| run: go vet ./... | |
| - name: Test | |
| run: go test ./... -v | |
| env: | |
| DATABASE_URL: postgres://mycelium:mycelium@localhost:5433/mycelium?sslmode=disable | |
| frontend: | |
| name: Next.js | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| cache-dependency-path: frontend/package-lock.json | |
| - name: Install | |
| run: cd frontend && npm ci | |
| - name: Build | |
| run: cd frontend && npm run build |