Skip to content

Commit

Permalink
Merge branch 'main' into spring2023-prep
Browse files Browse the repository at this point in the history
  • Loading branch information
cgpotts authored Mar 31, 2023
2 parents 9bcad03 + 81f217a commit cd2a2dc
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions hw_sentiment.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1873,7 +1873,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"### Task 2: Contextual representations [1 point]"
]
},
{
Expand Down Expand Up @@ -2171,7 +2170,17 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"### Optional use: Classifier interface"

"We have so far presented the bakeoff dev set as purely for evaluation. Since the train set consists entirely of SST-3 data, this makes the bakeoff split especially challenging. We might be able to reduce the challenging by adding some of the bakeoff dev set to the train set, keeping some of it for evaluation. The current question asks to begin explore the effects of such training.\n",
"\n",
"Your task: write a function `run_mixed_training_experiment`. The function should:\n",
"\n",
"1. Take as inputs (a) a model training wrapper like `fit_softmax_classifier` and (b) an integer `bakeoff_train_size` specifying the number of examples from `bakeoff_dev` that should be included in the train set.\n",
"1. Split `bakeoff_dev` so that the first `bakeoff_train_size` examples are in the train set and the rest are used for evaluation.\n",
"1. Use `sst.experiment` with the user-supplied model training wrapper, `unigrams_phi` as defined above, and a train set that consists of SST-3 train and the train portion of `bakeoff_dev` as defined in step 2. The value of `assess_dataframes` should be a list consisting of the SST-3 dev set and the evaluation portion of `bakeoff_dev` as defined in step 2.\n",
"1. Return the return value of `sst.experiment`.\n",
"\n",
"The function `test_run_mixed_training_experiment` will help you iterate to the required design."
]
},
{
Expand Down

0 comments on commit cd2a2dc

Please sign in to comment.