343 questions
0
votes
0
answers
80
views
prolog rule_based expert system
am a beginner in prolong, i want to develop a rule_based expert system that suggests best fit and next fit job for user based on his scores in some tests and skills . here is the knowledge base :
% ...
1
vote
1
answer
46
views
CLIPS Focused module after auto focused rule is executed
In CLIPS and if we are using modules then we can use auto-focus for rules in a module:
Auto focus rule property allows an automatic focus command to be
executed whenever a rule becomes active. If the ...
1
vote
1
answer
62
views
Forward chaining LIFO
For forward chaining (LIFO) it was mentioned that
Depth strategy: Newly activated rules are placed above all rules of
the same salience : for example if fact-a activates rule-1 and rule-2
and fact-...
1
vote
1
answer
49
views
Understand (forall) conditional element in CLIPS
in CLIPS it was mentioned that
(defrule example
(forall (a ?x) (b ?x) (c ?x))
=>)
is equivalent to
(defrule example
(not (and (a ?x)
(not (and (b ?x) (c ?x)))))
=>)
I ...
3
votes
1
answer
59
views
Which rule will be fire first, more specific or the last one?
I am new to CLIPS, but I have dealt before with Prolog, and as I remember that Prolog will execute the more specific rules, what is the case for CLIPS?
For example, I have the following facts:
(male ...
1
vote
1
answer
46
views
Undefined variable * referenced in RHS of defrule
I have these facts
(person "Mark")
(person "Nail")
(person "Stark")
(person "Maria")
(married "Stark" "Maria")
I defined the following ...
2
votes
1
answer
68
views
understand some of CLIPS primitive data type
I am using CLIPS for knowledge base systems, but I am facing a problem with understanding the following three types:
1- external-address
2- instance-name
3- instance-address
I read the following:
...
0
votes
1
answer
37
views
CLIPS rule based on another rule doesn't show up on agenda or matches
I have the following program (using CLIPS)
Facts:
(deffacts family
(father tom nicholas)
(mother clair nicholas)
(father tom john)
(father brad tom)
(father mark clair))
then I use (reset)
rule1:
(...
1
vote
0
answers
33
views
How to modify my Turbo Prolog expert system
I have Turbo Prolog expert system on rules that searching music albums based on answer of user about genres of this albums. I've modified that system and now user can answer "maybe" if he ...
0
votes
1
answer
32
views
Is there a function in CLIPS which checks if all/any/none of the elements in a multifields match a predicate?
I am aware of the member$ function in CLIPS. But its downside is that it only works on literal values as input. Does CLIPS have all/any/none functions where the elements are tested for a predicate? ...
-2
votes
1
answer
73
views
How to count the number of times a value appears in a list
I am trying to count how many times the name "Bob" appears in all classes.
I have these facts:
(deffacts classes
(class 11A Peter Jack Samuel Bob Bob)
(class 10A Lucy James John ...
0
votes
1
answer
43
views
Syntax for duplicating template facts in CLIPS
In the official examples there is a dilemma1 file that contains the following snippet
(defrule MAIN::move-alone
?node <- (status (search-depth ?num)
(farmer-location ?fs))
(...
0
votes
1
answer
41
views
Comparing contents of 2 lists with values not ordered the same
I have these templates,
(deftemplate classroom
(slot classroom_number (type INTEGER))
(multislot students (type SYMBOL))
)
(deftemplate students_to_classroom_lookup
(multislot students (...
0
votes
1
answer
90
views
How to merge values of multiple lists into one list in CLIPS
I'm building a simple expert system for illness diagnosis. I have collected the symptoms of a patient and stored them in lists like so:
(patient_symptoms headache)
(patient_symptoms temperature)
(...
0
votes
1
answer
72
views
Error in my CLIPS program to build an expert system
(defrule ask-question-1
=>
(printout t "Do you have a full-time job or go to school full-time? (yes/no): ")
(assert (full-time-occupation (read)))
)
(defrule ask-question-2
=>
...
0
votes
1
answer
147
views
Streamlit show streamlit suboptions under selected option
I have a streamlitradio for an expertsystem. With the options selected a number is created. Depending on the selected option, there are different suboptions, which makes up the number. There are ...
1
vote
1
answer
112
views
CLIPS programming
I am attempting to create a CLIPS program that asserts three facts as ingredients for a cake recipe. The goal is to determine the name of the cake recipe and the minimum number of cakes that can be ...
0
votes
1
answer
72
views
Error about a missing file when excecuting the example code of the cDMN python module
i am not an experienced programmer and i need to create an expert system for a project. I opted for the cDMN python module to do so. My first step was to follow the example on the documentation site.
...
-2
votes
1
answer
116
views
Expert system for feasible / actual cooking receipe, managing ingredients (available or feasible) [closed]
I would like to implement an expert system with CLIPS for cooking receipe. Basically, from available ingredients I have in stock (e.g. tomato, floor, oil, tomatoSauce, etc.) and "crafted" ...
0
votes
1
answer
71
views
Sorting algorithm of multifield variable in CLIPS
I jsut started to learn CLIPS and I made a simple sorting algorithm to sort multifield variables in ascending order, the problem is that the return multifield variable isn't modified during the ...
0
votes
1
answer
84
views
Recursive function in CLIPS
I'm trying to do simple algorithms on clips to get familiar with the language. In this algorithm, I'm trying to make simple recursion calls to calculate the greatest common divisor, but CLIPS breaks ...
0
votes
1
answer
531
views
How to generate a flow chart using the rules engine in python?
I would like to generate a flow using the rules that I defined in the rules engine. Below is the code
from pyknow import *
import pydot
class Wine(Fact):
"""Wine characteristics&...
0
votes
0
answers
110
views
Is there a way to integrate CLIPS with GUIs for .NET? I want to design a GUI in CLIPS for expert system Using a radio button and a button
Am writing a program with CLIPS for expert system that will diagnose symptoms and conclude the type of disease affecting a watermelon plant. Now I want to use .NET to design a graphical user interface....
0
votes
1
answer
141
views
How to integrate CLIPS with GUIs for .NET to design a graphical user interface in CLIPS for expert system
Am writing a program with CLIPS for expert system that will diagnose symptoms and conclude the type of disease affecting a watermelon plant. Now I want to use .NET to design a graphical user interface....
0
votes
1
answer
56
views
hey i have a problem in this clips expert system code its not printing the result
this is a Diet and Nutrition Expert System i have a problem that i cant print the result to the user after entering the input so can any one help me to make it run correctly?
(defrule read-gender
(...
0
votes
1
answer
105
views
hey i have a problem in this clips code can any one please fix it?
this is a clips expert system code to make a diagnosis for a disease so i am trying to find out whats the problem in that code and i really dont know what to do
[CSTRCPSR1]
[CSTRCPSR2]
error
defrule ...
0
votes
1
answer
90
views
Am writing a project, my code will be in the form as describe below in the code, Is there any need to include salience and how can I use interface?
Am writing a project, my code will be in the form as describe below in the code, Is there any need to include salience and how can I use interface? The software will require the user to answer a ...
0
votes
1
answer
54
views
I want this Clips program to compare 4 symptoms of disease using if then(the symptoms are ows, yhp, sda and dgb)
I want this Clips program to compare 4 symptoms of a disease Bacterial fruit blotch of watermelon using if then rules of Clips (the symptoms are ows, yhp, sda and dgb). the issue is when I run the ...
0
votes
1
answer
28
views
CLIPs How can I print all defacts as result throught a Defrule? Or be able to insert multiple traits as answer?
I'm working on a project that let's users find a list of jasmines based on flower color and blooming seasons, but I haven't found an effective way to be able to print all jasmines currently on the ...
-1
votes
1
answer
36
views
CLIPS: How can I allow users to input sentences as answers? Jasmine Flower Guess
Im currently working on a CLIPS program that guesses the name of the jasmine flower based only on the flower color and season, but I don't know how to use sentences as possibles answers to be able to ...
0
votes
1
answer
26
views
CLIPS How can I create a print out for when the values inserted are not any of the options?
I need to add to my program a print for when the user inserts values that dont correspond to the existing fruits on my program.
(clear)
(deftemplate fruta
(slot nombre)
(multislot color
...
0
votes
1
answer
1k
views
Expert system in Python with certain order of questions
I need to create expert system and I have one question. I'm using experta from Python and 3.8.0 is my version of Python interpreter in PyCharm. Here is my simple code:
from experta import *
class ...
1
vote
0
answers
46
views
Expert system returns this "catch/1" error
Below in code, the representation of a expert system to give response to a pattern of problems in a device (in this case, a mobile one), with the result being the probable cause of the issues, but as ...
2
votes
1
answer
685
views
How to compute MRR @n?
Supposed given a query, our system return 10 recommendation result
doc1, doc2, ... doc10
if the ground truth says relevant document says the relevant document is doc100 (which is in position 100), ...
-1
votes
1
answer
46
views
I have an error on this prolog code line 10 word first I cant figure it out what's my mistake plz help me
go:-
university(area),
write('Shall we start?: '),
write(area),
nl,
undo.
university(csandse) :- csandse, !.
csandse :-
verify(labs),
verify(classrooms),
...
1
vote
1
answer
157
views
CLIPS finding most common element across multiple multislot
I'm trying to find the most common element across multiple multislot entry of type symbol and I don't seem to get a decent way to extracts the content of those multislot to single entry to iterate ...
0
votes
1
answer
103
views
How can I find out at which step some rules have fired?
I need to know which rules and facts were fired in which inference step.
I used watch rules to print out which rules have fired. But I cannot figure out how to output at which steps the rules have ...
0
votes
1
answer
244
views
Clips 6.4 not generating initial-fact?
I'm testing if CLIPS generates the initial-fact after a (reset) command with CLIPSIDE 6.4. But it don't generates it.
It's dissapeared this initial-fact in the last versions?
Screenshot of clips (...
0
votes
1
answer
445
views
CLIPS: Clear-window in CLIPSDOS.exe and tab to indent in CLIPSIDE
With CLIPS, It's possible some of the following?? (V 6.4 for Windows)
1 - Use a command like (clear-window) in the CLIPSDOS console for clear the console.
2 - Use tabs for indentation in CLIPSIDE. ...
1
vote
1
answer
90
views
Can this type of problem be easily expressed in logic programming paradigm?
For simplicity, this is a toy version of the actual problem: given a set of integers, find the longest sequence of consecutive numbers from that set.
I looked at CLIPS and other expert systems, and ...
1
vote
0
answers
39
views
Mycin like diagnosis system using gpt3 model
I wondering if we can build a Mycin like expert system using most advanced deep learning model like GPT3 by fine tuning medical domain knowledge. We build 40 years ago Mycin using symbolic approach ...
0
votes
0
answers
220
views
Handle multiple choise answer in expert system prolog
I have to add a functionality to an already existing expert system, that is to manage questions with different types of answers, not Boolean, but for example multiple choice answers.
In the knowledge ...
0
votes
0
answers
70
views
Facing Type Problem with CLIPS 6.3 IDE editor?
After typing 4 alphabets, It won't appear the next typing alphabets. Please have a look the attached screenshot.
enter image description here
After I typed the "haii" word, the next alphabet ...
0
votes
1
answer
138
views
in CLIPS, I have to use conflict resolution strategies, can someone help me add the strategies?
;;; ***************************
;;; *DEF TEMPLATES AND DEF FACTS *
;;; ***************************
(deftemplate UI-state
(slot id (default-dynamic (gensym*)))
(slot display)
(slot relation-...
0
votes
1
answer
529
views
change the output in Prolog - for detecting covid symptoms
I would like to ask if you could advise me how to create a condition or redo the code. I need the output of the program to detect the symptoms of covid19. If I mark 'yes' at least 3 times out of ten ...
0
votes
1
answer
115
views
ArrayMinumun () returning last value
i'm trying to find the lowest value in an array that is determined between the last closed order and Timecurrent().
I'm always getting the last value of the buffer instead the minimum value of the ...
-1
votes
1
answer
257
views
How can I change a working python program so that it runs as python flask program
I have a python program, an expert system, it runs ok as a purely python program. but I now want to run it as a python flask program so that it can appear as on a browser and maybe be integrated as a ...
0
votes
2
answers
238
views
What version of Clips should I use - Clips 6.4Beta or 6.31?
What version of Clips should I use - Clips 6.4Beta or 6.31? Are there any problems with the Beta version?
-1
votes
1
answer
140
views
my if condition in Mql4 is never established
in the below code if(sma5_after > sma18_after) never is true while this condition is repeated many times in the chart
I use Mql4 in meta trader4
void OnTick()
{
if(iVolume(_Symbol,_Period,0)<=...
0
votes
1
answer
3k
views
Mql5 function for selecting open orders by Ticket, then Symbol, and trade Direction
Total newbie to Mql5, and need some help with this int OpenOrders() piece of code originally from Mql4 EA's, that finds open positions - (if any), and selects originally by SYMBOL, and MAGIC Number, ...