NeMo-Guardrails
/
pyproject.toml
137 строк · 3.6 Кб
1# SPDX-FileCopyrightText: Copyright (c) 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2# SPDX-License-Identifier: Apache-2.0
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15
16[project]
17name = "nemoguardrails"
18description = "NeMo Guardrails is an open-source toolkit for easily adding programmagle guardrails to LLM-based conversational systems."
19authors = [
20{ name = "NVIDIA", email = "nemoguardrails@nvidia.com"}
21]
22license = { file = "LICENSE.md" }
23readme = "README.md"
24dynamic = ["version"]
25classifiers = [
26"Development Status :: 4 - Beta",
27"Intended Audience :: Developers",
28"License :: OSI Approved :: Apache Software License",
29"Programming Language :: Python :: 3",
30"Programming Language :: Python :: 3.8",
31"Programming Language :: Python :: 3.9",
32"Programming Language :: Python :: 3.10",
33"Programming Language :: Python :: 3.11",
34]
35requires-python = ">=3.8"
36
37dependencies = [
38"aiohttp>=3.9.2",
39"annoy>=1.17.3",
40"fastapi>=0.103.0",
41"fastembed>=0.2.2",
42"httpx>=0.24.1",
43"jinja2>=3.1.3",
44# The 0.1.9 has a bug related to SparkLLM which breaks everything.
45"langchain>=0.1.0,<0.2.0,!=0.1.9",
46"langchain-core>=0.1.0,!=0.1.26",
47"langchain-community>=0.0.16,<0.1.0",
48"lark~=1.1.7",
49"nest-asyncio>=1.5.6",
50"prompt-toolkit>=3.0",
51"pydantic>=1.10",
52"pyyaml>=6.0",
53"rich>=13.5.2",
54"simpleeval>=0.9.13",
55"starlette>=0.27.0",
56"typer>=0.7.0",
57"uvicorn>=0.23",
58"watchdog>=3.0.0",
59]
60
61[project.optional-dependencies]
62eval = [
63"tqdm~=4.65",
64"numpy~=1.24"
65]
66openai = [
67"langchain-openai>=0.0.5"
68]
69sdd = [
70"presidio-analyzer>=2.2",
71"presidio-anonymizer>=2.2",
72"spacy>=3.7.2",
73]
74all = [
75"nemoguardrails[eval,sdd,openai]",
76]
77dev = [
78"black==23.3.0",
79"aioresponses>=0.7.6",
80"mypy>=1.1.1",
81"pre-commit>=3.1.1",
82"pylint>=2.17.0",
83"pytest>=7.2.2",
84"pytest-asyncio>=0.21.0",
85"pytest-cov>=4.1.0",
86"pytest-httpx>=0.22.0"
87]
88
89[project.urls]
90homepage = "https://github.com/NVIDIA/nemo-guardrails"
91documentation = "https://github.com/NVIDIA/nemo-guardrails/tree/develop/docs"
92repository = "https://github.com/NVIDIA/nemo-guardrails"
93issues = "https://github.com/NVIDIA/nemo-guardrails/issues"
94changelog = "https://github.com/NVIDIA/NeMo-Guardrails/blob/develop/CHANGELOG.md"
95
96[project.scripts]
97nemoguardrails = "nemoguardrails.__main__:app"
98
99[tool.setuptools]
100license-files = [
101"LICENSE.md",
102"LICENSE-Apache-2.0.txt",
103"LICENCES-3rd-party.txt"
104]
105
106[tool.setuptools.packages.find]
107where = ["."]
108include = ["nemoguardrails*"]
109
110[tool.setuptools.dynamic]
111version = {attr = "nemoguardrails.__version__"}
112
113[tool.setuptools.package-data]
114nemoguardrails = [
115"**/*.yml",
116"**/*.co",
117"**/*.txt",
118"**/*.json",
119"**/*.lark",
120"../examples/**/*",
121"../chat-ui/**/*",
122"eval/data/**/*",
123]
124
125[tool.pytest.ini_options]
126addopts = "-p no:warnings"
127log-level = "DEBUG"
128
129# The flag below should only be activated in special debug sessions
130# i.e. the test hangs and we need to see what happened up to that point.
131# There are some race conditions with how the logging streams are closed in the teardown
132# phase, which will cause tests to fail or "magically" ignored.
133log_cli = "False"
134
135[build-system]
136requires = ["setuptools"]
137build-backend = "setuptools.build_meta"
138