aartikis / RTEC

RTEC is an Event Calculus implementation optimised for stream reasoning

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cyclic/1, module structure, data-scoping & contributions

jacobfriedman opened this issue · comments

Hello @aartikis, @Periklismant, @manospits,

I was discussing this system with Paulo Moura. While trying to run the example in the manual, we found cyclic/1 was not defined. The manual would have to be updated, I think, to use the latest in /examples. Notwithstanding, we think RTEC is useful - and could contribute extra documentation and pull requests. A few things which were mentioned concerned working towards a scoped rule-compiler... would you be interested in such things, or, working with some input to streamline the system or make it more portable?

% Paulo Moura's cyclic/1: 

:- meta_predicate(cyclic(*)).
cyclic(UnificationGoal) :-
    \+ \+ (
        call(UnificationGoal),
        \+ acyclic_term(UnificationGoal)
    ).

cyclic/1 may be defined in some event descriptions but it is not mandatory. For example, it does not appear in the event description of our toy example. So, it had to be declared 'dynamic' to avoid the error you have mentioned. Now the compiler should work fine for the example of the manual. Thank you very much for your feedback!