-
Notifications
You must be signed in to change notification settings - Fork 33
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
Update model documentation #759
Update model documentation #759
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some wording/organization suggestions.
Do we want to mention --model-type constraints
?
docs/sphinx_docs/Usage/index.md
Outdated
Since 2.5.0, Alt-Ergo also generates models in the case it concludes on the satisfiability of | ||
the formula. | ||
There is two ways to activate model generation: | ||
Alt-Ergo generates best-effort models in the case it cannot conclude the unsatisfiability of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alt-Ergo generates best-effort models in the case it cannot conclude the unsatisfiability of | |
Alt-Ergo can generate best-effort models in the case it cannot conclude the unsatisfiability of |
docs/sphinx_docs/Usage/index.md
Outdated
Alt-Ergo generates best-effort models in the case it cannot conclude the unsatisfiability of | ||
the context or the validity of a goal. By default, the model format is the SMT format. | ||
|
||
By default the model generation is disable. There is three ways to activate it: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By default the model generation is disable. There is three ways to activate it: | |
Model generation is disabled by default. There are three ways to enable it: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should list the three ways succinctly, then expand on more details for each of them. We also should provide clear guidance on which way is recommended -- I think that's --dump-models
in the native language, and --produce-models
for smtlib2.
docs/sphinx_docs/Usage/index.md
Outdated
|
||
By default the model generation is disable. There is three ways to activate it: | ||
|
||
- with the `--dump-models` option, Alt-Ergo will produce a model after each `goal` in the native language |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
--dump-models
is mostly useful with the native language because SMT-LIB users are more likely to want --produce-models
to enable the standard (check-sat)
+ (get-model)
workflow, so the example should be in the native language maybe?
Also, goal
is confusing in the context of model generation because the formula is negated, we should advertise check_sat
rather than goal
for model generation.
docs/sphinx_docs/Usage/index.md
Outdated
) | ||
``` | ||
|
||
- with the `--produce-models` option, you turn the model generation on. You can display |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think --produce-models
and (set-option :produce-models true)
should be bundled together, because they do the same thing: enable support for (get-model)
, so that's probably the way to explain it (turn it around from "Model generation can be enabled. Once enabled, you can use (get-model)
." into "We support (get-model)
. To use it enable model generation with --produce-models
or (set-option :produce-models true)
.")
docs/sphinx_docs/Usage/index.md
Outdated
You can fine-tune the moment Alt-Ergo computes its models by using the option `--interpretation=VALUE` where VALUE can be: | ||
* "none", to disable model generation (by default); | ||
* "first", to output the first model found; | ||
* "every", to compute a model before each decision; | ||
* "last", to output the last model computed before returning 'unknown'. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure we want to document the --interpretation
option, except maybe advertise --interpretation every
for debugging? If we talk about it, we also should be clear that --interpretation last
is what --dump-models
and --produce-models
do.
Can't comment on --interpretation first
because I am not sure what it does...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree. Actually I hesitated to remove it.
docs/sphinx_docs/Usage/index.md
Outdated
(define-fun c () Int 0) | ||
) | ||
``` | ||
Note: you need to select the SAT solver Tableaux as the model generation is not |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: you need to select the SAT solver Tableaux as the model generation is not | |
*Note*: you need to select the SAT solver Tableaux as the model generation is not |
Also we should make it clear that --sat-solver Tableaux
is only necessary with (set-option :produce-models true)
, it is not needed for --produce-models
or --dump-models
(it is implicit currently but we should make it explicit).
docs/sphinx_docs/Usage/index.md
Outdated
the formula. | ||
There is two ways to activate model generation: | ||
Alt-Ergo generates best-effort models in the case it cannot conclude the unsatisfiability of | ||
the context or the validity of a goal. By default, the model format is the SMT format. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should make it clearer that models are printed in a SMT-LIB compatible format, even if the input problem is in the native language.
Also, we should probably remove the "By default" part -- if we keep it, we should document how to use a different format, and also check that the different forma still works, because I don't think it does...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In my opinion, the SMT-LIB format would be the only one to output models. I will ask to remove the other formats for the next release or we can do it now but if there is no documentation about it, we can keep the code in the 2.5.0.
We didn't test this feature so we shouldn't mention it. |
docs/sphinx_docs/Usage/index.md
Outdated
*Note*: you need to select the SAT solver Tableaux as the model generation is not | ||
supported yet by the other SAT solvers. The options `--dump-models` and `--produce-models` | ||
select the right SAT solver for you. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also needs --frontend dolmen
(which --produce-models
uses, but not --dump-models
).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is still relevant, the text should mention --frontend dolmen
.
docs/sphinx_docs/Usage/index.md
Outdated
`(set-option :produce-models true)` and the options `--sat-solver tableaux` | ||
and `--frontend dolmen`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
`(set-option :produce-models true)` and the options `--sat-solver tableaux` | |
and `--frontend dolmen`. | |
`(set-option :produce-models true)`. This currently requires using the options `--sat-solver tableaux` | |
and `--frontend dolmen`. |
docs/sphinx_docs/Usage/index.md
Outdated
*Note*: you need to select the SAT solver Tableaux as the model generation is not | ||
supported yet by the other SAT solvers. The options `--dump-models` and `--produce-models` | ||
select the right SAT solver for you. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is still relevant, the text should mention --frontend dolmen
.
* Update model documentation * Review changes * Review changes bis * Review changes ter * Clarify the dolmen option
This PR has to be backported on the release 2.5.0.