marella / chatdocs

Chat with your documents offline using AI.
MIT License
684 stars 99 forks source link

Integration with the UIs of the other major projects [Question]/[Suggestion] #4

Open ccelik97 opened 1 year ago

ccelik97 commented 1 year ago

Hey, neat project and/but I'm wondering how one could approach to integrating a project like this to/with the big ones like oobabooga/text-generation-webui & SillyTavern.

Both support extensions. Wouldn't it be cool if all the extra features of these somehow magically worked with separate efforts like this one?

Asking to hopefully get the discussions rolling.

marella commented 1 year ago

Hi, I created it in such a way that it can be integrated into other Python projects easily (see main.py). For example, chatdocs add command can be called from Python code as:

from chatdocs.add import add
from chatdocs.config import get_config

config = get_config()
add(config=config, source_directory="/path/to/documents")

But I'm planning to refactor some of the code to simplify its usage, so the Python API is not stable yet. I will let you know when it is ready.

ccelik97 commented 1 year ago

Thanks! Keep up the good work.

ManalIrfan commented 1 year ago

Can someone guide me how can i integrate this into a streamlit app. So when i run it i can replicate the html file code into my app