Load graph database in CI/CD
Browse files- .github/load.py +4 -0
- .github/workflows/ci-cd.yaml +22 -0
- .gitignore +1 -1
- README.md +12 -8
- definition.png +0 -0
- general-schema.png +0 -0
.github/load.py
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
from wilhelm_python_sdk.german_neo4j_loader import load_into_database
|
2 |
+
|
3 |
+
if __name__ == "__main__":
|
4 |
+
load_into_database("german.yaml")
|
.github/workflows/ci-cd.yaml
CHANGED
@@ -26,3 +26,25 @@ jobs:
|
|
26 |
with:
|
27 |
use-custom-yamllint-config-file: true
|
28 |
use-custom-markdownlint-config-file: true
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
with:
|
27 |
use-custom-yamllint-config-file: true
|
28 |
use-custom-markdownlint-config-file: true
|
29 |
+
|
30 |
+
load-neo4j:
|
31 |
+
name: Load vocabularies
|
32 |
+
if: github.ref == 'refs/heads/master'
|
33 |
+
needs: yml-md-style-and-link-checks
|
34 |
+
runs-on: ubuntu-latest
|
35 |
+
steps:
|
36 |
+
- uses: actions/checkout@v3
|
37 |
+
with:
|
38 |
+
fetch-depth: 0
|
39 |
+
- name: Set up Python 3.10
|
40 |
+
uses: actions/setup-python@v4
|
41 |
+
with:
|
42 |
+
python-version: "3.10"
|
43 |
+
- name: Load
|
44 |
+
run: |
|
45 |
+
pip3 install wilhelm-python-sdk
|
46 |
+
python3 .github/load.py
|
47 |
+
env:
|
48 |
+
NEO4J_URI: ${{ secrets.NEO4J_URI }}
|
49 |
+
NEO4J_USERNAME: ${{ secrets.NEO4J_USERNAME }}
|
50 |
+
NEO4J_PASSWORD: ${{ secrets.NEO4J_PASSWORD }}
|
.gitignore
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
.idea/
|
2 |
-
|
|
|
1 |
.idea/
|
2 |
+
.DS_Store
|
README.md
CHANGED
@@ -17,20 +17,24 @@ The data that serves [wilhelmlang.com](https://wilhelmlang.com/). They are writt
|
|
17 |
How Data (Vocabulary) is Stored in a Graph Database
|
18 |
---------------------------------------------------
|
19 |
|
20 |
-
###
|
21 |
|
22 |
Graph data representation assumes universal connectivity among world entities. This applies pretty well to the realm of
|
23 |
-
languages.
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
word (`term`) is presented in the following way
|
28 |
|
29 |
### Definition
|
30 |
|
31 |
-
_The meaning of a word is called the `definition`
|
|
|
|
|
|
|
32 |
|
33 |
-
|
|
|
|
|
34 |
|
35 |
[German](./german.yaml)
|
36 |
-----------------------
|
|
|
17 |
How Data (Vocabulary) is Stored in a Graph Database
|
18 |
---------------------------------------------------
|
19 |
|
20 |
+
### Why Graph Database
|
21 |
|
22 |
Graph data representation assumes universal connectivity among world entities. This applies pretty well to the realm of
|
23 |
+
languages. Multilanguage learners have already seen that Indo-European languages are similar in many different ways.
|
24 |
+
The similarities not only signify the historical facts about Philology but also surface a great opportunity for
|
25 |
+
multilanguage learners to study much more efficiently. What's missing is connecting the dots using Graph Databases that
|
26 |
+
visually presents these vastly enlightening links between the related languages.
|
|
|
27 |
|
28 |
### Definition
|
29 |
|
30 |
+
_The meaning of a word is called the `definition`_. A term has a natural relationship to its definition(s). For example,
|
31 |
+
the German noun ["Ecke"](https://en.wiktionary.org/wiki/Ecke#Noun) has at least 4 definitions:
|
32 |
+
|
33 |
+
![Relationship between term and defintion(s)](./definition.png "Error loading definition.png")
|
34 |
|
35 |
+
<div align="center">
|
36 |
+
Graph data generated by <a href="https://github.com/QubitPi/wilhelm-python-sdk">wilhelm-python-sdk</a>
|
37 |
+
</div>
|
38 |
|
39 |
[German](./german.yaml)
|
40 |
-----------------------
|
definition.png
ADDED
general-schema.png
DELETED
Binary file (278 kB)
|
|