from os import environ from typing import List SESSION_CONFIGS = [ dict( name="full", app_sequence=[ "welcome", "oneapp", "quiz", "ravens_test", "audiotest", "subtraction", "audiotestdelay", "oneapp_two", "end", "kick", ], num_demo_participants=8, compcode=0, ) ] SESSION_CONFIG_DEFAULTS = dict( real_world_currency_per_point=0.50, participation_fee=1.00, doc="", crt_points=2, subtraction_points=1, raven_points=1, raven_timeout=480, audio_points=0.25, # adjust MTurk settings here mturk_hit_settings=dict( keywords="bonus, study", title="Behavioral Experiment with Bonus Payments (~10 minutes)", description="description", frame_height=500, template="global/mturk_template.html", minutes_allotted_per_assignment=30, expiration_hours=24, grant_qualification_id="306WV99NLI5GURNMCMWJNX144NEN1Y", qualification_requirements=[ { "QualificationTypeId": "00000000000000000071", "Comparator": "EqualTo", "LocaleValues": [{"Country": "US"}], }, { "QualificationTypeId": "000000000000000000L0", "Comparator": "GreaterThanOrEqualTo", "IntegerValues": [99], }, { "QualificationTypeId": "00000000000000000040", "Comparator": "GreaterThanOrEqualTo", "IntegerValues": [5000], }, { "QualificationTypeId": "306WV99NLI5GURNMCMWJNX144NEN1Y", "Comparator": "DoesNotExist", }, ] # grant_qualification_id='YOUR_QUALIFICATION_ID_HERE', # to prevent retakes ), ) ROUNDS_PER_STRATEGY = 15 STRATEGIES = [ #"TfT", "Tf3T", # "AD", # "GT", # "TTfT", ] # See oneapp/Introduction.html for descriptions def create_variables_per_round( prefix: str, rounds: int = ROUNDS_PER_STRATEGY ) -> List[str]: """ Create participant variables per round. :param prefix: Prefix of the created variables :param rounds: Number of rounds for which variables should be created. :return: List of participant field names of the format '[strat_name]_[infix]_round_[nr]' """ return [f"{prefix}_round_{i}" for i in range(1, rounds + 1)] PARTICIPANT_FIELDS = [ "payment", "treatment_reminder", "treatment_rule", "last_timestamp", "gt_triggered", "audiocheck_answer", "nr_correct_answers_subtractions", "order", "num_correct_words", "num_correct_words_delay", "timeout", "crt_score", "attention_check_sft", "attention_check_quiz", "subtraction_pay", "raven_selection", "sft_pay", "points", "dcountTf3T", "dtriggerTf3T", "attention_check_failed", "payoff_performance", "crt_pay", "subtraction_pay", "audio_pay", "raven_pay" ] PARTICIPANT_FIELDS += create_variables_per_round( "seconds", ) PARTICIPANT_FIELDS += create_variables_per_round( "mistake", ) SESSION_FIELDS = [] # ISO-639 code # for example: de, fr, ja, ko, zh-hans LANGUAGE_CODE = "en" # e.g. EUR, GBP, CNY, JPY REAL_WORLD_CURRENCY_CODE = "USD" USE_POINTS = False ADMIN_USERNAME = "admin" # for security, best to set admin password in an environment variable ADMIN_PASSWORD = environ.get("OTREE_ADMIN_PASSWORD") DEMO_PAGE_INTRO_HTML = """ """ SECRET_KEY = "5553372934268" AWS_ACCESS_KEY_ID = environ.get("AWS_ACCESS_KEY_ID") AWS_SECRET_ACCESS_KEY = environ.get("AWS_SECRET_ACCESS_KEY")