- Python - to run things
- pyenv/poetry - to ease/automate the cumbersome things in the previous point
- discord account - to chat with things and optionally ppl
- discord developer account - to depelop parrot-like things and, in the future, people you like more
- open ai account - to empty your pocket
- will - to... whatever you want
Clone this repo
git clone [email protected]:francisco-perez-sorrosal/satnbot.gitInstall project dependencies
cd satnbot
poetry installdocker build -t "satnbot" .
docker run -it --rm -e DISCORD_TOKEN="MTA-xxx" -e OPENAI_API_KEY="sk-xxx" satnbotI'm assuming you have your fancy Discord account! 😃
- 
Create your server where to chat with your bot 
- 
Create your application/bot in the Discord Dev Portal 
- 
Assign the right permissions to let your bot do things! 🥶 3.1. In OAuth2's URL generator, select the scopes (e.g. botandapplication.command) 3.2 Then select the bot permissions (e.g.administrator)
- 
Copy the generated url and invite your bot to your server! 
- 
In your server, add the permissions to the slash commands (see below) that the bot registers (Server Settings/Integrations) 🧐 (e.g. /syf) 
- 
Use it! 
See TODOs below
Edit the tdb.sh and put your tokens/keys there:
DISCORD_TOKEN="<YOUR_DISCORD_APP_TOKEN_HERE>"
OPENAI_API_KEY="<YOUR_OPENAI_KEY_HERE>"
./tdb.shBear in mind when using the bot capabilities below that:
- Input/Output to/from OpenAI's ChatGPT is limited to a certain number of tokens (depending on the model)
- Discord's bot Output is limited to 2000 chars.
Both limitations can be workaround but this is not done at this point. Will be addressed later
- Introduce a prompt on your the discord channel of your server and add the name of your bot to it to trigger a request to ChatGPT. Example:
@fpsbot what should I do today apart from my daily learning duties reading about quantum physics, biomechatronics, synthetic biology and the wsj?
Yeah... I guess my life sucks...
There's also a slash command (/history) to check the history or requests...

...so you can ask again (with /h <idx_no>) to get another thrilling response..

You can use this thig also with the slash command /syf (syf: Stats Yahoo Finance) slash command to get a stats report of the tickers of the day from Yahoo Finance
By default you get a human readable output...
...but if you send the command with the parameter format as tsv /syf tsv it will return a tsv-formatted file for you to digest wisefully with a High Speed ML trading algorithm to become rich some day (Mental note: TODO ASAP).
In summary, basically this does to do what this engineer/scientist (representing many of us) had to do very painfully here
Important Note When passing the text extracted from the pdf document to the bot with the /ax command input has to be limited when sending it to ChatGPT. This can be done with the parameters chunks and chars_per_chunk available in the slash command.
You can use the bot also with the slash command /axs (arxiv sanity) to access the latest articles in the topic you specify:
/axs filter_tags cs.AI
Or you can retrieve stuff on two+ different topics:
/axs filter_tags cs.AI&cs.CV
Then you can copy the Arxiv ID and then use the /ax (arxiv) slash command to retrieve a summary of the article:
/ax arxiv_id: 2202.02098
You can specify also the language (english is default) in which you want the summary and the style (paragraph(default)|bulletpoints|sonnet) and number of style_items
/ax arxiv_id: 2202.02098 language: english style: bulletpoints style_items: 10
/ax arxiv_id:2202.02098 language:spanish style:paragraph style_items:2
For things here to do before I grow old or before I die see this.





