<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def _configure_device(commands, **kwargs):
    '''
    Helper function to send configuration commands to the device over a
    proxy minion or native minion using NX-API or SSH.
    '''
    if salt.utils.platform.is_proxy():
        return __proxy__['nxos.proxy_config'](commands, **kwargs)
    else:
        return _nxapi_config(commands, **kwargs)