langroid 0.1.257__py3-none-any.whl → 0.1.258__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {langroid-0.1.257.dist-info → langroid-0.1.258.dist-info}/METADATA +46 -40
- {langroid-0.1.257.dist-info → langroid-0.1.258.dist-info}/RECORD +5 -4
- pyproject.toml +233 -0
- {langroid-0.1.257.dist-info → langroid-0.1.258.dist-info}/LICENSE +0 -0
- {langroid-0.1.257.dist-info → langroid-0.1.258.dist-info}/WHEEL +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: langroid
|
3
|
-
Version: 0.1.
|
3
|
+
Version: 0.1.258
|
4
4
|
Summary: Harness LLMs with Multi-Agent Programming
|
5
5
|
License: MIT
|
6
6
|
Author: Prasad Chalasani
|
@@ -10,13 +10,14 @@ Classifier: License :: OSI Approved :: MIT License
|
|
10
10
|
Classifier: Programming Language :: Python :: 3
|
11
11
|
Classifier: Programming Language :: Python :: 3.10
|
12
12
|
Classifier: Programming Language :: Python :: 3.11
|
13
|
+
Provides-Extra: all
|
13
14
|
Provides-Extra: chainlit
|
14
15
|
Provides-Extra: chromadb
|
15
16
|
Provides-Extra: db
|
16
17
|
Provides-Extra: doc-chat
|
17
18
|
Provides-Extra: docx
|
18
|
-
Provides-Extra: embeddings
|
19
19
|
Provides-Extra: hf-embeddings
|
20
|
+
Provides-Extra: hf-transformers
|
20
21
|
Provides-Extra: lancedb
|
21
22
|
Provides-Extra: litellm
|
22
23
|
Provides-Extra: meilisearch
|
@@ -31,11 +32,12 @@ Provides-Extra: scrapy
|
|
31
32
|
Provides-Extra: sql
|
32
33
|
Provides-Extra: transformers
|
33
34
|
Provides-Extra: unstructured
|
35
|
+
Provides-Extra: vecdbs
|
34
36
|
Requires-Dist: aiohttp (>=3.9.1,<4.0.0)
|
35
37
|
Requires-Dist: async-generator (>=1.10,<2.0)
|
36
38
|
Requires-Dist: bs4 (>=0.0.1,<0.0.2)
|
37
|
-
Requires-Dist: chainlit (>=1.0.400,<2.0.0) ; extra == "chainlit"
|
38
|
-
Requires-Dist: chromadb (>=0.4.21,<=0.4.23) ; extra == "chromadb"
|
39
|
+
Requires-Dist: chainlit (>=1.0.400,<2.0.0) ; extra == "all" or extra == "chainlit"
|
40
|
+
Requires-Dist: chromadb (>=0.4.21,<=0.4.23) ; extra == "vecdbs" or extra == "all" or extra == "chromadb"
|
39
41
|
Requires-Dist: colorlog (>=6.7.0,<7.0.0)
|
40
42
|
Requires-Dist: docstring-parser (>=0.15,<0.16)
|
41
43
|
Requires-Dist: duckduckgo-search (>=6.0.0,<7.0.0)
|
@@ -47,47 +49,38 @@ Requires-Dist: google-generativeai (>=0.5.2,<0.6.0)
|
|
47
49
|
Requires-Dist: groq (>=0.5.0,<0.6.0)
|
48
50
|
Requires-Dist: grpcio (>=1.62.1,<2.0.0)
|
49
51
|
Requires-Dist: halo (>=0.0.31,<0.0.32)
|
50
|
-
Requires-Dist: huggingface-hub (>=0.21.2,<0.22.0) ; extra == "
|
52
|
+
Requires-Dist: huggingface-hub (>=0.21.2,<0.22.0) ; extra == "hf-transformers" or extra == "all" or extra == "transformers"
|
51
53
|
Requires-Dist: jinja2 (>=3.1.2,<4.0.0)
|
52
|
-
Requires-Dist: lancedb (>=0.6.2,<0.7.0) ; extra == "lancedb"
|
53
|
-
Requires-Dist: litellm (>=1.30.1,<2.0.0) ; extra == "litellm"
|
54
|
+
Requires-Dist: lancedb (>=0.6.2,<0.7.0) ; extra == "vecdbs" or extra == "all" or extra == "lancedb"
|
55
|
+
Requires-Dist: litellm (>=1.30.1,<2.0.0) ; extra == "all" or extra == "litellm"
|
54
56
|
Requires-Dist: lxml (>=4.9.3,<5.0.0)
|
55
57
|
Requires-Dist: meilisearch (>=0.28.3,<0.29.0) ; extra == "meilisearch"
|
56
58
|
Requires-Dist: meilisearch-python-sdk (>=2.2.3,<3.0.0) ; extra == "meilisearch"
|
57
|
-
Requires-Dist: metaphor-python (>=0.1.23,<0.2.0) ; extra == "metaphor"
|
58
|
-
Requires-Dist: mkdocs (>=1.4.2,<2.0.0) ; extra == "mkdocs"
|
59
|
-
Requires-Dist: mkdocs-awesome-pages-plugin (>=2.8.0,<3.0.0) ; extra == "mkdocs"
|
60
|
-
Requires-Dist: mkdocs-gen-files (>=0.4.0,<0.5.0) ; extra == "mkdocs"
|
61
|
-
Requires-Dist: mkdocs-jupyter (>=0.24.1,<0.25.0) ; extra == "mkdocs"
|
62
|
-
Requires-Dist: mkdocs-literate-nav (>=0.6.0,<0.7.0) ; extra == "mkdocs"
|
63
|
-
Requires-Dist: mkdocs-material (>=9.1.5,<10.0.0) ; extra == "mkdocs"
|
64
|
-
Requires-Dist: mkdocs-rss-plugin (>=1.8.0,<2.0.0) ; extra == "mkdocs"
|
65
|
-
Requires-Dist: mkdocs-section-index (>=0.3.5,<0.4.0) ; extra == "mkdocs"
|
66
|
-
Requires-Dist: mkdocstrings[python] (>=0.21.2,<0.22.0) ; extra == "mkdocs"
|
59
|
+
Requires-Dist: metaphor-python (>=0.1.23,<0.2.0) ; extra == "all" or extra == "metaphor"
|
67
60
|
Requires-Dist: momento (>=1.10.2,<2.0.0) ; extra == "momento"
|
68
|
-
Requires-Dist: neo4j (>=5.14.1,<6.0.0) ; extra == "neo4j"
|
61
|
+
Requires-Dist: neo4j (>=5.14.1,<6.0.0) ; extra == "all" or extra == "neo4j"
|
69
62
|
Requires-Dist: nest-asyncio (>=1.6.0,<2.0.0)
|
70
63
|
Requires-Dist: nltk (>=3.8.1,<4.0.0)
|
71
64
|
Requires-Dist: onnxruntime (>=1.16.1,<2.0.0)
|
72
65
|
Requires-Dist: openai (>=1.14.0,<2.0.0)
|
73
66
|
Requires-Dist: pandas (>=2.0.3,<3.0.0)
|
74
|
-
Requires-Dist: pdf2image (>=1.17.0,<2.0.0) ; extra == "doc-chat" or extra == "pdf-parsers"
|
75
|
-
Requires-Dist: pdfplumber (>=0.10.2,<0.11.0) ; extra == "doc-chat" or extra == "pdf-parsers"
|
67
|
+
Requires-Dist: pdf2image (>=1.17.0,<2.0.0) ; extra == "doc-chat" or extra == "all" or extra == "pdf-parsers"
|
68
|
+
Requires-Dist: pdfplumber (>=0.10.2,<0.11.0) ; extra == "doc-chat" or extra == "all" or extra == "pdf-parsers"
|
76
69
|
Requires-Dist: prettytable (>=3.8.0,<4.0.0)
|
77
|
-
Requires-Dist: psycopg2 (>=2.9.7,<3.0.0) ; extra == "db" or extra == "postgres" or extra == "sql"
|
78
|
-
Requires-Dist: pyarrow (==15.0.0) ; extra == "lancedb"
|
70
|
+
Requires-Dist: psycopg2 (>=2.9.7,<3.0.0) ; extra == "db" or extra == "all" or extra == "postgres" or extra == "sql"
|
71
|
+
Requires-Dist: pyarrow (==15.0.0) ; extra == "vecdbs" or extra == "all" or extra == "lancedb"
|
79
72
|
Requires-Dist: pydantic (==1.10.13)
|
80
73
|
Requires-Dist: pygithub (>=1.58.1,<2.0.0)
|
81
74
|
Requires-Dist: pygments (>=2.15.1,<3.0.0)
|
82
|
-
Requires-Dist: pymupdf (>=1.23.3,<2.0.0) ; extra == "doc-chat" or extra == "pdf-parsers"
|
83
|
-
Requires-Dist: pymysql (>=1.1.0,<2.0.0) ; extra == "db" or extra == "mysql" or extra == "sql"
|
75
|
+
Requires-Dist: pymupdf (>=1.23.3,<2.0.0) ; extra == "doc-chat" or extra == "all" or extra == "pdf-parsers"
|
76
|
+
Requires-Dist: pymysql (>=1.1.0,<2.0.0) ; extra == "db" or extra == "all" or extra == "mysql" or extra == "sql"
|
84
77
|
Requires-Dist: pyparsing (>=3.0.9,<4.0.0)
|
85
|
-
Requires-Dist: pypdf (>=3.12.2,<4.0.0) ; extra == "doc-chat" or extra == "pdf-parsers"
|
86
|
-
Requires-Dist: pytesseract (>=0.3.10,<0.4.0) ; extra == "doc-chat" or extra == "pdf-parsers"
|
87
|
-
Requires-Dist: python-docx (>=1.1.0,<2.0.0) ; extra == "doc-chat" or extra == "docx"
|
78
|
+
Requires-Dist: pypdf (>=3.12.2,<4.0.0) ; extra == "doc-chat" or extra == "all" or extra == "pdf-parsers"
|
79
|
+
Requires-Dist: pytesseract (>=0.3.10,<0.4.0) ; extra == "doc-chat" or extra == "all" or extra == "pdf-parsers"
|
80
|
+
Requires-Dist: python-docx (>=1.1.0,<2.0.0) ; extra == "doc-chat" or extra == "all" or extra == "docx"
|
88
81
|
Requires-Dist: python-dotenv (>=1.0.0,<2.0.0)
|
89
82
|
Requires-Dist: python-magic (>=0.4.27,<0.5.0)
|
90
|
-
Requires-Dist: python-socketio (>=5.11.0,<6.0.0) ; extra == "chainlit"
|
83
|
+
Requires-Dist: python-socketio (>=5.11.0,<6.0.0) ; extra == "all" or extra == "chainlit"
|
91
84
|
Requires-Dist: pyyaml (>=6.0.1,<7.0.0)
|
92
85
|
Requires-Dist: qdrant-client (>=1.8.0,<2.0.0)
|
93
86
|
Requires-Dist: rank-bm25 (>=0.2.2,<0.3.0)
|
@@ -96,16 +89,16 @@ Requires-Dist: requests (>=2.31.0,<3.0.0)
|
|
96
89
|
Requires-Dist: requests-oauthlib (>=1.3.1,<2.0.0)
|
97
90
|
Requires-Dist: rich (>=13.3.4,<14.0.0)
|
98
91
|
Requires-Dist: scrapy (>=2.11.0,<3.0.0) ; extra == "scrapy"
|
99
|
-
Requires-Dist: sentence-transformers (==2.2.2) ; extra == "
|
100
|
-
Requires-Dist: sqlalchemy (>=2.0.19,<3.0.0) ; extra == "db" or extra == "sql"
|
101
|
-
Requires-Dist: tantivy (>=0.21.0,<0.22.0) ; extra == "lancedb"
|
92
|
+
Requires-Dist: sentence-transformers (==2.2.2) ; extra == "hf-transformers" or extra == "all" or extra == "hf-embeddings"
|
93
|
+
Requires-Dist: sqlalchemy (>=2.0.19,<3.0.0) ; extra == "db" or extra == "all" or extra == "sql"
|
94
|
+
Requires-Dist: tantivy (>=0.21.0,<0.22.0) ; extra == "vecdbs" or extra == "all" or extra == "lancedb"
|
102
95
|
Requires-Dist: thefuzz (>=0.20.0,<0.21.0)
|
103
96
|
Requires-Dist: tiktoken (>=0.7.0,<0.8.0)
|
104
|
-
Requires-Dist: torch (==2.0.0) ; extra == "
|
97
|
+
Requires-Dist: torch (==2.0.0) ; extra == "hf-transformers" or extra == "all" or extra == "hf-embeddings" or extra == "transformers"
|
105
98
|
Requires-Dist: trafilatura (>=1.5.0,<2.0.0)
|
106
|
-
Requires-Dist: transformers (>=4.40.1,<5.0.0) ; extra == "
|
99
|
+
Requires-Dist: transformers (>=4.40.1,<5.0.0) ; extra == "hf-transformers" or extra == "all" or extra == "transformers"
|
107
100
|
Requires-Dist: typer (>=0.9.0,<0.10.0)
|
108
|
-
Requires-Dist: unstructured[docx,pdf,pptx] (>=0.10.16,<0.10.18) ; extra == "doc-chat" or extra == "unstructured"
|
101
|
+
Requires-Dist: unstructured[docx,pdf,pptx] (>=0.10.16,<0.10.18) ; extra == "doc-chat" or extra == "all" or extra == "unstructured"
|
109
102
|
Requires-Dist: wget (>=3.2,<4.0)
|
110
103
|
Description-Content-Type: text/markdown
|
111
104
|
|
@@ -234,12 +227,22 @@ teacher_task.run()
|
|
234
227
|
<summary> <b>Click to expand</b></summary>
|
235
228
|
|
236
229
|
- **May 2024:**
|
230
|
+
- **Slimmer langroid**: All document-parsers (i.e. pdf, doc, docx) and most
|
231
|
+
vector-databases (except qdrant)
|
232
|
+
are now optional/extra dependencies, which helps reduce build size, script
|
233
|
+
start-up time, and install time. For convenience various grouping of "extras" are
|
234
|
+
provided, e.g. `doc-chat`, `db` (for database-related dependencies). See updated
|
235
|
+
install instructions below and in the docs.
|
236
|
+
- **Few-shot examples** for tools: when defining a [ToolMessage](https://langroid.github.io/langroid/quick-start/chat-agent-tool/#example-find-the-smallest-number-in-a-list), previously you were able to include a classmethod named `examples`,
|
237
|
+
and a random example from this list would be used to generate a 1-shot example
|
238
|
+
for the LLM. This has been improved so you can now supply a list of examples
|
239
|
+
where each example is either a tool instance, or a tuple of (description,
|
240
|
+
tool instance), where the description is a "thought" that leads the LLM to use
|
241
|
+
the tool (see example in the [docs](https://langroid.github.io/langroid/quick-start/chat-agent-tool/#example-find-the-smallest-number-in-a-list)). In some scenarios this can improve LLM tool
|
242
|
+
generation accuracy. Also, now instead of a random example, ALL examples are used to generate few-shot
|
243
|
+
examples.
|
237
244
|
- [Infinite loop detection](https://github.com/langroid/langroid/blob/0ed30eb467b00d5eaf2933b577a4b2cc37de1aa1/langroid/agent/task.py#L1121) for task loops of cycle-length <= 10 (configurable
|
238
|
-
in [`TaskConfig`](https://github.
|
239
|
-
com/langroid/langroid/blob/0ed30eb467b00d5eaf2933b577a4b2cc37de1aa1/langroid/agent
|
240
|
-
/task.py#L61). Only detects _exact_ loops, rather than
|
241
|
-
_approximate_ loops where the entities are saying essentially similar (but not
|
242
|
-
exactly the same) things repeatedly.
|
245
|
+
in [`TaskConfig`](https://langroid.github.io/langroid/reference/agent/task/#langroid.agent.task.TaskConfig). Only detects _exact_ loops, rather than _approximate_ loops where the entities are saying essentially similar (but not exactly the same) things repeatedly.
|
243
246
|
- "@"-addressing: any entity can address any other by name, which can be the name
|
244
247
|
of an agent's responder ("llm", "user", "agent") or a sub-task name. This is a
|
245
248
|
simpler alternative to the `RecipientTool` mechanism, with the tradeoff that
|
@@ -489,7 +492,10 @@ For many practical scenarios, you may need additional optional dependencies:
|
|
489
492
|
```bash
|
490
493
|
pip install "langroid[doc-chat,db]"
|
491
494
|
```
|
492
|
-
|
495
|
+
- To simply install _all_ optional dependencies, use the `all` extra (but note that this will result in longer load/startup times and a larger install size):
|
496
|
+
```bash
|
497
|
+
pip install "langroid[all]"
|
498
|
+
```
|
493
499
|
<details>
|
494
500
|
<summary><b>Optional Installs for using SQL Chat with a PostgreSQL DB </b></summary>
|
495
501
|
|
@@ -126,7 +126,8 @@ langroid/vector_store/meilisearch.py,sha256=6frB7GFWeWmeKzRfLZIvzRjllniZ1cYj3Hmh
|
|
126
126
|
langroid/vector_store/momento.py,sha256=QaPzUnTwlswoawGB-paLtUPyLRvckFXLfLDfvbTzjNQ,10505
|
127
127
|
langroid/vector_store/qdrant_cloud.py,sha256=3im4Mip0QXLkR6wiqVsjV1QvhSElfxdFSuDKddBDQ-4,188
|
128
128
|
langroid/vector_store/qdrantdb.py,sha256=sk5Qb2ZNbooi0rorsMuqIMokF7WADw6PJ0D6goM2XBw,16802
|
129
|
-
|
130
|
-
langroid-0.1.
|
131
|
-
langroid-0.1.
|
132
|
-
langroid-0.1.
|
129
|
+
pyproject.toml,sha256=fDctkmdTjKOSWnSdsYxFKf-Ud0ESk7f4DI_0vE47dpk,7026
|
130
|
+
langroid-0.1.258.dist-info/LICENSE,sha256=EgVbvA6VSYgUlvC3RvPKehSg7MFaxWDsFuzLOsPPfJg,1065
|
131
|
+
langroid-0.1.258.dist-info/METADATA,sha256=vtecA1CocyelLpV30tpccSfGuwVCRtW8nMAIxH2Vkyg,52414
|
132
|
+
langroid-0.1.258.dist-info/WHEEL,sha256=FMvqSimYX_P7y0a7UY-_Mc83r5zkBZsCYPm7Lr0Bsq4,88
|
133
|
+
langroid-0.1.258.dist-info/RECORD,,
|
pyproject.toml
ADDED
@@ -0,0 +1,233 @@
|
|
1
|
+
[tool.poetry]
|
2
|
+
name = "langroid"
|
3
|
+
version = "0.1.258"
|
4
|
+
description = "Harness LLMs with Multi-Agent Programming"
|
5
|
+
authors = ["Prasad Chalasani <pchalasani@gmail.com>"]
|
6
|
+
readme = "README.md"
|
7
|
+
license = "MIT"
|
8
|
+
include = ["pyproject.toml"]
|
9
|
+
|
10
|
+
|
11
|
+
# =============== MAIN DEPS ==============
|
12
|
+
[tool.poetry.dependencies]
|
13
|
+
python = ">=3.10,<3.12"
|
14
|
+
|
15
|
+
# =========== OPTIONALS ==============================
|
16
|
+
chromadb = {version=">=0.4.21, <=0.4.23", optional=true}
|
17
|
+
momento = {version="^1.10.2", optional=true}
|
18
|
+
unstructured = {extras = ["docx", "pptx", "pdf"], version = ">=0.10.16,<0.10.18", optional=true}
|
19
|
+
sentence-transformers = {version="2.2.2", optional=true}
|
20
|
+
torch = {version="2.0.0", optional=true}
|
21
|
+
psycopg2 = {version="^2.9.7", optional=true}
|
22
|
+
pymysql = {version = "^1.1.0", optional = true}
|
23
|
+
meilisearch = {version="^0.28.3", optional=true}
|
24
|
+
meilisearch-python-sdk = {version="^2.2.3", optional=true}
|
25
|
+
litellm = {version = "^1.30.1", optional = true}
|
26
|
+
metaphor-python = {version = "^0.1.23", optional = true}
|
27
|
+
chainlit = {version = "^1.0.400", optional = true}
|
28
|
+
python-socketio = {version="^5.11.0", optional=true}
|
29
|
+
neo4j = {version = "^5.14.1", optional = true}
|
30
|
+
huggingface-hub = {version="^0.21.2", optional=true}
|
31
|
+
transformers = {version="^4.40.1", optional=true}
|
32
|
+
lancedb = {version="^0.6.2", optional=true}
|
33
|
+
tantivy = {version="^0.21.0", optional=true}
|
34
|
+
pypdf = {version="^3.12.2", optional=true}
|
35
|
+
pymupdf = {version="^1.23.3", optional=true}
|
36
|
+
pdf2image = {version="^1.17.0", optional=true}
|
37
|
+
pytesseract = {version="^0.3.10", optional=true}
|
38
|
+
sqlalchemy = {version="^2.0.19", optional=true}
|
39
|
+
pyarrow = {version="15.0.0", optional=true}
|
40
|
+
pdfplumber = {version="^0.10.2", optional=true}
|
41
|
+
python-docx = {version="^1.1.0", optional=true}
|
42
|
+
scrapy = {version="^2.11.0", optional=true}
|
43
|
+
|
44
|
+
# ====CORE================================
|
45
|
+
pyyaml = "^6.0.1"
|
46
|
+
onnxruntime = "^1.16.1"
|
47
|
+
fire = "^0.5.0"
|
48
|
+
bs4 = "^0.0.1"
|
49
|
+
python-dotenv = "^1.0.0"
|
50
|
+
wget = "^3.2"
|
51
|
+
rich = "^13.3.4"
|
52
|
+
requests-oauthlib = "^1.3.1"
|
53
|
+
trafilatura = "^1.5.0"
|
54
|
+
halo = "^0.0.31"
|
55
|
+
typer = "^0.9.0"
|
56
|
+
colorlog = "^6.7.0"
|
57
|
+
openai = "^1.14.0"
|
58
|
+
tiktoken = "^0.7.0"
|
59
|
+
pygithub = "^1.58.1"
|
60
|
+
pygments = "^2.15.1"
|
61
|
+
redis = "^5.0.1"
|
62
|
+
fakeredis = "^2.12.1"
|
63
|
+
faker = "^18.9.0"
|
64
|
+
requests = "^2.31.0"
|
65
|
+
pyparsing = "^3.0.9"
|
66
|
+
nltk = "^3.8.1"
|
67
|
+
qdrant-client = "^1.8.0"
|
68
|
+
pydantic = "1.10.13"
|
69
|
+
pandas = "^2.0.3"
|
70
|
+
prettytable = "^3.8.0"
|
71
|
+
|
72
|
+
google-api-python-client = "^2.95.0"
|
73
|
+
lxml = "^4.9.3"
|
74
|
+
|
75
|
+
rank-bm25 = "^0.2.2"
|
76
|
+
thefuzz = "^0.20.0"
|
77
|
+
|
78
|
+
jinja2 = "^3.1.2"
|
79
|
+
docstring-parser = "^0.15"
|
80
|
+
|
81
|
+
aiohttp = "^3.9.1"
|
82
|
+
grpcio = "^1.62.1"
|
83
|
+
duckduckgo-search = "^6.0.0"
|
84
|
+
|
85
|
+
google-generativeai = "^0.5.2"
|
86
|
+
groq = "^0.5.0"
|
87
|
+
nest-asyncio = "^1.6.0"
|
88
|
+
async-generator = "^1.10"
|
89
|
+
|
90
|
+
python-magic = "^0.4.27"
|
91
|
+
|
92
|
+
[tool.poetry.extras]
|
93
|
+
# install these using, e.g.,
|
94
|
+
# `poetry install -E [...]` where [...] is one of the extras below
|
95
|
+
# or install multiple extras using, e.g., `poetry install -E "litellm mysql"
|
96
|
+
|
97
|
+
# Groupings for common use-cases
|
98
|
+
doc-chat = [
|
99
|
+
"unstructured", "python-docx", "pdfplumber", "pypdf",
|
100
|
+
"pymupdf", "pdf2image", "pytesseract"
|
101
|
+
]
|
102
|
+
db = ["postgres", "mysql", "sqlalchemy", "psycopg2", "pymysql"]
|
103
|
+
hf-transformers = ["sentence-transformers", "torch", "transformers", "huggingface-hub"]
|
104
|
+
vecdbs = ["lancedb", "tantivy", "pyarrow", "chromadb"]
|
105
|
+
all = [
|
106
|
+
"unstructured", "python-docx", "pdfplumber", "pypdf",
|
107
|
+
"pymupdf", "pdf2image", "pytesseract",
|
108
|
+
"postgres", "mysql", "sqlalchemy", "psycopg2", "pymysql",
|
109
|
+
"sentence-transformers", "torch", "transformers", "huggingface-hub",
|
110
|
+
"lancedb", "tantivy", "pyarrow", "chromadb",
|
111
|
+
"metaphor-python", "neo4j",
|
112
|
+
"litellm",
|
113
|
+
"chainlit", "python-socketio",
|
114
|
+
]
|
115
|
+
# more granular groupings
|
116
|
+
lancedb = ["lancedb", "tantivy", "pyarrow"]
|
117
|
+
pdf-parsers = ["pdfplumber", "pypdf", "pymupdf", "pdf2image", "pytesseract"]
|
118
|
+
docx = ["python-docx"]
|
119
|
+
scrapy = ["scrapy"]
|
120
|
+
hf-embeddings = ["sentence-transformers", "torch"]
|
121
|
+
transformers = ["transformers", "huggingface-hub", "torch"]
|
122
|
+
unstructured = ["unstructured"]
|
123
|
+
postgres = ["psycopg2"]
|
124
|
+
mysql = ["pymysql"]
|
125
|
+
sql = ["sqlalchemy", "pymysql", "psycopg2"]
|
126
|
+
litellm = ["litellm"]
|
127
|
+
neo4j = ["neo4j"]
|
128
|
+
metaphor = ["metaphor-python"]
|
129
|
+
chainlit = ["chainlit", "python-socketio"]
|
130
|
+
chromadb = ["chromadb"]
|
131
|
+
mkdocs = [
|
132
|
+
"mkdocs", "mkdocs-material", "mkdocstrings", "mkdocs-awesome-pages-plugin",
|
133
|
+
"mkdocs-gen-files", "mkdocs-literate-nav",
|
134
|
+
"mkdocs-section-index", "mkdocs-jupyter", "mkdocs-rss-plugin"
|
135
|
+
]
|
136
|
+
meilisearch = ["meilisearch", "meilisearch-python-sdk"]
|
137
|
+
momento = ["momento"]
|
138
|
+
|
139
|
+
|
140
|
+
# ================= DEV DEPS =================
|
141
|
+
[tool.poetry.group.dev.dependencies]
|
142
|
+
black = {extras = ["jupyter"], version = "^24.3.0"}
|
143
|
+
flake8 = "^6.0.0"
|
144
|
+
mypy = "^1.7.0"
|
145
|
+
ruff = "^0.2.2"
|
146
|
+
pre-commit = "^3.3.2"
|
147
|
+
autopep8 = "^2.0.2"
|
148
|
+
|
149
|
+
types-redis = "^4.5.5.2"
|
150
|
+
types-requests = "^2.31.0.1"
|
151
|
+
types-pyyaml = "^6.0.12.20240311"
|
152
|
+
types-pillow = "^10.2.0.20240406"
|
153
|
+
|
154
|
+
pytest = "^7.3.1"
|
155
|
+
pytest-redis = "^3.0.2"
|
156
|
+
pytest-asyncio = "^0.21.1"
|
157
|
+
pytest-postgresql = "^5.0.0"
|
158
|
+
pytest-mysql = "^2.4.2"
|
159
|
+
coverage = "^7.2.5"
|
160
|
+
|
161
|
+
[tool.poetry.group.docs]
|
162
|
+
optional = true
|
163
|
+
|
164
|
+
[tool.poetry.group.docs.dependencies]
|
165
|
+
|
166
|
+
mkdocs = "^1.4.2"
|
167
|
+
mkdocs-material = "^9.1.5"
|
168
|
+
mkdocstrings = {extras = ["python"], version = "^0.21.2"}
|
169
|
+
mkdocs-awesome-pages-plugin = "^2.8.0"
|
170
|
+
mkdocs-rss-plugin = "^1.8.0"
|
171
|
+
mkdocs-gen-files = "^0.4.0"
|
172
|
+
mkdocs-literate-nav = "^0.6.0"
|
173
|
+
mkdocs-section-index = "^0.3.5"
|
174
|
+
mkdocs-jupyter = "^0.24.1"
|
175
|
+
|
176
|
+
|
177
|
+
|
178
|
+
# ========================================
|
179
|
+
[build-system]
|
180
|
+
requires = ["poetry-core"]
|
181
|
+
build-backend = "poetry.core.masonry.api"
|
182
|
+
|
183
|
+
[tool.black]
|
184
|
+
line-length = 88
|
185
|
+
include = '\.pyi?$'
|
186
|
+
# extend-exclude = '.*pyi$'
|
187
|
+
# exclude = '^stubs/'
|
188
|
+
|
189
|
+
[tool.pytype]
|
190
|
+
inputs = ["langroid"]
|
191
|
+
|
192
|
+
[tool.mypy]
|
193
|
+
python_version = "3.11"
|
194
|
+
#mypy_path = ["stubs"]
|
195
|
+
|
196
|
+
#follow_imports = "skip"
|
197
|
+
#check_untyped_defs = "True"
|
198
|
+
disallow_untyped_defs = "True"
|
199
|
+
ignore_missing_imports = "True"
|
200
|
+
warn_unused_ignores = "False"
|
201
|
+
strict = true
|
202
|
+
exclude = [
|
203
|
+
"docs", ".venv", "venv", "examples", "examples_dev", "langroid/utils/web",
|
204
|
+
"notebooks",
|
205
|
+
"langroid/parsing/repo_loader.py",
|
206
|
+
"langroid/embedding_models/clustering.py",
|
207
|
+
"langroid/agent/callbacks/chainlit.py",
|
208
|
+
"langroid/vector_store/chromadb.py",
|
209
|
+
"langroid/embedding_models/protoc" # ignore generated files
|
210
|
+
]
|
211
|
+
files=["langroid/*"]
|
212
|
+
plugins = [
|
213
|
+
"pydantic.mypy"
|
214
|
+
]
|
215
|
+
|
216
|
+
[tool.ruff]
|
217
|
+
line-length = 88
|
218
|
+
# Allow unused variables when underscore-prefixed.
|
219
|
+
lint.dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
|
220
|
+
# Assume Python 3.11.
|
221
|
+
target-version = "py311"
|
222
|
+
lint.select = [
|
223
|
+
"E", # pycodestyle
|
224
|
+
"F", # pyflakes
|
225
|
+
"I", # isort
|
226
|
+
]
|
227
|
+
lint.exclude = ["docs/**", ".venv", "venv", "examples/**", "examples_dev", "langroid/utils/web", "notebooks", "__init__.py", "langroid/embedding_models/protoc/*"]
|
228
|
+
lint.fixable = ["A", "B", "C", "D", "E", "F", "G", "I", "N", "Q", "S", "T", "W", "ANN", "ARG", "BLE", "COM", "DJ", "DTZ", "EM", "ERA", "EXE", "FBT", "ICN", "INP", "ISC", "NPY", "PD", "PGH", "PIE", "PL", "PT", "PTH", "PYI", "RET", "RSE", "RUF", "SIM", "SLF", "TCH", "TID", "TRY", "UP", "YTT"]
|
229
|
+
lint.unfixable = []
|
230
|
+
lint.extend-ignore = ["F821"]
|
231
|
+
|
232
|
+
[tool.pytest.ini_options]
|
233
|
+
filterwarnings = ["ignore::DeprecationWarning"]
|
File without changes
|
File without changes
|