ws-bom-robot-app 0.0.85__py3-none-any.whl → 0.0.87__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.
- ws_bom_robot_app/config.py +3 -1
- ws_bom_robot_app/llm/agent_description.py +123 -123
- ws_bom_robot_app/llm/agent_handler.py +174 -166
- ws_bom_robot_app/llm/agent_lcel.py +50 -50
- ws_bom_robot_app/llm/api.py +65 -3
- ws_bom_robot_app/llm/defaut_prompt.py +15 -15
- ws_bom_robot_app/llm/evaluator.py +319 -0
- ws_bom_robot_app/llm/feedbacks/feedback_manager.py +66 -66
- ws_bom_robot_app/llm/main.py +158 -158
- ws_bom_robot_app/llm/models/api.py +1 -1
- ws_bom_robot_app/llm/models/feedback.py +30 -30
- ws_bom_robot_app/llm/nebuly_handler.py +185 -185
- ws_bom_robot_app/llm/providers/llm_manager.py +27 -9
- ws_bom_robot_app/llm/tools/tool_builder.py +68 -65
- ws_bom_robot_app/llm/tools/tool_manager.py +332 -330
- ws_bom_robot_app/llm/tools/utils.py +41 -41
- ws_bom_robot_app/llm/utils/agent.py +34 -34
- ws_bom_robot_app/llm/utils/cms.py +114 -114
- ws_bom_robot_app/llm/utils/download.py +183 -183
- ws_bom_robot_app/llm/utils/print.py +29 -29
- ws_bom_robot_app/llm/vector_store/generator.py +137 -137
- ws_bom_robot_app/llm/vector_store/integration/shopify.py +143 -143
- ws_bom_robot_app/llm/vector_store/integration/thron.py +102 -102
- ws_bom_robot_app/llm/vector_store/loader/json_loader.py +25 -25
- ws_bom_robot_app/task_manager.py +14 -10
- {ws_bom_robot_app-0.0.85.dist-info → ws_bom_robot_app-0.0.87.dist-info}/METADATA +20 -20
- {ws_bom_robot_app-0.0.85.dist-info → ws_bom_robot_app-0.0.87.dist-info}/RECORD +29 -28
- {ws_bom_robot_app-0.0.85.dist-info → ws_bom_robot_app-0.0.87.dist-info}/WHEEL +0 -0
- {ws_bom_robot_app-0.0.85.dist-info → ws_bom_robot_app-0.0.87.dist-info}/top_level.txt +0 -0
|
@@ -1,102 +1,102 @@
|
|
|
1
|
-
import asyncio, logging, aiohttp
|
|
2
|
-
from ws_bom_robot_app.llm.vector_store.integration.base import IntegrationStrategy
|
|
3
|
-
from langchain_core.documents import Document
|
|
4
|
-
from ws_bom_robot_app.llm.vector_store.loader.base import Loader
|
|
5
|
-
from typing import List, Union, Optional
|
|
6
|
-
from pydantic import BaseModel, Field, AliasChoices
|
|
7
|
-
import json
|
|
8
|
-
import os
|
|
9
|
-
|
|
10
|
-
class ThronParams(BaseModel):
|
|
11
|
-
"""
|
|
12
|
-
ThronParams is a model that defines the parameters required for Thron integration.
|
|
13
|
-
|
|
14
|
-
Attributes:
|
|
15
|
-
app_id (str): The application ID for Thron.
|
|
16
|
-
client_id (str): The client ID for Thron.
|
|
17
|
-
client_secret (str): The client secret for Thron.
|
|
18
|
-
"""
|
|
19
|
-
organization_name: str = Field(validation_alias=AliasChoices("organizationName","organization_name"))
|
|
20
|
-
attribute_fields: Optional[List[str]] = Field(default=None, validation_alias=AliasChoices("attributeFields","attribute_fields"))
|
|
21
|
-
client_id: str = Field(validation_alias=AliasChoices("clientId","client_id"))
|
|
22
|
-
client_secret: str = Field(validation_alias=AliasChoices("clientSecret","client_secret"))
|
|
23
|
-
|
|
24
|
-
class Thron(IntegrationStrategy):
|
|
25
|
-
def __init__(self, knowledgebase_path: str, data: dict[str, Union[str,int,list]]):
|
|
26
|
-
super().__init__(knowledgebase_path, data)
|
|
27
|
-
self.__data = ThronParams.model_validate(self.data)
|
|
28
|
-
|
|
29
|
-
def working_subdirectory(self) -> str:
|
|
30
|
-
return 'thron'
|
|
31
|
-
|
|
32
|
-
async def run(self) -> None:
|
|
33
|
-
_data = await self.__get_data()
|
|
34
|
-
transformed_data = self.__transform_data(_data)
|
|
35
|
-
json_file_path = os.path.join(self.working_directory, 'thron_data.json')
|
|
36
|
-
with open(json_file_path, 'w', encoding='utf-8') as f:
|
|
37
|
-
json.dump(transformed_data, f, indent=2, ensure_ascii=False)
|
|
38
|
-
|
|
39
|
-
async def load(self) -> list[Document]:
|
|
40
|
-
await self.run()
|
|
41
|
-
await asyncio.sleep(1)
|
|
42
|
-
return await Loader(self.working_directory).load()
|
|
43
|
-
|
|
44
|
-
async def __get_auth_token(self) -> str:
|
|
45
|
-
try:
|
|
46
|
-
async with aiohttp.ClientSession() as session:
|
|
47
|
-
auth_data = {
|
|
48
|
-
"grant_type": "client_credentials",
|
|
49
|
-
"client_id": self.__data.client_id,
|
|
50
|
-
"client_secret": self.__data.client_secret
|
|
51
|
-
}
|
|
52
|
-
headers = {
|
|
53
|
-
"accept": "application/json",
|
|
54
|
-
"Content-Type": "application/x-www-form-urlencoded"
|
|
55
|
-
}
|
|
56
|
-
async with session.post(f"https://{self.__data.organization_name}.thron.com/api/v1/authentication/oauth2/token", data=auth_data, headers=headers) as response:
|
|
57
|
-
result = await response.json()
|
|
58
|
-
return result.get("access_token", "")
|
|
59
|
-
except Exception as e:
|
|
60
|
-
logging.error(f"Error fetching Thron auth token: {e}")
|
|
61
|
-
return None
|
|
62
|
-
|
|
63
|
-
async def __get_data(self) -> dict:
|
|
64
|
-
try:
|
|
65
|
-
token = await self.__get_auth_token()
|
|
66
|
-
if not token:
|
|
67
|
-
logging.error("Failed to obtain Thron authentication token.")
|
|
68
|
-
return {}
|
|
69
|
-
attribute_fields = ",".join(self.__data.attribute_fields) if self.__data.attribute_fields else ""
|
|
70
|
-
async with aiohttp.ClientSession() as session:
|
|
71
|
-
headers = {
|
|
72
|
-
"accept": "application/json",
|
|
73
|
-
"Authorization": f"Bearer {token}"
|
|
74
|
-
}
|
|
75
|
-
async with session.get(f"https://{self.__data.organization_name}.thron.com/api/v1/product-data/products?attributeFields=product_id,{attribute_fields}", headers=headers) as response:
|
|
76
|
-
result = await response.json()
|
|
77
|
-
return result.get("items", {})
|
|
78
|
-
except Exception as e:
|
|
79
|
-
logging.error(f"Error fetching Thron product data: {e}")
|
|
80
|
-
return {}
|
|
81
|
-
return []
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
def __transform_data(self, data: dict) -> dict:
|
|
86
|
-
_data = []
|
|
87
|
-
for item in data:
|
|
88
|
-
if item.get("hierarchyLevel") == "MASTER":
|
|
89
|
-
# Iterate through variants to find the product_id
|
|
90
|
-
for item_variant in data:
|
|
91
|
-
if item_variant.get("hierarchyLevel") == "VARIANT":
|
|
92
|
-
for attr in item.get("attributes", []):
|
|
93
|
-
if attr.get("code") == "product_id" and attr.get("identifier") == item_variant.get("variation").get("master").split(":")[-1]:
|
|
94
|
-
# Initialize variants list if it doesn't exist
|
|
95
|
-
if "variants" not in item:
|
|
96
|
-
item["variants"] = []
|
|
97
|
-
item["variants"].append(item_variant)
|
|
98
|
-
_data.append(item)
|
|
99
|
-
break
|
|
100
|
-
elif item.get("hierarchyLevel") == "SIMPLE":
|
|
101
|
-
_data.append(item)
|
|
102
|
-
return _data
|
|
1
|
+
import asyncio, logging, aiohttp
|
|
2
|
+
from ws_bom_robot_app.llm.vector_store.integration.base import IntegrationStrategy
|
|
3
|
+
from langchain_core.documents import Document
|
|
4
|
+
from ws_bom_robot_app.llm.vector_store.loader.base import Loader
|
|
5
|
+
from typing import List, Union, Optional
|
|
6
|
+
from pydantic import BaseModel, Field, AliasChoices
|
|
7
|
+
import json
|
|
8
|
+
import os
|
|
9
|
+
|
|
10
|
+
class ThronParams(BaseModel):
|
|
11
|
+
"""
|
|
12
|
+
ThronParams is a model that defines the parameters required for Thron integration.
|
|
13
|
+
|
|
14
|
+
Attributes:
|
|
15
|
+
app_id (str): The application ID for Thron.
|
|
16
|
+
client_id (str): The client ID for Thron.
|
|
17
|
+
client_secret (str): The client secret for Thron.
|
|
18
|
+
"""
|
|
19
|
+
organization_name: str = Field(validation_alias=AliasChoices("organizationName","organization_name"))
|
|
20
|
+
attribute_fields: Optional[List[str]] = Field(default=None, validation_alias=AliasChoices("attributeFields","attribute_fields"))
|
|
21
|
+
client_id: str = Field(validation_alias=AliasChoices("clientId","client_id"))
|
|
22
|
+
client_secret: str = Field(validation_alias=AliasChoices("clientSecret","client_secret"))
|
|
23
|
+
|
|
24
|
+
class Thron(IntegrationStrategy):
|
|
25
|
+
def __init__(self, knowledgebase_path: str, data: dict[str, Union[str,int,list]]):
|
|
26
|
+
super().__init__(knowledgebase_path, data)
|
|
27
|
+
self.__data = ThronParams.model_validate(self.data)
|
|
28
|
+
|
|
29
|
+
def working_subdirectory(self) -> str:
|
|
30
|
+
return 'thron'
|
|
31
|
+
|
|
32
|
+
async def run(self) -> None:
|
|
33
|
+
_data = await self.__get_data()
|
|
34
|
+
transformed_data = self.__transform_data(_data)
|
|
35
|
+
json_file_path = os.path.join(self.working_directory, 'thron_data.json')
|
|
36
|
+
with open(json_file_path, 'w', encoding='utf-8') as f:
|
|
37
|
+
json.dump(transformed_data, f, indent=2, ensure_ascii=False)
|
|
38
|
+
|
|
39
|
+
async def load(self) -> list[Document]:
|
|
40
|
+
await self.run()
|
|
41
|
+
await asyncio.sleep(1)
|
|
42
|
+
return await Loader(self.working_directory).load()
|
|
43
|
+
|
|
44
|
+
async def __get_auth_token(self) -> str:
|
|
45
|
+
try:
|
|
46
|
+
async with aiohttp.ClientSession() as session:
|
|
47
|
+
auth_data = {
|
|
48
|
+
"grant_type": "client_credentials",
|
|
49
|
+
"client_id": self.__data.client_id,
|
|
50
|
+
"client_secret": self.__data.client_secret
|
|
51
|
+
}
|
|
52
|
+
headers = {
|
|
53
|
+
"accept": "application/json",
|
|
54
|
+
"Content-Type": "application/x-www-form-urlencoded"
|
|
55
|
+
}
|
|
56
|
+
async with session.post(f"https://{self.__data.organization_name}.thron.com/api/v1/authentication/oauth2/token", data=auth_data, headers=headers) as response:
|
|
57
|
+
result = await response.json()
|
|
58
|
+
return result.get("access_token", "")
|
|
59
|
+
except Exception as e:
|
|
60
|
+
logging.error(f"Error fetching Thron auth token: {e}")
|
|
61
|
+
return None
|
|
62
|
+
|
|
63
|
+
async def __get_data(self) -> dict:
|
|
64
|
+
try:
|
|
65
|
+
token = await self.__get_auth_token()
|
|
66
|
+
if not token:
|
|
67
|
+
logging.error("Failed to obtain Thron authentication token.")
|
|
68
|
+
return {}
|
|
69
|
+
attribute_fields = ",".join(self.__data.attribute_fields) if self.__data.attribute_fields else ""
|
|
70
|
+
async with aiohttp.ClientSession() as session:
|
|
71
|
+
headers = {
|
|
72
|
+
"accept": "application/json",
|
|
73
|
+
"Authorization": f"Bearer {token}"
|
|
74
|
+
}
|
|
75
|
+
async with session.get(f"https://{self.__data.organization_name}.thron.com/api/v1/product-data/products?attributeFields=product_id,{attribute_fields}", headers=headers) as response:
|
|
76
|
+
result = await response.json()
|
|
77
|
+
return result.get("items", {})
|
|
78
|
+
except Exception as e:
|
|
79
|
+
logging.error(f"Error fetching Thron product data: {e}")
|
|
80
|
+
return {}
|
|
81
|
+
return []
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
def __transform_data(self, data: dict) -> dict:
|
|
86
|
+
_data = []
|
|
87
|
+
for item in data:
|
|
88
|
+
if item.get("hierarchyLevel") == "MASTER":
|
|
89
|
+
# Iterate through variants to find the product_id
|
|
90
|
+
for item_variant in data:
|
|
91
|
+
if item_variant.get("hierarchyLevel") == "VARIANT":
|
|
92
|
+
for attr in item.get("attributes", []):
|
|
93
|
+
if attr.get("code") == "product_id" and attr.get("identifier") == item_variant.get("variation").get("master").split(":")[-1]:
|
|
94
|
+
# Initialize variants list if it doesn't exist
|
|
95
|
+
if "variants" not in item:
|
|
96
|
+
item["variants"] = []
|
|
97
|
+
item["variants"].append(item_variant)
|
|
98
|
+
_data.append(item)
|
|
99
|
+
break
|
|
100
|
+
elif item.get("hierarchyLevel") == "SIMPLE":
|
|
101
|
+
_data.append(item)
|
|
102
|
+
return _data
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import json
|
|
2
|
-
from typing import Optional
|
|
3
|
-
from langchain_core.documents import Document
|
|
4
|
-
from langchain_community.document_loaders.base import BaseLoader
|
|
5
|
-
|
|
6
|
-
class JsonLoader(BaseLoader):
|
|
7
|
-
def __init__(self, file_path: str, meta_fields:Optional[list[str]] = [],encoding: Optional[str] = "utf-8"):
|
|
8
|
-
self.file_path = file_path
|
|
9
|
-
self.meta_fields = meta_fields
|
|
10
|
-
self.encoding = encoding
|
|
11
|
-
|
|
12
|
-
def load(self) -> list[Document]:
|
|
13
|
-
with open(self.file_path, "r", encoding=self.encoding) as file:
|
|
14
|
-
data = json.load(file)
|
|
15
|
-
_list = data if isinstance(data, list) else [data]
|
|
16
|
-
return [
|
|
17
|
-
Document(
|
|
18
|
-
page_content=json.dumps(item),
|
|
19
|
-
metadata={
|
|
20
|
-
"source": self.file_path,
|
|
21
|
-
**{field: item.get(field) for field in self.meta_fields if item.get(field)}
|
|
22
|
-
}
|
|
23
|
-
)
|
|
24
|
-
for item in _list
|
|
25
|
-
]
|
|
1
|
+
import json
|
|
2
|
+
from typing import Optional
|
|
3
|
+
from langchain_core.documents import Document
|
|
4
|
+
from langchain_community.document_loaders.base import BaseLoader
|
|
5
|
+
|
|
6
|
+
class JsonLoader(BaseLoader):
|
|
7
|
+
def __init__(self, file_path: str, meta_fields:Optional[list[str]] = [],encoding: Optional[str] = "utf-8"):
|
|
8
|
+
self.file_path = file_path
|
|
9
|
+
self.meta_fields = meta_fields
|
|
10
|
+
self.encoding = encoding
|
|
11
|
+
|
|
12
|
+
def load(self) -> list[Document]:
|
|
13
|
+
with open(self.file_path, "r", encoding=self.encoding) as file:
|
|
14
|
+
data = json.load(file)
|
|
15
|
+
_list = data if isinstance(data, list) else [data]
|
|
16
|
+
return [
|
|
17
|
+
Document(
|
|
18
|
+
page_content=json.dumps(item),
|
|
19
|
+
metadata={
|
|
20
|
+
"source": self.file_path,
|
|
21
|
+
**{field: item.get(field) for field in self.meta_fields if item.get(field)}
|
|
22
|
+
}
|
|
23
|
+
)
|
|
24
|
+
for item in _list
|
|
25
|
+
]
|
ws_bom_robot_app/task_manager.py
CHANGED
|
@@ -79,6 +79,7 @@ class TaskEntry(IdentifiableEntity):
|
|
|
79
79
|
coroutine: Any = None
|
|
80
80
|
headers: TaskHeader | None = None
|
|
81
81
|
status: Union[TaskStatus, None] = None
|
|
82
|
+
queue: Literal["slow", "fast"] | None = "slow"
|
|
82
83
|
def _get_coroutine_name(self, func: Any) -> str:
|
|
83
84
|
if inspect.iscoroutine(func):
|
|
84
85
|
return func.cr_code.co_name
|
|
@@ -120,7 +121,7 @@ class TaskStatistics(BaseModel):
|
|
|
120
121
|
class TaskStatisticExecutionInfo(BaseModel):
|
|
121
122
|
retention_days: float = config.robot_task_retention_days
|
|
122
123
|
max_parallelism: int
|
|
123
|
-
slot_available: int
|
|
124
|
+
slot_available: dict[str,int]
|
|
124
125
|
pid: int = os.getpid()
|
|
125
126
|
running: list[TaskStatus]
|
|
126
127
|
slowest: list
|
|
@@ -144,12 +145,12 @@ class TaskManagerStrategy(ABC):
|
|
|
144
145
|
workers = config.runtime_options().number_of_workers
|
|
145
146
|
max_concurrent_tasks = max(1, floor(config.robot_task_max_total_parallelism / max(1, workers)))
|
|
146
147
|
self.max_parallelism = max_concurrent_tasks
|
|
147
|
-
self.semaphore = asyncio.Semaphore(max_concurrent_tasks)
|
|
148
|
+
self.semaphore = {"slow": asyncio.Semaphore(max_concurrent_tasks), "fast": asyncio.Semaphore(max_concurrent_tasks*2)}
|
|
148
149
|
self.running_tasks = dict[str, TaskEntry]()
|
|
149
150
|
self.loop = asyncio.get_event_loop()
|
|
150
151
|
|
|
151
152
|
@abstractmethod
|
|
152
|
-
def create_task(self, coroutine, headers: TaskHeader | None = None) -> IdentifiableEntity:
|
|
153
|
+
def create_task(self, coroutine, headers: TaskHeader | None = None, queue: Literal["slow", "fast"] | None = "slow") -> IdentifiableEntity:
|
|
153
154
|
"""Create a new task.
|
|
154
155
|
Args:
|
|
155
156
|
coroutine (_type_): coroutine or callable to be executed.
|
|
@@ -160,6 +161,7 @@ class TaskManagerStrategy(ABC):
|
|
|
160
161
|
from ws_bom_robot_app.task_manager import task_manager
|
|
161
162
|
task_manager.create_task(my_coroutine, headers=my_headers) -> coroutine executed in-process
|
|
162
163
|
task_manager.create_task(lambda: my_coroutine, headers=my_headers) -> callable using subprocess
|
|
164
|
+
task_manager.create_task(lambda: my_coroutine, headers=my_headers, queue="fast") -> callable using subprocess with "fast" queue
|
|
163
165
|
"""
|
|
164
166
|
pass
|
|
165
167
|
|
|
@@ -227,7 +229,7 @@ class TaskManagerStrategy(ABC):
|
|
|
227
229
|
self._update_task_by_event(task_entry, "callback", None)
|
|
228
230
|
return callback
|
|
229
231
|
|
|
230
|
-
def create_task_entry(self, coroutine_or_callable: Any, headers: TaskHeader | None = None) -> TaskEntry:
|
|
232
|
+
def create_task_entry(self, coroutine_or_callable: Any, headers: TaskHeader | None = None, queue: Literal["slow", "fast"] | None = "slow") -> TaskEntry:
|
|
231
233
|
"""Create a new task entry.
|
|
232
234
|
|
|
233
235
|
Args:
|
|
@@ -251,7 +253,9 @@ class TaskManagerStrategy(ABC):
|
|
|
251
253
|
task_entry = TaskEntry(
|
|
252
254
|
id=_id,
|
|
253
255
|
coroutine=coroutine_or_callable,
|
|
254
|
-
headers=headers
|
|
256
|
+
headers=headers,
|
|
257
|
+
queue=queue
|
|
258
|
+
)
|
|
255
259
|
# Store hint for subprocess capability
|
|
256
260
|
task_entry.status.metadata.extra = task_entry.status.metadata.extra or {}
|
|
257
261
|
task_entry.status.metadata.extra["can_use_subprocess"] = can_use_subprocess
|
|
@@ -263,7 +267,7 @@ class TaskManagerStrategy(ABC):
|
|
|
263
267
|
|
|
264
268
|
async def _run_task_with_semaphore(self, task_entry: TaskEntry):
|
|
265
269
|
"""Run a task with semaphore control to limit concurrency."""
|
|
266
|
-
async with self.semaphore:
|
|
270
|
+
async with self.semaphore[task_entry.queue]:
|
|
267
271
|
await self._execute_task(task_entry)
|
|
268
272
|
|
|
269
273
|
async def _monitor_subprocess(self, task_entry: TaskEntry, proc, conn):
|
|
@@ -291,7 +295,7 @@ class TaskManagerStrategy(ABC):
|
|
|
291
295
|
_log.warning(f"Task {task_entry.id} failure, retrying {task_entry.status.retry}...")
|
|
292
296
|
async def delayed_retry():
|
|
293
297
|
_delay = config.robot_task_mp_retry_delay # help to backpressure when overloaded
|
|
294
|
-
if self.semaphore._value > 0: # free semaphore slots available
|
|
298
|
+
if self.semaphore[task_entry.queue]._value > 0: # free semaphore slots available
|
|
295
299
|
_delay = 5 # small/no delay if retry can run immediately
|
|
296
300
|
await asyncio.sleep(_delay) # delay in seconds
|
|
297
301
|
await self._run_task_with_semaphore(task_entry)
|
|
@@ -392,7 +396,7 @@ class TaskManagerStrategy(ABC):
|
|
|
392
396
|
exec_info=TaskStatistics.TaskStatisticExecutionInfo(
|
|
393
397
|
retention_days=config.robot_task_retention_days,
|
|
394
398
|
max_parallelism=self.max_parallelism,
|
|
395
|
-
slot_available=self.semaphore._value,
|
|
399
|
+
slot_available={queue: self.semaphore[queue]._value for queue in self.semaphore},
|
|
396
400
|
running=[task.status for task in self.running_task()],
|
|
397
401
|
slowest=_slowest
|
|
398
402
|
)
|
|
@@ -406,8 +410,8 @@ class MemoryTaskManagerStrategy(TaskManagerStrategy):
|
|
|
406
410
|
super().__init__(max_concurrent_tasks)
|
|
407
411
|
self.tasks: Dict[str, TaskEntry] = {}
|
|
408
412
|
|
|
409
|
-
def create_task(self, coroutine: Any, headers: TaskHeader | None = None) -> IdentifiableEntity:
|
|
410
|
-
task = self.create_task_entry(coroutine, headers)
|
|
413
|
+
def create_task(self, coroutine: Any, headers: TaskHeader | None = None, queue: Literal["slow", "fast"] | None = "slow") -> IdentifiableEntity:
|
|
414
|
+
task = self.create_task_entry(coroutine, headers, queue)
|
|
411
415
|
self.tasks[task.id] = task
|
|
412
416
|
return IdentifiableEntity(id=task.id)
|
|
413
417
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: ws_bom_robot_app
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.87
|
|
4
4
|
Summary: A FastAPI application serving ws bom/robot/llm platform ai.
|
|
5
5
|
Home-page: https://github.com/websolutespa/bom
|
|
6
6
|
Author: Websolute Spa
|
|
@@ -17,26 +17,26 @@ Requires-Dist: pydantic==2.11.7
|
|
|
17
17
|
Requires-Dist: pydantic-settings==2.10.1
|
|
18
18
|
Requires-Dist: fastapi[standard]==0.116.1
|
|
19
19
|
Requires-Dist: chevron==0.14.0
|
|
20
|
-
Requires-Dist: langchain==0.3.
|
|
21
|
-
Requires-Dist: langchain-community==0.3.
|
|
22
|
-
Requires-Dist: langchain-core==0.3.
|
|
23
|
-
Requires-Dist: langchain-openai==0.3.
|
|
24
|
-
Requires-Dist: langchain-anthropic==0.3.
|
|
25
|
-
Requires-Dist: langchain-ibm==0.3.
|
|
26
|
-
Requires-Dist: langchain-google-genai==2.
|
|
27
|
-
Requires-Dist: langchain-google-vertexai==2.0.
|
|
28
|
-
Requires-Dist: langchain-groq==0.3.
|
|
29
|
-
Requires-Dist: langchain-ollama==0.3.
|
|
30
|
-
Requires-Dist:
|
|
31
|
-
Requires-Dist:
|
|
32
|
-
Requires-Dist:
|
|
33
|
-
Requires-Dist:
|
|
20
|
+
Requires-Dist: langchain==0.3.27
|
|
21
|
+
Requires-Dist: langchain-community==0.3.29
|
|
22
|
+
Requires-Dist: langchain-core==0.3.75
|
|
23
|
+
Requires-Dist: langchain-openai==0.3.32
|
|
24
|
+
Requires-Dist: langchain-anthropic==0.3.19
|
|
25
|
+
Requires-Dist: langchain-ibm==0.3.17
|
|
26
|
+
Requires-Dist: langchain-google-genai==2.1.10
|
|
27
|
+
Requires-Dist: langchain-google-vertexai==2.0.28
|
|
28
|
+
Requires-Dist: langchain-groq==0.3.7
|
|
29
|
+
Requires-Dist: langchain-ollama==0.3.7
|
|
30
|
+
Requires-Dist: openevals==0.1.0
|
|
31
|
+
Requires-Dist: faiss-cpu==1.12.0
|
|
32
|
+
Requires-Dist: chromadb==1.0.20
|
|
33
|
+
Requires-Dist: langchain-chroma==0.2.5
|
|
34
34
|
Requires-Dist: langchain-qdrant==0.2.0
|
|
35
|
-
Requires-Dist: qdrant-client==1.15.
|
|
35
|
+
Requires-Dist: qdrant-client[fastembed]==1.15.1
|
|
36
36
|
Requires-Dist: lark==1.2.2
|
|
37
|
-
Requires-Dist: unstructured==0.18.
|
|
37
|
+
Requires-Dist: unstructured==0.18.14
|
|
38
38
|
Requires-Dist: unstructured[image]
|
|
39
|
-
Requires-Dist: unstructured-ingest==1.2.
|
|
39
|
+
Requires-Dist: unstructured-ingest==1.2.11
|
|
40
40
|
Requires-Dist: unstructured-ingest[azure]
|
|
41
41
|
Requires-Dist: unstructured-ingest[confluence]
|
|
42
42
|
Requires-Dist: unstructured-ingest[dropbox]
|
|
@@ -49,9 +49,9 @@ Requires-Dist: unstructured-ingest[sftp]
|
|
|
49
49
|
Requires-Dist: unstructured-ingest[sharepoint]
|
|
50
50
|
Requires-Dist: unstructured-ingest[slack]
|
|
51
51
|
Requires-Dist: html5lib==1.1
|
|
52
|
-
Requires-Dist: markdownify==1.
|
|
52
|
+
Requires-Dist: markdownify==1.2.0
|
|
53
53
|
Requires-Dist: duckduckgo-search==8.0.4
|
|
54
|
-
Requires-Dist:
|
|
54
|
+
Requires-Dist: langchain-google-community==2.0.7
|
|
55
55
|
Requires-Dist: trafilatura==2.0.0
|
|
56
56
|
Dynamic: author
|
|
57
57
|
Dynamic: author-email
|
|
@@ -1,46 +1,47 @@
|
|
|
1
1
|
ws_bom_robot_app/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
2
|
ws_bom_robot_app/auth.py,sha256=84nIbmJsMrNs0sxIQGEHbjsjc2P6ZrZZGSn8dkiL6is,895
|
|
3
|
-
ws_bom_robot_app/config.py,sha256=
|
|
3
|
+
ws_bom_robot_app/config.py,sha256=TWnFPlPpzN-GWVNib2CXfzY8IYVHCypkxdDJ6rLOatk,5443
|
|
4
4
|
ws_bom_robot_app/cron_manager.py,sha256=TOz7dsQhbGXzYMKW7GboKOSySg9aun4h0yLckj-5w4U,9372
|
|
5
5
|
ws_bom_robot_app/main.py,sha256=5h4qwQ4Ghm6CCSjO5eWvMhWxDATzUayQfQ-__E1Mw1I,6936
|
|
6
6
|
ws_bom_robot_app/subprocess_runner.py,sha256=N71HxPvgMP5TIRlO5w9UzHAEK-JKOA9i16QXM3anpjM,4195
|
|
7
|
-
ws_bom_robot_app/task_manager.py,sha256=
|
|
7
|
+
ws_bom_robot_app/task_manager.py,sha256=N2NzinjaxsRaLu78sREG9MCanMzygtKUU_yXo-aw2wA,24570
|
|
8
8
|
ws_bom_robot_app/util.py,sha256=t1VS6JQNOZe6aenBmjPLxJ_A3ncm7WqTZE8_gR85sQo,5022
|
|
9
9
|
ws_bom_robot_app/llm/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
10
|
ws_bom_robot_app/llm/agent_context.py,sha256=uatHJ8wcRly6h0S762BgfzDMpmcwCHwNzwo37aWjeE0,1305
|
|
11
|
-
ws_bom_robot_app/llm/agent_description.py,sha256=
|
|
12
|
-
ws_bom_robot_app/llm/agent_handler.py,sha256=
|
|
13
|
-
ws_bom_robot_app/llm/agent_lcel.py,sha256=
|
|
14
|
-
ws_bom_robot_app/llm/api.py,sha256=
|
|
15
|
-
ws_bom_robot_app/llm/defaut_prompt.py,sha256=
|
|
16
|
-
ws_bom_robot_app/llm/
|
|
17
|
-
ws_bom_robot_app/llm/
|
|
11
|
+
ws_bom_robot_app/llm/agent_description.py,sha256=5IP0qFSJvaE3zjGS7f0W1DuiegP0RHXRMBoDC5pCofA,4779
|
|
12
|
+
ws_bom_robot_app/llm/agent_handler.py,sha256=Y9_ESGV06p77u__gaYn_kqysmQyFYCtwddPPXHDsj-M,7753
|
|
13
|
+
ws_bom_robot_app/llm/agent_lcel.py,sha256=QRgGkdVXCwDXWjJj8R8qaYeLqUfpaYjtRnl3GrZCwVM,2530
|
|
14
|
+
ws_bom_robot_app/llm/api.py,sha256=jMoiKiD5HNxGu6gTb5_qZ5UU8d2uJ7UVrdLseDStI6o,7634
|
|
15
|
+
ws_bom_robot_app/llm/defaut_prompt.py,sha256=D9dn8yPveu0bVwGM1wQWLYftmBs5O76o0R_caLLll8w,1121
|
|
16
|
+
ws_bom_robot_app/llm/evaluator.py,sha256=tUyPX1oGZEjSiO4JixwNlgv6BI9cUHSmcAsTCpBnIn4,13322
|
|
17
|
+
ws_bom_robot_app/llm/main.py,sha256=GZ6Bkb3rNl4xf2ZXGkl9bhZrIRsvi40vUIRDJ-WwRAc,5828
|
|
18
|
+
ws_bom_robot_app/llm/nebuly_handler.py,sha256=wFO2UG849kv5hmjM5EoOp0Jsloy-BtQjrRh4pVosnfU,8163
|
|
18
19
|
ws_bom_robot_app/llm/feedbacks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
19
|
-
ws_bom_robot_app/llm/feedbacks/feedback_manager.py,sha256=
|
|
20
|
+
ws_bom_robot_app/llm/feedbacks/feedback_manager.py,sha256=vNcZLG9IKhurAk7hjBqyFgQTjnh3Cd4GnxeYsX7ZdiA,2922
|
|
20
21
|
ws_bom_robot_app/llm/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
21
|
-
ws_bom_robot_app/llm/models/api.py,sha256=
|
|
22
|
+
ws_bom_robot_app/llm/models/api.py,sha256=bahqx9rdP6jM9Kk9VGkqT-bhASJeuAzO_5Ir6tBxDIU,12212
|
|
22
23
|
ws_bom_robot_app/llm/models/base.py,sha256=1TqxuTK3rjJEALn7lvgoen_1ba3R2brAgGx6EDTtDZo,152
|
|
23
|
-
ws_bom_robot_app/llm/models/feedback.py,sha256=
|
|
24
|
+
ws_bom_robot_app/llm/models/feedback.py,sha256=pYNQGxNOBgeAAfdJLI95l7ePLBI5tVdsgnyjp5oMOQU,1722
|
|
24
25
|
ws_bom_robot_app/llm/models/kb.py,sha256=oVSw6_dmNxikAHrPqcfxDXz9M0ezLIYuxpgvzfs_Now,9514
|
|
25
26
|
ws_bom_robot_app/llm/providers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
26
|
-
ws_bom_robot_app/llm/providers/llm_manager.py,sha256=
|
|
27
|
+
ws_bom_robot_app/llm/providers/llm_manager.py,sha256=5XqQNRx0My-bXptCzOlsMTnjLTx3bcX9HRT3_l5IQ_A,16699
|
|
27
28
|
ws_bom_robot_app/llm/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
28
|
-
ws_bom_robot_app/llm/tools/tool_builder.py,sha256=
|
|
29
|
-
ws_bom_robot_app/llm/tools/tool_manager.py,sha256=
|
|
30
|
-
ws_bom_robot_app/llm/tools/utils.py,sha256=
|
|
29
|
+
ws_bom_robot_app/llm/tools/tool_builder.py,sha256=CtZwJ94aj0YGA3yVWkyCUxNE7WgU2zWjhl_tEfEskxw,3432
|
|
30
|
+
ws_bom_robot_app/llm/tools/tool_manager.py,sha256=avoFERE0v9MFQ3pUBMug8eGYIXbIYl7NqkP1kjNee7s,15439
|
|
31
|
+
ws_bom_robot_app/llm/tools/utils.py,sha256=Ba7ScFZPVJ3ke8KLO8ik1wyR2f_zC99Bikqx0OGnKoI,1924
|
|
31
32
|
ws_bom_robot_app/llm/tools/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
32
33
|
ws_bom_robot_app/llm/tools/models/main.py,sha256=1hICqHs-KS2heenkH7b2eH0N2GrPaaNGBrn64cl_A40,827
|
|
33
34
|
ws_bom_robot_app/llm/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
34
|
-
ws_bom_robot_app/llm/utils/agent.py,sha256=
|
|
35
|
+
ws_bom_robot_app/llm/utils/agent.py,sha256=uFuSfYMfGIE2WCKGNSKL-T2SDFn-tUKvbAYbGTPIw6g,1445
|
|
35
36
|
ws_bom_robot_app/llm/utils/chunker.py,sha256=zVXjRMloc3KbNEqiDcycYzy4N0Ey1g8XYeq6ftyvkyg,857
|
|
36
37
|
ws_bom_robot_app/llm/utils/cleanup.py,sha256=ARLZTX4mLbkLCEnMdIWYDYEAPOjzfy1laLGkYnxZe30,3063
|
|
37
|
-
ws_bom_robot_app/llm/utils/cms.py,sha256=
|
|
38
|
-
ws_bom_robot_app/llm/utils/download.py,sha256=
|
|
39
|
-
ws_bom_robot_app/llm/utils/print.py,sha256=
|
|
38
|
+
ws_bom_robot_app/llm/utils/cms.py,sha256=5TBDDlTsE4O8_bGvlqFOkkK13WFEoOvYRp_FOEXUuKY,6466
|
|
39
|
+
ws_bom_robot_app/llm/utils/download.py,sha256=rvc88E63UGHnFVlJJeMb05Z2FcBYIITqKnIE3ldEu6I,7293
|
|
40
|
+
ws_bom_robot_app/llm/utils/print.py,sha256=HK3zhZOd4cEyXZ8QcudLtTIfqqtMOERce_yTofS8NXo,803
|
|
40
41
|
ws_bom_robot_app/llm/utils/secrets.py,sha256=-HtqLIDVIJrpvGC5YhPAVyLsq8P4ChVM5g3GOfdwqVk,878
|
|
41
42
|
ws_bom_robot_app/llm/utils/webhooks.py,sha256=LAAZqyN6VhV13wu4X-X85TwdDgAV2rNvIwQFIIc0FJM,2114
|
|
42
43
|
ws_bom_robot_app/llm/vector_store/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
43
|
-
ws_bom_robot_app/llm/vector_store/generator.py,sha256=
|
|
44
|
+
ws_bom_robot_app/llm/vector_store/generator.py,sha256=W_hi_UOPaSjnEuazhUFIrMAwTvz64Du8_gpiVAxFlVc,6451
|
|
44
45
|
ws_bom_robot_app/llm/vector_store/db/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
45
46
|
ws_bom_robot_app/llm/vector_store/db/base.py,sha256=iQBY-1O8uJ1_dRzmCDmhWAMBYtpims0u5RelQMvOVLo,8310
|
|
46
47
|
ws_bom_robot_app/llm/vector_store/db/chroma.py,sha256=2riMQvwe2T99X_NtO9yO9lpZ0zj2Nb06l9Hb1lWJ00E,4509
|
|
@@ -60,15 +61,15 @@ ws_bom_robot_app/llm/vector_store/integration/manager.py,sha256=S5z8LK_RcsCmWvLi
|
|
|
60
61
|
ws_bom_robot_app/llm/vector_store/integration/s3.py,sha256=_SAuPfyK7lIz7Jq1LiBavkF1lre5yqe6DGlMYnxMa4o,3317
|
|
61
62
|
ws_bom_robot_app/llm/vector_store/integration/sftp.py,sha256=g6f-FKkEktx7nJahb7RKyQ4pM9wGik0_xXMDfWup-1c,2845
|
|
62
63
|
ws_bom_robot_app/llm/vector_store/integration/sharepoint.py,sha256=DhBcAwgr1u-dQ_8TxeLPu7kzr_EDogCRQeBrIULtWfo,4898
|
|
63
|
-
ws_bom_robot_app/llm/vector_store/integration/shopify.py,sha256=
|
|
64
|
+
ws_bom_robot_app/llm/vector_store/integration/shopify.py,sha256=pJzd1yBo_NWSAls88wl8FSBWXPzE-N-tOT4oxiZft2A,5531
|
|
64
65
|
ws_bom_robot_app/llm/vector_store/integration/sitemap.py,sha256=FJy2wQDvML_1fR4g_6y1pck6IKQWCJ_FmBF0I4ygVzE,5160
|
|
65
66
|
ws_bom_robot_app/llm/vector_store/integration/slack.py,sha256=hiE1kkg7868mbP2wVWQLmC1fK2jIE1lT7f8hVN0NqeY,2636
|
|
66
|
-
ws_bom_robot_app/llm/vector_store/integration/thron.py,sha256=
|
|
67
|
+
ws_bom_robot_app/llm/vector_store/integration/thron.py,sha256=WmVi6obKVtJeGxDcKP0rJqT0n1uZdbJfsw-FhaYXF6Y,4373
|
|
67
68
|
ws_bom_robot_app/llm/vector_store/loader/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
68
69
|
ws_bom_robot_app/llm/vector_store/loader/base.py,sha256=GjUS2oaz0LHOSal5pipBkomZtrYUNcKPSd8bzhUU5Dc,6889
|
|
69
70
|
ws_bom_robot_app/llm/vector_store/loader/docling.py,sha256=IOv1A0HSIWiHWQFzI4fdApfxrKgXOqwmC3mPXlKplqQ,4012
|
|
70
|
-
ws_bom_robot_app/llm/vector_store/loader/json_loader.py,sha256=
|
|
71
|
-
ws_bom_robot_app-0.0.
|
|
72
|
-
ws_bom_robot_app-0.0.
|
|
73
|
-
ws_bom_robot_app-0.0.
|
|
74
|
-
ws_bom_robot_app-0.0.
|
|
71
|
+
ws_bom_robot_app/llm/vector_store/loader/json_loader.py,sha256=LDppW0ZATo4_1hh-KlsAM3TLawBvwBxva_a7k5Oz1sc,858
|
|
72
|
+
ws_bom_robot_app-0.0.87.dist-info/METADATA,sha256=3pNNKhvD9yn8STxW00dHyEGUgedYB_bSKzK7ioNkmZ0,9985
|
|
73
|
+
ws_bom_robot_app-0.0.87.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
74
|
+
ws_bom_robot_app-0.0.87.dist-info/top_level.txt,sha256=Yl0akyHVbynsBX_N7wx3H3ZTkcMLjYyLJs5zBMDAKcM,17
|
|
75
|
+
ws_bom_robot_app-0.0.87.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|