Comment out !markov status command, since it's quite expensive

There's probably a better way to make this less expensive, but I'm not
sure what it is. Until then, we'll leave this feature out.

Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
2020-08-11 12:50:33 -07:00
parent 715480230a
commit 6110420015

View File

@@ -44,12 +44,12 @@ defmodule Omnibot.Contrib.Markov do
do_markov_message(irc, channel, nick, :all) do_markov_message(irc, channel, nick, :all)
end end
command "!markov", ["status"] do #command "!markov", ["status"] do
total = chain_server(channel, :all) |> ChainServer.chain_sum() #total = chain_server(channel, :all) |> ChainServer.chain_sum()
value = chain_server(channel, nick) |> ChainServer.chain_sum() #value = chain_server(channel, nick) |> ChainServer.chain_sum()
ratio = (value * 100) / total #ratio = (value * 100) / total
Irc.send_to(irc, channel, "#{nick}: You are worth #{ratio |> Float.round(4)}% of the channel") #Irc.send_to(irc, channel, "#{nick}: You are worth #{ratio |> Float.round(4)}% of the channel")
end #end
command "!markov", ["chance"] do command "!markov", ["chance"] do
chance = reply_chance(channel, nick) chance = reply_chance(channel, nick)