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

def _get_local_fields(self, model):
        "Return the names of all locally defined fields on the model class."
        local = [f for f in model._meta.fields]
        m2m = [f for f in model._meta.many_to_many]
        fields = local + m2m
        names = tuple([x.name for x in fields])

        return {
            ':local': dict(list(zip(names, fields))),
        }