Thomas (Tom) Gardos commited on
Commit
d55c537
β€’
2 Parent(s): c571e3b b7d3eda

Merge pull request #98 from edubotics-ai/dev_branch

Browse files
This view is limited to 50 files because it contains too many changes. Β  See raw diff
Files changed (50) hide show
  1. .github/workflows/publish.yml +29 -0
  2. .github/workflows/push_to_hf_space.yml +1 -1
  3. .vscode/launch.json +2 -2
  4. Dockerfile +1 -1
  5. Dockerfile.dev +1 -1
  6. README.md +6 -6
  7. apps/ai_tutor/.chainlit/config.toml +1 -1
  8. apps/ai_tutor/app.py +1 -1
  9. apps/ai_tutor/chainlit_app.py +4 -4
  10. apps/ai_tutor/config/config_manager.py +1 -1
  11. apps/ai_tutor/config/project_config.yml +1 -1
  12. apps/ai_tutor/helpers.py +1 -1
  13. apps/chainlit_base/chainlit_base.py +2 -2
  14. {modules β†’ edubotics_core}/__init__.py +0 -0
  15. {modules β†’ edubotics_core}/chat/__init__.py +0 -0
  16. {modules β†’ edubotics_core}/chat/base.py +0 -0
  17. {modules β†’ edubotics_core}/chat/chat_model_loader.py +0 -0
  18. {modules β†’ edubotics_core}/chat/helpers.py +0 -0
  19. {modules β†’ edubotics_core}/chat/langchain/__init__.py +0 -0
  20. {modules β†’ edubotics_core}/chat/langchain/langchain_rag.py +2 -2
  21. {modules β†’ edubotics_core}/chat/langchain/utils.py +0 -0
  22. {modules β†’ edubotics_core}/chat/llm_tutor.py +5 -5
  23. {modules β†’ edubotics_core}/chat_processor/__init__.py +0 -0
  24. {modules β†’ edubotics_core}/chat_processor/helpers.py +0 -0
  25. {modules β†’ edubotics_core}/chat_processor/literal_ai.py +0 -0
  26. {modules β†’ edubotics_core}/config/__init__.py +0 -0
  27. {modules β†’ edubotics_core}/config/constants.py +0 -0
  28. {modules β†’ edubotics_core}/dataloader/__init__.py +0 -0
  29. {modules β†’ edubotics_core}/dataloader/data_loader.py +5 -5
  30. {modules β†’ edubotics_core}/dataloader/helpers.py +1 -1
  31. {modules β†’ edubotics_core}/dataloader/pdf_readers/__init__.py +0 -0
  32. {modules β†’ edubotics_core}/dataloader/pdf_readers/base.py +0 -0
  33. {modules β†’ edubotics_core}/dataloader/pdf_readers/gpt.py +1 -1
  34. {modules β†’ edubotics_core}/dataloader/pdf_readers/llama.py +2 -2
  35. {modules β†’ edubotics_core}/dataloader/webpage_crawler.py +1 -1
  36. {modules β†’ edubotics_core}/retriever/__init__.py +0 -0
  37. {modules β†’ edubotics_core}/retriever/base.py +0 -0
  38. {modules β†’ edubotics_core}/retriever/chroma_retriever.py +0 -0
  39. {modules β†’ edubotics_core}/retriever/colbert_retriever.py +0 -0
  40. {modules β†’ edubotics_core}/retriever/faiss_retriever.py +0 -0
  41. {modules β†’ edubotics_core}/retriever/helpers.py +0 -0
  42. {modules β†’ edubotics_core}/retriever/raptor_retriever.py +0 -0
  43. {modules β†’ edubotics_core}/retriever/retriever.py +4 -4
  44. {modules β†’ edubotics_core}/vectorstore/__init__.py +0 -0
  45. {modules β†’ edubotics_core}/vectorstore/base.py +0 -0
  46. {modules β†’ edubotics_core}/vectorstore/chroma.py +1 -1
  47. {modules β†’ edubotics_core}/vectorstore/colbert.py +1 -1
  48. {modules β†’ edubotics_core}/vectorstore/embedding_model_loader.py +1 -1
  49. {modules β†’ edubotics_core}/vectorstore/faiss.py +1 -1
  50. {modules β†’ edubotics_core}/vectorstore/helpers.py +0 -0
