chore: update dev environment and sync workflow

- Add nil LSP package to devenv.nix
- Add datasets and rich.progress imports to feature_retrieval.py
- Update pyproject.toml ty environment config
- Expand .stignore with cache directories
- Update uv.lock dependency lock
- Update AGENTS.md, adding the content of development environment11
This commit is contained in:
2026-04-02 14:38:28 +08:00
parent aedcb25610
commit eaf02cc97a
7 changed files with 3937 additions and 3899 deletions

View File

@@ -3,10 +3,11 @@ from typing import Dict, List, Optional, cast
import torch
from database import db_manager
from datasets import load_dataset
from PIL import Image
from PIL.PngImagePlugin import PngImageFile
from torch import nn
from rich.progress import track
from torch import nn
from transformers import (
AutoImageProcessor,
AutoModel,
@@ -15,8 +16,6 @@ from transformers import (
)
from utils.feature_extractor import extract_batch_features
from datasets import load_dataset
def pil_image_to_bytes(image: Image.Image, format: str = "PNG") -> bytes:
"""Convert a PIL Image to bytes in the specified format.