<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_nugget_dict(self):
 """Return the Nugget as a dictionary."""

        nugget_dict = \
            {'id': self.id,
             'graph': {
                 'nodes': self.nodes,
                 'edges': self.edges
                 },
             'attrs': {
                 'name': self.name,
                 'rate': self.rate
                 }
            }
        return nugget_dict