Conversation
…om unfactored version of game app main page
safe reset of convos
Wiring front to back
Wiring front to back
* Baseline code for standardizing data loading * atomic teachers working * Cleanup atomic * quest goals teacher * Predictive machines to projects * Wild chat task and code and sweeps * Updating sweep paths to new locations * Cleaning up quests build * Finished all _operational_ quests code * Remaiing related sweeps * Core quests rl project code * Sweeps related to RL code * Adding missing models * Dropping sweeps * Removing _almost_ all checkpoint links * Uploading relevant models, adding download paths * Core quests rl project code * Sweeps related to RL code * Adding missing models * Removing _almost_ all checkpoint links * Removing sweeps * removing sweeps... again * Build scripts now point to real file
* Creating example builder script for story agents project * Writing play map example script
adding common sense + world builder code
* added gameplay task view * added gameplay task view * fixed message transmission in both gameapp reducer and task redux-slice * removed boilerplate * placed topmessage function at top of reducer
JackUrb
left a comment
There was a problem hiding this comment.
Just two style nits on this final implementation (related to use of ternaries).
@JustinPinero only thing I think is missing is the change catching "you cant ...." messages to undo do actions.
| setDoCounter(updatedWorkerDoCount); | ||
| }, [workerData]) | ||
|
|
||
| return ( |
There was a problem hiding this comment.
Style nit: Large ternaries are visibly hard to process. As a rule of thumb, if the content of your ternary is larger than a line each for condition, option 1, and option 2, don't put it in a ternary and try to find another way to encode your logic.
The below could be:
if ((MINIMUM_NUMBER_OF_SAYS <= sayCounter) && (MINIMUM_NUMBER_OF_DOS <= doCounter)) {
const modalContent = ...
} else {
const modalContent = ...
}
If (url != null) {
return ...
else {
return <> null </>;
}
| } | ||
| return ( | ||
| <Form className="radioform-container"> | ||
| {formQuestion |
There was a problem hiding this comment.
Note I'd consider this to be an OK example of a larger ternary, though you'd generally want to group the shorter context together to make this appropriate:
{ (formQuestion == null)
? null
:
...
}
This helps constrain the context of the ternary such that it's not really deep in the code that you find the alternate branch.
* added assets * added assets * added PreviewView, added assets to preview view, began styling preview view * added preview copy and screenshots, added instruction modal, added task copy from quip
Overview
Following up on #282, this PR updates the task frontend introduced in #281 to now be in a Mephisto-task format. Note, this now requires using Mephisto version 1.0.0.
Implementation
Due to how Mephisto tasks build, I had to rearrange a number of folders, configure webpack, change react versions, etc. to get things running. That's most of the churn of this PR. Additionally:
AppRoutercomponent with aLIGHTAppTaskFramecomponent, which does the type of routing that a Mephisto task expects. This component is also responsible for requesting the correct authorization key for a given worker, and passing the synthesized URL to the underlying task component.Taskcomponent to receive a passed URL and the submit function, though the latter is currently unused right now.run_task.pyscript that actually launches the mephisto job, requiring apreauth_secretthat needs to be shared between the server launch and the Mephisto task. This allows Mephisto to sign the worker's auth token properly.Some notes here, I've left a few messy components in the
LIGHTAppTaskFramefile. These should probably be refactored out. Also unfortunately @JustinPinero I expect there to be a significant amount of manual churn merging your onboarding flow, considering some fairly substantial folder thrash required to get Mephisto up-and-running. When you merge onboarding into this, you'll have to add anonboarding_qualificationto thelocalyaml configuration in order to see your onboarding view (after you insert it in theisOnboardingbranch ofLIGHTAppTaskFrame). See thelocal_test.yamlfile incrowdsourcing/dialogues/multi_party_chat/hydra_confsfolder for an example.Testing
Navigate to the desired location:
