Token Classification
GLiNER2
Safetensors
English
lora
finance
options
options-trading
unusual-options-flow
twitter
fintwit
stocks
ner
information-extraction
Instructions to use StephanAkkerman/options-recognizer-gliner2-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- GLiNER2
How to use StephanAkkerman/options-recognizer-gliner2-base with GLiNER2:
from gliner2 import AutoExtractor extractor = AutoExtractor.from_pretrained("StephanAkkerman/options-recognizer-gliner2-base") # Extract entities text = "Apple CEO Tim Cook announced iPhone 15 in Cupertino yesterday." result = extractor.extract_entities(text, ["company", "person", "product", "location"]) print(result) - Notebooks
- Google Colab
- Kaggle
Download recognizer_config.json from StephanAkkerman/options-recognizer-gliner2-base: direct link, hf CLI and curl.
- Browser
- Download file 1.44 kB
-
https://huggingface.co/StephanAkkerman/options-recognizer-gliner2-base/resolve/main/recognizer_config.json
- Command line
-
hf download hf://StephanAkkerman/options-recognizer-gliner2-base/recognizer_config.json
-
curl -L -o recognizer_config.json https://huggingface.co/StephanAkkerman/options-recognizer-gliner2-base/resolve/main/recognizer_config.json
1.44 kB
| { | |
| "base_model": "fastino/gliner2-base-v1", | |
| "adapter_version": 1, | |
| "labels": [ | |
| "ticker", | |
| "strike", | |
| "option_type", | |
| "expiry", | |
| "premium", | |
| "price" | |
| ], | |
| "entity_descriptions": { | |
| "ticker": "The stock or ETF symbol an option contract is written on, usually 1-5 letters and often preceded by a dollar sign (e.g., $AAPL, SPY, $T). MUST NOT be a company name, an @handle, or slang (YOLO, NFA, OTM, ITM).", | |
| "strike": "The strike price of an option contract, e.g. 350, 162.5, or $1300 in '$1300 calls'. MUST NOT be the stock's current price, a premium or per-contract price, a date, or a percentage.", | |
| "option_type": "Whether the contract is a call or a put, in any written form: C, P, call, calls, put, puts, c, p. Only the call/put word itself, not words like buyer or seller.", | |
| "expiry": "The expiration date of an option contract: 10/16, 11/06/2026, 6/17/27, November 20, 2026, December, or relative like '2 days'. MUST NOT be the date a report was posted (e.g. the 10/2 in '10/2 Notable Flow').", | |
| "premium": "The total dollar size of the trade, e.g. $1.2M, $993K, 23 million. MUST NOT be a strike, the per-contract price, or the stock price.", | |
| "price": "The per-contract price or average fill, e.g. .15 in '@ .15' or 4.37 in '4.37avg'. Only the number. MUST NOT be a strike, premium, or the underlying's stock price." | |
| }, | |
| "threshold": 0.75, | |
| "word_splitter": "alnum-v2" | |
| } |