{"id":2701,"date":"2022-11-19T01:33:38","date_gmt":"2022-11-19T01:33:38","guid":{"rendered":"http:\/\/optimumsportsperformance.com\/blog\/?p=2701"},"modified":"2022-11-19T15:06:13","modified_gmt":"2022-11-19T15:06:13","slug":"tidymodels-train-test-set-without-initial_split","status":"publish","type":"post","link":"https:\/\/optimumsportsperformance.com\/blog\/tidymodels-train-test-set-without-initial_split\/","title":{"rendered":"tidymodels train\/test set without initial_split"},"content":{"rendered":"<p><strong>Introduction<\/strong><\/p>\n<p>In {<strong>tidymodels<\/strong>} it is often recommended to split the data using the <strong>initial_split()<\/strong> function. This is useful when you are interested in a random sample from the data. As such, the <strong>initial_split()<\/strong> function produces a list of information that is used downstream in the model fitting and model prediction process. However, sometimes we have data that we want to fit specifically to a training set and then test on data set that we define. For example, training a model on years 2010-2015 and then testing a model on years 2016-2019.<\/p>\n<p>This tutorial walks through creating your own bespoke train\/test sets, fitting a model, and then making predictions, while circumventing the issues that may arise from not having the <strong>initial_split()<\/strong> object.<\/p>\n<p><strong>Load the AirQuality Data<\/strong><\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\nlibrary(tidyverse)\r\nlibrary(tidymodels)\r\nlibrary(datasets)\r\n\r\ndata(&quot;airquality&quot;)\r\n\r\nairquality %&gt;% count(Month)\r\n<\/pre>\n<p>&nbsp;<\/p>\n<p><strong>Train\/Test Split<\/strong><\/p>\n<p>We want to use `tidymodels` to build a model on months 5-7 and test the model on months 8 and 9?<\/p>\n<p>Currently the <strong>initial_split()<\/strong> function only takes a random sample of the data.<\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\nset.seed(192)\r\nsplit_rand &lt;- initial_split(airquality ,prop = 3\/4)\r\nsplit_rand\r\n\r\ntrain_rand &lt;- training(split_rand)\r\ntest_rand &lt;- testing(split_rand) train_rand %&gt;%\r\n  count(Month)\r\n\r\ntest_rand %&gt;%\r\n  count(Month)\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.03.58-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-2702\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.03.58-PM.png\" alt=\"\" width=\"467\" height=\"524\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.03.58-PM.png 792w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.03.58-PM-268x300.png 268w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.03.58-PM-768x861.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.03.58-PM-624x700.png 624w\" sizes=\"auto, (max-width: 467px) 100vw, 467px\" \/><\/a><\/p>\n<p>The <strong>strat<\/strong> argument within <strong>initial_split()<\/strong> only ensures that we get an even sample across our <strong>strat<\/strong> (in this case, Month).<\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\nsplit_strata &lt;- initial_split(airquality ,prop = 3\/4, strata = Month)\r\nsplit_strata\r\n\r\ntrain_strata &lt;- training(split_strata)\r\ntest_strata &lt;- testing(split_strata) train_strata %&gt;%\r\n  count(Month)\r\n\r\ntest_strata %&gt;%\r\n  count(Month)\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-2703\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM-1024x839.png\" alt=\"\" width=\"450\" height=\"369\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM-1024x839.png 1024w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM-300x246.png 300w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM-768x629.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM-624x511.png 624w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.05.25-PM.png 1038w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/a><\/p>\n<ul>\n<li>Create our own train\/test split, unique to the conditions we are interested in specifying.<\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\ntrain &lt;- airquality %&gt;%\r\n  filter(Month &lt; 8)\r\n\r\ntest &lt;- airquality %&gt;%\r\n  filter(Month &gt;= 8)\r\n<\/pre>\n<ul>\n<li>Create 5-fold cross validation for tuning our random forest model<\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\nset.seed(567)\r\ncv_folds &lt;- vfold_cv(data = train, v = 5)\r\n<\/pre>\n<p><strong>Set up the model specification<\/strong><\/p>\n<ul>\n<li>We will use random forest<\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\n## model specification\r\naq_rf &lt;- rand_forest(mtry = tune()) %&gt;%\r\n  set_engine(&quot;randomForest&quot;) %&gt;%\r\n  set_mode(&quot;regression&quot;)\r\n<\/pre>\n<p><strong>Create a model recipe<\/strong><\/p>\n<p>There are some NA&#8217;s in a few of the columns. We will impute those and we will also normalize the three numeric predictors in our model.<\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\n## recipe\r\naq_recipe &lt;- recipe( Ozone ~ Solar.R + Wind + Temp + Month, data = train ) %&gt;%\r\nstep_impute_median(Ozone, Solar.R) %&gt;%\r\nstep_normalize(Solar.R, Wind, Temp)\r\n\r\naq_recipe\r\n\r\n## check that normalization and NA imputation occurred in the training data\r\naq_recipe %&gt;%\r\nprep() %&gt;%\r\nbake(new_data = NULL)\r\n\r\n## check that normalization and NA imputation occurred in the testing data\r\naq_recipe %&gt;%\r\nprep() %&gt;%\r\nbake(new_data = test)\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-large wp-image-2704\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM-941x1024.png\" alt=\"\" width=\"625\" height=\"680\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM-941x1024.png 941w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM-276x300.png 276w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM-768x835.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM-624x679.png 624w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.16.30-PM.png 1162w\" sizes=\"auto, (max-width: 625px) 100vw, 625px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p><strong>Set up workflow<\/strong><\/p>\n<ul>\n<li>Compile all of our components above together into a single workflow.<\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\n## Workflow\r\naq_workflow &lt;- workflow() %&gt;%\r\nadd_model(aq_rf) %&gt;%\r\nadd_recipe(aq_recipe)\r\n\r\naq_workflow\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-large wp-image-2705\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM-1024x370.png\" alt=\"\" width=\"625\" height=\"226\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM-1024x370.png 1024w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM-300x108.png 300w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM-768x278.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM-624x226.png 624w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.19.13-PM.png 1848w\" sizes=\"auto, (max-width: 625px) 100vw, 625px\" \/><\/a><\/p>\n<p><strong>Tune the random forest model<\/strong><\/p>\n<ul>\n<li>We set up one hyperparmaeter to tune, <strong>mtry<\/strong>, in our model specification.<\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\n## tuning grid\r\nrf_tune_grid &lt;- grid_regular(\r\n  mtry(range = c(1, 4))\r\n)\r\n\r\nrf_tune_grid\r\n\r\nrf_tune &lt;- tune_grid(\r\n  aq_workflow,\r\n  resamples = cv_folds,\r\n  grid = rf_tune_grid\r\n)\r\n\r\nrf_tune\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.20.44-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-2706\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.20.44-PM.png\" alt=\"\" width=\"403\" height=\"408\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.20.44-PM.png 856w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.20.44-PM-297x300.png 297w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.20.44-PM-768x777.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.20.44-PM-624x631.png 624w\" sizes=\"auto, (max-width: 403px) 100vw, 403px\" \/><\/a><\/p>\n<p><strong>Get the model with the optimum mtry<\/strong><\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\n## view model metrics\r\ncollect_metrics(rf_tune)\r\n\r\n## Which is the best model?\r\nselect_best(rf_tune, &quot;rmse&quot;)\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-2707\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM-1024x625.png\" alt=\"\" width=\"527\" height=\"321\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM-1024x625.png 1024w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM-300x183.png 300w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM-768x469.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM-624x381.png 624w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.21.58-PM.png 1032w\" sizes=\"auto, (max-width: 527px) 100vw, 527px\" \/><\/a><\/p>\n<ul>\n<li>Looks like an <em><strong>mtry = 1<\/strong><\/em> was the best option as it had the lowest RMSE and highest r-squared.<\/li>\n<\/ul>\n<p><strong>Fit the final tuned model<\/strong><\/p>\n<ul>\n<li>model specification with <em><strong>mtry = 1<\/strong><\/em><\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\naq_rf_tuned &lt;- rand_forest(mtry = 1) %&gt;%\r\n  set_engine(&quot;randomForest&quot;) %&gt;%\r\n  set_mode(&quot;regression&quot;)\r\n<\/pre>\n<p><em>Tuned Workflow<\/em><\/p>\n<ul>\n<li>the recipe steps are the same<\/li>\n<\/ul>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\naq_workflow_tuned &lt;- workflow() %&gt;%\r\n  add_model(aq_rf_tuned) %&gt;%\r\n  add_recipe(aq_recipe) \r\n\r\naq_workflow_tuned\r\n<\/pre>\n<p><em>Final Fit<\/em><\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\naq_final &lt;- aq_workflow_tuned %&gt;%\r\n  fit(data = train)\r\n<\/pre>\n<p><em>Evaluate the final model<\/em><\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\naq_final %&gt;%\r\n  extract_fit_parsnip()\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-large wp-image-2708\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM-1024x416.png\" alt=\"\" width=\"625\" height=\"254\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM-1024x416.png 1024w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM-300x122.png 300w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM-768x312.png 768w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM-624x254.png 624w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.25.22-PM.png 1112w\" sizes=\"auto, (max-width: 625px) 100vw, 625px\" \/><\/a><\/p>\n<p><strong>Predict on test set<\/strong><\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\nozone_pred_rf &lt;- predict(\r\naq_final,\r\ntest\r\n)\r\n\r\nozone_pred_rf\r\n<\/pre>\n<p><a href=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.26.33-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-2709\" src=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.26.33-PM.png\" alt=\"\" width=\"260\" height=\"379\" srcset=\"https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.26.33-PM.png 358w, https:\/\/optimumsportsperformance.com\/blog\/wp-content\/uploads\/2022\/11\/Screen-Shot-2022-11-18-at-5.26.33-PM-206x300.png 206w\" sizes=\"auto, (max-width: 260px) 100vw, 260px\" \/><\/a><\/p>\n<p><strong>Conclusion<\/strong><\/p>\n<p>Pretty easy to fit a model to bespoke train\/test split that doesn&#8217;t require {<strong>tidymodels<\/strong>} <strong>initial_split() <\/strong>function. Simply construct the model, do any hyperparameter tuning, fit a final model, and make predictions.<\/p>\n<p>Below I&#8217;ve added the code for anyone interested in seeing this same process using linear regression, which is easier than the random forest model since there are no hyperparameters to tune.<\/p>\n<p>If you&#8217;d like to have the full code in one concise place, check out my <span style=\"color: #0000ff;\"><strong><a style=\"color: #0000ff;\" href=\"https:\/\/github.com\/pw2\/tidymodels_template\/blob\/main\/tidymodels%20train-test%20set%20without%20initial_split.Rmd\">GITHUB page<\/a><\/strong><\/span>.<\/p>\n<p><strong>Doing the same tasks with linear regression<\/strong><\/p>\n<ul>\n<li>This is a bit easier since it doesn&#8217;t require hyperparameter tuning.<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<pre class=\"brush: r; title: ; notranslate\" title=\"\">\r\n## Model specification\r\naq_linear &lt;- linear_reg() %&gt;%\r\n  set_engine(&quot;lm&quot;) %&gt;%\r\n  set_mode(&quot;regression&quot;)\r\n\r\n## Model Recipe (same as above)\r\naq_recipe &lt;- recipe( Ozone ~ Solar.R + Wind + Temp + Month, data = train ) %&gt;%\r\n  step_impute_median(Ozone, Solar.R) %&gt;% \r\n  step_normalize(Solar.R, Wind, Temp)\r\n\r\n## Workflow\r\naq_wf_linear &lt;- workflow() %&gt;%\r\n  add_recipe(aq_recipe) %&gt;%\r\n  add_model(aq_linear)\r\n\r\n## Fit the model to the training data\r\nlm_fit &lt;- aq_wf_linear %&gt;%\r\n  fit(data = train)\r\n\r\n## Get the model output\r\nlm_fit %&gt;%\r\n  extract_fit_parsnip()\r\n\r\n## Model output with traditional summary() function\r\nlm_fit %&gt;%\r\n  extract_fit_parsnip() %&gt;% \r\n  .$fit %&gt;%\r\n  summary()\r\n\r\n## Model output in tidy format  \r\nlm_fit %&gt;%\r\n  tidy()\r\n\r\n## Make predictions on test set\r\nozone_pred_lm &lt;- predict(\r\n  lm_fit,\r\n  test\r\n  )\r\n\r\nozone_pred_lm\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Introduction In {tidymodels} it is often recommended to split the data using the initial_split() function. This is useful when you are interested in a random sample from the data. As such, the initial_split() function produces a list of information that is used downstream in the model fitting and model prediction process. However, sometimes we have [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[47],"tags":[],"class_list":["post-2701","post","type-post","status-publish","format-standard","hentry","category-model-building-in-r"],"_links":{"self":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts\/2701","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/comments?post=2701"}],"version-history":[{"count":1,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts\/2701\/revisions"}],"predecessor-version":[{"id":2710,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts\/2701\/revisions\/2710"}],"wp:attachment":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/media?parent=2701"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/categories?post=2701"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/tags?post=2701"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}