HowdenParser 3.1.0__tar.gz → 4.0.1__tar.gz
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.
- {howdenparser-3.1.0 → howdenparser-4.0.1}/HowdenParser/parser.py +12 -3
- {howdenparser-3.1.0 → howdenparser-4.0.1}/PKG-INFO +3 -4
- howdenparser-4.0.1/pyproject.toml +48 -0
- howdenparser-3.1.0/pyproject.toml +0 -39
- {howdenparser-3.1.0 → howdenparser-4.0.1}/HowdenParser/__init__.py +0 -0
- {howdenparser-3.1.0 → howdenparser-4.0.1}/HowdenParser/parameter/__init__.py +0 -0
- {howdenparser-3.1.0 → howdenparser-4.0.1}/HowdenParser/parameter/huggingface.py +0 -0
- {howdenparser-3.1.0 → howdenparser-4.0.1}/HowdenParser/parameter/llamaparser.py +0 -0
- {howdenparser-3.1.0 → howdenparser-4.0.1}/HowdenParser/parameter/mistralocr.py +0 -0
- {howdenparser-3.1.0 → howdenparser-4.0.1}/README.md +0 -0
|
@@ -62,7 +62,9 @@ class Parser(BaseParser):
|
|
|
62
62
|
result_type: str,
|
|
63
63
|
mode: bool,
|
|
64
64
|
preserve_layout_alignment_across_pages: bool,
|
|
65
|
-
merge_tables_across_pages_in_markdown: bool
|
|
65
|
+
merge_tables_across_pages_in_markdown: bool,
|
|
66
|
+
hide_footers: bool,
|
|
67
|
+
hide_headers: bool,
|
|
66
68
|
) -> "LlamaParser": ...
|
|
67
69
|
|
|
68
70
|
@overload
|
|
@@ -237,13 +239,18 @@ class LlamaParser(BaseParser, name="llamaparser"):
|
|
|
237
239
|
mode: bool,
|
|
238
240
|
provider_and_model: str,
|
|
239
241
|
merge_tables_across_pages_in_markdown: bool,
|
|
240
|
-
preserve_layout_alignment_across_pages: bool
|
|
242
|
+
preserve_layout_alignment_across_pages: bool,
|
|
243
|
+
hide_footers: bool,
|
|
244
|
+
hide_headers: bool
|
|
245
|
+
) -> None:
|
|
241
246
|
logging.info("Initializing LlamaParser...")
|
|
242
247
|
self.result_type = result_type
|
|
243
248
|
self.mode = mode
|
|
244
249
|
self.provider_and_model = provider_and_model
|
|
245
250
|
self.merge_tables_across_pages_in_markdown = merge_tables_across_pages_in_markdown
|
|
246
251
|
self.preserve_layout_alignment_across_pages = preserve_layout_alignment_across_pages
|
|
252
|
+
self.hide_footers=hide_footers
|
|
253
|
+
self.hide_headers=hide_headers
|
|
247
254
|
|
|
248
255
|
from llama_parse import LlamaParse, ResultType
|
|
249
256
|
if result_type.lower() in ("md", "markdown"):
|
|
@@ -255,7 +262,9 @@ class LlamaParser(BaseParser, name="llamaparser"):
|
|
|
255
262
|
result_type=result_type,
|
|
256
263
|
premium_mode=self.mode,
|
|
257
264
|
merge_tables_across_pages_in_markdown=self.merge_tables_across_pages_in_markdown,
|
|
258
|
-
preserve_layout_alignment_across_pages=self.preserve_layout_alignment_across_pages
|
|
265
|
+
preserve_layout_alignment_across_pages=self.preserve_layout_alignment_across_pages,
|
|
266
|
+
hide_footers=self.hide_footers,
|
|
267
|
+
hide_headers=self.hide_headers)
|
|
259
268
|
|
|
260
269
|
def parse(self, file_path: Path) -> str:
|
|
261
270
|
documents = self._parser.load_data(str(file_path))
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: HowdenParser
|
|
3
|
-
Version:
|
|
3
|
+
Version: 4.0.1
|
|
4
4
|
Summary: A simple configuration manager with Pydantic and JSON export.
|
|
5
5
|
License: MIT
|
|
6
6
|
Keywords: config,configuration,pydantic,json
|
|
@@ -11,6 +11,7 @@ Classifier: License :: OSI Approved :: MIT License
|
|
|
11
11
|
Classifier: Programming Language :: Python :: 3
|
|
12
12
|
Classifier: Programming Language :: Python :: 3.12
|
|
13
13
|
Classifier: Programming Language :: Python :: 3.13
|
|
14
|
+
Provides-Extra: dev
|
|
14
15
|
Requires-Dist: fitz (>=0.0.1.dev2,<0.0.2)
|
|
15
16
|
Requires-Dist: hf-xet (>=1.1.7,<2.0.0)
|
|
16
17
|
Requires-Dist: langchain (>=0.3.27,<0.4.0)
|
|
@@ -18,13 +19,11 @@ Requires-Dist: llama-parse (>=0.6.58,<0.7.0)
|
|
|
18
19
|
Requires-Dist: mistralai (>=1.9.3,<2.0.0)
|
|
19
20
|
Requires-Dist: pdf2image (>=1.17.0,<2.0.0)
|
|
20
21
|
Requires-Dist: pypdf2 (>=3.0.1,<4.0.0)
|
|
22
|
+
Requires-Dist: toml (>=0.10.2,<0.11.0) ; extra == "dev"
|
|
21
23
|
Requires-Dist: torch (>=2.8.0,<3.0.0)
|
|
22
24
|
Requires-Dist: torchaudio (>=2.8.0,<3.0.0)
|
|
23
25
|
Requires-Dist: torchvision (>=0.23.0,<0.24.0)
|
|
24
26
|
Requires-Dist: transformers (>=4.55.2,<5.0.0)
|
|
25
|
-
Project-URL: Documentation, https://github.com/yourusername/config
|
|
26
|
-
Project-URL: Homepage, https://github.com/yourusername/config
|
|
27
|
-
Project-URL: Repository, https://github.com/yourusername/config
|
|
28
27
|
Description-Content-Type: text/markdown
|
|
29
28
|
|
|
30
29
|
# OCR & LLM Parser
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "HowdenParser"
|
|
3
|
+
version = "4.0.1"
|
|
4
|
+
description = "A simple configuration manager with Pydantic and JSON export."
|
|
5
|
+
readme = "README.md"
|
|
6
|
+
requires-python = ">=3.12,<3.14"
|
|
7
|
+
authors = [
|
|
8
|
+
{ name = "JesperThoftIllemannJ", email = "jesper.jaeger@howdendanmark.dk" },
|
|
9
|
+
]
|
|
10
|
+
keywords = [
|
|
11
|
+
"config",
|
|
12
|
+
"configuration",
|
|
13
|
+
"pydantic",
|
|
14
|
+
"json",
|
|
15
|
+
]
|
|
16
|
+
homepage = "https://github.com/yourusername/config"
|
|
17
|
+
repository = "https://github.com/yourusername/config"
|
|
18
|
+
documentation = "https://github.com/yourusername/config"
|
|
19
|
+
dependencies = [
|
|
20
|
+
"mistralai>=1.9.3,<2.0.0",
|
|
21
|
+
"llama-parse>=0.6.58,<0.7.0",
|
|
22
|
+
"langchain>=0.3.27,<0.4.0",
|
|
23
|
+
"transformers>=4.55.2,<5.0.0",
|
|
24
|
+
"fitz>=0.0.1.dev2,<0.0.2",
|
|
25
|
+
"pypdf2>=3.0.1,<4.0.0",
|
|
26
|
+
"pdf2image>=1.17.0,<2.0.0",
|
|
27
|
+
"torch>=2.8.0,<3.0.0",
|
|
28
|
+
"torchvision>=0.23.0,<0.24.0",
|
|
29
|
+
"torchaudio>=2.8.0,<3.0.0",
|
|
30
|
+
"hf-xet>=1.1.7,<2.0.0",
|
|
31
|
+
]
|
|
32
|
+
|
|
33
|
+
[project.license]
|
|
34
|
+
text = "MIT"
|
|
35
|
+
|
|
36
|
+
[project.optional-dependencies]
|
|
37
|
+
dev = [
|
|
38
|
+
"toml>=0.10.2,<0.11.0",
|
|
39
|
+
]
|
|
40
|
+
|
|
41
|
+
[build-system]
|
|
42
|
+
requires = [
|
|
43
|
+
"poetry-core>=2.0.0,<3.0.0",
|
|
44
|
+
]
|
|
45
|
+
build-backend = "poetry.core.masonry.api"
|
|
46
|
+
|
|
47
|
+
[tool.poetry.group.dev.dependencies]
|
|
48
|
+
tomli-w = "^1.2.0"
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
[project]
|
|
2
|
-
name = "HowdenParser"
|
|
3
|
-
description = ""
|
|
4
|
-
readme = "README.md"
|
|
5
|
-
requires-python = ">=3.12,<3.14"
|
|
6
|
-
dependencies = [ "mistralai (>=1.9.3,<2.0.0)", "llama-parse (>=0.6.58,<0.7.0)", "langchain (>=0.3.27,<0.4.0)", "transformers (>=4.55.2,<5.0.0)", "fitz (>=0.0.1.dev2,<0.0.2)", "pypdf2 (>=3.0.1,<4.0.0)", "pdf2image (>=1.17.0,<2.0.0)", "torch (>=2.8.0,<3.0.0)", "torchvision (>=0.23.0,<0.24.0)", "torchaudio (>=2.8.0,<3.0.0)", "hf-xet (>=1.1.7,<2.0.0)",]
|
|
7
|
-
[[project.authors]]
|
|
8
|
-
name = "JesperThoftIllemannJ"
|
|
9
|
-
email = "jesper.jaeger@howdendanmark.dk"
|
|
10
|
-
|
|
11
|
-
[build-system]
|
|
12
|
-
requires = [ "poetry-core>=2.0.0,<3.0.0",]
|
|
13
|
-
build-backend = "poetry.core.masonry.api"
|
|
14
|
-
|
|
15
|
-
[tool.poetry]
|
|
16
|
-
name = "HowdenParser"
|
|
17
|
-
version = "3.1.0"
|
|
18
|
-
description = "A simple configuration manager with Pydantic and JSON export."
|
|
19
|
-
authors = [ "JesperThoftIllemannJ <jesper.jaeger@howdendanmark.dk>",]
|
|
20
|
-
readme = "README.md"
|
|
21
|
-
license = "MIT"
|
|
22
|
-
keywords = [ "config", "configuration", "pydantic", "json",]
|
|
23
|
-
homepage = "https://github.com/yourusername/config"
|
|
24
|
-
repository = "https://github.com/yourusername/config"
|
|
25
|
-
documentation = "https://github.com/yourusername/config"
|
|
26
|
-
[[tool.poetry.packages]]
|
|
27
|
-
include = "HowdenParser"
|
|
28
|
-
|
|
29
|
-
[tool.poetry.dependencies.torch]
|
|
30
|
-
source = "pypi"
|
|
31
|
-
|
|
32
|
-
[tool.poetry.dependencies.torchvision]
|
|
33
|
-
source = "pypi"
|
|
34
|
-
|
|
35
|
-
[tool.poetry.dependencies.torchaudio]
|
|
36
|
-
source = "pypi"
|
|
37
|
-
|
|
38
|
-
[tool.poetry.group.dev.dependencies]
|
|
39
|
-
toml = "^0.10.2"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|