Skip to main content

Python SDK for H|psi Quantum Finance APIs.

Project description

HPSI Python REST SDK

The hpsilab-mcp Python package currently wraps the hosted hpsilab.com REST API.

The Python SDK currently wraps the hosted REST API. Some MCP-only tools are not yet available through REST endpoints.

Installation

pip install hpsilab-mcp

Quick Start

from hpsilab_mcp import HpsiMcpClient

client = HpsiMcpClient()

calls = {
    "analyze_stock": client.analyze_stock("NVDA"),
    "get_ai_prediction": client.get_ai_prediction("NVDA"),
    "get_iv_radar": client.get_iv_radar("NVDA"),
    "get_option_pressure": client.get_option_pressure("NVDA"),
    "get_monte_carlo": client.get_monte_carlo("NVDA"),
    "get_equity_curves": client.get_equity_curves("NVDA"),
    "generate_stock_images": client.generate_stock_images("NVDA"),
    "generate_stock_research_report": client.generate_stock_research_report("NVDA"),
}

print(calls["analyze_stock"])

Authenticated Usage

from hpsilab_mcp import HpsiMcpClient

client = HpsiMcpClient(
    api_key="YOUR_API_KEY",
    base_url="https://hpsilab.com",
)

result = client.get_ai_prediction("TSLA")

print(result)

REST SDK Methods

client.get_ai_prediction("NVDA")
client.analyze_stock("NVDA")
client.get_iv_radar("NVDA")
client.get_option_pressure("NVDA")
client.get_monte_carlo("NVDA")
client.get_equity_curve("NVDA")
client.get_equity_curves("NVDA")
client.generate_stock_images("NVDA")
client.generate_stock_research_report("NVDA")

Endpoint mapping:

Method Endpoint
analyze_stock(symbol) GET /api/analyze_stock/{symbol}
get_ai_prediction(symbol) GET /api/ai_prediction/{symbol}
get_iv_radar(symbol) GET /api/iv_batch?symbols={symbol}
get_option_pressure(symbol) GET /api/option_pressure/{symbol}
get_monte_carlo(symbol) GET /api/monte_carlo/{symbol}
get_equity_curve(symbol) GET /api/equity_curve/{symbol}
get_equity_curves(symbol) GET /api/equity_curve/{symbol}
generate_stock_images(symbol) POST /api/stock_report/{symbol}/images
generate_stock_research_report(symbol) POST /api/stock_report/{symbol}/research_report

Capability Matrix

Capability REST API MCP
analyze_stock Yes Yes
get_ai_prediction Yes Yes
get_iv_radar Yes Yes
get_option_pressure Yes Yes
get_monte_carlo Yes Yes
get_equity_curve Yes No
get_equity_curves Yes Yes
generate_stock_images Yes Yes
generate_stock_research_report Yes Yes

MCP Transport

All official MCP tools now have REST SDK coverage. Use an MCP-compatible client when you specifically need MCP transport, tool discovery, or assistant-native tool calls.

Scope

This package is a REST API wrapper. It does not implement MCP transport, SSE, streaming, tool discovery, Claude integration, or proprietary finance logic.

These tools return research-oriented information. They are not financial advice.

License

MIT. See LICENSE.

Project details


Download files

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

Source Distribution

hpsilab_mcp-0.2.0.tar.gz (9.0 kB view details)

Uploaded Source

Built Distribution

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

hpsilab_mcp-0.2.0-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file hpsilab_mcp-0.2.0.tar.gz.

File metadata

  • Download URL: hpsilab_mcp-0.2.0.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for hpsilab_mcp-0.2.0.tar.gz
Algorithm Hash digest
SHA256 960bef0a5d9116d2172ea4d7bb5dba85af5673f19fe941b67621317dcb3e0e15
MD5 3afaf80028b6689a61cb89c5d183476d
BLAKE2b-256 bac81b2f704dc0621c7d1b61c1971ef179c8ab9e75af40f67c5b53f6257740b4

See more details on using hashes here.

File details

Details for the file hpsilab_mcp-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: hpsilab_mcp-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 5.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for hpsilab_mcp-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 539aef64e7f6759203f436124dc467eee0c4d42e2a6c5659887a13b8c453585c
MD5 cc775558eea765cfa00e50043a7f6faa
BLAKE2b-256 3a006a7b7424b31b57a64b08a36078b7ec571f7e8e442d229cc14b11045c014c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page