Skip to main content

LangChain tools for the OptionsAhoy equity-compensation calculators.

Project description

optionsahoy-langchain

LangChain tools for the OptionsAhoy equity-compensation calculators. Each tool is a StructuredTool with a pydantic args_schema mirroring an OptionsAhoy REST endpoint, built on top of the keyless optionsahoy client. No API key is required.

Covered calculators: incentive stock option (ISO) / alternative minimum tax (AMT) optimizer, non-qualified stock options (NSO), restricted stock units (RSU) sell-versus-hold, single-stock concentration, protective put hedge pricing, qualified small business stock (QSBS), and funding a cash goal from equity.

Install

From this repository, install both packages editable:

pip install -e integrations/python/optionsahoy
pip install -e integrations/python/optionsahoy-langchain

Usage

from langchain_optionsahoy import get_optionsahoy_tools

tools = get_optionsahoy_tools()  # one StructuredTool per endpoint

# Bind to any LangChain-compatible agent / model:
#   model_with_tools = model.bind_tools(tools)
# or invoke a tool directly:
qsbs = next(t for t in tools if t.name == "optionsahoy_qsbs_check")
result = qsbs.invoke({
    "acquisitionDate": "2018-01-01",
    "saleDate": "2026-02-01",
    "entityType": "us-c-corp",
    "acquisitionMethod": "original-issuance",
    "assetCategory": "under-50m",
    "industry": "tech-software",
    "activeBusiness": "yes",
    "adjustedBasis": 10000,
    "expectedGain": 2000000,
    "stateCode": "CA",
    "ordinaryIncome": 250000,
    "filingStatus": "single",
})
print(result)

Pass your own configured client with get_optionsahoy_tools(client=OptionsAhoyClient(...)).

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

optionsahoy_langchain-0.1.0.tar.gz (6.3 kB view details)

Uploaded Source

Built Distribution

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

optionsahoy_langchain-0.1.0-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file optionsahoy_langchain-0.1.0.tar.gz.

File metadata

  • Download URL: optionsahoy_langchain-0.1.0.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for optionsahoy_langchain-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e4177cc5c4c4a4796eecb0b3c9938ecd74a712e55bd44858352ebb21ed7d1b17
MD5 09864e0286339b9e98e278e792e10ae5
BLAKE2b-256 e322214d91de0fb1cb52ff208f8d2095b432eefbc6f7a43c692c111f5d810472

See more details on using hashes here.

Provenance

The following attestation bundles were made for optionsahoy_langchain-0.1.0.tar.gz:

Publisher: publish-python.yml on AlvisoOculus/optionsahoy-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file optionsahoy_langchain-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for optionsahoy_langchain-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fdb18cce1381661ca16e5c5ddb2bbe9daab0a4675f3297ed6ad0f7503dc089a0
MD5 b7a4c3304fb71388c64f816a8bf10df4
BLAKE2b-256 24fbfe3accb7998998c58ad957ade438b3f33bb4f248604eb12957005a2ab6a3

See more details on using hashes here.

Provenance

The following attestation bundles were made for optionsahoy_langchain-0.1.0-py3-none-any.whl:

Publisher: publish-python.yml on AlvisoOculus/optionsahoy-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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