:- module(load_mbh_example, []). :- use_module(library('semweb/rdf_library')). :- use_module(library('semweb/rdf_db')). :- use_module(library(http/http_dispatch)). :- use_module(applications(vumix)). % this defines the http_vumix http handler used below ... :- use_module(library(tfidf)). :- use_module(library(listing)). :- rdf_load(rdf('mbh_test_fragments.ttl')). :- rdf_load(rdf('mbh_example.ttl')). % load example video and config file /* http_link_to_id(http_vumix, [target('http://semanticweb.cs.vu.nl/prestoprime/video18702'), field('http://semanticweb.cs.vu.nl/prestoprime/personAnnotation'), field('http://semanticweb.cs.vu.nl/prestoprime/placeAnnotation'), field('http://semanticweb.cs.vu.nl/prestoprime/nameAnnotation'), field('http://semanticweb.cs.vu.nl/prestoprime/subjectAnnotation') ], Location), http_handler(cliopatria(p0), http_redirect(moved, Location), []). */ load_tag_rank :- ( exists_file('tag_rank.pl') -> compile('tag_rank.pl') ; compute_tag_rank ). compute_tag_rank :- format('compute tag ranks'), tell('tag_rank.pl'), ( rdf(Video,rdf:type,pprime:'TestFragment'), tag_rank(Video, RankedTagList), portray_clause(tag_rank_cache(Video, RankedTagList)), fail ; told, format('tag rank finished') ).