mainGNU Prolog for Java - Support: sr #108389, GNU Prolog for Java - adding...

 
 

sr #108389: GNU Prolog for Java - adding fact(s) at runtime?

Submitter:  None
Submitted:  Thu 12 Sep 2013 08:39:19 AM UTC
   
 
Category:  None Priority:  5 - Normal
Severity:  4 - Important Status:  None
Privacy:  Public Assigned to:  rishabhgarg
Originator Email:  -email is unavailable- Open/Closed:  Open
Operating System:  GNU/Linux
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 12 Sep 2013 08:39:19 AM UTC, original submission:  

Hi there. I'd love to know if it is possible to add facts to the knowledgebase during run-time with GNU Prolog for Java, and if so how it is done.

For example, let's say I load a file that has simply;
hungry(bill).
hungry(bob).

Might I, during runtime, add the fact 'hungry(dave)'.
A primitive way to do this would be to append to the string to  the file the facts are loaded from, but that seems rather ridiculous.

I imagine I'd need to build a CompoundTerm with hungry as the functor and dave as a single argument but I don't know  I can add this as a fact to the environment.

Thanks for any help you can give me.

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by None (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2013-09-16 drt24 PrivacyPrivate Public
        Assigned toNone rishabhgarg

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code