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

Merge contexts metadata #19

Open
wants to merge 21 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
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
34 changes: 34 additions & 0 deletions .github/workflows/merge-contexts-metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Merge YAML Files

on:
push:
branches:
- main
workflow_dispatch:

jobs:
merge-yaml:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Install dependencies
run: pip install pyyaml

- name: Run YAML merge script
run: python scripts/merge_contexts_metadata.py

- name: Commit and push merged YAML file
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add merged-contexts-metadata.yaml
git diff --quiet && git diff --staged --quiet || git commit -m "Update contexts metadata file"
git push
10 changes: 7 additions & 3 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,15 @@ authors:
- given-names: Anna
family-names: Schwerdtel
affiliation: Humboldt-Universität zu Berlin
- given-names: Tobias
family-names: Hille
affiliation: University of Kassel
orcid: 'https://orcid.org/0000-0001-7813-9799'
repository-code: 'https://github.com/fcatools/contexts'
abstract: >-
This repository contains a collection of formal contexts to pursue
Formal Concept Analysis. The metadata for the contexts is contained
in the file contexts.yaml.
This repository contains a collection of formal contexts
to pursue Formal Concept Analysis. The metadata for the
contexts is contained in the file contexts.yaml.
license: CC0-1.0
commit: 6adc703bcb89c5b97709ac7a60930e9c962cc0c2
date-released: '2024-04-11'
18 changes: 10 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This repository contains a collection of formal contexts to pursue

