Discourse Chatbot 🤖 (Now smarter than ChatGPT!*)

Hmm - It doesnt seems to work he


Btw the answers should be 34,7% and 175,01 usd

But I see api call - as it started at 0 today.

1 Like

See if you can improve the prompts.

The current setup is preliminary and mainly for demo purposes.

If you want perfection it will need investing in.

1 Like

Will this work at your setup?

“Can you inform me about how much the S&P 500 has risen this year?”

Try it. If it doesn’t work then maybe prompt with a tracking ticker and some specific dates.

Please research your account with them:

I suspect a year ago on Friday is too old for the free account.

So not my code.

YTD is 9 month and 17 days.

Cool it work at you. My api request are increasing to now 17, so there should be some connection. Strange.

I will keep testing.

1 Like

I think it struggles with YTD because it only currently retrieves starting mid and eod prices for specific dates. I could add YTD probably. PR accepted.

I don’t think it has any way to tell what the first day of trading was.

In some ways tailoring it for market data is a complete project in itself and should probably be a piece of paid consulting work.

I looked into this in a little more depth.

The stock data is returned like so:


… and I drop most of these in response to the bot (take a look at the source code).

There is no “out of the box” YTD returned.

So to construct this we’d have to lead the bot through calculating it from discrete values for discrete dates.

I think that’s presently a bit of a stretch to do automatically, but if you want to get your coding hat on and have a go, PR accepted.

Otherwise, simply work out what the first trading day of the year was and be explicit in your prompt to help the bot give you an answer.

Note that I believe 1st of January was a weekend and (so) 2nd of January was a Bank Holiday.

So the first price I can get is the 3rd of January. So:

Hi @merefield, @Falco, I’m looking every day for more uses for the Discourse Chatbot and Discourse AI plugins .

Is it possible to implement something like a chat based on the existing Discourse chat? https://chat.openai.com/ :slightly_smiling_face:

Here’s an example of how this could be adapted in Discourse chat:

1 Like

At the moment the bot interaction happens via PMs, but where planning to also make it work via chat too.


Thank you for your quick response :raised_hands: and I look forward to future updates :ok_hand:

I’m a bit confused, Chatbot has always supported Chat?


1 Like

Oh sorry got confused, shouldn’t reply to mentions at 7am.


Actually my confusion was with @Aizada_M 's response to yours given I suspect that answer doesn’t satisfy his question :rofl:

1 Like

Sorry :pray: on my side of the world it’s 13:14 pm, I didn’t take your time of day into account :see_no_evil:

1 Like

It seems you didn’t understand me :smiley: I meant adding additional options, such as templates above the chat message editor and possibly an additional panel for displaying thematic chat histories (if you can call it that).

I’m using a translator, so please forgive me if I’m unclear in my messages :pray:

1 Like

Your mockup was pretty clear. Thanks for taking the time to prepare. I can’t promise that is on my roadmap at present but it’s an interesting idea.


@frold @cmdntd you might be interested in this.

I added a setting which will help you see what the bot is up to:


This is default OFF

It currently is counted as history and included in prompts sent to Openai … I’ll improve that in time. There’s no such thing as a whisper in PMs at present … I may override that.


Wow! That exactly does save my life.

1 Like

Sometimes, I want to share inner thought PM for only some agents, or restriction for some agents. How could I do it?