amosproj / amos2021ws01-geo-data-search

Natural language and buzzword search on routing and places
MIT License
3 stars 1 forks source link

Geo Data Search (AMOS WS 2021/22)

Mission

Our project mission is to achieve an interpretation of buzzword user queries in German through a web interface concerning location, length, height (difference) of public routes, places and regions. Multiple results, routes or places, matching the user query as close as possible will be displayed in a list as well as in a map. The software should be usable from desktop web browsers and be intuitive - an option to get examples for possible inputs in the web interface will be provided nevertheless.

Build instructions

Running on a local machine

Starting a single container

Restarting the backend container (for development)

Running example commands inside a container

Test instructions

Backend

To run the tests enter the following in the terminal:

docker build --target maven_test -f src/backend/Dockerfile src/backend

To change the log level see this page

NLP

To run the tests enter the following in the terminal:

docker compose run nlp pytest

Artifact export

docker compose build
docker save amos2021ws01-geo-data-search_nlp:latest > export/nlp.tar
docker save amos2021ws01-geo-data-search_frontend:latest > export/frontend.tar
docker save amos2021ws01-geo-data-search_backend:latest > export/backend.tar

Upload the files to https://gigamove.rwth-aachen.de

Artifact import

Download the files in a new folder

docker load -i nlp.tar
docker load -i frontend.tar
docker load -i backend.tar

Add a new docker-compose.yaml file:

version: "3.9"
services:
  frontend:
    image: amos2021ws01-geo-data-search_frontend:latest
    ports:
      - 8080:3000
    environment:
      - BACKEND_API_ROOT=http://backend:8080/backend
      - ENVIRONMENT=development
  backend:
    image: amos2021ws01-geo-data-search_backend:latest
    ports:
      - 5000:8080
    secrets:
      - source: here-api-key
  nlp:
    image: amos2021ws01-geo-data-search_nlp:latest
    ports:
      - 4000:8000
    command: /app/entrypoint.sh
secrets:
  here-api-key:
    file: ./secrets/here-api-key.txt

Create a folder for secrets and put your HERE API key:

mkdir secrets
echo "<YOUR_API_KEY>" > secrets/here-api-key.txt

run the stack:

docker compose up -d

The application should be available under http://localhost:8080