Usenet.com

www.Usenet.com

Group Index

Comp Thread Archive from Usenet.com

<-- __Chronological__ --> <-- __Thread__ -->

Re: CLIPS Question.



Yes. YOu have to test proximity from the point of view of each object.  I'd 
save the proximity scores in facts, then write a maximizing function of some
sort to sort them out after all the scoring is done.

But that is just my approach.  

The matching/scoring function would be better done using something akin to Case
Based reasoning. assuming there are a number of features, but the maximizing
could be done in a rule base pretty easily, especially if there are rules as
to how you resolve conflicts. 

Julie

StupendousMan <[EMAIL PROTECTED]> wrote:
A
> Ok.  Thanks.   So assuming I continue down the path I am on, where 
> matches with desirable traits are tallied and then reset as a match is 
> found, is this going to be horribly inefficient?  For each object in 
> pool 1, I will have to reset and re-run this trait tallying.

> Is there maybe a better way just to do that part?

> R

> Juliana L Holm wrote:
>> Possibly you could create, using your weighting of desirables a desirability
>> score and select the highest scoring desirables.
>> 
>> This may be a job for case based reasoning, not rule based reasoning.  
>> 
>> That said, I don't know of a free case based shell you could use that would
>> accomplish this.
>> 
>> Julie
>> 
>> StupendousMan <[EMAIL PROTECTED]> wrote:
>> 
>>>I think shells is the right group for this question.
>> 
>> 
>>>I am creating my first clips program and I have had a good read through 
>>>the Giarratano and Riley book but I think this is more of a taste/style 
>>>issue.
>> 
>> 
>>>I basically have two pools of objects that I need to match up based on 
>>>how well suited they are to each other.  There are numerous ways that 
>>>objects can match with each other, but in the end I need to end up with 
>>>one on one pairings of objects.  (no this isn't a dating service :-) )
>> 
>> 
>>>I have several dozen parameters that the objects could have in common, 
>>>which can be broken into two groups: mandatory and desirable.  Of course 
>>>the mandatory parameters must be met, which is easily done in CLIPS, but 
>>>its the desirable parameters that have me confused.
>> 
>> 
>>>Naturally, I want the object with the most matches in the desirable 
>>>group.  I'm really not sure how to accomplish this.
>> 
>> 
>>>If the desirable traits had some sort of weighting, I could create a 
>>>rule with every trait, give it the higest salience, then make another 
>>>rule with slightly lower salience that has one less trait in the LHS.
>> 
>> 
>>>The only solution I have come up with seems to be very inefficient, and 
>>>somewhat contrary to the principles of the language, but here goes (in 
>>>pseudo code)
>> 
>> 
>>>Add two new slots to the object, matches_mandatory and count_desirables
>> 
>> 
>>>IF object matches all mandatory constraints
>>>     THEN set matches_mandatory to true.
>> 
>> 
>>>IF object matches_mandatory AND matches desirable_quality_1
>>>     THEN set count_desirables = count_desirables + 1
>> 
>> 
>>>IF object matches_mandatory AND matches desirable_quality_2
>>>     THEN set count_desirables = count_desirables + 1
>> 
>> 
>>>blah ... blah ... blah...
>> 
>> 
>>>Finally, the object with the highest count is the right one and the rest 
>>>can be reset for the next object that comes along (since it will have 
>>>different desirable traits that it is looking for)
>> 
>> 
>>>Is there a better way?
>> 
>> 
>>>Rick
>> 
>> 
>> 


-- 
Julie 
**********
Check out my Travel Pages (non-commercial) at 
http://www.dragonsholm.org/travel.htm



<-- __Chronological__ --> <-- __Thread__ -->


Usenet.com



Please check out one of the premium Usenet Newsgroup Service Providers below for access to Usenet.