You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+16-18Lines changed: 16 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,9 @@
1
1
# Chronosymbolic Learning
2
-
Artifact for paper "Chronosymbolic Learning: Efficient CHC Solving with Symbolic Reasoning and Inductive Learning"
2
+
Artifact for the paper "Chronosymbolic Learning: Efficient CHC Solving with Symbolic Reasoning and Inductive Learning"
3
3
4
-
- See `./experiment` for some important results and configurations
4
+
- See `./experiment` for some significant results and configurations
5
5
6
-
- See `./examples` for examples on how our tool works
6
+
- See `./examples` for examples of how our tool works
7
7
8
8
## Requirement (To set up our environment)
9
9
Python (3.7.0 or higher, and anaconda recommended)
@@ -16,7 +16,7 @@ pip install -r requirements.txt
16
16
17
17
May have to manually set up `PYTHONPATH` and `PATH` properly, `PYTHONPATH=$Z3_BIN/python`, `PATH=$PATH:$Z3_BIN`
18
18
19
-
Then, prepare the dataset following the instruction in `data/` folder.
19
+
Then, prepare the dataset following the instructions in `data/` folder.
20
20
21
21
## Chronosymbolic Learning
22
22
- Support SMT-LIB2 format (check-sat) and Datalog format (rule-query)
@@ -33,33 +33,31 @@ Then, prepare the dataset following the instruction in `data/` folder.
33
33
34
34
- Run: `python test.py` with the parameters below:
35
35
36
-
- Specify instance file name using `-f FILE_NAME`
36
+
- Specify instance file name using `-f FILE_NAME` to run a single instance
37
37
38
-
- Specify log file (which records how the tool solves the CHC system) using `-l FILE_NAME`
38
+
- Specify the log file (which records how the tool solves the CHC system) using `-l FILE_NAME`
39
39
40
-
- Specify directory name using `-r -f DIR_NAME` (logs are automatically generated in log/DIR_NAME)
40
+
- Specify directory name using `-r -f DIR_NAME`to run a test suite (logs are automatically generated in log/DIR_NAME)
41
41
- e.g. `python test.py -f tests/safe/ -a -r -v -t 360 -o result/result.log`
42
42
43
-
- Or specify a file list using `-b -f FILELIST` (run files specified in the filelist, whose format is the same as `tests/filtered`)
43
+
- Or specify a file list using `-b -f FILELIST` (run files specified in the file list, whose format is the same as `tests/filtered`)
44
44
- e.g. `python test.py -a -v -b -f tests/filtered -a -t 360 -o result/result.log`
45
45
46
46
- Increase log file verbosity using `-v` (not effective in output on screen)
47
47
48
48
- Adjust timeout using `-t TIMEOUT`, only effective in directory mode
49
49
50
-
- Specify overall result file using `-o FILE_NAME`, export a result csv (with success and timing statistics) with the same file name using `-a`
50
+
- Specify the overall result file using `-o FILE_NAME`, export a result CSV (with success and timing statistics) with the same file name using `-a`
51
51
52
-
-Individual LOG files will be outputed in `./log/YOUR_INSTANCE_PATH`
52
+
-Start testing from the file index k in the folder `-s K` (`K` is the index starting from zero)
53
53
54
-
- Start testing from the file index k in the folder `-s k` (index start from zero)
55
-
56
-
- If you want to run multiple instances, make sure using different `FILE_NAME`-s in the config file to avoid clash (`config.yaml` in default)
54
+
- If you want to run multiple instances, make sure to use different `FILE_NAME`-s in the config file to avoid clash (`config.yaml` in default)
57
55
58
56
- More options see `--help`
59
57
60
58
# To reproduce Chronosymbolic-single
61
59
62
-
Please refer to the configuration in `./experiment/result_summary.log`. The default config should also be decent. Even fixed random seeds can cause some minor randomness that may slightly affect the performance.
60
+
Please refer to the configuration in `./experiment/result_summary.log`. The default config should also be decent. Even fixed random seeds can cause minor randomness that may slightly affect the performance.
@@ -74,22 +72,22 @@ Please refer to the configuration in `./experiment/result_summary.log`. The defa
74
72
75
73
- Specify the path of z3 (with GSpacer) binary in `utils/run_spacer.py` and `utils/run_spacer_filtered.py`
76
74
77
-
- Specify a folder name and run `utils/run_spacer.py` or specify a filelist name and run `utils/run_spacer_filtered.py`
75
+
- Specify a folder name and run `utils/run_spacer.py` or specify a file list name and run `utils/run_spacer_filtered.py`
78
76
79
77
- Enable GSpacer: `enable_global_guidance = 1`
80
78
81
79
## LinearArbitrary and Freqhorn
82
80
Refer to [LinearArbitrary](https://github.com/GaloisInc/LinearArbitrary-SeaHorn/tree/master/test) and [Freqhorn](https://github.com/freqhorn/freqhorn)
83
81
For LinearArbitrary, you can also try our optimized data-driven learner implementation (set `ClassAgent = Chronosymbolic` to `ClassAgent = DataDrivenLearner` in `test.py` and run it in the same way as Chronosymbolic does)
84
82
85
-
## Manually "guess" an inductive invariant
83
+
## Manually "guess" an inductive invariant (hard to scale up)
86
84
In `test.py``guess_manually` function:
87
85
- Modify `s = 'v_0 == v_1'` to indicate the inductive invariant
88
86
89
-
- Modify `db = load_horn_db_from_file("/home/ssr/chc-tools/chctools/NL/nl-1-chc.smt2", z3.main_ctx())` to indicate SMTLIB2 file name
87
+
- Modify `db = load_horn_db_from_file(args.file_name, z3.main_ctx())` or pass the parameter in through command line to indicate SMTLIB2 file name
90
88
91
89
## Enumeration
92
-
- A simple implementation of enumeration-based invariant synthesizer
90
+
- A simple implementation of an enumeration-based invariant synthesizer
93
91
94
92
- Run `learner/enumerate.py` that enumerates through a context-free grammar
0 commit comments