[project] name = "engine" version = "0.1.0" description = "AI Document Engine" requires-python = ">=3.13" dependencies = [ "fastapi>=0.116.0", "pgvector>=0.3.6", "psycopg[binary]>=3.2", "pydantic>=2.0.0", "pydantic-ai>=1.67.0", "pydantic-ai-slim[voyageai]>=1.67.0", "pydantic-settings>=2.0.0", "python-dotenv>=1.2.1", "sqlite-vec>=0.1.6", "uvicorn>=0.35.0", "opentelemetry-sdk>=1.39.0", "posthog>=3.0.0", ] [dependency-groups] dev = [ "anyio>=4.0.0", "datamodel-code-generator[ruff]>=0.26.0", "pytest>=8.0.0", "pyrefly==1.0.0", "referencing>=0.35.0", "ruff>=0.14.10", ] [build-system] requires = ["hatchling"] build-backend = "hatchling.build" [tool.hatch.build.targets.wheel] packages = ["src"] exclude = [ "tests", ] [tool.ruff] line-length = 120 target-version = "py313" [tool.ruff.lint] select = [ "E", "F", "I", "N", "W", "RUF100", "UP", "PYI", # flake8-pyi: flags deprecated typing constructs "FA", # flake8-future-annotations: flags missing future annotations imports "BLE", # flake8-blind-except: flags bare `except Exception` ] [tool.pytest.ini_options] testpaths = ["tests"] # ``tests`` is on the path so test modules can import shared helpers (e.g. # ``from conftest import build_app_settings``) without packaging the tests dir. pythonpath = ["src", "tests"] # Use importlib import mode so test directories don't need __init__.py files # and duplicate basenames (e.g. multiple test_routes.py) collect cleanly. addopts = "--import-mode=importlib" [tool.pyrefly] python-version = "3.13.0" search-path = [ "src", "tests", ] # Disallow `type: ignore` comments to encourage accurate error codes to be used in ignore comments # Pyrefly won't flag `type: ignore [wrong-code]`, but it will flag `pyrefly: ignore [wrong-code]` enabled-ignores = ["pyrefly"] min-severity = "warn" # TODO: Change settings below to `warn` - https://github.com/facebook/pyrefly/issues/3370 [tool.pyrefly.errors] deprecated = "error" implicit-any = "error" redundant-cast = "error" unused-ignore = "error" # TODO: Add equivalents to: # - reportImportCycles # - reportUnusedImport