-
Notifications
You must be signed in to change notification settings - Fork 22
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
Add streamline resource framework #1198
Add streamline resource framework #1198
Conversation
b0cb248
to
38699ef
Compare
Since this PR is so big, I'm splitting off some stand-alone pieces. (Thank you @parkerabercrombie for the suggestion) The first such piece is #1217, which has just the core classes, without particular dynamics types, effects, or resource derivation functions. |
Second piece of this PR to be split off: #1218 This is the unit-awareness library out of this PR, which is mostly self-contained. Only the |
Closing this PR to re-open it as an Aerie branch: #1253 |
Description
Implements a new resource framework, based on the one currently being used by Clipper and lessons learned from an older framework developed for Clipper.
The most important changes, compared to previous resource frameworks, are:
Avoiding that combinatorial explosion makes adding new dynamics types easier. This in turn gives us better modeling fidelity, since we can define and use an unusual dynamics type if needed. For example, we define and regularly use in derivations an exact clock based on
Duration
.errors
resource with additional debugging information attached. Hence errors and partial sim results are visible in the UI.streamline-framework.pdf
Reactions
class, which defines several useful reaction patterns.lessThan
, we have a functionwhen
to turn a boolean resource into the condition "that resource is true". This is especially useful in conjunction with reactions.PolynomialResources
for examples.Verification
Some core classes were unit-tested as needed for debugging. Additionally, Pranav on SRL has been using a preview version of this framework for a few weeks to help flush out bugs and missing features.
Documentation
streamline-framework.pdf
The intended audience for this document is a modeler looking to use the framework. I'd like to convert this document into a set of wiki pages so they're more easily accessible, and expand it with examples and lessons learned by modelers using this or other resource frameworks.
Future work
Fleshing out standard dynamics types, effects, and resource derivation functions as more models use them and find use cases that are missing or poorly supported.
There are known efficiency improvements around task handling and providing expiry information directly to Aerie when sampling resources. These may have small knock-on effects to this framework.
Also, as mentioned briefly above, Aerie's topic metadata feature will likely supplant the labelling system in this framework in the future.