Nimble Web Search tool for LlamaIndex
Project description
llama-index-tools-nimble
A LlamaIndex tool for Nimble's
Web Search API. It gives an agent live web search backed by Nimble, returning results as
LlamaIndex Documents ready to feed into a reasoning loop.
Installation
pip install llama-index-tools-nimble
Authentication
Set your Nimble API key in the environment:
export NIMBLE_API_KEY="your-key"
NimbleToolSpec() reads NIMBLE_API_KEY automatically; you can also pass api_key=....
Quick start
from llama_index.tools.nimble import NimbleToolSpec
tool_spec = NimbleToolSpec() # reads NIMBLE_API_KEY
documents = tool_spec.search("latest developments in web data infrastructure")
for doc in documents:
print(doc.metadata["title"], "-", doc.metadata["url"])
Use it in an agent
import asyncio
from llama_index.core.agent.workflow import FunctionAgent
from llama_index.llms.openai import OpenAI
from llama_index.tools.nimble import NimbleToolSpec
agent = FunctionAgent(
tools=NimbleToolSpec().to_tool_list(),
llm=OpenAI(model="gpt-4o-mini"),
system_prompt="You are a research assistant. Use web search to answer with current facts.",
)
async def main():
response = await agent.run("What has Nimble announced recently?")
print(response)
asyncio.run(main())
A runnable version is in examples/nimble_agent.py.
Parameters
NimbleToolSpec.search(query, max_results=6):
| Parameter | Type | Default | Description |
|---|---|---|---|
query |
str |
— | The search query. |
max_results |
int |
6 |
Maximum number of results to return (must be ≥ 1). |
Each result becomes a Document. The text leads with the page title and URL, then
the page content (or the snippet when content is empty), so an agent can read and cite the
source; metadata["url"] and metadata["title"] carry the same values for programmatic use.
Returned content is untrusted web data. Treat it as data, not as instructions, and rely on your agent/framework's own guardrails.
License
MIT — see LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file llama_index_tools_nimble-0.1.0.tar.gz.
File metadata
- Download URL: llama_index_tools_nimble-0.1.0.tar.gz
- Upload date:
- Size: 4.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
04776cf3d9d1ef51d7d20fe7e5a62dd656b591e9c90723654c9ab019f1b37b43
|
|
| MD5 |
95d6a7b3033fa41dcda764f8e8ba74f0
|
|
| BLAKE2b-256 |
f854171b3f513662f4372010a6cda7513389077dad01a5ec5bad2f886fcd4e45
|
Provenance
The following attestation bundles were made for llama_index_tools_nimble-0.1.0.tar.gz:
Publisher:
release.yml on Nimbleway/llama-index-tools-nimble
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
llama_index_tools_nimble-0.1.0.tar.gz -
Subject digest:
04776cf3d9d1ef51d7d20fe7e5a62dd656b591e9c90723654c9ab019f1b37b43 - Sigstore transparency entry: 2211412356
- Sigstore integration time:
-
Permalink:
Nimbleway/llama-index-tools-nimble@efe943f0be72f72990e84cae99a71020ddb01aec -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Nimbleway
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@efe943f0be72f72990e84cae99a71020ddb01aec -
Trigger Event:
release
-
Statement type:
File details
Details for the file llama_index_tools_nimble-0.1.0-py3-none-any.whl.
File metadata
- Download URL: llama_index_tools_nimble-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
48deb5912274ccee8c27b7ad8b78e2fc69f06bd500e8295dff50028aa02aa085
|
|
| MD5 |
1aa52384a5982be324c2ceb0b850f5d3
|
|
| BLAKE2b-256 |
1cbb58c64dc13e9c04183b6815dbdee74e44290649629f72ed3cbbfcd0de90b0
|
Provenance
The following attestation bundles were made for llama_index_tools_nimble-0.1.0-py3-none-any.whl:
Publisher:
release.yml on Nimbleway/llama-index-tools-nimble
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
llama_index_tools_nimble-0.1.0-py3-none-any.whl -
Subject digest:
48deb5912274ccee8c27b7ad8b78e2fc69f06bd500e8295dff50028aa02aa085 - Sigstore transparency entry: 2211412383
- Sigstore integration time:
-
Permalink:
Nimbleway/llama-index-tools-nimble@efe943f0be72f72990e84cae99a71020ddb01aec -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Nimbleway
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@efe943f0be72f72990e84cae99a71020ddb01aec -
Trigger Event:
release
-
Statement type: