From b97029d090c779e4a26ff103c2a3c277298af712 Mon Sep 17 00:00:00 2001 From: Oscar Plaisant Date: Tue, 2 Jul 2024 03:58:06 +0200 Subject: [PATCH] add documentation --- README.md | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 1c8c5e7..c823d79 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,41 @@ +# Description of the project + +## General informations + +The execution is managed via the Makefile. + +The python environment is managed via a virtual environment. Its configuration is standard. +If you need to install a new python package, add it to the `requirements.txt` file (using pip syntax). It shoule be installed automatically when you execute the project. Anyway, you can run `make requirements.txt` + +The installation of new databases (from csv) is managed in the Makefile. + + # Configuration The configuration is stored the the `src/config.yaml` file. ## Database-specific configuration -`database_name` should contain the name of the database to use. The database has to be stored in the proper directory structure (See the [Directory structure > Datasets](README.md#datasets)) +`database_name` should contain the name of the database to use. The database has to be stored in the proper directory structure (See the [Directory structure > Datasets](README.md#datasets)). This parameter is case sensitive. + +Each database can have a separated and independent config. +It is inside the key name like the database. +For example, the database named `SSB` has its configuration under the `SSB:` key (and this configuration will be used only when `database_name` is `SSB`). + +The following table explains every parameter that is used in the database specific configuration. + +| key | type | usage | +| --- | ---- | ----- | +| `orders_length` | integer | The length of considered orderings | +| `hypothesis_ordering` | list[str] | The ordering to test the correctness of | +| `parameter` | str | The "parameter" attribute in the query (an attribute in the database). | +| `authorized_parameter_values` | list[str] | The restriction over possibles values in the query's orderings (`WHERE parameter IN authorized_parameter_values`). | +| `summed_attribute` | str | The database attribute that is summed in the aggregation, and used to order the values. | +| `criterion` | list[str] | The list of possibles values for the criteria in the query. When getting a random query, one of these values is chosen randomly for the criteria. | + +The `query_generator` key is a parameter containing the name of the query-generator object that is used when building the query. You should not modify this unless you modify the code accordingly. + # Directory structure of the project