-
Notifications
You must be signed in to change notification settings - Fork 0
Loading the DaanMatch Knowledge Graph
This describes the process to load the DaanMatch knowledge graph system. This is just tentative and will be revised. These instructions assume the user is installing on a Windows desktop or laptop. In order to use Docker it is essential that Hyper-V is enabled in Windows. Docker emulates Linux and Hyper-V enables Windows to do Linux emulation. If you have Windows 10 Pro or Windows 11 Pro, Hyper-V should be enabled already but if not it should be pretty straight forward to do so. The Windows instructions for turning on Hyper-V in Windows 11 can be found here: Windows Instructions for Enabling Hyper-V
After enabling Hyper-V you need to download Docker Desktop. Go to this link: Downloading Docker Desktop and click on the link to download Docker Desktop for Windows.
Once you have installed Docker you need to load the Docker container for AllegroGraph. The nice thing about using Docker is you don't have to worry about configuring the server, the container comes with a preconfigured server. Unless you have a license you should just download the free community version of AllegroGraph. The current DaanMatch KG will work with the community version.
The following link explains how to download a Docker AllegroGraph container: Docker and AllegroGraph
Next you need to download the Python APIs for AllegroGraph. The Docker container gives you the ability to create graphs, edit and browse them using SPARQL and Gruff, run the reasoner, and many other features. However, to use a programming language you need to download the appropriate client. We use Python so you need to install the AllegroGraph Python client using pip. The instructions are here: AllegroGraph Python Installation
Note: you can ignore most of the text on that page. They explain how to install the Python clients on several different operating systems and how to build the client from scratch but you don't need to do it (and doing so could lead to errors). The easiest and best thing to do is to just do pip install agraph-python
You may encounter a bug related to PyCurl. The best way around that is to install miniconda and use miniconda as your interpreter for any AllegroGraph code. However, only do this if the tests in the Python client don't work properly. If they do work then you should be all set. You can download miniconda at the following site: Installing Miniconda
Now, pull the Python files for the Powersearch, DropdownMS, and NGODisplayfunctional into a directory in your Python IDE. Look through each file for any code that creates an AllegroGraph connection. That code looks like:
self.conn = ag_connect('NGO', host='localhost', port='10035', user='username', password='XXXXXX')
Note: in the Powersearch this code occurs twice. You need to change every occurrence of the connection with the user name and password you chose when you installed AllegroGraph. After that you should be able to go go the Powersearch.py file, run that file, and it should bring up the GUI.