trustgraph-embeddings-hf 1.2.0__tar.gz → 1.2.4__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.
- trustgraph_embeddings_hf-1.2.4/PKG-INFO +26 -0
- trustgraph_embeddings_hf-1.2.4/pyproject.toml +43 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/embeddings/hf/hf.py +6 -2
- trustgraph_embeddings_hf-1.2.4/trustgraph/embeddings_hf_version.py +1 -0
- trustgraph_embeddings_hf-1.2.4/trustgraph_embeddings_hf.egg-info/PKG-INFO +26 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph_embeddings_hf.egg-info/SOURCES.txt +2 -2
- trustgraph_embeddings_hf-1.2.4/trustgraph_embeddings_hf.egg-info/entry_points.txt +2 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph_embeddings_hf.egg-info/top_level.txt +0 -1
- trustgraph-embeddings-hf-1.2.0/PKG-INFO +0 -15
- trustgraph-embeddings-hf-1.2.0/scripts/embeddings-hf +0 -6
- trustgraph-embeddings-hf-1.2.0/setup.py +0 -55
- trustgraph-embeddings-hf-1.2.0/trustgraph/embeddings_hf_version.py +0 -1
- trustgraph-embeddings-hf-1.2.0/trustgraph_embeddings_hf.egg-info/PKG-INFO +0 -15
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/README.md +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/setup.cfg +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/__init__.py +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/embeddings/__init__.py +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/embeddings/hf/__init__.py +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/embeddings/hf/__main__.py +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph_embeddings_hf.egg-info/dependency_links.txt +0 -0
- {trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph_embeddings_hf.egg-info/requires.txt +9 -9
@@ -0,0 +1,26 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: trustgraph-embeddings-hf
|
3
|
+
Version: 1.2.4
|
4
|
+
Summary: HuggingFace embeddings support for TrustGraph.
|
5
|
+
Author-email: "trustgraph.ai" <security@trustgraph.ai>
|
6
|
+
Project-URL: Homepage, https://github.com/trustgraph-ai/trustgraph
|
7
|
+
Classifier: Programming Language :: Python :: 3
|
8
|
+
Classifier: Operating System :: OS Independent
|
9
|
+
Requires-Python: >=3.8
|
10
|
+
Description-Content-Type: text/markdown
|
11
|
+
Requires-Dist: trustgraph-base<1.3,>=1.2
|
12
|
+
Requires-Dist: trustgraph-flow<1.3,>=1.2
|
13
|
+
Requires-Dist: torch
|
14
|
+
Requires-Dist: urllib3
|
15
|
+
Requires-Dist: transformers
|
16
|
+
Requires-Dist: sentence-transformers
|
17
|
+
Requires-Dist: langchain
|
18
|
+
Requires-Dist: langchain-core
|
19
|
+
Requires-Dist: langchain-huggingface
|
20
|
+
Requires-Dist: langchain-community
|
21
|
+
Requires-Dist: huggingface-hub
|
22
|
+
Requires-Dist: pulsar-client
|
23
|
+
Requires-Dist: pyyaml
|
24
|
+
Requires-Dist: prometheus-client
|
25
|
+
|
26
|
+
See https://trustgraph.ai/
|
@@ -0,0 +1,43 @@
|
|
1
|
+
[build-system]
|
2
|
+
requires = ["setuptools>=61.0", "wheel"]
|
3
|
+
build-backend = "setuptools.build_meta"
|
4
|
+
|
5
|
+
[project]
|
6
|
+
name = "trustgraph-embeddings-hf"
|
7
|
+
dynamic = ["version"]
|
8
|
+
authors = [{name = "trustgraph.ai", email = "security@trustgraph.ai"}]
|
9
|
+
description = "HuggingFace embeddings support for TrustGraph."
|
10
|
+
readme = "README.md"
|
11
|
+
requires-python = ">=3.8"
|
12
|
+
dependencies = [
|
13
|
+
"trustgraph-base>=1.2,<1.3",
|
14
|
+
"trustgraph-flow>=1.2,<1.3",
|
15
|
+
"torch",
|
16
|
+
"urllib3",
|
17
|
+
"transformers",
|
18
|
+
"sentence-transformers",
|
19
|
+
"langchain",
|
20
|
+
"langchain-core",
|
21
|
+
"langchain-huggingface",
|
22
|
+
"langchain-community",
|
23
|
+
"huggingface-hub",
|
24
|
+
"pulsar-client",
|
25
|
+
"pyyaml",
|
26
|
+
"prometheus-client",
|
27
|
+
]
|
28
|
+
classifiers = [
|
29
|
+
"Programming Language :: Python :: 3",
|
30
|
+
"Operating System :: OS Independent",
|
31
|
+
]
|
32
|
+
|
33
|
+
[project.urls]
|
34
|
+
Homepage = "https://github.com/trustgraph-ai/trustgraph"
|
35
|
+
|
36
|
+
[project.scripts]
|
37
|
+
embeddings-hf = "trustgraph.embeddings.hf:run"
|
38
|
+
|
39
|
+
[tool.setuptools.packages.find]
|
40
|
+
include = ["trustgraph*"]
|
41
|
+
|
42
|
+
[tool.setuptools.dynamic]
|
43
|
+
version = {attr = "trustgraph.embeddings_hf_version.__version__"}
|
{trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/embeddings/hf/hf.py
RENAMED
@@ -4,10 +4,14 @@ Embeddings service, applies an embeddings model selected from HuggingFace.
|
|
4
4
|
Input is text, output is embeddings vector.
|
5
5
|
"""
|
6
6
|
|
7
|
+
import logging
|
7
8
|
from ... base import EmbeddingsService
|
8
9
|
|
9
10
|
from langchain_huggingface import HuggingFaceEmbeddings
|
10
11
|
|
12
|
+
# Module logger
|
13
|
+
logger = logging.getLogger(__name__)
|
14
|
+
|
11
15
|
default_ident = "embeddings"
|
12
16
|
|
13
17
|
default_model="all-MiniLM-L6-v2"
|
@@ -22,13 +26,13 @@ class Processor(EmbeddingsService):
|
|
22
26
|
**params | { "model": model }
|
23
27
|
)
|
24
28
|
|
25
|
-
|
29
|
+
logger.info(f"Loading HuggingFace embeddings model: {model}")
|
26
30
|
self.embeddings = HuggingFaceEmbeddings(model_name=model)
|
27
31
|
|
28
32
|
async def on_embeddings(self, text):
|
29
33
|
|
30
34
|
embeds = self.embeddings.embed_documents([text])
|
31
|
-
|
35
|
+
logger.debug("Embeddings generation complete")
|
32
36
|
return embeds
|
33
37
|
|
34
38
|
@staticmethod
|
@@ -0,0 +1 @@
|
|
1
|
+
__version__ = "1.2.4"
|
@@ -0,0 +1,26 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: trustgraph-embeddings-hf
|
3
|
+
Version: 1.2.4
|
4
|
+
Summary: HuggingFace embeddings support for TrustGraph.
|
5
|
+
Author-email: "trustgraph.ai" <security@trustgraph.ai>
|
6
|
+
Project-URL: Homepage, https://github.com/trustgraph-ai/trustgraph
|
7
|
+
Classifier: Programming Language :: Python :: 3
|
8
|
+
Classifier: Operating System :: OS Independent
|
9
|
+
Requires-Python: >=3.8
|
10
|
+
Description-Content-Type: text/markdown
|
11
|
+
Requires-Dist: trustgraph-base<1.3,>=1.2
|
12
|
+
Requires-Dist: trustgraph-flow<1.3,>=1.2
|
13
|
+
Requires-Dist: torch
|
14
|
+
Requires-Dist: urllib3
|
15
|
+
Requires-Dist: transformers
|
16
|
+
Requires-Dist: sentence-transformers
|
17
|
+
Requires-Dist: langchain
|
18
|
+
Requires-Dist: langchain-core
|
19
|
+
Requires-Dist: langchain-huggingface
|
20
|
+
Requires-Dist: langchain-community
|
21
|
+
Requires-Dist: huggingface-hub
|
22
|
+
Requires-Dist: pulsar-client
|
23
|
+
Requires-Dist: pyyaml
|
24
|
+
Requires-Dist: prometheus-client
|
25
|
+
|
26
|
+
See https://trustgraph.ai/
|
@@ -1,6 +1,5 @@
|
|
1
1
|
README.md
|
2
|
-
|
3
|
-
scripts/embeddings-hf
|
2
|
+
pyproject.toml
|
4
3
|
trustgraph/__init__.py
|
5
4
|
trustgraph/embeddings_hf_version.py
|
6
5
|
trustgraph/embeddings/__init__.py
|
@@ -10,5 +9,6 @@ trustgraph/embeddings/hf/hf.py
|
|
10
9
|
trustgraph_embeddings_hf.egg-info/PKG-INFO
|
11
10
|
trustgraph_embeddings_hf.egg-info/SOURCES.txt
|
12
11
|
trustgraph_embeddings_hf.egg-info/dependency_links.txt
|
12
|
+
trustgraph_embeddings_hf.egg-info/entry_points.txt
|
13
13
|
trustgraph_embeddings_hf.egg-info/requires.txt
|
14
14
|
trustgraph_embeddings_hf.egg-info/top_level.txt
|
@@ -1,15 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.1
|
2
|
-
Name: trustgraph-embeddings-hf
|
3
|
-
Version: 1.2.0
|
4
|
-
Summary: HuggingFace embeddings support for TrustGraph.
|
5
|
-
Home-page: https://github.com/trustgraph-ai/trustgraph
|
6
|
-
Download-URL: https://github.com/trustgraph-ai/trustgraph/archive/refs/tags/v1.2.0.tar.gz
|
7
|
-
Author: trustgraph.ai
|
8
|
-
Author-email: security@trustgraph.ai
|
9
|
-
Classifier: Programming Language :: Python :: 3
|
10
|
-
Classifier: License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
|
11
|
-
Classifier: Operating System :: OS Independent
|
12
|
-
Requires-Python: >=3.8
|
13
|
-
Description-Content-Type: text/markdown
|
14
|
-
|
15
|
-
See https://trustgraph.ai/
|
@@ -1,55 +0,0 @@
|
|
1
|
-
import setuptools
|
2
|
-
import os
|
3
|
-
import importlib
|
4
|
-
|
5
|
-
with open("README.md", "r") as fh:
|
6
|
-
long_description = fh.read()
|
7
|
-
|
8
|
-
# Load a version number module
|
9
|
-
spec = importlib.util.spec_from_file_location(
|
10
|
-
'version', 'trustgraph/embeddings_hf_version.py'
|
11
|
-
)
|
12
|
-
version_module = importlib.util.module_from_spec(spec)
|
13
|
-
spec.loader.exec_module(version_module)
|
14
|
-
|
15
|
-
version = version_module.__version__
|
16
|
-
|
17
|
-
setuptools.setup(
|
18
|
-
name="trustgraph-embeddings-hf",
|
19
|
-
version=version,
|
20
|
-
author="trustgraph.ai",
|
21
|
-
author_email="security@trustgraph.ai",
|
22
|
-
description="HuggingFace embeddings support for TrustGraph.",
|
23
|
-
long_description=long_description,
|
24
|
-
long_description_content_type="text/markdown",
|
25
|
-
url="https://github.com/trustgraph-ai/trustgraph",
|
26
|
-
packages=setuptools.find_namespace_packages(
|
27
|
-
where='./',
|
28
|
-
),
|
29
|
-
classifiers=[
|
30
|
-
"Programming Language :: Python :: 3",
|
31
|
-
"License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
|
32
|
-
"Operating System :: OS Independent",
|
33
|
-
],
|
34
|
-
python_requires='>=3.8',
|
35
|
-
download_url = "https://github.com/trustgraph-ai/trustgraph/archive/refs/tags/v" + version + ".tar.gz",
|
36
|
-
install_requires=[
|
37
|
-
"trustgraph-base>=1.2,<1.3",
|
38
|
-
"trustgraph-flow>=1.2,<1.3",
|
39
|
-
"torch",
|
40
|
-
"urllib3",
|
41
|
-
"transformers",
|
42
|
-
"sentence-transformers",
|
43
|
-
"langchain",
|
44
|
-
"langchain-core",
|
45
|
-
"langchain-huggingface",
|
46
|
-
"langchain-community",
|
47
|
-
"huggingface-hub",
|
48
|
-
"pulsar-client",
|
49
|
-
"pyyaml",
|
50
|
-
"prometheus-client",
|
51
|
-
],
|
52
|
-
scripts=[
|
53
|
-
"scripts/embeddings-hf",
|
54
|
-
]
|
55
|
-
)
|
@@ -1 +0,0 @@
|
|
1
|
-
__version__ = "1.2.0"
|
@@ -1,15 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.1
|
2
|
-
Name: trustgraph-embeddings-hf
|
3
|
-
Version: 1.2.0
|
4
|
-
Summary: HuggingFace embeddings support for TrustGraph.
|
5
|
-
Home-page: https://github.com/trustgraph-ai/trustgraph
|
6
|
-
Download-URL: https://github.com/trustgraph-ai/trustgraph/archive/refs/tags/v1.2.0.tar.gz
|
7
|
-
Author: trustgraph.ai
|
8
|
-
Author-email: security@trustgraph.ai
|
9
|
-
Classifier: Programming Language :: Python :: 3
|
10
|
-
Classifier: License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
|
11
|
-
Classifier: Operating System :: OS Independent
|
12
|
-
Requires-Python: >=3.8
|
13
|
-
Description-Content-Type: text/markdown
|
14
|
-
|
15
|
-
See https://trustgraph.ai/
|
File without changes
|
File without changes
|
File without changes
|
{trustgraph-embeddings-hf-1.2.0 → trustgraph_embeddings_hf-1.2.4}/trustgraph/embeddings/__init__.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -1,14 +1,14 @@
|
|
1
|
-
|
1
|
+
trustgraph-base<1.3,>=1.2
|
2
|
+
trustgraph-flow<1.3,>=1.2
|
3
|
+
torch
|
4
|
+
urllib3
|
5
|
+
transformers
|
6
|
+
sentence-transformers
|
2
7
|
langchain
|
3
|
-
langchain-community
|
4
8
|
langchain-core
|
5
9
|
langchain-huggingface
|
6
|
-
|
10
|
+
langchain-community
|
11
|
+
huggingface-hub
|
7
12
|
pulsar-client
|
8
13
|
pyyaml
|
9
|
-
|
10
|
-
torch
|
11
|
-
transformers
|
12
|
-
trustgraph-base<1.3,>=1.2
|
13
|
-
trustgraph-flow<1.3,>=1.2
|
14
|
-
urllib3
|
14
|
+
prometheus-client
|