Change type declaration according to pydantic
library and use in implementation of Resource class. This change allows for better data
validation and settings management in the Resource class, ensuring that instances
of the class adhere to the specified type constraints. (#2)