Hello!
Start here!
Demo installation(currently closed due to spam bots)
Download
Loki Semantic Wiki
BiFröST Framework
- About BiFröST (in progress…)
- Plugins:
lib/plugins/loki/temp/loki/tests/prolog.txt
before tests
Description: Simple Prolog goal for knowledge saved inside <pl></pl>
tag. Note that knowledge is not saved in cache!
Code:
<pl goal="woman(X),write(X),nl,fail"> woman(kate). man(john). </pl>
Expected result:
kate
Actual result:
kate
Description: Knowledge saved (cache=“true”
) inside one <pl></pl>
tag and used inside other <pl></pl>
tag with specified scope.
Code:
<pl cache="true"> man(jack). man(jim). </pl> <pl goal="man(X),write(X),nl,fail" scope="tests:prolog"> </pl>
Expected result:
jack jim
Note that john
should not appear because this fact should not be saved in cache! (it is from previous test)
Actual result:
jack
jim
Description: List all predicates in specified scope.
Code:
<pl goal="consult('lib/plugins/loki/loki.pl'),wikiconsult('tests/prolog'),list."> % </pl>
Expected result:
The list similar to the one shown below. It must contain predicates: man
, wiki_header
.
absolute_file_name atom_concat ->atomic_list_concat ;atomic_list_concat expand_answer expand_file_name expand_query file_search_path library_directory link_xpce:pcehome_ man '$member' '$pack':pack_dir prolog_file_type system:current_prolog_flag '$toplevel':catch toplevel_variables:expand_answer toplevel_variables:expand_query wiki_header
Actual result:
'$member'
'$pack':pack_dir
->atomic_list_concat
;atomic_list_concat
atom_concat
current_prolog_flag
file_search_path
library_directory
man
pcehome_
prolog_file_type
system:'$xdg_prolog_directory'
system:current_prolog_flag
wiki_header
Description: Show info about specified predicate in specified scope.
Code:
<pl goal="consult('lib/plugins/loki/loki.pl'),wikiconsult('tests/prolog'),list(man)."> % </pl>
Expected result:
man(jack). man(jim).
Actual result:
man(jack).
man(jim).
Description: Error messages for Prolog code
Code:
<pl goal="invalid_goal" scope="*" msgerr="display"></pl>
Expected result:
Errors list that contains (probably at the end):
ERROR: Prolog initialisation failed: ERROR: ignore/1: Undefined procedure: invalid_goal/0
Actual result: