-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Validation steps sometimes do not align in the multiagent #509
Comments
I had a chance to dig into this a bit more, and I realize that there might also be a bug in create_multiagent(agent_1, agent_3) %>%
get_multiagent_report(display_mode = "wide") With environment-insensitive hashing, we get 2 additional steps aligned: As I suspected, the newly aligned steps are those involving # Steps 5 and 6 of agent 1
col_vals_equal(vars(d), vars(d), na_pass = TRUE)
col_vals_between(vars(c), left = vars(a), right = vars(d), na_pass = TRUE)
# Steps 4 and 6 of agent 3
col_vals_equal(
vars(d), vars(d),
na_pass = TRUE
)
col_vals_between(
vars(c),
left = vars(a), right = vars(d),
na_pass = TRUE
) I think this is a bug but just wanted to get a second pair of eyes to confirm this. Relatedly: should we introduce environment-insensitive hashing as an opt-in alternative hashing method, or should that become the new default for future agents? Regardless of what we decide on above, it should be trivial to re-hash pre-existing agents for correct alignment since |
Great work here! I kind of think that environment-insensitive hashing should be the new default. Combined with version info in the hash (great idea by the way), I don’t think users would run into too many problems with these changes. We should also talk about the next release! |
Thanks! Will go ahead with that in the linked PR. And, yes - let me know what we'd need for the release. |
Problem
In the multiagent, we expect validation steps to align when they are equivalent in form (i.e., identical function calls). For example, four agents below all share the
col_vals_not_null(c)
step and the hash for this step is shared, regardless of when/where the step is added to the agent:However, the same step defined in different environments fail to align when they involve special data structures that record the environment. This is the case for:
preconditions
, when the function is defined inline (e.g., using the magrittr syntax. %>% ...
)vars()
) passed tovalues
This raises two concerns:
Possible remedy
digest::sha1()
, to avoid hashing the environmentThe text was updated successfully, but these errors were encountered: