llama-index-tools-wikipedia


Namellama-index-tools-wikipedia JSON
Version 0.3.1 PyPI version JSON
download
home_pageNone
Summaryllama-index tools wikipedia integration
upload_time2025-07-18 15:41:34
maintainerajhofmann
docs_urlNone
authorNone
requires_python<4.0,>=3.9
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Wikipedia Tool

This tool fetches content from wikipedia and makes it available to the agent as a Tool. You can search for pages or load pages directly.

## Usage

This tool has more extensive example usage documented in a Jupyter notebook [here](https://github.com/run-llama/llama_index/blob/main/llama-index-integrations/tools/llama-index-tools-wikipedia/examples/wikipedia.ipynb)

```python
from llama_index.tools.wikipedia import WikipediaToolSpec
from llama_index.agent.openai import OpenAIAgent

tool_spec = WikipediaToolSpec()

agent = OpenAIAgent.from_tools(tool_spec.to_tool_list())

agent.chat("Who is Ben Afflecks spouse?")
```

`load_data`: Loads a page from wikipedia
`search_data`: Searches wikipedia for a query and loads all matching pages

This loader is designed to be used as a way to load data as a Tool in a Agent.
See [this LlamaIndex tutorial][1] for examples.

[1]: https://gpt-index.readthedocs.io/en/stable/examples/index_structs/knowledge_graph/KnowledgeGraphIndex_vs_VectorStoreIndex_vs_CustomIndex_combined.html#load-data-from-wikipedia

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "llama-index-tools-wikipedia",
    "maintainer": "ajhofmann",
    "docs_url": null,
    "requires_python": "<4.0,>=3.9",
    "maintainer_email": null,
    "keywords": null,
    "author": null,
    "author_email": "Your Name <you@example.com>",
    "download_url": "https://files.pythonhosted.org/packages/fe/cd/a8b2f9044cdd5f956669e16788bc28e0fd037f979b5bc8ff4cfb0e58327a/llama_index_tools_wikipedia-0.3.1.tar.gz",
    "platform": null,
    "description": "# Wikipedia Tool\n\nThis tool fetches content from wikipedia and makes it available to the agent as a Tool. You can search for pages or load pages directly.\n\n## Usage\n\nThis tool has more extensive example usage documented in a Jupyter notebook [here](https://github.com/run-llama/llama_index/blob/main/llama-index-integrations/tools/llama-index-tools-wikipedia/examples/wikipedia.ipynb)\n\n```python\nfrom llama_index.tools.wikipedia import WikipediaToolSpec\nfrom llama_index.agent.openai import OpenAIAgent\n\ntool_spec = WikipediaToolSpec()\n\nagent = OpenAIAgent.from_tools(tool_spec.to_tool_list())\n\nagent.chat(\"Who is Ben Afflecks spouse?\")\n```\n\n`load_data`: Loads a page from wikipedia\n`search_data`: Searches wikipedia for a query and loads all matching pages\n\nThis loader is designed to be used as a way to load data as a Tool in a Agent.\nSee [this LlamaIndex tutorial][1] for examples.\n\n[1]: https://gpt-index.readthedocs.io/en/stable/examples/index_structs/knowledge_graph/KnowledgeGraphIndex_vs_VectorStoreIndex_vs_CustomIndex_combined.html#load-data-from-wikipedia\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "llama-index tools wikipedia integration",
    "version": "0.3.1",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "4503bdc5d662815079c4e5a1a5feb7618f0d0735488f3b38d9d6a4eea6e607e6",
                "md5": "1d96df13bb809651d698146a5a2132a1",
                "sha256": "4838ba3808c13f560b08e00337b078ab81f0d94ac20e3c61cbf00520c7498ddd"
            },
            "downloads": -1,
            "filename": "llama_index_tools_wikipedia-0.3.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "1d96df13bb809651d698146a5a2132a1",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.9",
            "size": 3489,
            "upload_time": "2025-07-18T15:41:33",
            "upload_time_iso_8601": "2025-07-18T15:41:33.637583Z",
            "url": "https://files.pythonhosted.org/packages/45/03/bdc5d662815079c4e5a1a5feb7618f0d0735488f3b38d9d6a4eea6e607e6/llama_index_tools_wikipedia-0.3.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "fecda8b2f9044cdd5f956669e16788bc28e0fd037f979b5bc8ff4cfb0e58327a",
                "md5": "b159a78ff36dd744128839fa6e581083",
                "sha256": "02de655e7c6ece99efaf75270b2eb6d8ad920823b8456f0fcb826b8b23b0ef16"
            },
            "downloads": -1,
            "filename": "llama_index_tools_wikipedia-0.3.1.tar.gz",
            "has_sig": false,
            "md5_digest": "b159a78ff36dd744128839fa6e581083",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.9",
            "size": 3888,
            "upload_time": "2025-07-18T15:41:34",
            "upload_time_iso_8601": "2025-07-18T15:41:34.648530Z",
            "url": "https://files.pythonhosted.org/packages/fe/cd/a8b2f9044cdd5f956669e16788bc28e0fd037f979b5bc8ff4cfb0e58327a/llama_index_tools_wikipedia-0.3.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-18 15:41:34",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "llama-index-tools-wikipedia"
}
        
Elapsed time: 2.00396s