Skip to content
This repository was archived by the owner on Jul 22, 2025. It is now read-only.

Conversation

@SamSaffron
Copy link
Member

@SamSaffron SamSaffron commented Sep 16, 2024

This allows custom tools access to uploads and sophisticated searches using embedding.

It introduces:

  1. A shared front end for listing and uploading files (shared with personas)
  2. Backend implementation of index.search function within a custom tool.

Custom tools now may search through uploaded files

function invoke(params) {
   return index.search(params.query)
}

This means that RAG implementers now may preload tools with knowledge and have high fidelity over
the search.

The search function support

  1. specifying max results
  2. specifying a subset of files to search (from uploads)

Also

  • Improved documentation for tools (when creating a tool a preamble explains all the functionality)
  • uploads were a bit finicky, fixed an edge case where the UI would not show them as updated

Comment on lines +27 to +31
<a
href="#"
class="rag-options__indexing-options"
{{on "click" this.toggleIndexingOptions}}
>{{this.indexingOptionsText}}</a>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use a button here? It's a lot of code just because we try to use an anchor for something which is not an anchor

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably, will leave this to @awesomerobot to address in a followup, he probably wants to rethink some of the design here.

Comment on lines +261 to +265
# name :string not null
# description :string not null
# summary :string not null
# parameters :jsonb not null
# script :text not null
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we limit the size of these fields?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah probably but a bit unrelated to this commit, it was there from before

export default class PersonaRagUploader extends Component.extend(
UppyUploadMixin
) {
export default class RagUploader extends Component.extend(UppyUploadMixin) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@davidtaylorhq FYI as you are working on this

Copy link
Contributor

@jjaffeux jjaffeux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have enough knowledge of discourse-ai to have a very strong opinion, but I saw nothing stopping to merge this.

@SamSaffron SamSaffron merged commit 5cbc919 into main Sep 30, 2024
5 checks passed
@SamSaffron SamSaffron deleted the rag_tool branch September 30, 2024 07:27
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants