Except for a few very special ansible modules like command, module args should be key= value. From the playbook’s point of view this can be specified as a yaml dict or a single string of key= value paid separated by spaces.
Inside of the controller, ansible takes either of these forms and transforms them into a python dictionary. For new style ansible modules (those written in python and using the helper class in lib/ansible/module_utils/basic.py ) this dict is turned into a string representation and embedded in the module. Then the module is passed over the wire and executed on the remote machine.
On the remote machine, the code inside module_utils/basic.py takes care of turning the the args back into a python dict from the string representation so that the rest of the code in the middle can access the parameters via that dict.