Performance - Order of conditions in a rule

Advanced automation available in Guardian - Chat with others and share files here.
Post Reply
sniffer66
Posts: 1679
Joined: Thu May 02, 2019 8:37 am

I have a large baf with many rules, with a lot of conditions in each rule. The baf can be applied to many matches concurrently. Am I right in thinking that Guardian will stop assessing conditions, and move on to the next rule the first time it fails to match, therefore condition order is useful ?
I've not placed in any particular order as yet but will do if it's going to help.
jamesg46
Posts: 3769
Joined: Sat Jul 30, 2016 1:05 pm

sniffer66 wrote:
Fri Dec 04, 2020 9:48 am
I have a large baf with many rules, with a lot of conditions in each rule. The baf can be applied to many matches concurrently. Am I right in thinking that Guardian will stop assessing conditions, and move on to the next rule the first time it fails to match, therefore condition order is useful ?
I've not placed in any particular order as yet but will do if it's going to help.
If one of your conditions aren't matched it won't place a bet but that doesn't necessarily mean it will stop searching for all criteria to be met.

If you have a list of conditions that are in order of importance & its not critical that all of them must be met or the opposite where all of them must be met then you can group conditions.

Essentially, you're putting groups of conditions into containers, you can do this for multiple sets of conditions, some containers (groups) you can then set the rules of these groups to all conditions must be met, one or more must be met, none of these must be met.
sniffer66
Posts: 1679
Joined: Thu May 02, 2019 8:37 am

jamesg46 wrote:
Fri Dec 04, 2020 9:59 am
sniffer66 wrote:
Fri Dec 04, 2020 9:48 am
I have a large baf with many rules, with a lot of conditions in each rule. The baf can be applied to many matches concurrently. Am I right in thinking that Guardian will stop assessing conditions, and move on to the next rule the first time it fails to match, therefore condition order is useful ?
I've not placed in any particular order as yet but will do if it's going to help.
If one of your conditions aren't matched it won't place a bet but that doesn't necessarily mean it will stop searching for all criteria to be met.

If you have a list of conditions that are in order of importance & its not critical that all of them must be met or the opposite where all of them must be met then you can group conditions.

Essentially, you're putting groups of conditions into containers, you can do this for multiple sets of conditions, some containers (groups) you can then set the rules of these groups to all conditions must be met, one or more must be met, none of these must be met.
Thanks. I get that and thats exactly what I'm doing. My question is whether Guardian stops assessing a list of conditions in a rule once it fails to match. Say it fails to match the 1st grouped condition, will it continue to check the rest ? Or is it intelligent enough to move on to the next rule ? If thats the case condition order would help in a very complex automation. I have over 500 rules in this one so anything I can do to speed it up the better
jamesg46
Posts: 3769
Joined: Sat Jul 30, 2016 1:05 pm

sniffer66 wrote:
Fri Dec 04, 2020 10:50 am
jamesg46 wrote:
Fri Dec 04, 2020 9:59 am
sniffer66 wrote:
Fri Dec 04, 2020 9:48 am
I have a large baf with many rules, with a lot of conditions in each rule. The baf can be applied to many matches concurrently. Am I right in thinking that Guardian will stop assessing conditions, and move on to the next rule the first time it fails to match, therefore condition order is useful ?
I've not placed in any particular order as yet but will do if it's going to help.
If one of your conditions aren't matched it won't place a bet but that doesn't necessarily mean it will stop searching for all criteria to be met.

If you have a list of conditions that are in order of importance & its not critical that all of them must be met or the opposite where all of them must be met then you can group conditions.

Essentially, you're putting groups of conditions into containers, you can do this for multiple sets of conditions, some containers (groups) you can then set the rules of these groups to all conditions must be met, one or more must be met, none of these must be met.
Thanks. I get that and thats exactly what I'm doing. My question is whether Guardian stops assessing a list of conditions in a rule once it fails to match. Say it fails to match the 1st grouped condition, will it continue to check the rest ? Or is it intelligent enough to move on to the next rule ? If thats the case condition order would help in a very complex automation. I have over 500 rules in this one so anything I can do to speed it up the better
Right sorry, I'm with you.

I can only assume that if you select "One or more of the conditions in the group must be True" that it would check the whole group and order would be irrelevant.

That's an assumption and now get why you're asking. Sorry sniffer, defo a question for BetAngel.
sniffer66
Posts: 1679
Joined: Thu May 02, 2019 8:37 am

jamesg46 wrote:
Fri Dec 04, 2020 11:04 am
sniffer66 wrote:
Fri Dec 04, 2020 10:50 am
jamesg46 wrote:
Fri Dec 04, 2020 9:59 am


If one of your conditions aren't matched it won't place a bet but that doesn't necessarily mean it will stop searching for all criteria to be met.

If you have a list of conditions that are in order of importance & its not critical that all of them must be met or the opposite where all of them must be met then you can group conditions.

Essentially, you're putting groups of conditions into containers, you can do this for multiple sets of conditions, some containers (groups) you can then set the rules of these groups to all conditions must be met, one or more must be met, none of these must be met.
Thanks. I get that and thats exactly what I'm doing. My question is whether Guardian stops assessing a list of conditions in a rule once it fails to match. Say it fails to match the 1st grouped condition, will it continue to check the rest ? Or is it intelligent enough to move on to the next rule ? If thats the case condition order would help in a very complex automation. I have over 500 rules in this one so anything I can do to speed it up the better
Right sorry, I'm with you.

I can only assume that if you select "One or more of the conditions in the group must be True" that it would check the whole group and order would be irrelevant.

That's an assumption and now get why you're asking. Sorry sniffer, defo a question for BetAngel.
No worries - thanks for the help

It just seems sensible that if I have 20 conditions in a rule (grouped or not) that if it fails to match condition 1 (so the entire rule can never be true) then it stops assessing the other 19 and moves to the next rule

If coding it would be: If x = y Then do a, b & c... Else
Post Reply

Return to “Bet Angel - Automation”