summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornorthern-64bit <75195383+northern-64bit@users.noreply.github.com>2021-09-30 01:13:59 +0200
committerGitHub <noreply@github.com>2021-09-29 16:13:59 -0700
commitf93deafa5ee9e046cf45324a8f91e081c7e8f717 (patch)
treeefe671a2a38b9da8032cd3388c97ee57317f41f1
parent95f77b1048f093941bee2bb106bb239ea32daeba (diff)
Adding the Discord Bot (#766)
* Adding the Discord Bot From https://github.com/GamestonkTerminal/DiscordBot. * Fixed code format to GST * Fixed spelling * Fixed check errors * Reformated with pre-commit * Fixed names of files
-rw-r--r--discordbot/README.md82
-rw-r--r--discordbot/config_discordbot.py31
-rw-r--r--discordbot/discordbot.py29
-rw-r--r--discordbot/economy/currencies.py38
-rw-r--r--discordbot/economy/economy_menu.py124
-rw-r--r--discordbot/economy/feargreed.py78
-rw-r--r--discordbot/economy/futures.py40
-rw-r--r--discordbot/economy/glbonds.py40
-rw-r--r--discordbot/economy/indices.py38
-rw-r--r--discordbot/economy/overview.py40
-rw-r--r--discordbot/economy/performance.py93
-rw-r--r--discordbot/economy/usbonds.py36
-rw-r--r--discordbot/economy/valuation.py93
-rw-r--r--discordbot/generic_commands.py55
-rw-r--r--discordbot/helpers.py102
-rw-r--r--discordbot/images/gst_logo_lockup_rGreen_with_letters.pngbin0 -> 86589 bytes
-rw-r--r--discordbot/images/image.pngbin0 -> 55261 bytes
-rw-r--r--discordbot/images/picture_1.pngbin0 -> 41121 bytes
-rw-r--r--discordbot/images/picture_2.pngbin0 -> 47963 bytes
-rw-r--r--discordbot/images/picture_3.pngbin0 -> 47955 bytes
-rw-r--r--discordbot/images/picture_4.pngbin0 -> 21721 bytes
-rw-r--r--discordbot/images/picture_5.pngbin0 -> 53001 bytes
-rw-r--r--discordbot/images/picture_6.pngbin0 -> 63939 bytes
-rw-r--r--discordbot/images/picture_7.pngbin0 -> 51832 bytes
-rw-r--r--discordbot/stocks/dark_pool_shorts/dpotc.py118
-rw-r--r--discordbot/stocks/dark_pool_shorts/dps_menu.py122
-rw-r--r--discordbot/stocks/dark_pool_shorts/ftd.py77
-rw-r--r--discordbot/stocks/dark_pool_shorts/hsi.py72
-rw-r--r--discordbot/stocks/dark_pool_shorts/pos.py110
-rw-r--r--discordbot/stocks/dark_pool_shorts/psi.py105
-rw-r--r--discordbot/stocks/dark_pool_shorts/shorted.py72
-rw-r--r--discordbot/stocks/dark_pool_shorts/sidtc.py97
-rw-r--r--discordbot/stocks/dark_pool_shorts/spos.py78
33 files changed, 1770 insertions, 0 deletions
diff --git a/discordbot/README.md b/discordbot/README.md
new file mode 100644
index 00000000000..f683e7c0a19
--- /dev/null
+++ b/discordbot/README.md
@@ -0,0 +1,82 @@
+# DiscordBot
+Implementation of a discord bot, which is WORK IN PROGRESS
+
+<!-- PROJECT LOGO -->
+<br />
+<p align="center">
+ <a href="https://github.com/GamestonkTerminal/DiscordBot">
+ <img src="images/gst_logo_lockup_rGreen_with_letters.png" alt="Logo" width="800" height="276">
+ </a>
+
+## Set Up
+
+### Step 1: Getting a discord bot
+Go to https://discord.com/developers/applications and click on "New Application" (See Picture 1)
+Enter a name for example "Gamestonk Terminal Discord Bot"
+Picture 1:
+<img src="images/picture_1.png" alt="Logo" width="1183" height="157">
+Then go to the bot page:
+<img src="images/picture_2.png" alt="Logo" width="1183" height="251">
+Then press "Add Bot":
+<img src="images/picture_3.png" alt="Logo" width="1183" height="324">
+Now go to your applications "OAuth2" Tab:
+
+<img src="images/picture_4.png" alt="Logo" width="455" height="423">
+Then copy your Client ID:
+<img src="images/picture_5.png" alt="Logo" width="1183" height="301">
+Then invite your bot to your discord server by replacing the ENTERCLIENTID with your copied client ID in this url: https://discord.com/oauth2/authorize?client_id=ENTERCLIENTID&scope=bot (You can also do it on via this link generator https://discordapi.com/permissions.html where you can select the proper permissions)
+After clicking the link you'll see something similar to this:
+<img src="images/picture_6.png" alt="Logo" width="472" height="624">
+Register your app <a href="https://imgur.com/signin?redirect=http://api.imgur.com/oauth2/addclient" class="dy ie" rel="noopener ugc nofollow">here</a>. Choose “OAuth 2 authorization without a callback URL”. Registering is free for all open source projects and if your discord bot uses fewer than 1,250 uploads per day. You will receive an client ID and client secret once you submit the form.
+
+### Step 2: Get the scripts to run the GST Discord Bot
+
+(Note this assumes that you already have installed GST for more info about the installation: https://github.com/GamestonkTerminal/GamestonkTerminal#getting-started)
+
+Download the code from this repository.
+
+Then open the main.py file and go back to https://discord.com/developers/applications/ and go to your bot page. There you'll have to copy the token
+<img src="images/picture_7.png" alt="Logo" width="1183" height="419">
+
+Then change the settings in the beginning of main.py:
+```
+##############
+## Settings ##
+##############
+DISCORD_BOT_TOKEN = 'string' # Insert your bots secrets token
+IMGUR_CLIENT_ID = 'string' # Enter your imgur client id
+COMMAND_PREFIX = '!' # Sets the prefix to the commands
+activity = discord.Game(name='Gametonk Terminal: https://github.com/GamestonkTerminal/GamestonkTerminal')
+gst_path = 'C:\\Users\\user\\GamestonkTerminal' # The path to Gamestonk Terminal
+date_input_format = '%Y-%m-%d' # Enter your prefered date input format
+```
+
+### Step 3:
+Activate your GST virtual enviroment and go to the place where your main.py file is located and run it.
+<img src="images/image.png" alt="Logo" width="1167" height="294">
+Your finished! Go to your server and you should see the bot online!!!
+
+## Code Structure and Contributing
+The file system is built in the following way:
+- Each context is one file unless it has categories and if it has it then it should have a file in the directory named context_main.py (example: Stocks has as a category Dark Pool Shorts -> stocks is a directory with a file stocks_main.py and dps is a file; economy has no categories -> economy is one file)
+- The settings shall currently be in the main.py file (example: API keys)
+
+A context/category file is built in the following way:
+```
+Imports
+
+Functions
+ Returns the embed or sends the response via pagination function from main
+
+Class with the commands as cogs
+ The Commands call the functions with given arguments
+ Has one command with a list of the commands and can run them via emoji reactions from the user
+
+Add the cogs class to the bot
+```
+If a funtion is often used by a context with categories or multiple files then add them to the context_main.py or the main.py file.
+
+## Disclaimer
+"A few things I am not. I am not a cat. I am not an institutional investor, nor am I a hedge fund. I do not have clients and I do not provide personalized investment advice for fees or commissions." DFV
+
+Trading in financial instruments involves high risks including the risk of losing some, or all, of your investment amount, and may not be suitable for all investors. Before deciding to trade in financial instrument you should be fully informed of the risks and costs associated with trading the financial markets, carefully consider your investment objectives, level of experience, and risk appetite, and seek professional advice where needed. The data contained in GST is not necessarily accurate. GST Discord Bot/GST and any provider of the data contained in this website will not accept liability for any loss or damage as a result of your trading, or your reliance on the information displayed.
diff --git a/discordbot/config_discordbot.py b/discordbot/config_discordbot.py
new file mode 100644
index 00000000000..2677e07757e
--- /dev/null
+++ b/discordbot/config_discordbot.py
@@ -0,0 +1,31 @@
+import os
+import sys
+import discord
+
+from dotenv import load_dotenv
+
+env_files = [f for f in os.listdir() if f.endswith(".env")]
+if env_files:
+ load_dotenv(env_files[0])
+
+# Path to the terminal
+GST_PATH = os.path.join("~", "Documents", "GamestonkTerminal")
+sys.path.append(GST_PATH)
+
+# https://discord.com/developers/applications/
+DISCORD_BOT_TOKEN = os.getenv("GT_DISCORD_BOT_TOKEN") or "REPLACE_ME"
+
+# https://apidocs.imgur.com
+IMGUR_CLIENT_ID = os.getenv("GT_IMGUR_CLIENT_ID") or "REPLACE_ME"
+
+# Settings
+COMMAND_PREFIX = "!"
+DATE_FORMAT = "%Y-%m-%d"
+COLOR = discord.Color.from_rgb(0, 206, 154)
+MENU_TIMEOUT = 30
+
+AUTHOR_NAME = "Gamestonk Terminal"
+AUTHOR_ICON_URL = (
+ "https://github.com/GamestonkTerminal/GamestonkTerminal/"
+ "blob/main/images/gst_logo_green_white_background.png?raw=true"
+)
diff --git a/discordbot/discordbot.py b/discordbot/discordbot.py
new file mode 100644
index 00000000000..6d4dbe36e5d
--- /dev/null
+++ b/discordbot/discordbot.py
@@ -0,0 +1,29 @@
+import discord
+import discord_components
+import pyimgur
+import config_discordbot as cfg
+
+
+activity = discord.Game(
+ name="Gametonk Terminal: https://github.com/GamestonkTerminal/GamestonkTerminal"
+)
+
+gst_bot = discord.ext.commands.Bot(
+ command_prefix=cfg.COMMAND_PREFIX, intents=discord.Intents.all(), activity=activity
+)
+discord_components.DiscordComponents(gst_bot)
+
+
+async def on_ready():
+ print("GST Discord Bot Ready to Gamestonk!")
+
+
+gst_imgur = pyimgur.Imgur(cfg.IMGUR_CLIENT_ID)
+
+# Loads the commands (Cogs) from each "context"
+gst_bot.load_extension("generic_commands")
+gst_bot.load_extension("economy.economy_menu")
+gst_bot.load_extension("stocks.dark_pool_shorts.dps_menu")
+
+# Runs the bot
+gst_bot.run(cfg.DISCORD_BOT_TOKEN)
diff --git a/discordbot/economy/currencies.py b/discordbot/economy/currencies.py
new file mode 100644
index 00000000000..97e835471a9
--- /dev/null
+++ b/discordbot/economy/currencies.py
@@ -0,0 +1,38 @@
+import discord
+import config_discordbot as cfg
+
+from gamestonk_terminal.economy import wsj_model
+
+
+async def currencies_command(ctx, arg):
+ # Help
+ if arg == "-h" or arg == "help":
+ help_txt = "Currencies [Source: Wall St. Journal]\n"
+ embed = discord.Embed(
+ title="Economy: [WSJ] Currencies HELP",
+ description=help_txt,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
+
+ else:
+ df_data = wsj_model.global_currencies()
+ if df_data.empty:
+ df_data_str = "No currencies data available"
+ else:
+ df_data_str = "```" + df_data.to_string(index=False) + "```"
+
+ embed = discord.Embed(
+ title="Economy: [WSJ] Currencies", description=df_data_str, colour=cfg.COLOR
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
diff --git a/discordbot/economy/economy_menu.py b/discordbot/economy/economy_menu.py
new file mode 100644
index 00000000000..fc69f9f36ea
--- /dev/null
+++ b/discordbot/economy/economy_menu.py
@@ -0,0 +1,124 @@
+import discord
+import asyncio
+import config_discordbot as cfg
+from discordbot import gst_bot
+
+from economy.feargreed import feargreed_command
+from economy.overview import overview_command
+from economy.indices import indices_command
+from economy.futures import futures_command
+from economy.usbonds import usbonds_command
+from economy.glbonds import glbonds_command
+from economy.currencies import currencies_command
+from economy.valuation import valuation_command
+from economy.performance import performance_command
+
+
+class EconomyCommands(discord.ext.commands.Cog):
+ """Economy Commands menu"""
+
+ def __init__(self, bot: discord.ext.commands.Bot):
+ self.bot = bot
+
+ @discord.ext.commands.command(name="economy.feargreed")
+ async def feargreed(self, ctx: discord.ext.commands.Context, arg=""):
+ await feargreed_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.overview")
+ async def overview(self, ctx: discord.ext.commands.Context, arg=""):
+ await overview_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.indices")
+ async def indices(self, ctx: discord.ext.commands.Context, arg=""):
+ await indices_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.futures")
+ async def futures(self, ctx: discord.ext.commands.Context, arg=""):
+ await futures_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.usbonds")
+ async def usbonds(self, ctx: discord.ext.commands.Context, arg=""):
+ await usbonds_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.glbonds")
+ async def glbonds(self, ctx: discord.ext.commands.Context, arg=""):
+ await glbonds_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.currencies")
+ async def currencies(self, ctx: discord.ext.commands.Context, arg=""):
+ await currencies_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.valuation")
+ async def valuation(self, ctx: discord.ext.commands.Context, arg=""):
+ await valuation_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy.performance")
+ async def performance(self, ctx: discord.ext.commands.Context, arg=""):
+ await performance_command(ctx, arg)
+
+ @discord.ext.commands.command(name="economy")
+ async def economy(self, ctx: discord.ext.commands.Context):
+ text = (
+ "0️⃣ !economy.overview\n"
+ "1️⃣ !economy.futures\n"
+ "2️⃣ !economy.usbonds\n"
+ "3️⃣ !economy.glbonds\n"
+ "4️⃣ !economy.indices\n"
+ "5️⃣ !economy.currencies\n"
+ "6️⃣ !economy.feargreed\n"
+ "7️⃣ !economy.valuation <GROUP>\n"
+ "8️⃣ !economy.performance <GROUP>"
+ )
+
+ title = "Economy Menu"
+ embed = discord.Embed(title=title, description=text, colour=cfg.COLOR)
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+ msg = await ctx.send(embed=embed)
+
+ emoji_list = ["0️⃣", "1️⃣", "2️⃣", "3️⃣", "4️⃣", "5️⃣", "6️⃣", "7️⃣", "8️⃣"]
+
+ for emoji in emoji_list:
+ await msg.add_reaction(emoji)
+
+ def check(reaction, user):
+ return user == ctx.message.author and str(reaction.emoji) in emoji_list
+
+ try:
+ reaction, user = await gst_bot.wait_for(
+ "reaction_add", timeout=cfg.MENU_TIMEOUT, check=check
+ )
+ if reaction.emoji == "0️⃣":
+ await overview_command(ctx)
+ elif reaction.emoji == "1️⃣":
+ await futures_command(ctx)
+ elif reaction.emoji == "2️⃣":
+ await usbonds_command(ctx)
+ elif reaction.emoji == "3️⃣":
+ await glbonds_command(ctx)
+ elif reaction.emoji == "4️⃣":
+ await indices_command(ctx)
+ elif reaction.emoji == "5️⃣":
+ await currencies_command(ctx)
+ elif reaction.emoji == "6️⃣":
+ await feargreed_command(ctx)
+ elif reaction.emoji == "7️⃣":
+ await valuation_command(ctx, "")
+ elif reaction.emoji == "8️⃣":
+ await performance_command(ctx, "")
+
+ # TODO: Make this work - may need to set different discord server configurations
+ # await msg.remove_reaction(reaction.emoji, user)
+ # for emoji in emoji_list:
+ # await msg.remove_reaction(emoji, user)
+
+ except asyncio.TimeoutError:
+ text = text + "\n\nCOMMAND TIMEOUT."
+ embed = discord.Embed(title=title, description=text)
+ await msg.edit(embed=embed)
+
+
+def setup(bot: discord.ext.commands.Bot):
+ gst_bot.add_cog(EconomyCommands(bot))
diff --git a/discordbot/economy/feargreed.py b/discordbot/economy/feargreed.py
new file mode 100644
index 00000000000..fbab7545520
--- /dev/null
+++ b/discordbot/economy/feargreed.py
@@ -0,0 +1,78 @@
+import discord
+import matplotlib.pyplot as plt
+import os
+import datetime
+import config_discordbot as cfg
+from discordbot import gst_imgur
+
+from gamestonk_terminal.economy import cnn_view, cnn_model
+
+
+async def feargreed_command(ctx, arg):
+ # Help
+ if arg == "-h" or arg == "help":
+ help_txt = """CNN Fear And Greed indicator or index. From Junk Bond Demand, Market Volatility,
+ Put and Call Options, Market Momentum Stock Price Strength, Stock Price Breadth,
+ Safe Heaven Demand, and Index. [Source: CNN Business]\n"""
+
+ embed = discord.Embed(
+ title="Economy: [CNN] Fear Geed Index HELP",
+ description=help_txt,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
+
+ else:
+ plt.ion()
+ fig = plt.figure(figsize=[1, 1], dpi=10)
+
+ report, _ = cnn_model.get_feargreed_report("", fig)
+ cnn_view.fear_and_greed_index(indicator="", export="png")
+
+ plt.close("all")
+
+ now = datetime.datetime.now()
+ image_path = os.path.join(
+ cfg.GST_PATH,
+ "exports",
+ "economy",
+ f"feargreed_{now.strftime('%Y%m%d_%H%M%S')}.png",
+ )
+
+ i = 0
+ while not os.path.exists(image_path) and i < 10:
+ now -= datetime.timedelta(seconds=1)
+ image_path = os.path.join(
+ cfg.GST_PATH,
+ "exports",
+ "economy",
+ f"feargreed_{now.strftime('%Y%m%d_%H%M%S')}.png",
+ )
+ i += 1
+
+ embed = discord.Embed(
+ title="Economy: [CNN] Fear Geed Index", description=report, colour=cfg.COLOR
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ if os.path.exists(image_path):
+ uploaded_image = gst_imgur.upload_image(
+ image_path, title="FearGreed Charts"
+ )
+ embed.set_image(url=uploaded_image.link)
+
+ else:
+ # report = "Error: The image could not be found"
+ print("Error with uploading the the image to Imgur.")
+
+ plt.close("all")
+
+ await ctx.send(embed=embed)
diff --git a/discordbot/economy/futures.py b/discordbot/economy/futures.py
new file mode 100644
index 00000000000..d4cde1f2238
--- /dev/null
+++ b/discordbot/economy/futures.py
@@ -0,0 +1,40 @@
+import discord
+import config_discordbot as cfg
+
+from gamestonk_terminal.economy import wsj_model
+
+
+async def futures_command(ctx, arg):
+ # Help
+ if arg == "-h" or arg == "help":
+ help_txt = "Futures/Commodities [Source: Wall St. Journal]\n"
+ embed = discord.Embed(
+ title="Economy: [WSJ] Futures/Commodities HELP",
+ description=help_txt,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
+
+ else:
+ df_data = wsj_model.top_commodities()
+ if df_data.empty:
+ df_data_str = "No futures/commodities data available"
+ else:
+ df_data_str = "```" + df_data.to_string(index=False) + "```"
+
+ embed = discord.Embed(
+ title="Economy: [WSJ] Futures/Commodities",
+ description=df_data_str,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
diff --git a/discordbot/economy/glbonds.py b/discordbot/economy/glbonds.py
new file mode 100644
index 00000000000..f2cace3b8dd
--- /dev/null
+++ b/discordbot/economy/glbonds.py
@@ -0,0 +1,40 @@
+import discord
+import config_discordbot as cfg
+
+from gamestonk_terminal.economy import wsj_model
+
+
+async def glbonds_command(ctx, arg):
+ # Help
+ if arg == "-h" or arg == "help":
+ help_txt = "Global Bonds [Source: Wall St. Journal]\n"
+ embed = discord.Embed(
+ title="Economy: [WSJ] Global Bonds HELP",
+ description=help_txt,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
+
+ else:
+ df_data = wsj_model.global_bonds()
+ if df_data.empty:
+ df_data_str = "No global bonds data available"
+ else:
+ df_data_str = "```" + df_data.to_string(index=False) + "```"
+
+ embed = discord.Embed(
+ title="Economy: [WSJ] Global Bonds",
+ description=df_data_str,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
diff --git a/discordbot/economy/indices.py b/discordbot/economy/indices.py
new file mode 100644
index 00000000000..0018882065e
--- /dev/null
+++ b/discordbot/economy/indices.py
@@ -0,0 +1,38 @@
+import discord
+import config_discordbot as cfg
+
+from gamestonk_terminal.economy import wsj_model
+
+
+async def indices_command(ctx, arg):
+ # Help
+ if arg == "-h" or arg == "help":
+ help_txt = "US Indices [Source: Wall St. Journal]\n"
+ embed = discord.Embed(
+ title="Economy: [WSJ] US Indices HELP",
+ description=help_txt,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
+
+ else:
+ df_data = wsj_model.us_indices()
+ if df_data.empty:
+ df_data_str = "No indices data available"
+ else:
+ df_data_str = "```" + df_data.to_string(index=False) + "```"
+
+ embed = discord.Embed(
+ title="Economy: [WSJ] US Indices", description=df_data_str, colour=cfg.COLOR
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
diff --git a/discordbot/economy/overview.py b/discordbot/economy/overview.py
new file mode 100644
index 00000000000..632bf21cf2d
--- /dev/null
+++ b/discordbot/economy/overview.py
@@ -0,0 +1,40 @@
+import discord
+import config_discordbot as cfg
+
+from gamestonk_terminal.economy import wsj_model
+
+
+async def overview_command(ctx, arg):
+ # Help
+ if arg == "-h" or arg == "help":
+ help_txt = "Market Overview [Source: Wall St. Journal]\n"
+ embed = discord.Embed(
+ title="Economy: [WSJ] Market Overview HELP",
+ description=help_txt,
+ colour=cfg.COLOR,
+ )
+ embed.set_author(
+ name=cfg.AUTHOR_NAME,
+ icon_url=cfg.AUTHOR_ICON_URL,
+ )
+
+ await ctx.send(embed=embed)
+
+ else:
+ df_data = wsj_model.market_overview()
+ if df_data.empty:
+ df_data_str = "No overview data available"
+ else:
+