No project description provided
Project description
Tickermood
Tickermood is a Python package that provides market sentiment analysis for stock tickers based on news from multiple sources. It combines web scraping techniques with large language models (LLMs) using the LangChain and LangGraph frameworks to generate sentiment scores for given tickers.
📦 Installation
Install Tickermood via pip:
pip install tickermood
Note: To use Tickermood locally, Ollama must be installed. Alternatively, you can use the OpenAI API by providing your API key.
🚀 Usage
Programmatic Usage
from tickermood import TickerMood
ticker_mood = TickerMood.from_symbols(["AAPL", "GOOGL", "MSFT"])
ticker_mood.run()
CLI Usage
tickermood run AAPL GOOGL MSFT
This will:
- Fetch the latest news for the specified tickers
- Run LLM agents to analyze the news
- Provide a sentiment score for each ticker
Results are stored in a SQLite database.
🗃️ Database
Tickermood creates a SQLite database in the current directory named tickermood.db if it doesn't already exist. It includes:
- Sentiment ratings (e.g., Buy, Hold, Sell)
- Price targets
- Summaries of the fetched news articles
⚙️ LLM Backend Options
Default: Local LLM (Ollama)
- Runs LLMs locally for free
- Performance depends on your hardware
Optional: OpenAI API
- Requires setting the
OPENAI_API_KEYenvironment variable
Or, pass the key via CLI:
tickermood run AAPL GOOGL MSFT --openai_api_key_path /path/to/openai_api_key.txt
📝 License
MIT License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tickermood-0.11.0.tar.gz.
File metadata
- Download URL: tickermood-0.11.0.tar.gz
- Upload date:
- Size: 14.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
98e3a9c75a0a668e114a8f536dc767e1bbb284c49d12e4d6318d11101cc3b195
|
|
| MD5 |
c0aa0d4a1df2ea8700bfbe0152ea0543
|
|
| BLAKE2b-256 |
ab55f70407520dba5ed7a3fff766e75c5efa950cda917ce95122a7b1f04226e7
|
File details
Details for the file tickermood-0.11.0-py3-none-any.whl.
File metadata
- Download URL: tickermood-0.11.0-py3-none-any.whl
- Upload date:
- Size: 19.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4cfb8ed3e590b7eb201f1323f1a4e08de78886d0f65141418ed919299bad2cf3
|
|
| MD5 |
c6a59654634bad0508bcba3417b1455b
|
|
| BLAKE2b-256 |
4122ecbe7e718e6d4e0d00f2b2db744e7bcf397dd2dd0896f898467688ec29a0
|