:- dynamic goal/1, violation_of_norms/0, disagreement_on_violation/0, rejected/1.
:-compile('C:/GorgiasB/gorgias-src-0.6d/lib/gorgias.pl').
:-compile('C:/GorgiasB/gorgias-src-0.6d/ext/lpwnf.pl').
rule(r1(regret_yihan), propose(regret_yihan), []).
rule(r2(regret_baoqian), propose(regret_baoqian), []).
rule(r3(apology_baoqian), propose(apology_baoqian), []).
rule(r4(regret_yihan), neg(propose(regret_yihan)), []):-rejected(regret_yihan).
rule(r5(regret_baoqian), neg(propose(regret_baoqian)), []):-rejected(regret_baoqian).
rule(r6(apology_baoqian), neg(propose(apology_baoqian)), []):-rejected(apology_baoqian).
rule(p1(regret_yihan), prefer(r4(regret_yihan), r1(regret_yihan)), []).
rule(p2(regret_baoqian), prefer(r5(regret_baoqian), r2(regret_baoqian)), []).
rule(p3(apology_baoqian), prefer(r6(apology_baoqian), r3(apology_baoqian)), []).
rule(p4(regret_baoqian), prefer(r2(regret_baoqian), r3(apology_baoqian)), []):-goal(saving_face).
rule(p5(apology_baoqian), prefer(r3(apology_baoqian), r2(regret_baoqian)), []):-violation_of_norms.
rule(p6(regret_yihan), prefer(r1(regret_yihan), r2(regret_baoqian)), []):-goal(saving_face).
rule(p7(regret_yihan), prefer(r1(regret_yihan), r3(apology_baoqian)), []):-goal(saving_face).
rule(p8(apology_baoqian), prefer(r3(apology_baoqian), r1(regret_yihan)), []):-violation_of_norms.
rule(c1(regret_baoqian), prefer(p4(regret_baoqian), p5(apology_baoqian)), []):-disagreement_on_violation.
rule(c2(apology_baoqian), prefer(p5(apology_baoqian), p4(regret_baoqian)), []).
rule(c3(apology_baoqian), prefer(p8(apology_baoqian), p7(regret_yihan)), []).
rule(c4(regret_yihan), prefer(p7(regret_yihan), p8(apology_baoqian)), []):-disagreement_on_violation.
rule(c5(regret_baoqian), prefer(c1(regret_baoqian), c2(apology_baoqian)), []).
rule(c6(regret_yihan), prefer(c4(regret_yihan), c3(apology_baoqian)), []).
complement(propose(regret_yihan), propose(regret_baoqian)).
complement(propose(regret_baoqian), propose(regret_yihan)).
complement(propose(regret_yihan), propose(apology_baoqian)).
complement(propose(apology_baoqian), propose(regret_yihan)).
complement(propose(regret_baoqian), propose(apology_baoqian)).
complement(propose(apology_baoqian), propose(regret_baoqian)).