7.4 Conscript (Original)
7.4.1 Goals and Philosophy
Conscript aims to provide a simpler and streamlined syntax for writing studies compared to congame. There are two dialects of conscript:
Plain conscript, which cannot require Racket functions that we are not providing by default.
conscript/with-require, which allows the user to require.
Since conscript/with-require provides a mechanism to require arbitrary Racket packages, it has essentially the same power as full congame, while conscript can only require a limited set of libraries and functionality of Racket. Due to these limitations, we can allow such studies to be uploaded to a congame server by users with “researcher” accounts, and be run without requiring access to the code repository. This is not possible (out of security concerns) with conscript/with-require studies.
7.4.2 Grammar
| definition | = | (require module ...) | ||||||
| | | (provide id ...) | |||||||
| | | (defvar var-id unique-id-expr) | |||||||
| | |
| |||||||
| | |
| |||||||
| | |
| |||||||
| | | racket-definition | |||||||
| maybe-require-bindings | = | |||||||
| | | #:require-bindings ([local-id parent-id] ...) | |||||||
| maybe-provide-bindings | = | |||||||
| | | #:provide-bindings ([parent-id local-id] ...) | |||||||
| maybe-requires | = | |||||||
| | | #:requires [require-id ...] | |||||||
| maybe-provides | = | |||||||
| | | #:provides [provide-id ...] | |||||||
| transition | = | [step-id --> transition] | ||||||
| | | [step-id --> ,done] | |||||||
| | | [step-id --> ,(lambda () expr)] | |||||||
| | | [step-id --> {step-id expr}] |
7.4.3 How Tos
The Tutorial explains how to use conscript. Here we list some How Tos that are not covered in a terse style, providing examples to achieve a given goal without providing the full study around or explaining how it works.