UB-AICLUB / RagBot

A discord bot using RAG methodology for the club
MIT License
5 stars 18 forks source link

Dicord Client #1

Open UB-AICLUB opened 2 months ago

UB-AICLUB commented 2 months ago

Issue Overview: Discord Bot Command Implementation

This issue focuses on developing a Discord bot that processes messages based on specific commands. The primary goal is to implement two key commands: /remember and /ask. Multiple developers may collaborate on this task.

Resources:

Command Specifications:

  1. /remember Command:

    • Access Control:
      • This command is restricted to users with the Core Members role and can only be used in a designated channel.
    • Functionality:
      • When a user inputs a YouTube link, the bot will:
        1. Caption Retrieval: Extract auto-generated captions from the video using a library like youtube-transcript-api or pytube.
        2. Writing to DB Send a request to the Database handler API at embed:8001 (during development, use localhost:8001) to save it The request body will be {"text":"an example text", "metadata":{...}}, the contents of metadata are TBD and left for the developer to decide and the response will return {"message":"Task started successfully"} during development use a dummy link or ignore this part till #2 is finished.
        3. Response: The bot will acknowledge the success or failure of the operation with a message.
  2. /ask Command:

    • Functionality:
      • When a user asks a question, the bot will:
        1. Database Query: Query ChromaDB to retrieve the top 5 similar text chunks related to the question (use a persistent client with some dummy data manually dumped for testing).
        2. Response Formation: If any of these chunks are linked to a YouTube video, include a link to the video in the response. or just return the texts as quotes
apurvabanka commented 1 month ago

@beaterblank I am planning to work on this issue. Will post question if I have any.

beaterblank commented 1 month ago

@beaterblank I am planning to work on this issue. Will post question if I have any.

Cool go through the resources lmk if u have any questions about the architecture . You are free to make decisions about how the data should be structrured or customised. Make sure to put good commit messages

https://www.conventionalcommits.org/en/v1.0.0/

Refer this for more on how to make good commits

kcbhola3030 commented 1 month ago

@beaterblank I am planning to work on this issue. Will post question if I have any.

Are u still working on it ? I am willing to collaborate on this one

apurvabanka commented 1 month ago

@beaterblank I am planning to work on this issue. Will post question if I have any.

Are u still working on it ? I am willing to collaborate on this one

Hey @kcbhola3030, not much is left in this issue. All the required functions are created and out for PR review.