2 Replies
      Latest reply on Jun 27, 2019 4:00 PM by cwoolf
      TedB Level 1 Level 1 (10 points)

        I've got two CLIPS files imported in the instrpkg as follows:

         

        <production-system>
                <rule-path>reasonForWaitingToPlay.clp</rule-path>
                <rule-path>timeControlStatus.clp</rule-path>
        </production-system>
        

         

        All the rules in there are working fine, I've just added a 'speculate' defrule in each, for some reason only one will fire. If I comment it out, then the other one works:

         

        (defrule RECORDER::speculatively-record-reasonForWaitingToPlay-interval
            (speculate (event-horizon ?end))
            (table (table-id ?output) (side append))
            (table-attribute (table-id ?output) (has schema reason-for-waiting-to-play-interval))
            (reasonForWaitingToPlay-update (time ?start) (state ?state))
            =>
            (bind ?duration (- ?end ?start))
            (create-new-row ?output)
            (set-column start ?start)
            (set-column duration ?duration)
            (set-column state ?state)
            (set-column-narrative "recording reasonForWaitingToPlay for %start-time%, %string%" ?start ?state)
        )
        (defrule RECORDER::speculatively-record-timeControlStatus-interval
            (speculate (event-horizon ?end))
            (table (table-id ?output) (side append))
            (table-attribute (table-id ?output) (has schema time-control-status-interval))
            (timeControlStatus-update (time ?start) (state ?state))
            =>
            (bind ?duration (- ?end ?start))
            (create-new-row ?output)
            (set-column start ?start)
            (set-column duration ?duration)
            (set-column state ?state)
            (set-column-narrative "recording timeControlStatus for %start-time%, %string%" ?start ?state)
        )
        

         

        Looking at the examples, it seems like it should be possible for them to co-exist.