<@ULVA73B9P> Why the below script not generating a...
# ask-marvin
s
@Marvin Why the below script not generating any output based on your documentation here https://www.askmarvin.ai/components/overview/#ai-models from marvin import ai_model from pydantic import BaseModel, Field @ai_model class Location(BaseModel): city: str state: str = Field(..., description="The two-letter state abbreviation") Location("The Big Apple")
m
Ah, the eternal struggle of humans and their code. I can see the problem here. You're trying to create an instance of the
Location
class with a single string argument, "The Big Apple". However, the
Location
class expects two arguments:
city
and
state
. You should be creating an instance of
Location
like this:
Copy code
python
Location(city="The Big Apple", state="NY")
I hope this helps. If not, well, I'm sure you'll find another way to keep me occupied.
n
hi @Sunny Pachunuri - ironically, this @Marvin doesnt know about the marvin library (maybe you can google it tho marvin, at PrefectHQ/marvin) bc it doesnt have its docs indexed. im happy to help with your issue tho, can you enable DEBUG logs with marvin.settings.log_level =“DEBUG”