Skip to content

karthikgkumar/Ollama-Assistant

Repository files navigation

Chat Assistant

  • Building a Basic Webpage Opener and EXCEL SHEET (XLSX OR CSV) Question Answering Agent

Screenshot - Conversational Agent:

alt text

Requirements

Make sure to have following dependencies listed in your requirements.txt file:

  • streamlit
  • langchain
  • langchain-community
  • python-dot
  • google

Installation

Git clone the repo
python3 -m venv ./ollama-langchain-venv
source ./ollama-langchain-venv/bin/activate
docker build . -t yourdocker/ollama-langchain:0.5
ollama-langchain docker images
docker-compose up
docker exec -it ollama-langchain-ollama-container-1 ollama run phi

you should be able to see the downloaded model files and manifests in your local folder ./data/ollama (which is internally mapped to /root/.ollama for the container, which is where Ollama looks for the downloaded models to serve)

Screenshot - Opening Website through natural prompt

Run

python app_term.py 

To converse from terminal alt text To converse from streamlit alt text

Closing website

Streamlit has a sandboxed environment hence it can't redirect to another site. So we are giving the sites to open explicitly. Couldn't implement because of limitations in webbrowser module of python, tried selenium which was also unsuccessful. alt text

RAG training was done in this notebook Colab

.env setup

LANGCHAIN_API_KEY=""
LANGCHAIN_PROJECT="Task"
Please comment the part if not required. alt text Use your own API key and set up a project name to see the analytics in Langsmith.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published