unique_internal_search 2026.36.0.dev0__tar.gz → 2026.36.0.dev2__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.
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/PKG-INFO +2 -2
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/pyproject.toml +2 -2
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/service.py +3 -25
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/uploaded_search/service.py +1 -19
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/README.md +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/__init__.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/config.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/invocation_stats.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/prompts.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/services/message_log.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/uploaded_search/config.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/uploaded_search/prompts/__init__.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/uploaded_search/prompts/tool_description_for_system_prompt.j2 +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/utils.py +0 -0
- {unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/unique_internal_search/validators.py +0 -0
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: unique-internal-search
|
|
3
|
-
Version: 2026.36.0.
|
|
3
|
+
Version: 2026.36.0.dev2
|
|
4
4
|
Summary:
|
|
5
5
|
Author: Martin Fadler, Sadique Sheik, Fabian Schläpfer, Pascal Hauri
|
|
6
6
|
Author-email: Martin Fadler <martin.fadler@unique.ch>, Sadique Sheik <sadique@unique.ch>, Fabian Schläpfer <fabian@unique.ch>, Pascal Hauri <pascal@unique.ch>
|
|
7
7
|
License: Proprietary
|
|
8
8
|
Requires-Dist: pydantic>=2.8.2,<3
|
|
9
9
|
Requires-Dist: typing-extensions>=4.9.0,<5
|
|
10
|
-
Requires-Dist: unique-toolkit>=2026.36.0.
|
|
10
|
+
Requires-Dist: unique-toolkit>=2026.36.0.dev6,<2026.36.0rc0
|
|
11
11
|
Requires-Python: >=3.12, <4
|
|
12
12
|
Description-Content-Type: text/markdown
|
|
13
13
|
|
{unique_internal_search-2026.36.0.dev0 → unique_internal_search-2026.36.0.dev2}/pyproject.toml
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "unique_internal_search"
|
|
3
|
-
version = "2026.36.0.
|
|
3
|
+
version = "2026.36.0.dev2"
|
|
4
4
|
description = ""
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
license = { text = "Proprietary" }
|
|
@@ -14,7 +14,7 @@ requires-python = ">=3.12,<4"
|
|
|
14
14
|
dependencies = [
|
|
15
15
|
"pydantic>=2.8.2,<3",
|
|
16
16
|
"typing-extensions>=4.9.0,<5",
|
|
17
|
-
"unique-toolkit>=2026.36.0.
|
|
17
|
+
"unique-toolkit>=2026.36.0.dev6,<2026.36.0rc0",
|
|
18
18
|
]
|
|
19
19
|
|
|
20
20
|
[build-system]
|
|
@@ -549,23 +549,14 @@ class InternalSearchTool(Tool[InternalSearchConfig], InternalSearchService):
|
|
|
549
549
|
search_strings_list = list(dict.fromkeys(search_strings_list))
|
|
550
550
|
search_strings_list = search_strings_list[: self.config.max_search_strings]
|
|
551
551
|
|
|
552
|
-
new_answers_ui = feature_flags.enable_new_answers_ui_un_14411.is_enabled(
|
|
553
|
-
self.company_id
|
|
554
|
-
)
|
|
555
|
-
|
|
556
552
|
message_logger = self._get_message_logger(
|
|
557
|
-
|
|
553
|
+
message_step_logger=self._message_step_logger
|
|
558
554
|
)
|
|
559
555
|
|
|
560
556
|
await message_logger.log_queries(search_strings_list)
|
|
561
557
|
|
|
562
558
|
await message_logger.log_progress("_Retrieving search results_")
|
|
563
559
|
|
|
564
|
-
if not new_answers_ui:
|
|
565
|
-
await self.post_progress_message(
|
|
566
|
-
f"{'; '.join(search_strings_list)}", tool_call
|
|
567
|
-
)
|
|
568
|
-
|
|
569
560
|
selected_chunks = await self.search(
|
|
570
561
|
**tool_call.arguments,
|
|
571
562
|
log_progress=message_logger.log_progress,
|
|
@@ -589,19 +580,6 @@ class InternalSearchTool(Tool[InternalSearchConfig], InternalSearchService):
|
|
|
589
580
|
system_reminder=self.config.experimental_features.tool_response_system_reminder.get_reminder_prompt,
|
|
590
581
|
)
|
|
591
582
|
|
|
592
|
-
if (
|
|
593
|
-
self.tool_progress_reporter
|
|
594
|
-
and not feature_flags.enable_new_answers_ui_un_14411.is_enabled(
|
|
595
|
-
self.company_id
|
|
596
|
-
)
|
|
597
|
-
):
|
|
598
|
-
await self.tool_progress_reporter.notify_from_tool_call(
|
|
599
|
-
tool_call=tool_call,
|
|
600
|
-
name=f"**{self.tool_execution_message_name}**",
|
|
601
|
-
message=f"{'; '.join(search_strings_list)}",
|
|
602
|
-
state=ProgressState.FINISHED,
|
|
603
|
-
)
|
|
604
|
-
|
|
605
583
|
return tool_response
|
|
606
584
|
|
|
607
585
|
## Note: This function is only used by the Investment Research Agent and Agentic Search. Once these agents are moved out of the monorepo, this function should be removed.
|
|
@@ -641,14 +619,14 @@ class InternalSearchTool(Tool[InternalSearchConfig], InternalSearchService):
|
|
|
641
619
|
)
|
|
642
620
|
|
|
643
621
|
def _get_message_logger(
|
|
644
|
-
self,
|
|
622
|
+
self, message_step_logger: MessageStepLogger | None
|
|
645
623
|
) -> InternalSearchMessageLogger | InternalSearchMessageLoggerNoop:
|
|
646
624
|
return (
|
|
647
625
|
InternalSearchMessageLogger(
|
|
648
626
|
message_step_logger=message_step_logger,
|
|
649
627
|
tool_display_name=self._display_name,
|
|
650
628
|
)
|
|
651
|
-
if message_step_logger is not None
|
|
629
|
+
if message_step_logger is not None
|
|
652
630
|
else InternalSearchMessageLoggerNoop()
|
|
653
631
|
)
|
|
654
632
|
|
|
@@ -10,10 +10,7 @@ from unique_toolkit.agentic.tools.factory import ToolFactory
|
|
|
10
10
|
from unique_toolkit.agentic.tools.names import UPLOADED_SEARCH_TOOL_NAME
|
|
11
11
|
from unique_toolkit.agentic.tools.schemas import ToolCallResponse
|
|
12
12
|
from unique_toolkit.agentic.tools.tool import Tool
|
|
13
|
-
from unique_toolkit.agentic.tools.tool_progress_reporter import
|
|
14
|
-
ProgressState,
|
|
15
|
-
ToolProgressReporter,
|
|
16
|
-
)
|
|
13
|
+
from unique_toolkit.agentic.tools.tool_progress_reporter import ToolProgressReporter
|
|
17
14
|
from unique_toolkit.app.schemas import ChatEvent
|
|
18
15
|
from unique_toolkit.chat.service import LanguageModelToolDescription
|
|
19
16
|
from unique_toolkit.content import Content
|
|
@@ -113,10 +110,7 @@ class UploadedSearchTool(Tool[UploadedSearchConfig]):
|
|
|
113
110
|
return evaluation_check_list
|
|
114
111
|
|
|
115
112
|
async def run(self, tool_call: LanguageModelFunction) -> ToolCallResponse:
|
|
116
|
-
search_string_data = ""
|
|
117
113
|
if isinstance(tool_call.arguments, dict):
|
|
118
|
-
search_string_data = tool_call.arguments.get("search_string", "") or ""
|
|
119
|
-
|
|
120
114
|
# Verify no content_id outside valid ones, as tool may not be strict
|
|
121
115
|
|
|
122
116
|
if "content_ids" in tool_call.arguments:
|
|
@@ -137,18 +131,6 @@ class UploadedSearchTool(Tool[UploadedSearchConfig]):
|
|
|
137
131
|
tool_call.arguments["content_ids"] = filtered
|
|
138
132
|
|
|
139
133
|
tool_response = await self._internal_search_tool.run(tool_call)
|
|
140
|
-
if (
|
|
141
|
-
self._tool_progress_reporter
|
|
142
|
-
and not feature_flags.enable_new_answers_ui_un_14411.is_enabled(
|
|
143
|
-
self._company_id
|
|
144
|
-
)
|
|
145
|
-
):
|
|
146
|
-
await self._tool_progress_reporter.notify_from_tool_call(
|
|
147
|
-
tool_call=tool_call,
|
|
148
|
-
name="**Search Uploaded Document**",
|
|
149
|
-
message=f"{search_string_data}",
|
|
150
|
-
state=ProgressState.FINISHED,
|
|
151
|
-
)
|
|
152
134
|
tool_response.name = self.name
|
|
153
135
|
if self._config.enable_tool_call_system_reminder:
|
|
154
136
|
tool_response.system_reminder = (
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|