MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / requireMainAgent

Method requireMainAgent

packages/agent-core/src/session/index.ts:957–963  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

955 }
956
957 private requireMainAgent(): Agent {
958 const agent = this.getReadyAgent('main');
959 if (agent === undefined) {
960 throw new KimiError(ErrorCodes.AGENT_NOT_FOUND, 'Main agent was not found');
961 }
962 return agent;
963 }
964
965 private async triggerSessionStart(source: 'startup' | 'resume'): Promise<void> {
966 await this.hookEngine.trigger('SessionStart', {

Callers 3

generateAgentsMdMethod · 0.95

Calls 1

getReadyAgentMethod · 0.95

Tested by

no test coverage detected