<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def as_dict(self):
 """ Json-serializable dict representation for Site. """

        species_list = []
        for spec, occu in self.species.items():
            d = spec.as_dict()
            del d["@module"]
            del d["@class"]
            d["occu"] = occu
            species_list.append(d)
        d = {"name": self.species_string, "species": species_list,
             "xyz": [float(c) for c in self.coords],
             "properties": self.properties,
             "@module": self.__class__.__module__,
             "@class": self.__class__.__name__}
        if self.properties:
            d["properties"] = self.properties
        return d