# Discourse AI Topic Summary 🤖

**URL:** https://meta.discourse.org/t/discourse-ai-topic-summary/256711
**Category:** Plugin
**Tags:** ai
**Created:** [March 1, 2023, 7:23pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711 "2023-03-01T19:23:17Z")
**Posts on this page:** 20
**Page:** 5

<div class="post-metadata">

### Author: ![ncaming215](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ncaming215/32/205701_2.png) [@ncaming215](https://meta.discourse.org/u/ncaming215)
#### Post date: [May 5, 2024, 2:28pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/83 "2024-05-05T14:28:34Z")

</div>

The prompt is a button, “Summarize with AI”, unless I’m missing the obvious here? Also, this is a fantastic plug-in, can’t wait to explore.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 5, 2024, 2:29pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/84 "2024-05-05T14:29:24Z")

</div>

The prompts are all shown in the post precisely one back from your first 😅

---

<div class="post-metadata">

### Author: ![ncaming215](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ncaming215/32/205701_2.png) [@ncaming215](https://meta.discourse.org/u/ncaming215)
#### Post date: [May 5, 2024, 2:30pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/85 "2024-05-05T14:30:34Z")

</div>

Rookie error. 🫣 This is what I get for moving too fast … I’ll give it a whirl and report back.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 5, 2024, 2:31pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/86 "2024-05-05T14:31:02Z")

</div>

Make sure you are using my plugin. It was the first to summarise with AI but is not the official plugin.

---

<div class="post-metadata">

### Author: ![RGJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rgj/32/523185_2.png) [@RGJ](https://meta.discourse.org/u/RGJ)
#### Post date: [May 11, 2024, 7:17am UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/87 "2024-05-11T07:17:38Z")

</div>

Bug: Selecting `gpt-4-turbo` results in a 500 error when a post is being made.  
That might be because of a wrong setup or permissions but a 500 error on every post creation might be a bit harsh.

```plaintext
Faraday::BadRequestError (the server responded with status 400)
faraday (2.9.0) lib/faraday/response/raise_error.rb:16:in `on_complete'
faraday (2.9.0) lib/faraday/middleware.rb:18:in `block in call'
faraday (2.9.0) lib/faraday/response.rb:42:in `on_complete'
faraday (2.9.0) lib/faraday/middleware.rb:17:in `call'
faraday (2.9.0) lib/faraday/rack_builder.rb:152:in `build_response'
faraday (2.9.0) lib/faraday/connection.rb:444:in `run_request'
faraday (2.9.0) lib/faraday/connection.rb:280:in `post'
ruby-openai (7.0.0) lib/openai/http.rb:22:in `json_post'
ruby-openai (7.0.0) lib/openai/client.rb:30:in `chat'
plugins/discourse-ai-topic-summary/lib/ai_topic_summary/call_bot.rb:15:in `get_response'
plugins/discourse-ai-topic-summary/lib/ai_topic_summary/summarise.rb:6:in `retrieve_summary'
plugins/discourse-ai-topic-summary/plugin.rb:62:in `block (2 levels) in activate!'
lib/discourse_event.rb:12:in `block in trigger'