.github/workflows/publish.yml ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Publish to PyPI
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ tags:
8
+ - "v*"
9
+
10
+ jobs:
11
+ deploy:
12
+ runs-on: ubuntu-latest
13
+ steps:
14
+ - uses: actions/checkout@v2
15
+ - name: Set up Python
16
+ uses: actions/setup-python@v2
17
+ with:
18
+ python-version: "3.x"
19
+ - name: Install dependencies
20
+ run: |
21
+ python -m pip install --upgrade pip
22
+ pip install setuptools wheel twine
23
+ - name: Build and publish
24
+ env:
25
+ TWINE_USERNAME: __token__
26
+ TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} # from pypi
27
+ run: |
28
+ python setup.py sdist bdist_wheel
29
+ twine upload dist/*
.github/workflows/push_to_hf_space.yml CHANGED
@@ -18,4 +18,4 @@ jobs:
18
  - name: Deploy Production (main) to HuggingFace
19
  env:
20
  HF_TOKEN: ${{ secrets.HF_TOKEN }}
21
- run: git push --force https://trgardos:$HF_TOKEN@huggingface.co/spaces/dl4ds/dl4ds_tutor main:main
 
18
  - name: Deploy Production (main) to HuggingFace
19
  env:
20
  HF_TOKEN: ${{ secrets.HF_TOKEN }}
21
+ run: git push --force https://trgardos:$HF_TOKEN@huggingface.co/spaces/edubotics/dl4ds_tutor main:main
.vscode/launch.json CHANGED
@@ -17,7 +17,7 @@
17
  { "name":"Python Debugger: Module store_manager",
18
  "type":"debugpy",
19
  "request":"launch",
20
- "module":"modules.vectorstore.store_manager",
21
  "env": {"PYTHONPATH": "${workspaceFolder}/code"},
22
  "cwd": "${workspaceFolder}/code",
23
  "justMyCode": true
@@ -26,7 +26,7 @@
26
  "name": "Python Debugger: Module data_loader",
27
  "type": "debugpy",
28
  "request": "launch",
29
- "module": "modules.dataloader.data_loader",
30
  "env": {"PYTHONPATH": "${workspaceFolder}/code"},
31
  "cwd": "${workspaceFolder}/code",
32
  "justMyCode": true
 
17
  { "name":"Python Debugger: Module store_manager",
18
  "type":"debugpy",
19
  "request":"launch",
20
+ "module":"edubotics_core.vectorstore.store_manager",
21
  "env": {"PYTHONPATH": "${workspaceFolder}/code"},
22
  "cwd": "${workspaceFolder}/code",
23
  "justMyCode": true
 
26
  "name": "Python Debugger: Module data_loader",
27
  "type": "debugpy",
28
  "request": "launch",
29
+ "module": "edubotics_core.dataloader.data_loader",
30
  "env": {"PYTHONPATH": "${workspaceFolder}/code"},
31
  "cwd": "${workspaceFolder}/code",
32
  "justMyCode": true
Dockerfile CHANGED
@@ -40,4 +40,4 @@ RUN --mount=type=secret,id=LITERAL_API_KEY_LOGGING,mode=0444,required=true
40
  RUN --mount=type=secret,id=CHAINLIT_AUTH_SECRET,mode=0444,required=true
41
 
42
  # Default command to run the application
43
- CMD python -m modules.vectorstore.store_manager --config_file config/config.yml --project_config_file config/project_config.yml && python -m uvicorn app:app --host 0.0.0.0 --port 7860
 
40
  RUN --mount=type=secret,id=CHAINLIT_AUTH_SECRET,mode=0444,required=true
41
 
42
  # Default command to run the application
43
+ CMD python -m edubotics_core.vectorstore.store_manager --config_file config/config.yml --project_config_file config/project_config.yml && python -m uvicorn app:app --host 0.0.0.0 --port 7860
Dockerfile.dev CHANGED
@@ -35,4 +35,4 @@ RUN ls -R /code
35
  EXPOSE 7860
36
 
37
  # Default command to run the application
38
- CMD python -m modules.vectorstore.store_manager --config_file config/config.yml --project_config_file config/project_config.yml && python -m uvicorn app:app --host 0.0.0.0 --port 7860
 
35
  EXPOSE 7860
36
 
37
  # Default command to run the application
38
+ CMD python -m edubotics_core.vectorstore.store_manager --config_file config/config.yml --project_config_file config/project_config.yml && python -m uvicorn app:app --host 0.0.0.0 --port 7860
README.md CHANGED
@@ -9,9 +9,9 @@ app_port: 7860
9
  ---
10
  # DL4DS Tutor πŸƒ
11
 
12
- ![Build Status](https://github.com/DL4DS/dl4ds_tutor/actions/workflows/push_to_hf_space.yml/badge.svg)
13
- ![License](https://img.shields.io/github/license/DL4DS/dl4ds_tutor)
14
- ![GitHub stars](https://img.shields.io/github/stars/DL4DS/dl4ds_tutor)
15
  ![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)
16
 
17
 
@@ -34,7 +34,7 @@ Please visit [setup](https://dl4ds.github.io/dl4ds_tutor/guide/setup/) for more
34
 
35
  1. **Clone the Repository**
36
  ```bash
37
- git clone https://github.com/DL4DS/dl4ds_tutor
38
  ```
39
 
40
  2. Create your app in the apps folder. (An example is the `apps/ai_tutor` app)
@@ -50,13 +50,13 @@ Please visit [setup](https://dl4ds.github.io/dl4ds_tutor/guide/setup/) for more
50
  3. **To test Data Loading (Optional)**
51
  ```bash
52
  cd apps/your_app
53
- python -m modules.dataloader.data_loader --links "your_pdf_link" --config_file config/config.yml --project_config_file config/project_config.yml
54
  ```
55
 
56
  4. **Create the Vector Database**
57
  ```bash
58
  cd apps/your_app
59
- python -m modules.vectorstore.store_manager --config_file config/config.yml --project_config_file config/project_config.yml
60
  ```
61
 
62
  6. **Run the FastAPI App**
 
9
  ---
10
  # DL4DS Tutor πŸƒ
11
 
12
+ ![Build Status](https://github.com/edubotics-ai/edubot-core/actions/workflows/push_to_hf_space.yml/badge.svg)
13
+ ![License](https://img.shields.io/github/license/edubotics-ai/edubot-core)
14
+ ![GitHub stars](https://img.shields.io/github/stars/edubotics-ai/edubot-core)
15
  ![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)
16
 
17
 
 
34
 
35
  1. **Clone the Repository**
36
  ```bash
37
+ git clone https://github.com/edubotics-ai/edubot-core
38
  ```
39
 
40
  2. Create your app in the apps folder. (An example is the `apps/ai_tutor` app)
 
50
  3. **To test Data Loading (Optional)**
51
  ```bash
52
  cd apps/your_app
53
+ python -m edubotics_core.dataloader.data_loader --links "your_pdf_link" --config_file config/config.yml --project_config_file config/project_config.yml
54
  ```
55
 
56
  4. **Create the Vector Database**
57
  ```bash
58
  cd apps/your_app
59
+ python -m edubotics_core.vectorstore.store_manager --config_file config/config.yml --project_config_file config/project_config.yml
60
  ```
61
 
62
  6. **Run the FastAPI App**
apps/ai_tutor/.chainlit/config.toml CHANGED
@@ -65,7 +65,7 @@ default_collapse_content = true
65
  cot = "hidden"
66
 
67
  # Link to your github repo. This will add a github button in the UI's header.
68
- github = "https://github.com/DL4DS/dl4ds_tutor"
69
 
70
  # Specify a CSS file that can be used to customize the user interface.
71
  # The CSS file can be served from the public directory or via an external link.
 
65
  cot = "hidden"
66
 
67
  # Link to your github repo. This will add a github button in the UI's header.
68
+ github = "https://github.com/edubotics-ai/edubot-core"
69
 
70
  # Specify a CSS file that can be used to customize the user interface.
71
  # The CSS file can be served from the public directory or via an external link.
apps/ai_tutor/app.py CHANGED
@@ -21,7 +21,7 @@ from helpers import (
21
  reset_tokens_for_user,
22
  check_user_cooldown,
23
  )
24
- from modules.chat_processor.helpers import get_user_details, update_user_info
25
  from config.config_manager import config_manager
26
  import hashlib
27
 
 
21
  reset_tokens_for_user,
22
  check_user_cooldown,
23
  )
24
+ from edubotics_core.chat_processor.helpers import get_user_details, update_user_info
25
  from config.config_manager import config_manager
26
  import hashlib
27
 
apps/ai_tutor/chainlit_app.py CHANGED
@@ -4,18 +4,18 @@ from config.constants import (
4
  LITERAL_API_KEY_LOGGING,
5
  LITERAL_API_URL,
6
  )
7
- from modules.chat_processor.literal_ai import CustomLiteralDataLayer
8
  import json
9
  from typing import Any, Dict, no_type_check
10
  import chainlit as cl
11
- from modules.chat.llm_tutor import LLMTutor
12
- from modules.chat.helpers import (
13
  get_sources,
14
  get_history_chat_resume,
15
  get_history_setup_llm,
16
  # get_last_config,
17
  )
18
- from modules.chat_processor.helpers import (
19
  update_user_info,
20
  get_user_details,
21
  )
 
4
  LITERAL_API_KEY_LOGGING,
5
  LITERAL_API_URL,
6
  )
7
+ from edubotics_core.chat_processor.literal_ai import CustomLiteralDataLayer
8
  import json
9
  from typing import Any, Dict, no_type_check
10
  import chainlit as cl
11
+ from edubotics_core.chat.llm_tutor import LLMTutor
12
+ from edubotics_core.chat.helpers import (
13
  get_sources,
14
  get_history_chat_resume,
15
  get_history_setup_llm,
16
  # get_last_config,
17
  )
18
+ from edubotics_core.chat_processor.helpers import (
19
  update_user_info,
20
  get_user_details,
21
  )
apps/ai_tutor/config/config_manager.py CHANGED
@@ -104,7 +104,7 @@ class TokenConfig(BaseModel):
104
 
105
 
106
  class MiscConfig(BaseModel):
107
- github_repo: HttpUrl = "https://github.com/DL4DS/dl4ds_tutor"
108
  docs_website: HttpUrl = "https://dl4ds.github.io/dl4ds_tutor/"
109
 
110
 
 
104
 
105
 
106
  class MiscConfig(BaseModel):
107
+ github_repo: HttpUrl = "https://github.com/edubotics-ai/edubot-core"
108
  docs_website: HttpUrl = "https://dl4ds.github.io/dl4ds_tutor/"
109
 
110
 
apps/ai_tutor/config/project_config.yml CHANGED
@@ -13,7 +13,7 @@ token_config:
13
  all_time_tokens_allocated: 1000000
14
 
15
  misc:
16
- github_repo: "https://github.com/DL4DS/dl4ds_tutor"
17
  docs_website: "https://dl4ds.github.io/dl4ds_tutor/"
18
 
19
  api_config:
 
13
  all_time_tokens_allocated: 1000000
14
 
15
  misc:
16
+ github_repo: "https://github.com/edubotics-ai/edubot-core"
17
  docs_website: "https://dl4ds.github.io/dl4ds_tutor/"
18
 
19
  api_config:
apps/ai_tutor/helpers.py CHANGED
@@ -1,6 +1,6 @@
1
  from datetime import datetime, timedelta, timezone
2
  import tiktoken
3
- from modules.chat_processor.helpers import update_user_info, convert_to_dict
4
 
5
 
6
  def get_time():
 
1
  from datetime import datetime, timedelta, timezone
2
  import tiktoken
3
+ from edubotics_core.chat_processor.helpers import update_user_info, convert_to_dict
4
 
5
 
6
  def get_time():
apps/chainlit_base/chainlit_base.py CHANGED
@@ -2,8 +2,8 @@ import chainlit.data as cl_data
2
  import asyncio
3
  from typing import Any, Dict, no_type_check
4
  import chainlit as cl
5
- from modules.chat.llm_tutor import LLMTutor
6
- from modules.chat.helpers import (
7
  get_sources,
8
  get_history_setup_llm,
9
  )
 
2
  import asyncio
3
  from typing import Any, Dict, no_type_check
4
  import chainlit as cl
5
+ from edubotics_core.chat.llm_tutor import LLMTutor
6
+ from edubotics_core.chat.helpers import (
7
  get_sources,
8
  get_history_setup_llm,
9
  )
{modules β†’ edubotics_core}/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/base.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/chat_model_loader.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/helpers.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/langchain/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/langchain/langchain_rag.py RENAMED
@@ -1,8 +1,8 @@
1
  from langchain_core.prompts import ChatPromptTemplate
2
 
3
- # from modules.chat.langchain.utils import
4
  from langchain_community.chat_message_histories import ChatMessageHistory
5
- from modules.chat.base import BaseRAG
6
  from langchain_core.prompts import PromptTemplate
7
  from langchain.memory import ConversationBufferWindowMemory
8
  from langchain_core.runnables.utils import ConfigurableFieldSpec
 
1
  from langchain_core.prompts import ChatPromptTemplate
2
 
3
+ # from edubotics_core.chat.langchain.utils import
4
  from langchain_community.chat_message_histories import ChatMessageHistory
5
+ from edubotics_core.chat.base import BaseRAG
6
  from langchain_core.prompts import PromptTemplate
7
  from langchain.memory import ConversationBufferWindowMemory
8
  from langchain_core.runnables.utils import ConfigurableFieldSpec
{modules β†’ edubotics_core}/chat/langchain/utils.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat/llm_tutor.py RENAMED
@@ -1,8 +1,8 @@
1
- from modules.chat.helpers import get_prompt
2
- from modules.chat.chat_model_loader import ChatModelLoader
3
- from modules.vectorstore.store_manager import VectorStoreManager
4
- from modules.retriever.retriever import Retriever
5
- from modules.chat.langchain.langchain_rag import (
6
  Langchain_RAG_V2,
7
  QuestionGenerator,
8
  )
 
1
+ from edubotics_core.chat.helpers import get_prompt
2
+ from edubotics_core.chat.chat_model_loader import ChatModelLoader
3
+ from edubotics_core.vectorstore.store_manager import VectorStoreManager
4
+ from edubotics_core.retriever.retriever import Retriever
5
+ from edubotics_core.chat.langchain.langchain_rag import (
6
  Langchain_RAG_V2,
7
  QuestionGenerator,
8
  )
{modules β†’ edubotics_core}/chat_processor/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat_processor/helpers.py RENAMED
File without changes
{modules β†’ edubotics_core}/chat_processor/literal_ai.py RENAMED
File without changes
{modules β†’ edubotics_core}/config/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/config/constants.py RENAMED
File without changes
{modules β†’ edubotics_core}/dataloader/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/dataloader/data_loader.py RENAMED
@@ -18,11 +18,11 @@ from urllib.parse import urljoin
18
  import html2text
19
  import bs4
20
  import PyPDF2
21
- from modules.dataloader.pdf_readers.base import PDFReader
22
- from modules.dataloader.pdf_readers.llama import LlamaParser
23
- from modules.dataloader.pdf_readers.gpt import GPTParser
24
- from modules.dataloader.helpers import get_metadata
25
- from modules.config.constants import TIMEOUT
26
 
27
  logger = logging.getLogger(__name__)
28
  BASE_DIR = os.getcwd()
 
18
  import html2text
19
  import bs4
20
  import PyPDF2
21
+ from edubotics_core.dataloader.pdf_readers.base import PDFReader
22
+ from edubotics_core.dataloader.pdf_readers.llama import LlamaParser
23
+ from edubotics_core.dataloader.pdf_readers.gpt import GPTParser
24
+ from edubotics_core.dataloader.helpers import get_metadata
25
+ from edubotics_core.config.constants import TIMEOUT
26
 
27
  logger = logging.getLogger(__name__)
28
  BASE_DIR = os.getcwd()
{modules β†’ edubotics_core}/dataloader/helpers.py RENAMED
@@ -2,7 +2,7 @@ import requests
2
  from bs4 import BeautifulSoup
3
  from urllib.parse import urlparse
4
  import tempfile
5
- from modules.config.constants import (
6
  TIMEOUT,
7
  ) # TODO: MOVE THIS TO APP SPECIFIC DIRECTORY
8
 
 
2
  from bs4 import BeautifulSoup
3
  from urllib.parse import urlparse
4
  import tempfile
5
+ from edubotics_core.config.constants import (
6
  TIMEOUT,
7
  ) # TODO: MOVE THIS TO APP SPECIFIC DIRECTORY
8
 
{modules β†’ edubotics_core}/dataloader/pdf_readers/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/dataloader/pdf_readers/base.py RENAMED
File without changes
{modules β†’ edubotics_core}/dataloader/pdf_readers/gpt.py RENAMED
@@ -6,7 +6,7 @@ from io import BytesIO
6
  from openai import OpenAI
7
  from pdf2image import convert_from_path
8
  from langchain.schema import Document
9
- from modules.config.constants import TIMEOUT
10
 
11
 
12
  class GPTParser:
 
6
  from openai import OpenAI
7
  from pdf2image import convert_from_path
8
  from langchain.schema import Document
9
+ from edubotics_core.config.constants import TIMEOUT
10
 
11
 
12
  class GPTParser:
{modules β†’ edubotics_core}/dataloader/pdf_readers/llama.py RENAMED
@@ -2,8 +2,8 @@ import os
2
  import requests
3
  from llama_parse import LlamaParse
4
  from langchain.schema import Document
5
- from modules.config.constants import OPENAI_API_KEY, LLAMA_CLOUD_API_KEY, TIMEOUT
6
- from modules.dataloader.helpers import download_pdf_from_url
7
 
8
 
9
  class LlamaParser:
 
2
  import requests
3
  from llama_parse import LlamaParse
4
  from langchain.schema import Document
5
+ from edubotics_core.config.constants import OPENAI_API_KEY, LLAMA_CLOUD_API_KEY, TIMEOUT
6
+ from edubotics_core.dataloader.helpers import download_pdf_from_url
7
 
8
 
9
  class LlamaParser:
{modules β†’ edubotics_core}/dataloader/webpage_crawler.py RENAMED
@@ -4,7 +4,7 @@ import asyncio
4
  import requests
5
  from bs4 import BeautifulSoup
6
  from urllib.parse import urljoin, urldefrag
7
- from modules.config.constants import TIMEOUT
8
 
9
 
10
  class WebpageCrawler:
 
4
  import requests
5
  from bs4 import BeautifulSoup
6
  from urllib.parse import urljoin, urldefrag
7
+ from edubotics_core.config.constants import TIMEOUT
8
 
9
 
10
  class WebpageCrawler:
{modules β†’ edubotics_core}/retriever/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/base.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/chroma_retriever.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/colbert_retriever.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/faiss_retriever.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/helpers.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/raptor_retriever.py RENAMED
File without changes
{modules β†’ edubotics_core}/retriever/retriever.py RENAMED
@@ -1,7 +1,7 @@
1
- from modules.retriever.faiss_retriever import FaissRetriever
2
- from modules.retriever.chroma_retriever import ChromaRetriever
3
- from modules.retriever.colbert_retriever import ColbertRetriever
4
- from modules.retriever.raptor_retriever import RaptorRetriever
5
 
6
 
7
  class Retriever:
 
1
+ from edubotics_core.retriever.faiss_retriever import FaissRetriever
2
+ from edubotics_core.retriever.chroma_retriever import ChromaRetriever
3
+ from edubotics_core.retriever.colbert_retriever import ColbertRetriever
4
+ from edubotics_core.retriever.raptor_retriever import RaptorRetriever
5
 
6
 
7
  class Retriever:
{modules β†’ edubotics_core}/vectorstore/__init__.py RENAMED
File without changes
{modules β†’ edubotics_core}/vectorstore/base.py RENAMED
File without changes
{modules β†’ edubotics_core}/vectorstore/chroma.py RENAMED
@@ -1,5 +1,5 @@
1
  from langchain_community.vectorstores import Chroma
2
- from modules.vectorstore.base import VectorStoreBase
3
  import os
4
 
5
 
 
1
  from langchain_community.vectorstores import Chroma
2
+ from edubotics_core.vectorstore.base import VectorStoreBase
3
  import os
4
 
5
 
{modules β†’ edubotics_core}/vectorstore/colbert.py RENAMED
@@ -1,5 +1,5 @@
1
  from ragatouille import RAGPretrainedModel
2
- from modules.vectorstore.base import VectorStoreBase
3
  from langchain_core.retrievers import BaseRetriever
4
  from langchain_core.callbacks.manager import CallbackManagerForRetrieverRun
5
  from langchain_core.documents import Document
 
1
  from ragatouille import RAGPretrainedModel
2
+ from edubotics_core.vectorstore.base import VectorStoreBase
3
  from langchain_core.retrievers import BaseRetriever
4
  from langchain_core.callbacks.manager import CallbackManagerForRetrieverRun
5
  from langchain_core.documents import Document
{modules β†’ edubotics_core}/vectorstore/embedding_model_loader.py RENAMED
@@ -1,6 +1,6 @@
1
  from langchain_community.embeddings import OpenAIEmbeddings
2
  from langchain_community.embeddings import HuggingFaceEmbeddings
3
- from modules.config.constants import OPENAI_API_KEY, HUGGINGFACE_TOKEN
4
 
5
 
6
  class EmbeddingModelLoader:
 
1
  from langchain_community.embeddings import OpenAIEmbeddings
2
  from langchain_community.embeddings import HuggingFaceEmbeddings
3
+ from edubotics_core.config.constants import OPENAI_API_KEY, HUGGINGFACE_TOKEN
4
 
5
 
6
  class EmbeddingModelLoader:
{modules β†’ edubotics_core}/vectorstore/faiss.py RENAMED
@@ -1,5 +1,5 @@
1
  from langchain_community.vectorstores import FAISS
2
- from modules.vectorstore.base import VectorStoreBase
3
  import os
4
 
5
 
 
1
  from langchain_community.vectorstores import FAISS
2
+ from edubotics_core.vectorstore.base import VectorStoreBase
3
  import os
4
 
5
 
{modules β†’ edubotics_core}/vectorstore/helpers.py RENAMED
File without changes