Repository: RasaHQ/rasa
Pull request: Add recipe to example bot configs.
Closes #9886.

Problem statement:
Update bot examples in repository to use the `DefaultV1.Recipe`
**Overview**
We use the `DefaultV1Recipe` to convert our current config format to the graph architecture. We choose this recipe by default but print a warning if the `recipe` key is not defined in the config file. 

**Definition of Done**
- [ ] update all configs in example projects to have the `recipe` key specified in their config
- [ ] make sure all examples bots work as expected

Hints from issue discussion:

Commit message: Merge branch 'main' into add_recipe_to_example_bot_configs

Patch to review:
diff --git a/data/configs_for_docs/example_for_suggested_config.yml b/data/configs_for_docs/example_for_suggested_config.yml
index d8de71b0278a..d12b0f676380 100644
--- a/data/configs_for_docs/example_for_suggested_config.yml
+++ b/data/configs_for_docs/example_for_suggested_config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/configs_for_docs/example_for_suggested_config_after_train.yml b/data/configs_for_docs/example_for_suggested_config_after_train.yml
index 517fb78418c2..4055cd5f425a 100644
--- a/data/configs_for_docs/example_for_suggested_config_after_train.yml
+++ b/data/configs_for_docs/example_for_suggested_config_after_train.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test/config_embedding_test.yml b/data/test/config_embedding_test.yml
index 1c9eb116fb09..01837c12ebc9 100644
--- a/data/test/config_embedding_test.yml
+++ b/data/test/config_embedding_test.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 - name: "CountVectorsFeaturizer"
diff --git a/data/test_config/config_crf_no_pattern_feature.yml b/data/test_config/config_crf_no_pattern_feature.yml
index cac2cf1a96a2..ee673b11073d 100644
--- a/data/test_config/config_crf_no_pattern_feature.yml
+++ b/data/test_config/config_crf_no_pattern_feature.yml
@@ -1,7 +1,8 @@
+recipe: default.v1
 language: en
 pipeline:
   - name: "WhitespaceTokenizer"
   - name: "RegexFeaturizer"
   - name: "CRFEntityExtractor"
     features: [['low', 'title', 'upper'],['bias', 'low', 'digit'],['low', 'title', 'upper']]
-  - name: "EntitySynonymMapper"
\ No newline at end of file
+  - name: "EntitySynonymMapper"
diff --git a/data/test_config/config_crf_no_regex.yml b/data/test_config/config_crf_no_regex.yml
index 3d916ede50d2..14c198d37384 100644
--- a/data/test_config/config_crf_no_regex.yml
+++ b/data/test_config/config_crf_no_regex.yml
@@ -1,5 +1,6 @@
+recipe: default.v1
 language: en
 pipeline:
   - name: "WhitespaceTokenizer"
   - name: "CRFEntityExtractor"
-  - name: "EntitySynonymMapper"
\ No newline at end of file
+  - name: "EntitySynonymMapper"
diff --git a/data/test_config/config_crf_no_synonyms.yml b/data/test_config/config_crf_no_synonyms.yml
index 543bc85a966c..5bc65bd26801 100644
--- a/data/test_config/config_crf_no_synonyms.yml
+++ b/data/test_config/config_crf_no_synonyms.yml
@@ -1,4 +1,5 @@
+recipe: default.v1
 language: en
 pipeline:
   - name: "WhitespaceTokenizer"
-  - name: "CRFEntityExtractor"
\ No newline at end of file
+  - name: "CRFEntityExtractor"
diff --git a/data/test_config/config_defaults.yml b/data/test_config/config_defaults.yml
index 098e1f08c39c..91a6056c1d99 100644
--- a/data/test_config/config_defaults.yml
+++ b/data/test_config/config_defaults.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline: []
 # # No configuration for the NLU pipeline was provided. The following default pipeline was used to train your model.
diff --git a/data/test_config/config_empty_en.yml b/data/test_config/config_empty_en.yml
index cfdf8c427e3d..c4eb18c351f9 100644
--- a/data/test_config/config_empty_en.yml
+++ b/data/test_config/config_empty_en.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 policies:
diff --git a/data/test_config/config_empty_en_after_dumping.yml b/data/test_config/config_empty_en_after_dumping.yml
index 1151d723446d..eeb382417117 100644
--- a/data/test_config/config_empty_en_after_dumping.yml
+++ b/data/test_config/config_empty_en_after_dumping.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 # # No configuration for the NLU pipeline was provided. The following default pipeline was used to train your model.
diff --git a/data/test_config/config_empty_en_after_dumping_core.yml b/data/test_config/config_empty_en_after_dumping_core.yml
index 8f5e06bd33a5..8519cf2e03c3 100644
--- a/data/test_config/config_empty_en_after_dumping_core.yml
+++ b/data/test_config/config_empty_en_after_dumping_core.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 policies:
diff --git a/data/test_config/config_empty_en_after_dumping_nlu.yml b/data/test_config/config_empty_en_after_dumping_nlu.yml
index 66a77530f4a2..298d7165fbd6 100644
--- a/data/test_config/config_empty_en_after_dumping_nlu.yml
+++ b/data/test_config/config_empty_en_after_dumping_nlu.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 # # No configuration for the NLU pipeline was provided. The following default pipeline was used to train your model.
diff --git a/data/test_config/config_language_only.yml b/data/test_config/config_language_only.yml
index d867310af68b..72d709f118a6 100644
--- a/data/test_config/config_language_only.yml
+++ b/data/test_config/config_language_only.yml
@@ -1 +1,2 @@
+recipe: default.v1
 language: en
diff --git a/data/test_config/config_pipeline_empty.yml b/data/test_config/config_pipeline_empty.yml
index d314c6a4e9d9..fcd032b8e7ac 100644
--- a/data/test_config/config_pipeline_empty.yml
+++ b/data/test_config/config_pipeline_empty.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_config/config_pipeline_missing.yml b/data/test_config/config_pipeline_missing.yml
index b31fa1c4d1e4..8247af10e1ed 100644
--- a/data/test_config/config_pipeline_missing.yml
+++ b/data/test_config/config_pipeline_missing.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 policies:
diff --git a/data/test_config/config_policies_empty.yml b/data/test_config/config_policies_empty.yml
index 7c201969d7a4..ed1ec9bb370d 100644
--- a/data/test_config/config_policies_empty.yml
+++ b/data/test_config/config_policies_empty.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_config/config_policies_missing.yml b/data/test_config/config_policies_missing.yml
index 8cf8f6d7954d..c89741e1ac5b 100644
--- a/data/test_config/config_policies_missing.yml
+++ b/data/test_config/config_policies_missing.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_config/config_response_selector_minimal.yml b/data/test_config/config_response_selector_minimal.yml
index a99e2904b370..5f1dcde027b2 100644
--- a/data/test_config/config_response_selector_minimal.yml
+++ b/data/test_config/config_response_selector_minimal.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
    - name: WhitespaceTokenizer
diff --git a/data/test_config/config_spacy_entity_extractor.yml b/data/test_config/config_spacy_entity_extractor.yml
index b8617a035dab..0843360a62d0 100644
--- a/data/test_config/config_spacy_entity_extractor.yml
+++ b/data/test_config/config_spacy_entity_extractor.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
     - name: "SpacyNLP"
@@ -6,4 +7,4 @@ pipeline:
     - name: "SpacyFeaturizer"
     - name: "RegexFeaturizer"
     - name: "SpacyEntityExtractor"
-    - name: "EntitySynonymMapper"
\ No newline at end of file
+    - name: "EntitySynonymMapper"
diff --git a/data/test_config/config_with_comment_between_suggestions.yml b/data/test_config/config_with_comment_between_suggestions.yml
index 31ba221d8fec..bb4156a8d4e8 100644
--- a/data/test_config/config_with_comment_between_suggestions.yml
+++ b/data/test_config/config_with_comment_between_suggestions.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 # # No configuration for the NLU pipeline was provided. The following default pipeline was used to train your model.
diff --git a/data/test_config/config_with_comments.yml b/data/test_config/config_with_comments.yml
index 195ee51fee4b..a83d3d9a93d3 100644
--- a/data/test_config/config_with_comments.yml
+++ b/data/test_config/config_with_comments.yml
@@ -1,4 +1,5 @@
 # here is some comment
+recipe: default.v1
 language: en
 
 # another comment
diff --git a/data/test_config/config_with_comments_after_dumping.yml b/data/test_config/config_with_comments_after_dumping.yml
index 29ae5e01c60a..c3dde4750acd 100644
--- a/data/test_config/config_with_comments_after_dumping.yml
+++ b/data/test_config/config_with_comments_after_dumping.yml
@@ -1,4 +1,5 @@
 # here is some comment
+recipe: default.v1
 language: en
 
 # another comment
diff --git a/data/test_config/stack_config.yml b/data/test_config/stack_config.yml
index d02a174d7b0a..eef7ebffa96c 100644
--- a/data/test_config/stack_config.yml
+++ b/data/test_config/stack_config.yml
@@ -1,5 +1,6 @@
 # Configuration for Rasa NLU.
 # https://rasa.com/docs/rasa/components
+recipe: default.v1
 language: en
 pipeline:
   - name: KeywordIntentClassifier
diff --git a/data/test_e2ebot/config.yml b/data/test_e2ebot/config.yml
index d04a947bf677..1e4f13b08cab 100644
--- a/data/test_e2ebot/config.yml
+++ b/data/test_e2ebot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
   - name: WhitespaceTokenizer
diff --git a/data/test_moodbot/config.yml b/data/test_moodbot/config.yml
index a71877e3de47..421f3f143cbb 100644
--- a/data/test_moodbot/config.yml
+++ b/data/test_moodbot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_moodbot/unexpected_intent_policy_config.yml b/data/test_moodbot/unexpected_intent_policy_config.yml
index 666a32c5e263..d74d96cdaa04 100644
--- a/data/test_moodbot/unexpected_intent_policy_config.yml
+++ b/data/test_moodbot/unexpected_intent_policy_config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_multi_domain/config.yml b/data/test_multi_domain/config.yml
index dba37fe301bd..b16f679fd3a9 100644
--- a/data/test_multi_domain/config.yml
+++ b/data/test_multi_domain/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_multi_domain/data/MoodBot/config.yml b/data/test_multi_domain/data/MoodBot/config.yml
index 9280fe205096..4b814827f485 100644
--- a/data/test_multi_domain/data/MoodBot/config.yml
+++ b/data/test_multi_domain/data/MoodBot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline: "pretrained_embeddings_spacy"
@@ -7,4 +8,4 @@ policies:
   - name: TEDPolicy
 
 imports:
-- ../GreetBot
\ No newline at end of file
+- ../GreetBot
diff --git a/data/test_multiproject/config.yml b/data/test_multiproject/config.yml
index d59086ca1247..973796932ef8 100644
--- a/data/test_multiproject/config.yml
+++ b/data/test_multiproject/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_response_selector_bot/config.yml b/data/test_response_selector_bot/config.yml
index 48cf2d3d246d..b3c1718329c9 100644
--- a/data/test_response_selector_bot/config.yml
+++ b/data/test_response_selector_bot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_restaurantbot/config.yml b/data/test_restaurantbot/config.yml
index e93ea37d13d0..cb0a7604a9d0 100644
--- a/data/test_restaurantbot/config.yml
+++ b/data/test_restaurantbot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/data/test_spacybot/config.yml b/data/test_spacybot/config.yml
index 347930eedbfa..d6c77cd06378 100644
--- a/data/test_spacybot/config.yml
+++ b/data/test_spacybot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/docs/static/spec/rasa.yml b/docs/static/spec/rasa.yml
index 3542769a0e74..a52425b8b129 100644
--- a/docs/static/spec/rasa.yml
+++ b/docs/static/spec/rasa.yml
@@ -1551,6 +1551,7 @@ components:
       type: string
       description: Rasa config in plain text
       example: >-
