Files
Foxel/MyDbContext.cs
ShiYu 32af3720e3 feat(vector-db): integrate vector database for image search
- Replace pgvector with Microsoft Vector DB for image vector storage and search
- Update Picture model to use float[] instead of Vector type
- Modify PictureService to use VectorDbService for vector search
- Remove vector-related code from MyDbContext
- Add PictureVector model for Vector DB integration
2025-05-31 00:33:37 +08:00

15 lines
555 B
C#

using Foxel.Models.DataBase;
using Microsoft.EntityFrameworkCore;
namespace Foxel;
public class MyDbContext(DbContextOptions<MyDbContext> options) : DbContext(options)
{
public DbSet<Picture> Pictures { get; set; } = null!;
public DbSet<User> Users { get; set; } = null!;
public DbSet<Tag> Tags { get; set; } = null!;
public DbSet<Config> Configs { get; set; } = null!;
public DbSet<Favorite> Favorites { get; set; } = null!;
public DbSet<Album> Albums { get; set; } = null!;
public DbSet<Role> Roles { get; set; } = null!;
}