MCPcopy Create free account
hub / github.com/modelscope/ms-agent / load_from_plan

Method load_from_plan

ms_agent/skill/schema.py:575–593  ·  view source on GitHub ↗

Load resources based on the execution plan. Loads only the scripts, references, and resources specified in the plan.

(self)

Source from the content-addressed store, hash-verified

573 return loaded
574
575 def load_from_plan(self) -> None:
576 """
577 Load resources based on the execution plan.
578
579 Loads only the scripts, references, and resources specified in the plan.
580 """
581 if self._resources_loaded or not self.plan:
582 return
583
584 if self.plan.required_scripts:
585 self.load_scripts(self.plan.required_scripts)
586
587 if self.plan.required_references:
588 self.load_references(self.plan.required_references)
589
590 if self.plan.required_resources:
591 self.load_resources(self.plan.required_resources)
592
593 self._resources_loaded = True
594
595 def load_all(self) -> None:
596 """Load all available resources (scripts, references, resources)."""

Callers 1

load_skill_resourcesMethod · 0.80

Calls 3

load_scriptsMethod · 0.95
load_referencesMethod · 0.95
load_resourcesMethod · 0.95

Tested by

no test coverage detected