Metadata-Version: 2.4
Name: atradebot
Version: 1.0.0
Summary: atradebot package
Author-email: AndreChang <andrechang67@gmail.com>
Keywords: algotrade,fintech,stocks
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
Requires-Dist: beautifulsoup4
Requires-Dist: bitsandbytes
Requires-Dist: datasets
Requires-Dist: huggingface_hub
Requires-Dist: matplotlib
Requires-Dist: nltk
Requires-Dist: numpy
Requires-Dist: pandas
Requires-Dist: peft
Requires-Dist: pytest
Requires-Dist: python_dateutil
Requires-Dist: PyYAML
Requires-Dist: scikit_learn
Requires-Dist: sentencepiece
Requires-Dist: setuptools
Requires-Dist: torch
Requires-Dist: transformers
Requires-Dist: yfinance
Requires-Dist: lxml_html_clean
Requires-Dist: trafilatura
Requires-Dist: finnhub-python
Requires-Dist: openai
Requires-Dist: sentence-transformers
Requires-Dist: PyPortfolioOpt
Requires-Dist: diskcache
Requires-Dist: statsmodels
Requires-Dist: pmdarima
Requires-Dist: gitpython
Requires-Dist: alpaca-py

## Atradebot

![image](img/Atradebot.jpg)

Yet another Bot to help you choose what to invest using AI 

[Documentation](https://atradebot.readthedocs.io/en/latest/index.html#)

### API keys:

Get your api keys from:

[Finhub](https://finnhub.io/) 
[OpenAI](https://openai.com/index/openai-api/)
[Alpaca](https://alpaca.markets/)
[tavily](https://tavily.com/)

```
export FINNHUB_API_KEY=<api key>
export OPENAI_API_KEY=<api key>
export ALPACA_API=<api key>
export ALPACA_SECRET=<api key>
export TAVILY_API_KEY=<api key>
```

And set it to your environment variables


### Install

Requirement:

```
pip install -r requirements.txt
```

Install using pip

```
pip install -e .
```

if errors do:
```
pip install --upgrade pip
```

Install gpt-researcher: `https://github.com/assafelovic/gpt-researcher.git`

## Regression test

`pytest -m "test" tests/test_main.py`

## How to run

1. to generate full report and visualize results

download current portifolio .csv file from broker and put in sd/


```
python main.py -s GPTStrategy -n finhub -i 20 -f 30
```

this will generate files in sd/output/
then visualize with:

```
python dashboard.py
```

2. auto trade:
run gen_allocation to place buy/sell in alpaca API

```
python autotrade.py
```

# License

Atradebot is open-source software released under the [Apache 2.0 license](https://github.com/Superalgos/Superalgos/blob/master/LICENSE)
