[rules-users] Re: the n best solutions on a very simple test case (drools-solver)

Geoffrey De Smet ge0ffrey.spam at gmail.com
Thu Jul 2 14:43:59 EDT 2009


Only the solution which is reached by each chosen step is send to the 
BestSolutionRecaller. If you do only one step, you 'd have to do some 
dirty hack to get those other 4.

Maybe you can use your current Finish combined with AND and a at least 4 
steps taken finish, to force at least (4 - 1 = )3 steps. Combine it with 
a completeSolutionTabu of at least 3 (usually I take a 1000) and you 'll 
have 4 distinct solutions. Your starting solution will also count as one.

But I am interested in this use case :)

1) Why do you want to recall you best 4 solutions? Only the best 
solution seems relevant to me (but I could be wrong). If this is a 
genuine use case, I can add a MultiBestSolutionRecaller in the 
drools-solver code.

2) Extending a BestSolutionRecaller is easy, but how did you hook it up 
into the framework?
a) Did you build your solver and then do a setBestSolutionRecaller()
b) Or did you use xstream ability to configure in your 
BestSolutionRecaller implementation directly?

BTW: other feed-back on how to improve drools-solver is welcome

With kind regards,
Geoffrey De Smet


Laurent Michenaud schreef:
> Hi, 
> 
> We have implemented a best score recaller to keep
> the n best found solutions.
> It seems to be ok except on very simple
> test cases :
> 
> - On the first step, 4 moves are tested. They all 
> return a feseable score. The best one is kept and
> sent to the solution recaller.
> - After each of these moves, no other moves are
> possible and the other solutions of the first step
> are not sent to the solution recaller.
> 
> So, in our solution recaller, we have only one
> solution.
> 
> Thanks for your help
> Michenux.
> 
> 
> 
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
> 




More information about the rules-users mailing list