From Metadata • AI Agent SDK
from_metadata: Parse an automation block from a skill's “metadata“ mapping.
from_metadata
Method
</div>
This is a method of the SkillAutomation class in the models module.
Parse an automation block from a skill’s `metadata` mapping.
Looks up `metadata['praisonai']['automation']. Returns None when the block is absent or malformed (missing/empty schedule), so skills without automation simply parse to automation=None`.
Signature
def from_metadata(metadata: dict) -> Optional['SkillAutomation']Parameters
ParamField
dictThe parsed `metadata` bag from SKILL.md frontmatter.
Returns
ResponseField
Optional['SkillAutomation']SkillAutomation instance, or None when no valid block is present.
Uses
cls
Used By
Source
View on GitHubpraisonaiagents/skills/models.py at line 170