Commit Graph
1332 Commits
Author SHA1 Message Date
Keegan George 9485f3110a UX: AI Helper positioning (#506) 2024-03-05 08:58:00 +11:00
Keegan George cee1b3d275 FIX: Backspace in composer custom prompt closes menu (#505) 2024-03-04 13:33:31 -08:00
SamandJoffrey JAFFEUX 77cf9e2cff FIX: system persona non English save, missing bot pms
- FIX: only update system attributes when updating system persona
- FIX: update participant count by hand so bot messages show in inbox
 

Co-authored-by: Joffrey JAFFEUX <[email protected]>
2024-03-04 09:56:59 +11:00
Sam c02794cf2e FIX: support multiple tool calls (#502)
* FIX: support multiple tool calls

Prior to this change we had a hard limit of 1 tool call per llm
round trip. This meant you could not google multiple things at
once or perform searches across two tools.

Also:

- Hint when Google stops working
- Log topic_id / post_id when performing completions

* Also track id for title
2024-03-02 07:53:21 +11:00
Kris b72ee805b6 DEV: update caption test for core interaction change (#503) 2024-03-01 14:58:33 -05:00
Sam 59bab2bba3 FIX: stream messages when directly PMing a persona (#500)
previous to this fix we did not consider personas a bot in the
front end
2024-03-01 07:53:42 +11:00
Sam 9fb1430e40 FIX: support spaces within arguments for Open AI (#499)
Previous to this fix if a tool call ever streamed a SPACE alone,
we would eat it and ignore it, breaking params

Also fixes some tests to ensure they are actually called :)
2024-02-29 12:47:34 +11:00
Rafael dos Santos Silva 1b72a00d2c FEATURE: Option for AI triage to send a post to the review queue (#498)
Option for AI triage to send a post to the review queue
2024-02-29 12:33:28 +11:00
Keegan George 6a30b06a55 DEV: Cancel popup should abort request (#497) 2024-02-28 13:32:45 -08:00
SamandMartin Brennan 484fd1435b DEV: improve internal design of ai persona and bug fix (#495)
* DEV: improve internal design of ai persona and bug fix

- Fixes bug where OpenAI could not describe images
- Fixes bug where mentionable personas could not be mentioned unless overarching bot was enabled
- Improves internal design of playground and bot to allow better for non "bot" users
- Allow PMs directly to persona users (previously bot user would also have to be in PM)
- Simplify internal code


Co-authored-by: Martin Brennan <[email protected]>
2024-02-28 16:46:32 +11:00
Keegan George a1b607db80 FIX: Composer service call breaking shared edits (#494) 2024-02-28 10:13:46 +11:00
Rafael dos Santos Silva a1f1067f69 FIX: Lower truncation size for Gemini Embeddings (#493) 2024-02-28 08:52:53 +11:00
Discourse Translator Bot 1414a91db4 Update translations (#492) 2024-02-27 16:32:29 -03:00
Selase Krakani fc2ffb9fec DEV: Pin plugin for Discourse < 3.3.0.beta1-dev (#491) 2024-02-27 16:32:13 -03:00
SamandRafael Silva d036f3fb8e FEATURE: AI helper support in non English languages (#489)
* FEATURE: AI helper support in non English languages

This attempts some prompt engineering to coerce AI helper to answer
in the appropriate language.

Note mileage will vary, in testing GPT-4 produces the best results
GPT-3.5 can return OKish results.

* Extend non english support for GPT-4V image caption

* Update db/fixtures/ai_helper/603_completion_prompts.rb

---------

Co-authored-by: Rafael Silva <[email protected]>
2024-02-27 16:31:51 -03:00
Sam aabff87501 FIX: image generation in gemini was broken (#490)
We need to inject blank model answers after tool calls if absent
otherwise model will reject it.
2024-02-27 18:24:30 +11:00
Keegan George 2c7d34ff1f DEV: Image caption system specs (#487) 2024-02-26 12:22:09 -08:00
Keegan George 0596ce41fe DEV: Auto save caption on mobile view (#486) 2024-02-23 10:06:39 -08:00
Kris 0f761234f9 UX: minor adjustments for image caption size, behavior (#484) 2024-02-22 12:31:25 -05:00
Discourse Translator Bot cbb3807237 Update translations (#480) 2024-02-22 10:50:35 -03:00
Roman Rizzi 94ba0dadc2 SECURITY: Place a SSRF protection when calling services from the plugin. (#485)
The Faraday adapter and `FinalDestionation::HTTP` will protect us from admin-initiated SSRF attacks when interacting with the external services powering this plugin features.:
2024-02-21 17:14:50 -03:00
Keegan George 97f3cba603 DEV: Add attribution to AI captioned images (#483) 2024-02-21 10:10:22 -08:00
Kris d88dceb49d UX: minor image caption style adjustments (#482) 2024-02-20 17:59:59 -05:00
Rafael dos Santos Silva bfd4fafaec FIX: Caption was broken with multiple subsequent calls (#481) 2024-02-20 12:44:15 -03:00
Sam becbe01f68 FIX: unable to share conversations with persona user (#479)
Persona users are still bots, but we were not properly accounting
for it and share icon was not showing up.

This depends on a core change that adds .topic to transformed posts
2024-02-20 16:16:23 +11:00
Rafael dos Santos Silva a5fe941e6a DEV: Update libraries for Ruby 3.3 compat (#477) 2024-02-20 13:45:16 +11:00
Martin Brennan 0c1aad7850 DEV: Cleanup caption endpoint and account for secure uploads (#478)
Utilizes the check for secure upload permissions from core PR
https://github.com/discourse/discourse/pull/25758 and cleans up
controller codes and spec code to reuse existing code and better
reflect reality.
2024-02-19 23:43:39 -03:00
Rafael dos Santos Silva cf19ce0d72 FEATURE: Handle secure uploads in image caption (#476) 2024-02-19 18:08:19 -03:00
Keegan GeorgeandRafael Silva a9b2d6a30a FEATURE: AI image caption (#470)
This PR adds a new feature where you can generate captions for images in the composer using AI.

---------

Co-authored-by: Rafael Silva <[email protected]>
2024-02-19 14:56:28 -03:00
Sam 1f74a77e17 DEV: correct flaky spec (#475)
We were not properly expiring prompt cache
2024-02-19 15:21:55 +11:00