aiqtoolkit-llama-index 1.2.0.dev0__py3-none-any.whl → 1.2.0rc2__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.

Potentially problematic release.


This version of aiqtoolkit-llama-index might be problematic. Click here for more details.

aiq/meta/pypi.md CHANGED
@@ -15,7 +15,7 @@ See the License for the specific language governing permissions and
15
15
  limitations under the License.
16
16
  -->
17
17
 
18
- ![NVIDIA Agent Intelligence Toolkit](https://media.githubusercontent.com/media/NVIDIA/AIQToolkit/refs/heads/main/docs/source/_static/aiqtoolkit_banner.png "AIQ toolkit banner image")
18
+ ![NVIDIA Agent Intelligence Toolkit](https://media.githubusercontent.com/media/NVIDIA/NeMo-Agent-Toolkit/refs/heads/main/docs/source/_static/aiqtoolkit_banner.png "AIQ toolkit banner image")
19
19
 
20
20
  # NVIDIA Agent Intelligence Toolkit Subpackage
21
21
  This is a subpackage for Llama-Index integration in AIQ toolkit.
@@ -16,8 +16,11 @@
16
16
  from aiq.builder.builder import Builder
17
17
  from aiq.builder.framework_enum import LLMFrameworkEnum
18
18
  from aiq.cli.register_workflow import register_llm_client
19
+ from aiq.data_models.retry_mixin import RetryMixin
20
+ from aiq.llm.aws_bedrock_llm import AWSBedrockModelConfig
19
21
  from aiq.llm.nim_llm import NIMModelConfig
20
22
  from aiq.llm.openai_llm import OpenAIModelConfig
23
+ from aiq.utils.exception_handlers.automatic_retries import patch_with_retry
21
24
 
22
25
 
23
26
  @register_llm_client(config_type=NIMModelConfig, wrapper_type=LLMFrameworkEnum.LLAMA_INDEX)
@@ -32,6 +35,12 @@ async def nim_llama_index(llm_config: NIMModelConfig, builder: Builder):
32
35
 
33
36
  llm = NVIDIA(**kwargs)
34
37
 
38
+ if isinstance(llm_config, RetryMixin):
39
+ llm = patch_with_retry(llm,
40
+ retries=llm_config.num_retries,
41
+ retry_codes=llm_config.retry_on_status_codes,
42
+ retry_on_messages=llm_config.retry_on_errors)
43
+
35
44
  yield llm
36
45
 
37
46
 
@@ -47,7 +56,28 @@ async def openai_llama_index(llm_config: OpenAIModelConfig, builder: Builder):
47
56
 
48
57
  llm = OpenAI(**kwargs)
49
58
 
50
- # Disable content blocks
51
- llm.supports_content_blocks = False
59
+ if isinstance(llm_config, RetryMixin):
60
+ llm = patch_with_retry(llm,
61
+ retries=llm_config.num_retries,
62
+ retry_codes=llm_config.retry_on_status_codes,
63
+ retry_on_messages=llm_config.retry_on_errors)
64
+
65
+ yield llm
66
+
67
+
68
+ @register_llm_client(config_type=AWSBedrockModelConfig, wrapper_type=LLMFrameworkEnum.LLAMA_INDEX)
69
+ async def aws_bedrock_llama_index(llm_config: AWSBedrockModelConfig, builder: Builder):
70
+
71
+ from llama_index.llms.bedrock import Bedrock
72
+
73
+ kwargs = llm_config.model_dump(exclude={"type", "max_tokens"}, by_alias=True)
74
+
75
+ llm = Bedrock(**kwargs)
76
+
77
+ if isinstance(llm_config, RetryMixin):
78
+ llm = patch_with_retry(llm,
79
+ retries=llm_config.num_retries,
80
+ retry_codes=llm_config.retry_on_status_codes,
81
+ retry_on_messages=llm_config.retry_on_errors)
52
82
 
53
83
  yield llm
@@ -1,14 +1,15 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: aiqtoolkit-llama-index
3
- Version: 1.2.0.dev0
3
+ Version: 1.2.0rc2
4
4
  Summary: Subpackage for Llama-Index integration in AIQtoolkit
5
5
  Keywords: ai,rag,agents
6
6
  Classifier: Programming Language :: Python
7
7
  Requires-Python: <3.13,>=3.11
8
8
  Description-Content-Type: text/markdown
9
- Requires-Dist: aiqtoolkit==v1.2.0-dev
9
+ Requires-Dist: aiqtoolkit==v1.2.0-rc2
10
10
  Requires-Dist: llama-index-core==0.12.21
11
11
  Requires-Dist: llama-index-embeddings-nvidia==0.3.1
12
+ Requires-Dist: llama-index-llms-bedrock==0.3.8
12
13
  Requires-Dist: llama-index-llms-nvidia==0.3.1
13
14
  Requires-Dist: llama-index-readers-file==0.4.4
14
15
  Requires-Dist: llama-index==0.12.21
@@ -30,7 +31,7 @@ See the License for the specific language governing permissions and
30
31
  limitations under the License.
31
32
  -->
32
33
 
33
- ![NVIDIA Agent Intelligence Toolkit](https://media.githubusercontent.com/media/NVIDIA/AIQToolkit/refs/heads/main/docs/source/_static/aiqtoolkit_banner.png "AIQ toolkit banner image")
34
+ ![NVIDIA Agent Intelligence Toolkit](https://media.githubusercontent.com/media/NVIDIA/NeMo-Agent-Toolkit/refs/heads/main/docs/source/_static/aiqtoolkit_banner.png "AIQ toolkit banner image")
34
35
 
35
36
  # NVIDIA Agent Intelligence Toolkit Subpackage
36
37
  This is a subpackage for Llama-Index integration in AIQ toolkit.
@@ -0,0 +1,10 @@
1
+ aiq/meta/pypi.md,sha256=tcqovA7tPKu3gSR9froqCciJUn-NrMKKnbC47tjRyp0,1088
2
+ aiq/plugins/llama_index/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
+ aiq/plugins/llama_index/llm.py,sha256=kxoorizIF5jM9-mAup57c2tmV5zp4t3eDuaGhDG9EiI,3220
4
+ aiq/plugins/llama_index/register.py,sha256=da1IYMrYe4MUtlwzBGIiukPazf7WU40j5X3n2KCjNts,868
5
+ aiq/plugins/llama_index/tool_wrapper.py,sha256=n7E6uzVtcyFXSWtkYG8yrtqRCsXVHdEU38eTrWLSlrU,1387
6
+ aiqtoolkit_llama_index-1.2.0rc2.dist-info/METADATA,sha256=0Ki10EGELmB-icT-xOWy482nFtEfJm4JZJO8iCAjgMo,1664
7
+ aiqtoolkit_llama_index-1.2.0rc2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
8
+ aiqtoolkit_llama_index-1.2.0rc2.dist-info/entry_points.txt,sha256=2_FES--T1uOL8QdHJWWhuFipXoSK8uo0DR8olysK2Ck,68
9
+ aiqtoolkit_llama_index-1.2.0rc2.dist-info/top_level.txt,sha256=fo7AzYcNhZ_tRWrhGumtxwnxMew4xrT1iwouDy_f0Kc,4
10
+ aiqtoolkit_llama_index-1.2.0rc2.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.7.1)
2
+ Generator: setuptools (80.9.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,10 +0,0 @@
1
- aiq/meta/pypi.md,sha256=ekC3K0mCeJGZYxfubRfTs5qFLWDwQGf5_iCNqrD8sCw,1080
2
- aiq/plugins/llama_index/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
- aiq/plugins/llama_index/llm.py,sha256=3F-hNlqgkrTz_yd1WtarRmN1GhcLOTQCizuXGiKbBYw,1848
4
- aiq/plugins/llama_index/register.py,sha256=da1IYMrYe4MUtlwzBGIiukPazf7WU40j5X3n2KCjNts,868
5
- aiq/plugins/llama_index/tool_wrapper.py,sha256=n7E6uzVtcyFXSWtkYG8yrtqRCsXVHdEU38eTrWLSlrU,1387
6
- aiqtoolkit_llama_index-1.2.0.dev0.dist-info/METADATA,sha256=6idWcPhp8gzNSSUswJjV4qcFGR56LckstL07KpI5rPU,1611
7
- aiqtoolkit_llama_index-1.2.0.dev0.dist-info/WHEEL,sha256=Nw36Djuh_5VDukK0H78QzOX-_FQEo6V37m3nkm96gtU,91
8
- aiqtoolkit_llama_index-1.2.0.dev0.dist-info/entry_points.txt,sha256=2_FES--T1uOL8QdHJWWhuFipXoSK8uo0DR8olysK2Ck,68
9
- aiqtoolkit_llama_index-1.2.0.dev0.dist-info/top_level.txt,sha256=fo7AzYcNhZ_tRWrhGumtxwnxMew4xrT1iwouDy_f0Kc,4
10
- aiqtoolkit_llama_index-1.2.0.dev0.dist-info/RECORD,,