hyperforge-nucliadb 1.0.0.post108__py3-none-any.whl → 1.0.0.post113__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.
- hyperforge_nucliadb/basic_ask_agent.py +16 -1
- hyperforge_nucliadb/driver.py +8 -2
- {hyperforge_nucliadb-1.0.0.post108.dist-info → hyperforge_nucliadb-1.0.0.post113.dist-info}/METADATA +11 -1
- {hyperforge_nucliadb-1.0.0.post108.dist-info → hyperforge_nucliadb-1.0.0.post113.dist-info}/RECORD +6 -6
- {hyperforge_nucliadb-1.0.0.post108.dist-info → hyperforge_nucliadb-1.0.0.post113.dist-info}/WHEEL +1 -1
- {hyperforge_nucliadb-1.0.0.post108.dist-info → hyperforge_nucliadb-1.0.0.post113.dist-info}/top_level.txt +0 -0
|
@@ -1554,6 +1554,17 @@ class BasicAskAgent(ContextAgent, Agent[BasicAskAgentConfig]):
|
|
|
1554
1554
|
logger.info(
|
|
1555
1555
|
f"No labels selected for faceted search on question {question}, skipping."
|
|
1556
1556
|
)
|
|
1557
|
+
context = Context(
|
|
1558
|
+
agent_id=self.agent_id,
|
|
1559
|
+
original_question_uuid=memory.original_question_uuid,
|
|
1560
|
+
actual_question_uuid=None,
|
|
1561
|
+
missing=question,
|
|
1562
|
+
question=question,
|
|
1563
|
+
source=source.id,
|
|
1564
|
+
chunks=[],
|
|
1565
|
+
agent="basic_ask_facets",
|
|
1566
|
+
title=f"Faceted search on {source.id} Knowledge Box",
|
|
1567
|
+
)
|
|
1557
1568
|
else:
|
|
1558
1569
|
# We are assuming resources equals fields here
|
|
1559
1570
|
facets, total = await ndb.field_labels(labelsets=labels_selected)
|
|
@@ -1593,7 +1604,11 @@ class BasicAskAgent(ContextAgent, Agent[BasicAskAgentConfig]):
|
|
|
1593
1604
|
await memory.add_step(
|
|
1594
1605
|
step_module=self.config.module,
|
|
1595
1606
|
step_title=self.step_title("Faceted count"),
|
|
1596
|
-
step_reason=
|
|
1607
|
+
step_reason=(
|
|
1608
|
+
"Faceted search performed"
|
|
1609
|
+
if labels_selected
|
|
1610
|
+
else "Faceted search skipped"
|
|
1611
|
+
),
|
|
1597
1612
|
step_value=selected_labels.get("reasoning", ""),
|
|
1598
1613
|
timeit=time() - t0,
|
|
1599
1614
|
input_nuclia_tokens=input_nt,
|
hyperforge_nucliadb/driver.py
CHANGED
|
@@ -303,9 +303,13 @@ class NucliaDBDriver(Driver):
|
|
|
303
303
|
result.append(word)
|
|
304
304
|
return " ".join(result)
|
|
305
305
|
|
|
306
|
-
async def ask(
|
|
306
|
+
async def ask(
|
|
307
|
+
self, item: AskRequest, headers: dict[str, str] | None = None
|
|
308
|
+
) -> SyncAskResponse:
|
|
309
|
+
request_headers = httpx.Headers(headers)
|
|
310
|
+
request_headers["X-NDB-Client"] = "agentic"
|
|
307
311
|
return await self.driver.ask(
|
|
308
|
-
kbid=self.config.kbid, content=item, headers=
|
|
312
|
+
kbid=self.config.kbid, content=item, headers=dict(request_headers)
|
|
309
313
|
)
|
|
310
314
|
|
|
311
315
|
async def find(
|
|
@@ -313,6 +317,7 @@ class NucliaDBDriver(Driver):
|
|
|
313
317
|
) -> KnowledgeboxFindResults:
|
|
314
318
|
return await self.driver.find(
|
|
315
319
|
kbid=self.config.kbid,
|
|
320
|
+
headers={"X-NDB-Client": "agentic"},
|
|
316
321
|
content=FindRequest(
|
|
317
322
|
query=q,
|
|
318
323
|
resource_filters=rids,
|
|
@@ -326,6 +331,7 @@ class NucliaDBDriver(Driver):
|
|
|
326
331
|
return await self.driver.find(
|
|
327
332
|
kbid=self.config.kbid,
|
|
328
333
|
content=q,
|
|
334
|
+
headers={"X-NDB-Client": "agentic"},
|
|
329
335
|
)
|
|
330
336
|
|
|
331
337
|
async def graph_relations(
|
{hyperforge_nucliadb-1.0.0.post108.dist-info → hyperforge_nucliadb-1.0.0.post113.dist-info}/METADATA
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: hyperforge_nucliadb
|
|
3
|
-
Version: 1.0.0.
|
|
3
|
+
Version: 1.0.0.post113
|
|
4
4
|
Summary: NucliaDB Hyperforge agent
|
|
5
5
|
Author-email: Nuclia <nucliadb@nuclia.com>
|
|
6
6
|
License-Expression: Apache-2.0
|
|
@@ -25,3 +25,13 @@ Basic ASK - Basic initial agent
|
|
|
25
25
|
Advanced ASK (deprecated)
|
|
26
26
|
ASK (experimental)
|
|
27
27
|
Sync (Sync Service oauth linked)
|
|
28
|
+
|
|
29
|
+
## Client identification
|
|
30
|
+
|
|
31
|
+
NucliaDB `/ask` and `/find` requests made by these agents use
|
|
32
|
+
`X-NDB-Client: agentic`, including when invoked as tools by a smart agent in a
|
|
33
|
+
RAO workflow. The Sync driver inherits the same behavior. Other request headers
|
|
34
|
+
are preserved, and caller-provided headers are not modified.
|
|
35
|
+
|
|
36
|
+
Workflow memory searches through `/find` also use the `agentic` client type.
|
|
37
|
+
The receiving NucliaDB API must support the `agentic` client type.
|
{hyperforge_nucliadb-1.0.0.post108.dist-info → hyperforge_nucliadb-1.0.0.post113.dist-info}/RECORD
RENAMED
|
@@ -2,9 +2,9 @@ hyperforge_nucliadb/__init__.py,sha256=65O_n-XVNaIHi258phJD-0yVKxb_l934ZrHorCkj7
|
|
|
2
2
|
hyperforge_nucliadb/advanced_ask_agent.py,sha256=nfoF0Gk8P38OQ43bIuItx05yP7ifDSSi9Xq-rJuKS2k,9477
|
|
3
3
|
hyperforge_nucliadb/advanced_ask_config.py,sha256=c44cUPb9V6doPFpLsIbypeWJTO3_pFd3zwbaJSTQdFs,12395
|
|
4
4
|
hyperforge_nucliadb/ask_utils.py,sha256=03KG4TnLoC-YhPHv32p65ZAyaU0IUaz62PjztZz0FwE,8528
|
|
5
|
-
hyperforge_nucliadb/basic_ask_agent.py,sha256=
|
|
5
|
+
hyperforge_nucliadb/basic_ask_agent.py,sha256=FeGm4mb-egaHmpCV5O_Ygdzufgt1cJOKJzN2Ei58I04,71956
|
|
6
6
|
hyperforge_nucliadb/basic_ask_config.py,sha256=6Fjzy1ff8MIsmAY6MM_uGmJ8VxOH5_6JoECenf1Dh04,1385
|
|
7
|
-
hyperforge_nucliadb/driver.py,sha256=
|
|
7
|
+
hyperforge_nucliadb/driver.py,sha256=UVFJFt39AdWi8twQJxoRS_F64fkQRTkpeTYRDj2Howg,15420
|
|
8
8
|
hyperforge_nucliadb/driver_config.py,sha256=CSBuQef-zir5JqDy-FnYRiLiZfpXyEK0UJETf3U82rg,1676
|
|
9
9
|
hyperforge_nucliadb/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
10
|
hyperforge_nucliadb/ask/__init__.py,sha256=PEAGi9HPhHsJuGrhUvPRc0jYR63ZAyVodY-UcmyW07M,50
|
|
@@ -26,7 +26,7 @@ hyperforge_nucliadb/sync/agent.py,sha256=3WFjZ2Xv1YL9XmcOLeaGM5qJbeWw1KDW85VpLEQ
|
|
|
26
26
|
hyperforge_nucliadb/sync/config.py,sha256=kmf6mM-IFlnlmsXqrZHzTUIa3LCLipBCH7tp8brVyuo,319
|
|
27
27
|
hyperforge_nucliadb/sync/config_driver.py,sha256=msBONAAQw2qfVrpyL3Ew9wWXXhwJZgdQ033sWZg5isk,1284
|
|
28
28
|
hyperforge_nucliadb/sync/driver.py,sha256=jPWQNMBOQVsZV-tFXNg2Qp1e_fX2hzIvJawLPAW2wTw,9859
|
|
29
|
-
hyperforge_nucliadb-1.0.0.
|
|
30
|
-
hyperforge_nucliadb-1.0.0.
|
|
31
|
-
hyperforge_nucliadb-1.0.0.
|
|
32
|
-
hyperforge_nucliadb-1.0.0.
|
|
29
|
+
hyperforge_nucliadb-1.0.0.post113.dist-info/METADATA,sha256=4VCRS3qFc39iaI8W5MrwgY18lm9fOj3ZiVLNdhJEeEs,1467
|
|
30
|
+
hyperforge_nucliadb-1.0.0.post113.dist-info/WHEEL,sha256=mOdXR9C3wMVov7cSY8PY-XCzo3SmmWCHvGQr5csJoao,91
|
|
31
|
+
hyperforge_nucliadb-1.0.0.post113.dist-info/top_level.txt,sha256=jtg2wNgOFs27BzB5Gu5xGfoeL2txFEZTzr0QCHzNROk,20
|
|
32
|
+
hyperforge_nucliadb-1.0.0.post113.dist-info/RECORD,,
|
|
File without changes
|