Skip to main content

llama-index-tools-opticparse

Official LlamaIndex BaseToolSpec integration for OpticParse Multimodal Vision Web Scraper and PhishVision Zero-Day Cybersecurity & Drainer Detection.

Empower your autonomous LlamaIndex agents, RAG workflows, and retrieval pipelines with stealth, anti-bot resilient web extraction and real-time security scanning.


Installation

pip install llama-index-tools-opticparse

Quickstart

1. Zero-CSS Autonomous Web Extraction

Equip your LlamaIndex Agent to scrape live websites without worrying about dynamic JavaScript, Cloudflare challenges, or brittle CSS selectors:

import os
from llama_index.tools.opticparse import OpticParseToolSpec
from llama_index.core.agent import FunctionCallingAgentWorker

# Initialize tool spec
tool_spec = OpticParseToolSpec(
    api_key=os.getenv("OPTICPARSE_API_KEY", "op_live_demo_agent")
)

# Convert to LlamaIndex tool list
tools = tool_spec.to_tool_list()

# Attach tools directly to your LlamaIndex Agent
# agent = FunctionCallingAgentWorker.from_tools(tools, llm=llm).as_agent()
# response = agent.chat("Scrape the latest pricing and specs from https://news.ycombinator.com")
# print(response)

2. Standalone Tool Execution

You can also run tool operations directly as standard Python methods:

from llama_index.tools.opticparse import OpticParseToolSpec

tool_spec = OpticParseToolSpec()

# Extract structured content
docs = tool_spec.extract(
    url="https://example.com",
    query="Extract product details and main headers"
)
print("Extracted content:", docs[0].text)

# Inspect unknown URLs for zero-day phishing or wallet drainers
threat_docs = tool_spec.inspect_threat(
    url="https://suspicious-crypto-portal.xyz"
)
print("Threat analysis:", threat_docs[0].text)

Tool Functions Exposed

Function Description Return Type
extract(url, query) Visual web scraper with anti-bot evasion & structured parsing. List[Document]
inspect_threat(url) Real-time zero-day cybersecurity & Web3 wallet-drainer scanner. List[Document]

Supported Ecosystems

  • LlamaIndex Agents: FunctionCallingAgent, OpenAIAgent, ReActAgent
  • LangChain: Use langchain-opticparse
  • Model Context Protocol (MCP): Native integration on Smithery & Glama
  • Coinbase AgentKit: On-chain autonomous agent action provider

License

MIT License. Maintained by OpticParse Enterprise.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llama_index_tools_opticparse-1.0.0.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llama_index_tools_opticparse-1.0.0-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file llama_index_tools_opticparse-1.0.0.tar.gz.

File metadata

File hashes

Hashes for llama_index_tools_opticparse-1.0.0.tar.gz
Algorithm Hash digest
SHA256 b80f36a8cbf23607f1cab913f07efb401d2f24e5e2c31ad1c563a55d0ab35d41
MD5 40b71095b12607c0945f67c9be646574
BLAKE2b-256 7f8bccd101fa86ca5734b24a274cca405080883973b77cd31ca489b4485aedfa

See more details on using hashes here.

File details

Details for the file llama_index_tools_opticparse-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for llama_index_tools_opticparse-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2904a12cc93da61c8643e3c76d4fb8bbb78847da287a44c971c0b8e1bf11baff
MD5 81b4ee83ec22fb40e520cca5430adef6
BLAKE2b-256 e82699a5bfa082618e0fc087e72e0e332ba9717b1a40cbae03a2f63fdbf003a4

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page