A. Bug fixing:

1) predicate index_rules/3: add copy_term(Head,Head1) to anticipate unification in Head.

2) predicate process_pos_rule/2: add a clause to deal with facts (rules with empty body), i.e., with 2nd argument=[].

B. Add an example th1.ab.