The metadata for [the
contexts](https://github.com/fcatools/contexts/tree/main/contexts) is
contained in [this YAML file](contexts.yaml).
contained in [this YAML file](merged-contexts-metadata.yaml).

More contexts can be found in the repository for
[ConExp-CLJ](https://github.com/tomhanika/conexp-clj/tree/dev/testing-data),
Expand All @@ -24,7 +24,7 @@ example, in Python 3 you could do:
```python
import urllib.request

url = "https://github.com/fcatools/contexts/raw/main/contexts/livingbeings_en.cxt"
url = "https://github.com/fcatools/contexts/raw/main/contexts/living-beings-and-water/livingbeings_en.cxt"
context = urllib.request.urlopen(url).read().decode("utf-8")
```

Expand All @@ -42,16 +42,18 @@ If you think your context is suitable, then proceed as follows:

1. [Fork this repository](https://github.com/fcatools/contexts/fork)
and make the following changes in your fork:
1. Add your ASCII-encoded CXT file to the
[contexts](https://github.com/fcatools/contexts/tree/main/contexts)
directory, using a meaningful name (English, all lowercase, with
two letters indicating the [ISO 639 language
code](https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes)
1. Add a subfolder to the [contexts](https://github.com/fcatools/contexts/tree/main/contexts)
directory, and add your ASCII-encoded CXT file there.
Use a meaningful name for both (English, all lowercase, with
two letters indicating the [ISO 639 language code](https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes)
at the end, e.g., `bodiesofwater_de.cxt` for the German bodies
of water context).
2. Describe your context in [contexts.yaml](contexts.yaml)
2. Describe your context in a metadata yaml file
following the example of the other contexts. Try to be concise
and precise.
3. Optionally: Merge the metadata automatically by running the included python script
([scripts/merge_contexts_metadata.py](scripts/merge_contexts_metadata.py),
requires ```pyyaml```).
2. Make a pull request to merge your changes into this repository.

## Further information
Expand Down
159 changes: 0 additions & 159 deletions contexts.yaml

This file was deleted.

File renamed without changes.
8 changes: 8 additions & 0 deletions contexts/animals/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
animals/animals_en.cxt:
title: Animals
source: "Ganter, B., Wille, R., & Stumme, G. (2005). Formal Concept Analysis: Foundations and Applications (Vol. 3626). Springer, p. 27"
size:
objects: 35
attributes: 11
language: English
description: animals and their characteristics
18 changes: 18 additions & 0 deletions contexts/bodies-of-water/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
bodies-of-water/bodiesofwater_en.cxt:
title: Bodies of water
source: "Wille, R. (1984). Liniendiagramme hierarchischer Begriffssysteme. Studien zur Klassifikation. Indeks Verlag"
size:
objects: 8
attributes: 6
language: English
description: bodies of water and their properties

bodies-of-water/bodiesofwater_de.cxt:
title: Gewässer
source: "Wille, R. (1984). Liniendiagramme hierarchischer Begriffssysteme. Studien zur Klassifikation. Indeks Verlag"
size:
objects: 8
attributes: 6
language: German
description: bodies of water and their properties
note: German version of bodiesofwater_en.cxt
19 changes: 19 additions & 0 deletions contexts/drive-concepts-for-motorcars/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
drive-concepts-for-motorcars/driveconcepts_en.cxt:
title: Drive Concepts
source: "Ganter, B., & Wille, R. (1999). Formal Concept analysis. Springer, p. 39"
size:
objects: 5
attributes: 25
language: English
description: drive concepts for motorcars
note: "Derived from a table on page 402 in the book Schlag nach! 100000 Tatsachen aus allen Wissensgebieten. 13. Auflage. Meyers Lexikonverlag, 1988"

drive-concepts-for-motorcars/driveconcepts_de.cxt:
title: Drive Concepts
source: "Ganter, B., & Wille, R. (1996). Formale Begriffsanalyse. Springer. p. 39"
size:
objects: 5
attributes: 25
language: German
description: drive concepts for motorcars
note: German version of driveconcepts_en.cxt
8 changes: 8 additions & 0 deletions contexts/famous-animals/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
famous-animals/famous_animals_en.cxt:
title: Famous Animals
source: "Priss, U. (2006), Formal concept analysis in information science. Ann. Rev. Info. Sci. Tech., 40: 521-543. p.525"
size:
objects: 5
attributes: 6
language: English
description: famous animals and their characteristics
18 changes: 18 additions & 0 deletions contexts/living-beings-and-water/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
living-beings-and-water/livingbeings_en.cxt:
title: Living Beings and Water
source: "Ganter, B., & Wille, R. (1999). Formal Concept analysis. Springer, p. 18"
size:
objects: 8
attributes: 9
language: English
description: conditions different living beings need

living-beings-and-water/livingbeings_de.cxt:
title: Lebewesen und Wasser
source: "Ganter, B., & Wille, R. (1996). Formale Begriffsanalyse. Springer. p. 18"
size:
objects: 8
attributes: 9
language: German
description: conditions different living beings need
note: German version of livingbeings_en.cxt
18 changes: 18 additions & 0 deletions contexts/miss-marple/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
miss-marple/missmarple_en.cxt:
title: Methods of murder in Miss Marple novels
source: "Schott, B. (2004). Schotts Sammelsurium. Bloomsbury, Berlin"
size:
objects: 12
attributes: 6
language: English
description: methods of murder in Miss Marple novels (not short stories!)

miss-marple/missmarple_de.cxt:
title: Mordmethoden in Miss-Marple-Romanen
source: "Schott, B. (2004). Schotts Sammelsurium. Bloomsbury, Berlin"
size:
objects: 12
attributes: 6
language: German / English
description: methods of murder in Miss Marple novels (not short stories!)
note: German version of missmarple_en.cxt
File renamed without changes.
File renamed without changes.
8 changes: 8 additions & 0 deletions contexts/music-characteristics/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
music-characteristics/music_en.cxt:
title: Music
source: "Ganter, B., Wille, R., & Stumme, G. (2005). Formal Concept Analysis: Foundations and Applications (Vol. 3626). Springer, p. 22"
size:
objects: 31
attributes: 11
language: English
description: music and their characteristics
File renamed without changes.
8 changes: 8 additions & 0 deletions contexts/new-zealand-activities/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
new-zealand-activities/newzealand_en.cxt:
title: New Zealand Leasure
source: "DK Eyewitness Travel Guide New Zealand. Dorling Kindersley Publishing Inc. 2001."
size:
objects: 13
attributes: 8
language: English
description: Places in New Zealand and offered activities
18 changes: 18 additions & 0 deletions contexts/office-supplies-and-services/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
office-supplies-and-services/officesupplies_en.cxt:
title: Office Supplies
source: "Ganter, B., & Wille, R. (1999). Formal Concept analysis. Springer, p. 25"
size:
objects: 8
attributes: 5
language: English
description: service offers of an office supplies business

office-supplies-and-services/officesupplies_de.cxt:
title: Bürobedarf
source: "Ganter, B., & Wille, R. (1996). Formale Begriffsanalyse. Springer. p. 25"
size:
objects: 8
attributes: 5
language: German
description: service offers of an office supplies business
note: German version of officesupplies_en.cxt
8 changes: 8 additions & 0 deletions contexts/planets/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
planets/planets_en.cxt:
title: Planets
source: "Anggraini, D. (2011). Analisis Perubahan Kelompok Berdasarkan Perubahan Nilai Jual Pada Bloomberg Market Data dengan Menggunakan Formal Concept Analysis, p. 7"
size:
objects: 9
attributes: 7
language: English
description: size and distance of planets
File renamed without changes.
Loading