invoke • AI Agent SDK

invoke: Render a skill body into a ready-to-send prompt.

invoke

Method

</div>

This is a method of the SkillManager class in the manager module.

Render a skill body into a ready-to-send prompt.

Substitutes `$ARGUMENTS, $N, $&#123;PRAISON_SKILL_DIR&#125; and optionally runs !cmd inline shell blocks when shell_exec` is True.

Signature

python
def invoke(name: str, raw_args: str, session_id: Optional[str], shell_exec: bool) -> Optional[str]

Parameters

ParamField str

No description available.

ParamField str

No description available.

ParamField Optional[str]

No description available.

ParamField bool

No description available.

Returns

ResponseField Optional[str]

Rendered body, or None if the skill does not exist or is not user-invocable.

Uses

  • get_skill
  • activate
  • render_skill_body
  • render_shell_blocks

Source

View on GitHub

praisonaiagents/skills/manager.py at line 530