```

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 11, 2024, 7:21am UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/88 "2024-05-11T07:21:34Z")

</div>

Yep, true.

It should also probably spawn a job rather than do the work inline, just like Chatbot.

Probably should log the detail response if at all possible too.

Does it work with `gpt-3.5-turbo`?

If so, very likely this is a permissions issue where the admin does not have access to GPT 4 turbo for some reason, but agree it should not result in a failure to post, perhaps just do no summary update and log an error.

---

<div class="post-metadata">

### Author: ![RGJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rgj/32/523185_2.png) [@RGJ](https://meta.discourse.org/u/RGJ)
#### Post date: [May 11, 2024, 9:44am UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/89 "2024-05-11T09:44:53Z")

</div>

> [@merefield](#):
>
> Does it work with `gpt-3.5-turbo`?

Yes, it’s a permissions issue for sure.

---

<div class="post-metadata">

### Author: ![ncaming215](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ncaming215/32/205701_2.png) [@ncaming215](https://meta.discourse.org/u/ncaming215)
#### Post date: [May 13, 2024, 8:00pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/90 "2024-05-13T20:00:16Z")

</div>

![Screenshot 2024-05-13 at 3.57.12 PM](https://global.discourse-cdn.com/meta/original/4X/5/0/d/50d225d392f7e0f8d60a487836b1d6d1420a5c7e.png)

Is tagging based on the summary that’s generated? For example, I’d prefer no summary but have tagging function. And if that’s the case, maybe hide it?

Lastly (see screenshot), this thing is ripe for abuse. At the moment it appears even non-logged in users can downvote.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 13, 2024, 8:18pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/91 "2024-05-13T20:18:40Z")

</div>

> [@ncaming215](#):
>
> Is tagging based on the summary that’s generated?

Correct.

> [@ncaming215](#):
>
> And if that’s the case, maybe hide it?

Sure you could do that with CSS, or might get away with this settting:

`ai topic summary rely on sidebar widget instead` and just not use the widget.

> [@ncaming215](#):
>
> Lastly (see screenshot), this thing is ripe for abuse. At the moment it appears even non-logged in users can downvote.

No it isn’t?

Anonymous users are not presented with this interface, nor are they allowed to vote.

> <https://github.com/merefield/discourse-ai-topic-summary/blob/941107637522a9edd3b85a25f8d34261824b81e4/assets/javascripts/discourse/components/ai-topic-summary.js#L39>

> <https://github.com/merefield/discourse-ai-topic-summary/blob/941107637522a9edd3b85a25f8d34261824b81e4/app/controllers/ai_topic_summary/vote.rb#L5>

but thanks for the reputation bomb 😅

This plugin is over a year old - I think the community would have caught that one 😉

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 13, 2024, 8:22pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/92 "2024-05-13T20:22:45Z")

</div>

As with Chatbot, you can now use the latest Open AI model with this plugin:

`gpt-4o`

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 17, 2024, 11:37am UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/93 "2024-05-17T11:37:19Z")

</div>

A couple of BIG improvements here:

[https://github.com/merefield/discourse-ai-topic-summary/pull/14](https://github.com/merefield/discourse-ai-topic-summary/pull/14)

[https://github.com/merefield/discourse-ai-topic-summary/pull/15?query=1](https://github.com/merefield/discourse-ai-topic-summary/pull/15?query=1)

This should make things _much_ more robust, prevent blocking of posting when there’s an AI issue, and give you _much_ more information when things go wrong.

@RGJ @Jagster

---

<div class="post-metadata">

### Author: ![ncaming215](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ncaming215/32/205701_2.png) [@ncaming215](https://meta.discourse.org/u/ncaming215)
#### Post date: [May 19, 2024, 1:54pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/94 "2024-05-19T13:54:20Z")

</div>

> [@merefield](#):
>
> but thanks for the reputation bomb 😅

Oh man, I didn’t mean to imply that at all. I’m assuming I opened in Incognito, and must’ve had another Incognito window already open w/ a logged in user.

This plug-in is incredible, and I wish it could be adopted into core. You do fantastic work, Robert. Again, my apologies. Totally unintentional dig!

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 19, 2024, 2:27pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/95 "2024-05-19T14:27:16Z")

</div>

No issues! That’s for the kind words.

---

<div class="post-metadata">

### Author: ![ncaming215](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ncaming215/32/205701_2.png) [@ncaming215](https://meta.discourse.org/u/ncaming215)
#### Post date: [May 19, 2024, 10:07pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/96 "2024-05-19T22:07:22Z")

</div>

Now that I’ve redeemed myself 😅… what’s the difference between “system\_tagging” and “prompt.tag”?

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 19, 2024, 10:13pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/97 "2024-05-19T22:13:58Z")

</div>

> [@ncaming215](#):
>
> “system\_tagging”

Is the system prompt (you can edit this if you wish)

> [@ncaming215](#):
>
> “prompt.tag”?

Is the “user” query sent to the Chat Completion that actually does the work.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 22, 2024, 1:04pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/98 "2024-05-22T13:04:50Z")

</div>

btw, I’ve noticed better performance of `gpt-4-turbo` for the tagging task on one of my sites than `gpt-4o`. I cannot explain why and have not had time to investigate. It may relate to the sheer number of tags, but you’d expect the newer model to cope with more. YMMV.

---

<div class="post-metadata">

### Author: ![ncaming215](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ncaming215/32/205701_2.png) [@ncaming215](https://meta.discourse.org/u/ncaming215)
#### Post date: [May 22, 2024, 1:06pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/99 "2024-05-22T13:06:47Z")

</div>

> [@merefield](#):
>
> btw, I’ve noticed better performance of `gpt-4-turbo` for the tagging task on one of my sites than `gpt-4o`. I cannot explain why and have not had time to investigate. YMMV.

I’ll give it a shot. I tried to upgrade to 4-turbo and users were met with 500 error (I’m hosted by @RGJ’s Communiteq) so quickly reverted back to 3.5 and it resolved. This was last week, so perhaps something has changed.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 22, 2024, 1:07pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/100 "2024-05-22T13:07:48Z")

</div>

Sounds like the plugin is out of date:

> [@Discourse AI Topic Summary robot](https://meta.discourse.org/t/discourse-ai-topic-summary-automated-summaries-and-smart-tagging/256711/93):
>
> A couple of BIG improvements here: [https://github.com/merefield/discourse-ai-topic-summary/pull/14](https://github.com/merefield/discourse-ai-topic-summary/pull/14)[https://github.com/merefield/discourse-ai-topic-summary/pull/15?query=1](https://github.com/merefield/discourse-ai-topic-summary/pull/15?query=1) This should make things much more robust, prevent blocking of posting when there’s an AI issue, and give you much more information when things go wrong. @RGJ @Jagster

---

<div class="post-metadata">

### Author: ![RGJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rgj/32/523185_2.png) [@RGJ](https://meta.discourse.org/u/RGJ)
#### Post date: [May 22, 2024, 1:10pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/101 "2024-05-22T13:10:11Z")

</div>

> [@merefield](#):
>
> Sounds like the plugin is out of date:

No - Nate ran into that issue before you updated the plugin - his issue was actually the reason for my bug report.

If you believe you have addressed these issues then we’ll be updating the plugin on all our applicable instances tomorrow morning.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [May 22, 2024, 1:17pm UTC](https://meta.discourse.org/t/discourse-ai-topic-summary/256711/102 "2024-05-22T13:17:55Z")

</div>

You not “liking” the fix ( 😢 ) suggested no update had take place. 😉

[Previous page](https://meta.discourse.org/t/discourse-ai-topic-summary/256711.md?page=4)

[Next page](https://meta.discourse.org/t/discourse-ai-topic-summary/256711.md?page=6)
