Skip to content

Commit

Permalink
Kg generation and old kg deletion (#86)
Browse files Browse the repository at this point in the history
* updated documentation and CLI input

* improved documentation

* parallelised kg_conversion

* added example KG

* excluded ireal forum from kg_generation

* updated query with SHA URIs

* query bug fixing

* kg CLI commands

* kg first version up

* updated commands

* updated URI rules

* kg version 2 up

* bug fixing sparql query

* kg version 3 up

* Update partitions and conversions data (#81)

* article data stats

* added test file for converters stats

* converters stats first version up

* updated converter_instances.py

* updated converter_commands.sh

* regenerated roman numeral conversions

* bug fixing roman converter

* updated expert validation

* bug fixing lark converter

* bug fixing prettify harte

* final bug fixing in converter

* bug fixing nottingham

* regenerated all partitions

* updated converters stats

Co-authored-by: Jacopo de Berardinis <[email protected]>

* regenerated kg version 4

* updated kg_generation.py

* updated query and bug fixing in kg_generation

* knowledge graph version 5

* query bug fixing

* added knowledge graph v6

* reformat query

* query major update

* updated kg_generation.py and bug fixing

* updated query and bug fixing

* generated new knowledge graphs

* regenerated knowledge-graph

* query refinement and previous version of kg deletion

Co-authored-by: Jacopo de Berardinis <[email protected]>
  • Loading branch information
andreamust and jonnybluesman authored Oct 9, 2022
1 parent 4343faa commit fe997c4
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions choco/kg-generation/queries/jams_ontology.sparql
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,6 @@ WHERE {
(xsd:int(STRAFTER(STR(?annotation_time_float), "."))),
xsd:int(0)) AS ?annotation_time_beat)
?annotation_properties xyz:data ?data .
#BIND (IF (?namespace = "key_mode", jams:ScoreKeyModeOccurrence, jams:ScoreChordOccurrence) AS ?occurrence_type )

#####################
# ANNOTATION METADATA
Expand Down Expand Up @@ -288,8 +287,8 @@ WHERE {
BIND (IF (?namespace = "chord_roman", URI(CONCAT(STR(roman:chord), "/", ?observation_value)), IF (CONTAINS(?namespace, "chord"), URI(CONCAT(STR(chord:symbol), "/", ?observation_value)), "")) as ?chord_equivalence)

OPTIONAL {
FILTER (?object_type = "score")
BIND (jams:hasValue as ?measure_has_value)
FILTER (?object_type = "score")
BIND (jams:hasValue as ?measure_has_value)
}

BIND (IF (?object_type = "score", ?annotation_time_beat, ?annotation_time_float) AS ?annotation_time_first_component)
Expand All @@ -301,16 +300,16 @@ WHERE {
?x xyz:file_metadata ?file_meta .
?file_meta xyz:title ?title .
OPTIONAL {?file_meta xyz:jams_version ?jams_version .}
?file_meta xyz:identifiers ?ids .
?file_meta xyz:identifiers ?ids .
OPTIONAL {?ids xyz:music_brainz ?mb_id .}
OPTIONAL {?ids xyz:discogs ?discogs_id .}
OPTIONAL {?ids xyz:perlam ?perlam_id .}
OPTIONAL {?file_meta xyz:duration ?duration .}
?file_meta xyz:release ?release_string .
?file_meta xyz:release ?release_string .
OPTIONAL {
FILTER (?duration != "")
BIND (?release_string AS ?release)
}
FILTER (?duration != "")
BIND (?release_string AS ?release)
}
}

# URIs
Expand Down

0 comments on commit fe997c4

Please sign in to comment.