Skip to content

Commit

Permalink
Remove unnecessary mixin
Browse files Browse the repository at this point in the history
  • Loading branch information
yellowcap committed Feb 12, 2025
1 parent c51187e commit 319e3de
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions zeno/agents/layerfinder/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
from typing_extensions import Self


# Add this mixin to all models
class JSONSerializable(BaseModel):
def to_dict(self):
return json.loads(json.dumps(self, default=lambda o: o.dict()))


class Dataset(JSONSerializable):
class Dataset(BaseModel):
title: str = Field(description="The title of the dataset")
dataset: str = Field(description="The slug of the dataset")
explanation: str = Field(
Expand All @@ -31,7 +25,7 @@ def set_uri_and_tilelayer(self) -> Self:
return self


class LayerFinderResponse(JSONSerializable):
class LayerFinderResponse(BaseModel):
datasets: List[Dataset]


Expand Down

0 comments on commit 319e3de

Please sign in to comment.