-
Notifications
You must be signed in to change notification settings - Fork 1
/
pyproject.toml
137 lines (116 loc) · 3.21 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
[tool.poetry]
name = "dewy"
version = "0.4.0"
description = "Knowledge base service."
authors = ["Ben Chambers <ben.chambers@datastax.com>", "Ryan Michael <ryan.michael@datastax.com>"]
readme = "README.md"
license = "Apache-2.0"
include = [
{ path = "dewy/migrations" },
{ path = "dewy/frontend/dist" },
]
[tool.poetry.scripts]
dewy = "dewy.main:dewy"
[tool.poe.tasks.check-ruff]
help = "Check ruff formatting and checks."
sequence = ["check-ruff-format", "check-ruff-checks"]
[tool.poe.tasks.fix-ruff]
help = "Fix ruff formatting and checks."
sequence = ["fix-ruff-format", "fix-ruff-checks"]
[tool.poe.tasks.check-ruff-checks]
cmd = "ruff check"
[tool.poe.tasks.check-ruff-format]
cmd = "ruff format --check"
[tool.poe.tasks.fix-ruff-checks]
cmd = "ruff check --fix"
[tool.poe.tasks.fix-ruff-format]
cmd = "ruff format"
[tool.poe.tasks.test]
help = "Run unit and feature tests"
cmd = "pytest"
[tool.poe.tasks.extract-openapi]
help = "Update openapi.toml from the swagger docs"
cmd = "python scripts/extract_openapi.py"
[tool.poe.tasks.generate-client]
help = "Generate the openapi client"
cmd = "openapi-python-client generate --path=openapi.yaml --config=openapi_client_config.yaml"
[tool.poe.tasks.update-client]
help = "Update the openapi client"
cmd = "openapi-python-client update --path=openapi.yaml --config=openapi_client_config.yaml"
[tool.poetry.dependencies]
python = ">=3.11,<3.12"
pydantic = "^2.5.3"
pydantic-settings = "^2.1.0"
fastapi = "^0.108.0"
uvicorn = "^0.25.0"
pymupdf = "^1.23.8"
llama-index = "^0.9.28"
loguru = "^0.7.2"
accelerate = "^0.26.1"
safetensors = "^0.4.1"
asyncpg = "^0.29.0"
pgvector = "^0.2.4"
numpy = "^1.26.3"
transformers = "^4.37.1"
python-multipart = "^0.0.7"
langchain-core = "^0.1.27"
langchain-openai = "^0.0.8"
langchain-community = "^0.0.24"
langchain = "^0.1.9"
click = "^8.1.7"
sentence-transformers = "^2.5.0"
unstructured = { version = "^0.12.5", extras = ["html", "docx", "doc", "md", "pdf"] }
markdown = "^3.5.2"
docx = "^0.2.4"
taskiq = { version = "^0.11.0", extras = ["cbor"] }
taskiq-aio-pika = "^0.4.0"
taskiq-dependencies = "^1.5.1"
python-dotenv = "^1.0.1"
[tool.poetry.group.dev.dependencies]
ruff = "^0.3.0"
mypy = "^1.8.0"
ipykernel = "^6.28.0"
asyncpg-stubs = "^0.29.1"
httpx = "^0.26.0"
pytest = "^7.4.4"
pytest-asyncio = "^0.21.1"
pytest-docker-fixtures = {extras = ["pg"], version = "^1.3.18"}
asgi-lifespan = "^2.1.0"
openapi-python-client = "^0.17.2"
poethepoet = "^0.24.4"
dewy-client = { path = "./dewy-client" }
pytest-timeout = "^2.2.0"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.ruff]
line-length = 98
# Assume Python 3.11.
target-version = "py311"
[tool.ruff.lint]
# Enable Pyflakes `E` and `F` codes by default.
select = [
# Pyflakes
"F",
# Pycodestyle
"E",
"W",
# isort
"I001",
]
ignore = []
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
[tool.ruff.lint.mccabe]
# Unlike Flake8, default to a complexity level of 10.
max-complexity = 10
[tool.mypy]
strict = true
warn_unreachable = true
pretty = true
show_column_numbers = true
show_error_context = true
[tool.pytest.ini_options]
testpaths = ["tests"]
asyncio_mode = "auto"
timeout = 20