def METHOD_NAME(obj, key, value):
    if obj is None:
        return
    if '.' in key:
        k1, k2 = key.split('.', 1)
        METHOD_NAME(getattr(obj, k1, None), k2, value)
    else:
        target = getattr(obj, key, None)
        if target is not None and hasattr(target, 'bind_lora'):
            target.bind_lora(value)