Hi,
I am developing an expert system that helps a user recover from errors that
may occur during software installation. I have a list keywords related to a
particular type of error contained in a deftemplate:
(error (type hard-disk) (keywords disk space hard IDE))
(error (type font) (keywords font Tahoma Helvetica true type))
(error (type network) (keywords connection tcp/ip host server))
an error message is input by the user and exploded:
(search out of disk space)
I am trying to use the error message input by the user to establish what
type of error has occurred. So if any of the words in the search fact are
present in the keyword list of an error fact then assert the type of the
error. I have experimented with the following but am hitting problems:
(foreach ?element $?search
(if (member ?element $?error-list) then
(assert ?type))
I first thought that I could match the error deftemplate on the LHS of a
rule and then run the code listed above on the RHS. However, I can not see
how I can check every instance of an error deftemplate. Does anyone have any
suggestions or hints?
---------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the
list (use your own address!) List problems? Notify [EMAIL PROTECTED]
---------------------------------------------------------------------