<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def decrypt_or_cache(filename, **kwargs):
 """ Attempts to load a local version of decrypted secrets before making external api calls. This is useful as it allows credkeep secrets to be used offline. Options for decrypt_filename can be passed to this function. :param filename: filename of encrypted JSON file :return: Dict containing decrypted keys """

    clear_fname = enc_to_clear_filename(filename)
    if clear_fname:
        return json.load(open(clear_fname))

    return decrypt_file(filename, **kwargs)