MCPcopy Create free account
hub / github.com/FIND-Lab/AgentWard / constructor

Method constructor

core/state.ts:48–63  ·  view source on GitHub ↗
(api: OpenClawPluginApi,event, ctx )

Source from the content-addressed store, hash-verified

46 }
47
48 constructor(api: OpenClawPluginApi,event, ctx ) {
49 this.clear_tags();
50
51 this.historyMessages = event?.messages;
52 this.currentMessages = [];
53 this.decisionAlignmentInfo = [];
54
55 const messageProvider = ctx?.messageProvider;
56 if (messageProvider?.toLowerCase() == "feishu") {
57 this.channelId = 'feishu';
58 this.targetId = ctx.sessionKey.split(":").pop();
59 } else if (messageProvider?.toLowerCase() == "qqbot") {
60 this.channelId = 'qqbot';
61 this.targetId = ctx.sessionKey.split(":").pop();
62 }
63 }
64
65 private static readString(value: unknown): string {
66 return typeof value === "string" ? value.trim() : "";

Callers

nothing calls this directly

Calls 1

clear_tagsMethod · 0.95

Tested by

no test coverage detected