MCPcopy
hub / github.com/wshobson/agents / AgentSource

Class AgentSource

tools/adapters/base.py:221–244  ·  view source on GitHub ↗

One agent: plugins/ /agents/ .md.

Source from the content-addressed store, hash-verified

219
220@dataclass
221class AgentSource:
222 """One agent: plugins/<plugin>/agents/<name>.md."""
223
224 plugin: str
225 name: str
226 path: Path
227 frontmatter: dict
228 body: str
229
230 @property
231 def description(self) -> str:
232 return (self.frontmatter.get("description") or "").strip()
233
234 @property
235 def model(self) -> str:
236 return (self.frontmatter.get("model") or "inherit").strip()
237
238 @property
239 def tools(self) -> list[str]:
240 return split_tools_list(self.frontmatter.get("tools"))
241
242 @property
243 def color(self) -> str:
244 return (self.frontmatter.get("color") or "").strip()
245
246
247@dataclass

Callers 2

_make_agentFunction · 0.90
load_pluginFunction · 0.85

Calls

no outgoing calls

Tested by 1

_make_agentFunction · 0.72