Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Made changes to chat app to enable docker deployment #50

Merged
merged 1 commit into from
Nov 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions MinuteMate/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@
- **Response Generation** - Generates a response, typically by sending a request to a generative model with the original user prompt and a system prompt including selected resources acquired from the vector database.
- **Trust & Safety** - Two separate stages, each using an external generative model. The first stage examines only the incoming prompt. If an inappropriate prompt is detected at this stage, all ordinary steps are skipped and a response is sent declining the prompt. The second examines generated responses and vetoes those with inappropriate content.

##### Setup - Docker



In MinuteMate/back:

Set up secrets in a .env file according to .env.example

```bash
docker compose --env-file .env up -d --build
```

In MinuteMate/front:

```bash
docker compose up -d --build
```


##### Setup - Repo

**Front-End
Expand Down
6 changes: 6 additions & 0 deletions MinuteMate/back/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#OPENAI API KEY
OPENAI_API_KEY =

# Weaviate cloud deployment
WEAVIATE_URL =
WEAVIATE_API_KEY =
13 changes: 7 additions & 6 deletions MinuteMate/back/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
FROM python:3.11-slim
WORKDIR /App
COPY . /App
RUN python -m pip install -r requirements.txt
EXPOSE 8000
CMD [" ", "start","--port","8002","--host","0.0.0.0"]
FROM python:3.11
WORKDIR /app
COPY . /app
RUN pip install --upgrade pip
RUN pip install -r requirements.txt
EXPOSE 8001
CMD ["uvicorn", "main:app","--host","0.0.0.0","--port","8001"]
11 changes: 11 additions & 0 deletions MinuteMate/back/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
services:
chat_backend:
build:
context: ./
dockerfile: Dockerfile
ports:
- 8001:8001
environment:
- WEAVIATE_ENDPOINT_URL=$WEAVIATE_ENDPOINT_URL
- WEAVIATE_API_KEY=$WEAVIATE_API_KEY
- OPENAI_API_KEY=$OPENAI_API_KEY
Loading
Loading