Repository navigation
examples: the rule-check demo behind the clip - #32
Merged
Merged
Conversation
examples/rule-check/demo.py (Python 3.9 standard library, probbit 0.8.2 or later) runs the rule-check demo on the shipped dispatch example: the policy minus its routine habit, the day-0 rule check and test, 300 synthetic rewarded events per individual, day 30, the population line over seeds 0-99, then the same check and events with the habit back. README paragraph with the measured numbers, CHANGELOG line, and a smoke test in the Python suite (4 individuals, 20 events, about 2 s).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The script behind the rule-check clip, on the shipped dispatch example, so anyone can reproduce every number in it.
examples/rule-check/demo.py(Python 3.9 standard library;PROBBIT_BINorprobbiton PATH; probbit 0.8.2 or later; uses onlypersona prove,liveandlive verify)examples/persona/dispatch-policy.yamlminus itsroutine_actshabit (the list item and the comment above it), written to a temp dir.persona prove --props dispatch-props.json, ruleroutine_work_acts), a day-0 test of 10 routine requests, 300 synthetic events in which users praise asking and criticise acting (live, fixed clock,src: human:synthetic), 20 routine requests on day 30, andlive verifyon every strand.--seeds 0-19,--events 300,--population 0-99. The output is identical between runs apart from the elapsed time on the last line.Measured with probbit 0.8.2 (and with a build of main; same output):
Also:
examples/rule-check/README.md; one README paragraph in "Check in CI" ("Reproduce the clip") with these numbers; a CHANGELOG 0.8.3Addedline;python/test_rule_check_demo.py, a smoke test that runs the demo with--seeds 0-3 --events 20(about 2 s). Python suite: 45 OK. No Rust or workflow change; no tag, release or publish.