<commit_before>import logging; logger = logging.getLogger("novela." + __name__)
logger.setLevel(logging.DEBUG)

from action import action, genom_request
from action import wait as basewait

@action
def setup_scenario(scenario):
    """ Allows to load a custom scene configuration ('sce' files) in SPARK
    at runtime.
    
    :param scenario: The complete path to a valid scenario file ('.sce')
    """
    return [genom_request("spark", "LoadSce", scenario)]

@action
def wait(seconds):
	""" This special action simply waits for a given amount of second before 
	sending the next action.
	"""
	return [basewait(seconds)]
<commit_msg>Added action to lock/unlock an object in SPARK<commit_after>import logging; logger = logging.getLogger("novela." + __name__)
logger.setLevel(logging.DEBUG)

from action import action, genom_request
from action import wait as basewait

@action
def setup_scenario(scenario):
    """ Allows to load a custom scene configuration ('sce' files) in SPARK
    at runtime.
    
    :param scenario: The complete path to a valid scenario file ('.sce')
    """
    return [genom_request("spark", "LoadSce", scenario)]

@action
def lock_object(object):
    """ Lock to position of an object in SPARK. It won't be updated
    anymore.
    
    :param object: The ID of the object to lock.
    """
    return [genom_request("spark", "SetObjectFixed", [object, "GEN_TRUE"])]

@action
def unlock_object(object):
    """ Unlock to position of an object in SPARK. It won't be updated
    anymore.
    
    :param object: The ID of the object to lock.
    """
    return [genom_request("spark", "SetObjectFixed", [object, "GEN_FALSE"])]


@action
def wait(seconds):
	""" This special action simply waits for a given amount of second before 
	sending the next action.
	"""
	return [basewait(seconds)]

{'fraction_non_alphanumeric': 0.10511832691249312, 'fraction_numerical': 0.0, 'mean_word_length': 4.0220994475138125, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '342224', 'n_tokens_mistral': 544, 'n_tokens_neox': 533, 'n_words': 205}