+        recipe: default.v1
         language: en
 
         pipeline: supervised_embeddings
diff --git a/examples/concertbot/config.yml b/examples/concertbot/config.yml
index 614da5a99e27..13f82ae2d57a 100644
--- a/examples/concertbot/config.yml
+++ b/examples/concertbot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/examples/e2ebot/config.yml b/examples/e2ebot/config.yml
index 50eb460d8c7e..2afdf7b2f1fa 100644
--- a/examples/e2ebot/config.yml
+++ b/examples/e2ebot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
   - name: WhitespaceTokenizer
diff --git a/examples/formbot/config.yml b/examples/formbot/config.yml
index 0db27fda9552..78d715f71eda 100644
--- a/examples/formbot/config.yml
+++ b/examples/formbot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/examples/knowledgebasebot/config.yml b/examples/knowledgebasebot/config.yml
index f2e29f8f3464..acf7f6ec0dde 100644
--- a/examples/knowledgebasebot/config.yml
+++ b/examples/knowledgebasebot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/examples/moodbot/config.yml b/examples/moodbot/config.yml
index 69975b758722..baf6adc2a5df 100644
--- a/examples/moodbot/config.yml
+++ b/examples/moodbot/config.yml
@@ -1,8 +1,10 @@
+recipe: default.v1
 language: en
 
 pipeline:
   - name: "SpacyNLP"
     model: "en_core_web_md"
+  - name: "SpacyPreprocessor"
   - name: "SpacyTokenizer"
   - name: "SpacyFeaturizer"
   - name: "DIETClassifier"
diff --git a/examples/reminderbot/config.yml b/examples/reminderbot/config.yml
index 86c4d7171e9a..00b981d43630 100644
--- a/examples/reminderbot/config.yml
+++ b/examples/reminderbot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 pipeline:
 - name: "WhitespaceTokenizer"
diff --git a/examples/responseselectorbot/config.yml b/examples/responseselectorbot/config.yml
index 48e02fa096a3..2652413756fb 100644
--- a/examples/responseselectorbot/config.yml
+++ b/examples/responseselectorbot/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/examples/rules/config.yml b/examples/rules/config.yml
index 573961b93c14..05b833204711 100644
--- a/examples/rules/config.yml
+++ b/examples/rules/config.yml
@@ -1,3 +1,4 @@
+recipe: default.v1
 language: en
 
 pipeline:
diff --git a/tests/shared/utils/test_io.py b/tests/shared/utils/test_io.py
index 8c2e5cf0c993..ceb023160568 100644
--- a/tests/shared/utils/test_io.py
+++ b/tests/shared/utils/test_io.py
@@ -444,6 +444,7 @@ def test_validate_config_file(config_file: Path):
 def test_validate_config_file_with_extra_keys(tmp_path: Path):
     content = textwrap.dedent(
         """
+        recipe: default.v1
         language: en
         pipeline:
         policies:
diff --git a/tests/test_server.py b/tests/test_server.py
index 28550850d35d..d478e0d7fd39 100644
--- a/tests/test_server.py
+++ b/tests/test_server.py
@@ -598,6 +598,7 @@ async def test_train_with_yaml(
  utter_greet:
  - text: Hi
 
+recipe: default.v1
 language: en
 
 policies:
@@ -637,6 +638,7 @@ async def test_train_with_yaml_with_params(
 intents: []
 nlu: []
 responses: {}
+recipe: default.v1
 language: en
 policies: []
 pipeline: []


Code review comments:
diff_hunk: @@ -1,8 +1,10 @@
+recipe: default.v1
 language: en
 
 pipeline:
   - name: "SpacyNLP"
     model: "en_core_web_md"
+  - name: "SpacyPreprocessor"
path: examples/moodbot/config.yml
text: @user1:
```suggestion
```