Skip to content
Snippets Groups Projects
Commit 934c4d1a authored by Chen, Eric's avatar Chen, Eric
Browse files

Update README (fix typos)

parent 0e9522cc
No related branches found
No related tags found
No related merge requests found
...@@ -26,7 +26,7 @@ To use the three models at inference time, the script to run is quite similar to ...@@ -26,7 +26,7 @@ To use the three models at inference time, the script to run is quite similar to
Some arguments are common to three models, such as: Some arguments are common to three models, such as:
* **--mode** which is equal to 'inference' at inference time * **--mode** which is equal to 'inference' at inference time
* **--ckpt_name** to load an already fine-tuned model * **--ckpt_name** to load an already fine-tuned model
* **--decoding** which can take as values 'greedy', 'beam', 'top_k' or nucleus representing respectively response generation strategies such as the greedy approach, beam search, top_k or nucleus sampling * **--decoding** which can take as values 'greedy', 'beam', 'top_k' or 'nucleus' representing respectively response generation strategies such as the greedy approach, beam search, top_k or nucleus sampling
For the GPT-2 model, we can run the following script which includes the **--max_time** argument that represents the number of successive messages considered as inputs to generate a reply. For the GPT-2 model, we can run the following script which includes the **--max_time** argument that represents the number of successive messages considered as inputs to generate a reply.
``` ```
...@@ -43,7 +43,7 @@ python3 models/conditional_gpt2_model.py \ ...@@ -43,7 +43,7 @@ python3 models/conditional_gpt2_model.py \
--mode='inference' \ --mode='inference' \
--ckpt_name=best_ckpt \ --ckpt_name=best_ckpt \
--decoding=top_k \ --decoding=top_k \
--age='over 18' --age='over 18' \
--gender='male' \ --gender='male' \
--topic='anxiety' --topic='anxiety'
``` ```
...@@ -51,7 +51,7 @@ python3 models/conditional_gpt2_model.py \ ...@@ -51,7 +51,7 @@ python3 models/conditional_gpt2_model.py \
For StyleGPT2, the model can generate replies based on the chosen style token thanks to the **--style_label** argument. For StyleGPT2, the model can generate replies based on the chosen style token thanks to the **--style_label** argument.
``` ```
python3 models/style_tokens_model/run_styleGPT2.py \ python3 models/style_tokens_model/run_styleGPT2.py \
--mode='inference' --mode='inference' \
--ckpt_name=best_ckpt \ --ckpt_name=best_ckpt \
--decoding=greedy \ --decoding=greedy \
--style_label=1 --style_label=1
...@@ -66,11 +66,11 @@ The directory 'pre-processing' includes all the pre-processing techniques perfor ...@@ -66,11 +66,11 @@ The directory 'pre-processing' includes all the pre-processing techniques perfor
## Clustering ## Clustering
The directory 'clustering' is dedicated to the generation of conversation embeddings and cluster analysis on them: The directory 'clustering' is dedicated to the generation of conversation embeddings and cluster analysis on them:
* clustering.ipynb is used to perform cluster analysis on features created on simple models such as TF-IDF but also to prepare the data to be used to generate embeddings using transformer methods * clustering.ipynb is used to perform cluster analysis on features created with simple models such as TF-IDF but also to prepare the data to be used to generate embeddings using transformer methods
* gpt2_features.py allows the generation of GPT-2 embeddings for each conversation * gpt2_features.py allows the generation of GPT-2 embeddings for each conversation
* gpt2_emb_clusters.py aims to perform cluster analysis on these GPT-2 embeddings to extract some style tokens. * gpt2_emb_clusters.py aims to perform cluster analysis on these GPT-2 embeddings to extract some style tokens.
## Helpers ## Helpers
The directory 'helpers' contains useful methods for training models such as providing the pre-processed dataset with custom_data.py and extracting information from surveys such conversation topics, the age and the gender of the texter. The directory 'helpers' contains useful methods for training models such as providing the pre-processed dataset with custom_data.py and extracting information from surveys such as conversation topics, the age and the gender of the texter.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment