opc-agent 2.0.2 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +603 -545
- package/dist/channels/voice.d.ts +59 -0
- package/dist/channels/voice.js +351 -1
- package/dist/cli.js +284 -5
- package/dist/core/agent.d.ts +9 -0
- package/dist/core/agent.js +49 -0
- package/dist/core/collaboration.d.ts +89 -0
- package/dist/core/collaboration.js +201 -0
- package/dist/deploy/index.d.ts +40 -0
- package/dist/deploy/index.js +261 -0
- package/dist/index.d.ts +7 -1
- package/dist/index.js +47 -3
- package/dist/mcp/servers/calculator-mcp.d.ts +3 -0
- package/dist/mcp/servers/calculator-mcp.js +65 -0
- package/dist/mcp/servers/crypto-mcp.d.ts +3 -0
- package/dist/mcp/servers/crypto-mcp.js +108 -0
- package/dist/mcp/servers/database-mcp.d.ts +3 -0
- package/dist/mcp/servers/database-mcp.js +73 -0
- package/dist/mcp/servers/datetime-mcp.d.ts +3 -0
- package/dist/mcp/servers/datetime-mcp.js +71 -0
- package/dist/mcp/servers/filesystem.d.ts +3 -0
- package/dist/mcp/servers/filesystem.js +101 -0
- package/dist/mcp/servers/github-mcp.d.ts +3 -0
- package/dist/mcp/servers/github-mcp.js +60 -0
- package/dist/mcp/servers/index.d.ts +21 -0
- package/dist/mcp/servers/index.js +50 -0
- package/dist/mcp/servers/json-mcp.d.ts +3 -0
- package/dist/mcp/servers/json-mcp.js +126 -0
- package/dist/mcp/servers/memory-mcp.d.ts +3 -0
- package/dist/mcp/servers/memory-mcp.js +60 -0
- package/dist/mcp/servers/regex-mcp.d.ts +3 -0
- package/dist/mcp/servers/regex-mcp.js +56 -0
- package/dist/mcp/servers/web-mcp.d.ts +3 -0
- package/dist/mcp/servers/web-mcp.js +51 -0
- package/dist/memory/index.d.ts +2 -0
- package/dist/memory/index.js +4 -1
- package/dist/memory/seed-loader.d.ts +51 -0
- package/dist/memory/seed-loader.js +200 -0
- package/dist/schema/oad.d.ts +292 -12
- package/dist/schema/oad.js +12 -1
- package/dist/security/guardrails.d.ts +50 -0
- package/dist/security/guardrails.js +197 -0
- package/dist/studio/server.d.ts +31 -1
- package/dist/studio/server.js +154 -3
- package/dist/studio-ui/index.html +1278 -662
- package/dist/tools/integrations/calendar.d.ts +3 -0
- package/dist/tools/integrations/calendar.js +73 -0
- package/dist/tools/integrations/code-exec.d.ts +3 -0
- package/dist/tools/integrations/code-exec.js +42 -0
- package/dist/tools/integrations/csv-analyzer.d.ts +3 -0
- package/dist/tools/integrations/csv-analyzer.js +142 -0
- package/dist/tools/integrations/database.d.ts +3 -0
- package/dist/tools/integrations/database.js +44 -0
- package/dist/tools/integrations/email-send.d.ts +3 -0
- package/dist/tools/integrations/email-send.js +104 -0
- package/dist/tools/integrations/git-tool.d.ts +3 -0
- package/dist/tools/integrations/git-tool.js +49 -0
- package/dist/tools/integrations/github-tool.d.ts +3 -0
- package/dist/tools/integrations/github-tool.js +77 -0
- package/dist/tools/integrations/image-gen.d.ts +3 -0
- package/dist/tools/integrations/image-gen.js +58 -0
- package/dist/tools/integrations/index.d.ts +30 -0
- package/dist/tools/integrations/index.js +107 -0
- package/dist/tools/integrations/jira.d.ts +3 -0
- package/dist/tools/integrations/jira.js +85 -0
- package/dist/tools/integrations/notion.d.ts +3 -0
- package/dist/tools/integrations/notion.js +71 -0
- package/dist/tools/integrations/npm-tool.d.ts +3 -0
- package/dist/tools/integrations/npm-tool.js +49 -0
- package/dist/tools/integrations/pdf-reader.d.ts +3 -0
- package/dist/tools/integrations/pdf-reader.js +91 -0
- package/dist/tools/integrations/slack.d.ts +3 -0
- package/dist/tools/integrations/slack.js +67 -0
- package/dist/tools/integrations/summarizer.d.ts +3 -0
- package/dist/tools/integrations/summarizer.js +49 -0
- package/dist/tools/integrations/translator.d.ts +3 -0
- package/dist/tools/integrations/translator.js +48 -0
- package/dist/tools/integrations/trello.d.ts +3 -0
- package/dist/tools/integrations/trello.js +60 -0
- package/dist/tools/integrations/vector-search.d.ts +3 -0
- package/dist/tools/integrations/vector-search.js +44 -0
- package/dist/tools/integrations/web-scraper.d.ts +3 -0
- package/dist/tools/integrations/web-scraper.js +48 -0
- package/dist/tools/integrations/web-search.d.ts +3 -0
- package/dist/tools/integrations/web-search.js +60 -0
- package/dist/tools/integrations/webhook.d.ts +3 -0
- package/dist/tools/integrations/webhook.js +39 -0
- package/dist/ui/components.d.ts +10 -0
- package/dist/ui/components.js +123 -0
- package/package.json +1 -1
- package/src/channels/voice.ts +365 -0
- package/src/cli.ts +294 -6
- package/src/core/agent.ts +56 -0
- package/src/core/collaboration.ts +275 -0
- package/src/deploy/index.ts +255 -0
- package/src/index.ts +21 -1
- package/src/mcp/servers/calculator-mcp.ts +65 -0
- package/src/mcp/servers/crypto-mcp.ts +73 -0
- package/src/mcp/servers/database-mcp.ts +72 -0
- package/src/mcp/servers/datetime-mcp.ts +69 -0
- package/src/mcp/servers/filesystem.ts +66 -0
- package/src/mcp/servers/github-mcp.ts +58 -0
- package/src/mcp/servers/index.ts +63 -0
- package/src/mcp/servers/json-mcp.ts +102 -0
- package/src/mcp/servers/memory-mcp.ts +56 -0
- package/src/mcp/servers/regex-mcp.ts +53 -0
- package/src/mcp/servers/web-mcp.ts +49 -0
- package/src/memory/index.ts +3 -0
- package/src/memory/seed-loader.ts +212 -0
- package/src/schema/oad.ts +13 -0
- package/src/security/guardrails.ts +248 -0
- package/src/studio/server.ts +166 -4
- package/src/studio-ui/index.html +1278 -662
- package/src/tools/integrations/calendar.ts +73 -0
- package/src/tools/integrations/code-exec.ts +39 -0
- package/src/tools/integrations/csv-analyzer.ts +92 -0
- package/src/tools/integrations/database.ts +44 -0
- package/src/tools/integrations/email-send.ts +76 -0
- package/src/tools/integrations/git-tool.ts +42 -0
- package/src/tools/integrations/github-tool.ts +76 -0
- package/src/tools/integrations/image-gen.ts +56 -0
- package/src/tools/integrations/index.ts +92 -0
- package/src/tools/integrations/jira.ts +83 -0
- package/src/tools/integrations/notion.ts +71 -0
- package/src/tools/integrations/npm-tool.ts +48 -0
- package/src/tools/integrations/pdf-reader.ts +58 -0
- package/src/tools/integrations/slack.ts +65 -0
- package/src/tools/integrations/summarizer.ts +49 -0
- package/src/tools/integrations/translator.ts +48 -0
- package/src/tools/integrations/trello.ts +60 -0
- package/src/tools/integrations/vector-search.ts +42 -0
- package/src/tools/integrations/web-scraper.ts +47 -0
- package/src/tools/integrations/web-search.ts +58 -0
- package/src/tools/integrations/webhook.ts +38 -0
- package/src/ui/components.ts +127 -0
- package/tests/brain-seed-extended.test.ts +490 -0
- package/tests/brain-seed.test.ts +239 -0
- package/tests/collaboration.test.ts +319 -0
- package/tests/deploy-and-dag.test.ts +196 -0
- package/tests/guardrails.test.ts +177 -0
- package/tests/integrations.test.ts +249 -0
- package/tests/mcp-servers.test.ts +260 -0
- package/tests/voice-enhanced.test.ts +169 -0
- package/dist/dtv/data.d.ts +0 -18
- package/dist/dtv/data.js +0 -25
- package/dist/dtv/trust.d.ts +0 -19
- package/dist/dtv/trust.js +0 -40
- package/dist/dtv/value.d.ts +0 -23
- package/dist/dtv/value.js +0 -38
- package/dist/marketplace/index.d.ts +0 -34
- package/dist/marketplace/index.js +0 -202
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Multi-agent collaboration patterns
|
|
4
|
+
* @module core/collaboration
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.ConversationProtocol = exports.SharedContext = exports.HierarchyPattern = exports.PipelinePattern = exports.VotingPattern = exports.DebatePattern = void 0;
|
|
8
|
+
// ─── Helper ─────────────────────────────────────────────────
|
|
9
|
+
function makeMsg(role, content) {
|
|
10
|
+
return { id: `msg-${Date.now()}-${Math.random().toString(36).slice(2, 8)}`, role, content, timestamp: Date.now() };
|
|
11
|
+
}
|
|
12
|
+
async function agentChat(agent, prompt) {
|
|
13
|
+
const response = await agent.handleMessage(makeMsg('user', prompt));
|
|
14
|
+
return response.content;
|
|
15
|
+
}
|
|
16
|
+
// ─── DebatePattern ──────────────────────────────────────────
|
|
17
|
+
class DebatePattern {
|
|
18
|
+
agents;
|
|
19
|
+
rounds;
|
|
20
|
+
constructor(agents, rounds = 3) {
|
|
21
|
+
this.agents = agents;
|
|
22
|
+
this.rounds = rounds;
|
|
23
|
+
}
|
|
24
|
+
async debate(topic, judgeAgent) {
|
|
25
|
+
const allArgs = [];
|
|
26
|
+
let context = '';
|
|
27
|
+
for (let round = 1; round <= this.rounds; round++) {
|
|
28
|
+
for (const agent of this.agents) {
|
|
29
|
+
const prompt = round === 1
|
|
30
|
+
? `Debate topic: "${topic}". Present your argument.`
|
|
31
|
+
: `Debate topic: "${topic}". Previous arguments:\n${context}\nPresent your counter-argument for round ${round}.`;
|
|
32
|
+
const argument = await agentChat(agent, prompt);
|
|
33
|
+
allArgs.push({ agent: agent.name, round, argument });
|
|
34
|
+
context += `\n[${agent.name} round ${round}]: ${argument}`;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
const judge = judgeAgent ?? this.agents[0];
|
|
38
|
+
const summaryPrompt = `You are the judge. Summarize and decide the winner of this debate on "${topic}":\n${context}`;
|
|
39
|
+
const summary = await agentChat(judge, summaryPrompt);
|
|
40
|
+
return { topic, rounds: allArgs, summary, judge: judge.name };
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
exports.DebatePattern = DebatePattern;
|
|
44
|
+
// ─── VotingPattern ──────────────────────────────────────────
|
|
45
|
+
class VotingPattern {
|
|
46
|
+
agents;
|
|
47
|
+
constructor(agents) {
|
|
48
|
+
this.agents = agents;
|
|
49
|
+
}
|
|
50
|
+
async vote(question, options) {
|
|
51
|
+
const votes = [];
|
|
52
|
+
const optionList = options.map((o, i) => `${i + 1}. ${o}`).join('\n');
|
|
53
|
+
for (const agent of this.agents) {
|
|
54
|
+
const prompt = `Question: "${question}"\nOptions:\n${optionList}\nRespond with ONLY the exact text of your chosen option.`;
|
|
55
|
+
const raw = await agentChat(agent, prompt);
|
|
56
|
+
const choice = options.find(o => raw.includes(o)) ?? raw.trim();
|
|
57
|
+
votes.push({ agent: agent.name, choice, confidence: 1 });
|
|
58
|
+
}
|
|
59
|
+
return this.tallyVotes(question, votes);
|
|
60
|
+
}
|
|
61
|
+
async weightedVote(question, options) {
|
|
62
|
+
const votes = [];
|
|
63
|
+
const optionList = options.map((o, i) => `${i + 1}. ${o}`).join('\n');
|
|
64
|
+
for (const agent of this.agents) {
|
|
65
|
+
const prompt = `Question: "${question}"\nOptions:\n${optionList}\nRespond in format: CHOICE|CONFIDENCE(0-1)`;
|
|
66
|
+
const raw = await agentChat(agent, prompt);
|
|
67
|
+
const parts = raw.split('|');
|
|
68
|
+
const choiceRaw = parts[0]?.trim() ?? '';
|
|
69
|
+
const choice = options.find(o => choiceRaw.includes(o)) ?? choiceRaw;
|
|
70
|
+
const confidence = Math.min(1, Math.max(0, parseFloat(parts[1] ?? '0.5') || 0.5));
|
|
71
|
+
votes.push({ agent: agent.name, choice, confidence });
|
|
72
|
+
}
|
|
73
|
+
return this.tallyVotes(question, votes);
|
|
74
|
+
}
|
|
75
|
+
tallyVotes(question, votes) {
|
|
76
|
+
const tally = {};
|
|
77
|
+
for (const v of votes) {
|
|
78
|
+
tally[v.choice] = (tally[v.choice] ?? 0) + v.confidence;
|
|
79
|
+
}
|
|
80
|
+
const winner = Object.entries(tally).sort((a, b) => b[1] - a[1])[0]?.[0] ?? '';
|
|
81
|
+
return { question, votes, winner, tally };
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
exports.VotingPattern = VotingPattern;
|
|
85
|
+
// ─── PipelinePattern ────────────────────────────────────────
|
|
86
|
+
class PipelinePattern {
|
|
87
|
+
stages;
|
|
88
|
+
constructor(stages) {
|
|
89
|
+
this.stages = stages;
|
|
90
|
+
}
|
|
91
|
+
async process(input) {
|
|
92
|
+
const stageResults = [];
|
|
93
|
+
let current = input;
|
|
94
|
+
const t0 = Date.now();
|
|
95
|
+
for (const stage of this.stages) {
|
|
96
|
+
const stageInput = stage.transform ? stage.transform(current) : current;
|
|
97
|
+
const start = Date.now();
|
|
98
|
+
const output = await agentChat(stage.agent, stageInput);
|
|
99
|
+
stageResults.push({ agent: stage.agent.name, input: stageInput, output, durationMs: Date.now() - start });
|
|
100
|
+
current = output;
|
|
101
|
+
}
|
|
102
|
+
return { stages: stageResults, finalOutput: current, totalDurationMs: Date.now() - t0 };
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
exports.PipelinePattern = PipelinePattern;
|
|
106
|
+
// ─── HierarchyPattern ───────────────────────────────────────
|
|
107
|
+
class HierarchyPattern {
|
|
108
|
+
leader;
|
|
109
|
+
workers;
|
|
110
|
+
constructor(leader, workers) {
|
|
111
|
+
this.leader = leader;
|
|
112
|
+
this.workers = workers;
|
|
113
|
+
}
|
|
114
|
+
async execute(task) {
|
|
115
|
+
// Leader decomposes
|
|
116
|
+
const decomposePrompt = `Decompose this task into ${this.workers.length} subtasks (one per line, no numbering): "${task}"`;
|
|
117
|
+
const decomposition = await agentChat(this.leader, decomposePrompt);
|
|
118
|
+
const subtasks = decomposition.split('\n').map(s => s.trim()).filter(Boolean);
|
|
119
|
+
// Workers execute in parallel
|
|
120
|
+
const workerResults = await Promise.all(this.workers.map(async (worker, i) => {
|
|
121
|
+
const subtask = subtasks[i] ?? subtasks[subtasks.length - 1] ?? task;
|
|
122
|
+
const result = await agentChat(worker, `Complete this subtask: "${subtask}"`);
|
|
123
|
+
return { agent: worker.name, subtask, result };
|
|
124
|
+
}));
|
|
125
|
+
// Leader synthesizes
|
|
126
|
+
const synthPrompt = `Original task: "${task}"\nSubtask results:\n${workerResults.map(r => `[${r.agent}] ${r.subtask}: ${r.result}`).join('\n')}\nSynthesize a final answer.`;
|
|
127
|
+
const synthesis = await agentChat(this.leader, synthPrompt);
|
|
128
|
+
return { task, subtasks: workerResults, synthesis };
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
exports.HierarchyPattern = HierarchyPattern;
|
|
132
|
+
// ─── SharedContext ───────────────────────────────────────────
|
|
133
|
+
class SharedContext {
|
|
134
|
+
store = new Map();
|
|
135
|
+
listeners = new Map();
|
|
136
|
+
set(key, value) {
|
|
137
|
+
this.store.set(key, value);
|
|
138
|
+
const cbs = this.listeners.get(key);
|
|
139
|
+
if (cbs)
|
|
140
|
+
cbs.forEach(cb => cb(value));
|
|
141
|
+
}
|
|
142
|
+
get(key) {
|
|
143
|
+
return this.store.get(key);
|
|
144
|
+
}
|
|
145
|
+
getAll() {
|
|
146
|
+
const result = {};
|
|
147
|
+
for (const [k, v] of this.store)
|
|
148
|
+
result[k] = v;
|
|
149
|
+
return result;
|
|
150
|
+
}
|
|
151
|
+
onChange(key, callback) {
|
|
152
|
+
const existing = this.listeners.get(key) ?? [];
|
|
153
|
+
existing.push(callback);
|
|
154
|
+
this.listeners.set(key, existing);
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
exports.SharedContext = SharedContext;
|
|
158
|
+
// ─── ConversationProtocol ───────────────────────────────────
|
|
159
|
+
class ConversationProtocol {
|
|
160
|
+
async roundRobin(agents, topic, rounds) {
|
|
161
|
+
const messages = [];
|
|
162
|
+
let context = `Topic: "${topic}"`;
|
|
163
|
+
for (let round = 0; round < rounds; round++) {
|
|
164
|
+
for (const agent of agents) {
|
|
165
|
+
const prompt = `${context}\n\nIt's your turn to contribute to this discussion. Be concise.`;
|
|
166
|
+
const content = await agentChat(agent, prompt);
|
|
167
|
+
const msg = makeMsg('assistant', content);
|
|
168
|
+
msg.agent = agent.name;
|
|
169
|
+
messages.push(msg);
|
|
170
|
+
context += `\n[${agent.name}]: ${content}`;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
return messages;
|
|
174
|
+
}
|
|
175
|
+
async moderated(agents, moderator, topic) {
|
|
176
|
+
const messages = [];
|
|
177
|
+
let context = `Topic: "${topic}"`;
|
|
178
|
+
// Moderator opens
|
|
179
|
+
const opening = await agentChat(moderator, `You are moderating a discussion on "${topic}". Introduce the topic and ask the first question.`);
|
|
180
|
+
const openMsg = makeMsg('assistant', opening);
|
|
181
|
+
openMsg.agent = moderator.name;
|
|
182
|
+
messages.push(openMsg);
|
|
183
|
+
context += `\n[Moderator ${moderator.name}]: ${opening}`;
|
|
184
|
+
// Each agent responds
|
|
185
|
+
for (const agent of agents) {
|
|
186
|
+
const content = await agentChat(agent, `${context}\n\nRespond to the moderator's question.`);
|
|
187
|
+
const msg = makeMsg('assistant', content);
|
|
188
|
+
msg.agent = agent.name;
|
|
189
|
+
messages.push(msg);
|
|
190
|
+
context += `\n[${agent.name}]: ${content}`;
|
|
191
|
+
}
|
|
192
|
+
// Moderator summarizes
|
|
193
|
+
const summary = await agentChat(moderator, `${context}\n\nSummarize the discussion and provide closing remarks.`);
|
|
194
|
+
const closeMsg = makeMsg('assistant', summary);
|
|
195
|
+
closeMsg.agent = moderator.name;
|
|
196
|
+
messages.push(closeMsg);
|
|
197
|
+
return messages;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
exports.ConversationProtocol = ConversationProtocol;
|
|
201
|
+
//# sourceMappingURL=collaboration.js.map
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export interface DeployOptions {
|
|
2
|
+
port?: number;
|
|
3
|
+
env?: Record<string, string>;
|
|
4
|
+
platform?: 'docker' | 'railway' | 'fly' | 'render';
|
|
5
|
+
replicas?: number;
|
|
6
|
+
}
|
|
7
|
+
export interface DeployResult {
|
|
8
|
+
platform: string;
|
|
9
|
+
success: boolean;
|
|
10
|
+
url?: string;
|
|
11
|
+
message: string;
|
|
12
|
+
files?: string[];
|
|
13
|
+
}
|
|
14
|
+
export declare class AgentDeployer {
|
|
15
|
+
/**
|
|
16
|
+
* Generate Dockerfile for the agent
|
|
17
|
+
*/
|
|
18
|
+
generateDockerfile(agentDir: string, options?: DeployOptions): Promise<string>;
|
|
19
|
+
/**
|
|
20
|
+
* Generate docker-compose.yml
|
|
21
|
+
*/
|
|
22
|
+
generateCompose(agentDir: string, options?: DeployOptions): Promise<string>;
|
|
23
|
+
/**
|
|
24
|
+
* Deploy to Railway (via CLI)
|
|
25
|
+
*/
|
|
26
|
+
deployRailway(agentDir: string): Promise<DeployResult>;
|
|
27
|
+
/**
|
|
28
|
+
* Deploy to Fly.io
|
|
29
|
+
*/
|
|
30
|
+
deployFly(agentDir: string): Promise<DeployResult>;
|
|
31
|
+
/**
|
|
32
|
+
* Deploy locally via Docker
|
|
33
|
+
*/
|
|
34
|
+
deployLocal(agentDir: string, options?: DeployOptions): Promise<DeployResult>;
|
|
35
|
+
/**
|
|
36
|
+
* Generate deployment files without deploying
|
|
37
|
+
*/
|
|
38
|
+
generateFiles(agentDir: string, options?: DeployOptions): Promise<DeployResult>;
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.AgentDeployer = void 0;
|
|
37
|
+
/**
|
|
38
|
+
* AgentDeployer - Deploy agents to Docker, Railway, Fly.io
|
|
39
|
+
*/
|
|
40
|
+
const fs = __importStar(require("fs"));
|
|
41
|
+
const path = __importStar(require("path"));
|
|
42
|
+
const child_process_1 = require("child_process");
|
|
43
|
+
class AgentDeployer {
|
|
44
|
+
/**
|
|
45
|
+
* Generate Dockerfile for the agent
|
|
46
|
+
*/
|
|
47
|
+
async generateDockerfile(agentDir, options) {
|
|
48
|
+
const port = options?.port || 3000;
|
|
49
|
+
const pkgPath = path.join(agentDir, 'package.json');
|
|
50
|
+
let startCmd = 'node src/index.js';
|
|
51
|
+
if (fs.existsSync(pkgPath)) {
|
|
52
|
+
try {
|
|
53
|
+
const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf-8'));
|
|
54
|
+
if (pkg.scripts?.start) {
|
|
55
|
+
startCmd = pkg.scripts.start;
|
|
56
|
+
}
|
|
57
|
+
if (pkg.main) {
|
|
58
|
+
startCmd = `node ${pkg.main}`;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
catch { }
|
|
62
|
+
}
|
|
63
|
+
return `FROM node:22-slim
|
|
64
|
+
WORKDIR /app
|
|
65
|
+
|
|
66
|
+
# Install dependencies
|
|
67
|
+
COPY package*.json ./
|
|
68
|
+
RUN npm ci --production
|
|
69
|
+
|
|
70
|
+
# Copy source
|
|
71
|
+
COPY . .
|
|
72
|
+
|
|
73
|
+
# Build if needed
|
|
74
|
+
RUN if [ -f "tsconfig.json" ]; then npx tsc || true; fi
|
|
75
|
+
|
|
76
|
+
EXPOSE ${port}
|
|
77
|
+
|
|
78
|
+
ENV NODE_ENV=production
|
|
79
|
+
ENV PORT=${port}
|
|
80
|
+
|
|
81
|
+
CMD ["${startCmd.split(' ')[0]}", ${startCmd.split(' ').slice(1).map(s => `"${s}"`).join(', ')}]
|
|
82
|
+
`;
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Generate docker-compose.yml
|
|
86
|
+
*/
|
|
87
|
+
async generateCompose(agentDir, options) {
|
|
88
|
+
const port = options?.port || 3000;
|
|
89
|
+
const replicas = options?.replicas || 1;
|
|
90
|
+
const agentName = path.basename(agentDir).toLowerCase().replace(/[^a-z0-9-]/g, '-') || 'opc-agent';
|
|
91
|
+
const envLines = options?.env
|
|
92
|
+
? Object.entries(options.env).map(([k, v]) => ` - ${k}=${v}`).join('\n')
|
|
93
|
+
: '';
|
|
94
|
+
return `version: "3.8"
|
|
95
|
+
|
|
96
|
+
services:
|
|
97
|
+
${agentName}:
|
|
98
|
+
build: .
|
|
99
|
+
ports:
|
|
100
|
+
- "${port}:${port}"
|
|
101
|
+
environment:
|
|
102
|
+
- NODE_ENV=production
|
|
103
|
+
- PORT=${port}
|
|
104
|
+
${envLines ? envLines + '\n' : ''} restart: unless-stopped
|
|
105
|
+
${replicas > 1 ? ` deploy:\n replicas: ${replicas}` : ''}
|
|
106
|
+
volumes:
|
|
107
|
+
- agent-data:/app/data
|
|
108
|
+
|
|
109
|
+
volumes:
|
|
110
|
+
agent-data:
|
|
111
|
+
`;
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Deploy to Railway (via CLI)
|
|
115
|
+
*/
|
|
116
|
+
async deployRailway(agentDir) {
|
|
117
|
+
try {
|
|
118
|
+
(0, child_process_1.execSync)('railway version', { stdio: 'pipe' });
|
|
119
|
+
}
|
|
120
|
+
catch {
|
|
121
|
+
return { platform: 'railway', success: false, message: 'Railway CLI not installed. Run: npm i -g @railway/cli' };
|
|
122
|
+
}
|
|
123
|
+
try {
|
|
124
|
+
// Ensure Dockerfile exists
|
|
125
|
+
const dockerfilePath = path.join(agentDir, 'Dockerfile');
|
|
126
|
+
if (!fs.existsSync(dockerfilePath)) {
|
|
127
|
+
const content = await this.generateDockerfile(agentDir);
|
|
128
|
+
fs.writeFileSync(dockerfilePath, content);
|
|
129
|
+
}
|
|
130
|
+
const output = (0, child_process_1.execSync)('railway up --detach', { cwd: agentDir, encoding: 'utf-8' });
|
|
131
|
+
const urlMatch = output.match(/(https:\/\/[^\s]+)/);
|
|
132
|
+
return {
|
|
133
|
+
platform: 'railway',
|
|
134
|
+
success: true,
|
|
135
|
+
url: urlMatch?.[1],
|
|
136
|
+
message: 'Deployed to Railway successfully'
|
|
137
|
+
};
|
|
138
|
+
}
|
|
139
|
+
catch (e) {
|
|
140
|
+
return { platform: 'railway', success: false, message: e.message };
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
/**
|
|
144
|
+
* Deploy to Fly.io
|
|
145
|
+
*/
|
|
146
|
+
async deployFly(agentDir) {
|
|
147
|
+
try {
|
|
148
|
+
(0, child_process_1.execSync)('fly version', { stdio: 'pipe' });
|
|
149
|
+
}
|
|
150
|
+
catch {
|
|
151
|
+
return { platform: 'fly', success: false, message: 'Fly CLI not installed. Run: curl -L https://fly.io/install.sh | sh' };
|
|
152
|
+
}
|
|
153
|
+
try {
|
|
154
|
+
const agentName = path.basename(agentDir).toLowerCase().replace(/[^a-z0-9-]/g, '-');
|
|
155
|
+
// Generate fly.toml if not exists
|
|
156
|
+
const flyTomlPath = path.join(agentDir, 'fly.toml');
|
|
157
|
+
if (!fs.existsSync(flyTomlPath)) {
|
|
158
|
+
fs.writeFileSync(flyTomlPath, `app = "${agentName}"
|
|
159
|
+
primary_region = "sjc"
|
|
160
|
+
|
|
161
|
+
[build]
|
|
162
|
+
|
|
163
|
+
[http_service]
|
|
164
|
+
internal_port = 3000
|
|
165
|
+
force_https = true
|
|
166
|
+
auto_stop_machines = true
|
|
167
|
+
auto_start_machines = true
|
|
168
|
+
|
|
169
|
+
[checks]
|
|
170
|
+
[checks.alive]
|
|
171
|
+
type = "tcp"
|
|
172
|
+
port = 3000
|
|
173
|
+
`);
|
|
174
|
+
}
|
|
175
|
+
// Ensure Dockerfile exists
|
|
176
|
+
const dockerfilePath = path.join(agentDir, 'Dockerfile');
|
|
177
|
+
if (!fs.existsSync(dockerfilePath)) {
|
|
178
|
+
const content = await this.generateDockerfile(agentDir);
|
|
179
|
+
fs.writeFileSync(dockerfilePath, content);
|
|
180
|
+
}
|
|
181
|
+
const output = (0, child_process_1.execSync)('fly deploy', { cwd: agentDir, encoding: 'utf-8' });
|
|
182
|
+
return {
|
|
183
|
+
platform: 'fly',
|
|
184
|
+
success: true,
|
|
185
|
+
url: `https://${agentName}.fly.dev`,
|
|
186
|
+
message: 'Deployed to Fly.io successfully'
|
|
187
|
+
};
|
|
188
|
+
}
|
|
189
|
+
catch (e) {
|
|
190
|
+
return { platform: 'fly', success: false, message: e.message };
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
/**
|
|
194
|
+
* Deploy locally via Docker
|
|
195
|
+
*/
|
|
196
|
+
async deployLocal(agentDir, options) {
|
|
197
|
+
try {
|
|
198
|
+
(0, child_process_1.execSync)('docker version', { stdio: 'pipe' });
|
|
199
|
+
}
|
|
200
|
+
catch {
|
|
201
|
+
return { platform: 'docker', success: false, message: 'Docker not installed or not running' };
|
|
202
|
+
}
|
|
203
|
+
const files = [];
|
|
204
|
+
// Generate Dockerfile
|
|
205
|
+
const dockerfilePath = path.join(agentDir, 'Dockerfile');
|
|
206
|
+
if (!fs.existsSync(dockerfilePath)) {
|
|
207
|
+
fs.writeFileSync(dockerfilePath, await this.generateDockerfile(agentDir, options));
|
|
208
|
+
files.push('Dockerfile');
|
|
209
|
+
}
|
|
210
|
+
// Generate docker-compose.yml
|
|
211
|
+
const composePath = path.join(agentDir, 'docker-compose.yml');
|
|
212
|
+
if (!fs.existsSync(composePath)) {
|
|
213
|
+
fs.writeFileSync(composePath, await this.generateCompose(agentDir, options));
|
|
214
|
+
files.push('docker-compose.yml');
|
|
215
|
+
}
|
|
216
|
+
try {
|
|
217
|
+
(0, child_process_1.execSync)('docker compose up -d --build', { cwd: agentDir, stdio: 'inherit' });
|
|
218
|
+
const port = options?.port || 3000;
|
|
219
|
+
return {
|
|
220
|
+
platform: 'docker',
|
|
221
|
+
success: true,
|
|
222
|
+
url: `http://localhost:${port}`,
|
|
223
|
+
message: 'Running locally via Docker',
|
|
224
|
+
files
|
|
225
|
+
};
|
|
226
|
+
}
|
|
227
|
+
catch (e) {
|
|
228
|
+
return { platform: 'docker', success: false, message: e.message, files };
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
/**
|
|
232
|
+
* Generate deployment files without deploying
|
|
233
|
+
*/
|
|
234
|
+
async generateFiles(agentDir, options) {
|
|
235
|
+
const files = [];
|
|
236
|
+
const port = options?.port || 3000;
|
|
237
|
+
const dockerfile = await this.generateDockerfile(agentDir, options);
|
|
238
|
+
fs.writeFileSync(path.join(agentDir, 'Dockerfile'), dockerfile);
|
|
239
|
+
files.push('Dockerfile');
|
|
240
|
+
const compose = await this.generateCompose(agentDir, options);
|
|
241
|
+
fs.writeFileSync(path.join(agentDir, 'docker-compose.yml'), compose);
|
|
242
|
+
files.push('docker-compose.yml');
|
|
243
|
+
// Generate .dockerignore
|
|
244
|
+
const dockerignore = `node_modules
|
|
245
|
+
.git
|
|
246
|
+
.env
|
|
247
|
+
*.log
|
|
248
|
+
dist
|
|
249
|
+
`;
|
|
250
|
+
fs.writeFileSync(path.join(agentDir, '.dockerignore'), dockerignore);
|
|
251
|
+
files.push('.dockerignore');
|
|
252
|
+
return {
|
|
253
|
+
platform: 'docker',
|
|
254
|
+
success: true,
|
|
255
|
+
message: `Generated ${files.length} deployment files`,
|
|
256
|
+
files,
|
|
257
|
+
};
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
exports.AgentDeployer = AgentDeployer;
|
|
261
|
+
//# sourceMappingURL=index.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -35,7 +35,8 @@ export type { A2ARequest, A2AResponse, AgentCapability, AgentRegistration, Agent
|
|
|
35
35
|
export { HITLManager } from './core/hitl';
|
|
36
36
|
export type { ApprovalRequest, ApprovalResponse, HITLConfig } from './core/hitl';
|
|
37
37
|
export { VoiceChannel } from './channels/voice';
|
|
38
|
-
export type { VoiceChannelConfig, STTProvider, TTSProvider } from './channels/voice';
|
|
38
|
+
export type { VoiceChannelConfig, STTProvider, TTSProvider, VoiceConfig } from './channels/voice';
|
|
39
|
+
export { WhisperSTTProvider, DeepgramSTTProvider, EdgeTTSProvider, OpenAITTSProvider, ElevenLabsTTSProvider, createVoiceProviders } from './channels/voice';
|
|
39
40
|
export { WebhookChannel } from './channels/webhook';
|
|
40
41
|
export type { WebhookConfig, WebhookPayload } from './channels/webhook';
|
|
41
42
|
export { VersionManager } from './core/versioning';
|
|
@@ -90,6 +91,8 @@ export type { PluginManifest, Plugin } from './plugins';
|
|
|
90
91
|
export { loggerPlugin } from './plugins/logger';
|
|
91
92
|
export { rateLimiterPlugin, createRateLimiterPlugin as createEnhancedRateLimiterPlugin } from './plugins/rate-limiter';
|
|
92
93
|
export { contentFilterPlugin, createContentFilterPlugin } from './plugins/content-filter';
|
|
94
|
+
export { GuardrailManager, createGuardrailsFromConfig } from './security/guardrails';
|
|
95
|
+
export type { GuardrailConfig, GuardrailRule, GuardrailResult, GuardrailViolation } from './security/guardrails';
|
|
93
96
|
export { FeishuChannel } from './channels/feishu';
|
|
94
97
|
export type { FeishuChannelConfig } from './channels/feishu';
|
|
95
98
|
export { DiscordChannel } from './channels/discord';
|
|
@@ -124,5 +127,8 @@ export { AgentEvaluator } from './eval';
|
|
|
124
127
|
export type { EvalCase, EvalResult, EvalSuite, EvalReport } from './eval';
|
|
125
128
|
export { AGUIServer, AGUIEventEmitter, AGUIClient } from './protocols/agui';
|
|
126
129
|
export { AGUI_EVENT_TYPES, isValidEventType } from './protocols/agui';
|
|
130
|
+
export { DebatePattern, VotingPattern, PipelinePattern, HierarchyPattern, SharedContext, ConversationProtocol } from './core/collaboration';
|
|
131
|
+
export type { DebateResult, DebateArgument, VoteResult, VoteEntry, PipelineResult, PipelineStageResult, HierarchyResult, WorkerResult } from './core/collaboration';
|
|
127
132
|
export type { AGUIEvent, AGUIEventType, AGUIMessage, AGUIRunRequest, AGUIToolCall, AGUIToolDefinition, TextMessageStartEvent, TextMessageContentEvent, TextMessageEndEvent, ToolCallStartEvent, ToolCallArgsEvent, ToolCallEndEvent, StateSnapshotEvent, StateDeltaEvent, MessagesSnapshotEvent, RunStartedEvent, RunFinishedEvent, RunErrorEvent, StepStartedEvent, StepFinishedEvent, CustomEvent, } from './protocols/agui';
|
|
133
|
+
export { SlackTool, EmailSendTool, WebhookTool, NotionTool, GitHubTool, JiraTool, CalendarTool, TrelloTool, WebSearchTool, WebScraperTool, DatabaseTool, VectorSearchTool, CodeExecutionTool, GitTool, NpmTool, ImageGenerationTool, PDFReaderTool, CSVAnalyzerTool, SummarizerTool, TranslatorTool, getAllIntegrationTools, getIntegrationTool, } from './tools/integrations';
|
|
128
134
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
5
|
-
exports.isValidEventType = exports.AGUI_EVENT_TYPES = exports.AGUIClient = exports.AGUIEventEmitter = exports.AGUIServer = exports.AgentEvaluator = exports.agentToMCPResources = exports.agentToMCPTools = exports.MCPServer = exports.JSON_RPC_ERRORS = exports.oadToAgentCard = exports.A2AClient = exports.A2AServer = exports.StudioServer = exports.AgentInstaller = exports.AgentPublisher = exports.AgentPackager = exports.MCPClient = exports.getBuiltinToolsByName = exports.getBuiltinTools = exports.cronMatches = exports.parseCron = exports.Scheduler = exports.SubAgentManager = exports.generateSpanId = exports.generateTraceId = exports.OTLPHttpExporter = exports.FileExporter = exports.ConsoleExporter = exports.Tracer = exports.DeepBrainExporter = exports.TraceConsoleExporter = exports.TraceCollector = exports.StreamableResponse = exports.StreamingManager = exports.ToolGateway = exports.ProcessWatcher = void 0;
|
|
3
|
+
exports.KnowledgeBase = exports.addMessages = exports.detectLocale = exports.getLocale = exports.setLocale = exports.t = exports.LazyLoader = exports.RequestBatcher = exports.ConnectionPool = exports.VersionManager = exports.WebhookChannel = exports.createVoiceProviders = exports.ElevenLabsTTSProvider = exports.OpenAITTSProvider = exports.EdgeTTSProvider = exports.DeepgramSTTProvider = exports.WhisperSTTProvider = exports.VoiceChannel = exports.HITLManager = exports.AgentCardRegistry = exports.AgentRegistry = exports.parseOADWorkflow = exports.WorkflowBuilder = exports.GraphWorkflowEngine = exports.WorkflowEngine = exports.Analytics = exports.KeyManager = exports.ApprovalManager = exports.Sandbox = exports.PluginManager = exports.createMCPTool = exports.MCPToolRegistry = exports.Room = exports.SUPPORTED_PROVIDERS = exports.createProvider = exports.DeepBrainMemoryStore = exports.InMemoryStore = exports.SkillRegistry = exports.BaseSkill = exports.WebSocketChannel = exports.TelegramChannel = exports.WebChannel = exports.BaseChannel = exports.OADSchema = exports.validateOAD = exports.loadOAD = exports.Logger = exports.truncateOutput = exports.AgentRuntime = exports.BaseAgent = void 0;
|
|
4
|
+
exports.loggerPlugin = exports.createRateLimitPlugin = exports.createAnalyticsPlugin = exports.createLoggingPlugin = exports.inputValidation = exports.APIKeyManager = exports.corsMiddleware = exports.securityHeaders = exports.detectInjection = exports.sanitizeInput = exports.formatErrorForUser = exports.wrapError = exports.TimeoutError = exports.SecurityError = exports.RateLimitError = exports.PluginError = exports.ChannelError = exports.ConfigError = exports.ValidationError = exports.ProviderError = exports.OPCError = exports.createTeacherConfig = exports.createDataAnalystConfig = exports.getSupportedLocales = exports.LLMCache = exports.RateLimiter = exports.AnalyticsEngine = exports.formatReport = exports.loadTestCases = exports.runTests = exports.parseSkillMarkdown = exports.skillToMarkdown = exports.SkillLearner = exports.DocumentSkill = exports.SchedulerSkill = exports.WebhookTriggerSkill = exports.HttpSkill = exports.TextAnalysisTool = exports.JsonTransformTool = exports.DateTimeTool = exports.CalculatorTool = exports.WeChatChannel = exports.SlackChannel = exports.EmailChannel = exports.compose = exports.AgentPipeline = exports.Orchestrator = exports.getActiveSessions = exports.createAuthMiddleware = exports.deployToHermes = void 0;
|
|
5
|
+
exports.SharedContext = exports.HierarchyPattern = exports.PipelinePattern = exports.VotingPattern = exports.DebatePattern = exports.isValidEventType = exports.AGUI_EVENT_TYPES = exports.AGUIClient = exports.AGUIEventEmitter = exports.AGUIServer = exports.AgentEvaluator = exports.agentToMCPResources = exports.agentToMCPTools = exports.MCPServer = exports.JSON_RPC_ERRORS = exports.oadToAgentCard = exports.A2AClient = exports.A2AServer = exports.StudioServer = exports.AgentInstaller = exports.AgentPublisher = exports.AgentPackager = exports.MCPClient = exports.getBuiltinToolsByName = exports.getBuiltinTools = exports.cronMatches = exports.parseCron = exports.Scheduler = exports.SubAgentManager = exports.generateSpanId = exports.generateTraceId = exports.OTLPHttpExporter = exports.FileExporter = exports.ConsoleExporter = exports.Tracer = exports.DeepBrainExporter = exports.TraceConsoleExporter = exports.TraceCollector = exports.StreamableResponse = exports.StreamingManager = exports.ToolGateway = exports.ProcessWatcher = exports.DiscordChannel = exports.FeishuChannel = exports.createGuardrailsFromConfig = exports.GuardrailManager = exports.createContentFilterPlugin = exports.contentFilterPlugin = exports.createEnhancedRateLimiterPlugin = exports.rateLimiterPlugin = void 0;
|
|
6
|
+
exports.getIntegrationTool = exports.getAllIntegrationTools = exports.TranslatorTool = exports.SummarizerTool = exports.CSVAnalyzerTool = exports.PDFReaderTool = exports.ImageGenerationTool = exports.NpmTool = exports.GitTool = exports.CodeExecutionTool = exports.VectorSearchTool = exports.DatabaseTool = exports.WebScraperTool = exports.WebSearchTool = exports.TrelloTool = exports.CalendarTool = exports.JiraTool = exports.GitHubTool = exports.NotionTool = exports.WebhookTool = exports.EmailSendTool = exports.SlackTool = exports.ConversationProtocol = void 0;
|
|
6
7
|
// OPC Agent — Open Agent Framework
|
|
7
8
|
var agent_1 = require("./core/agent");
|
|
8
9
|
Object.defineProperty(exports, "BaseAgent", { enumerable: true, get: function () { return agent_1.BaseAgent; } });
|
|
@@ -65,6 +66,13 @@ var hitl_1 = require("./core/hitl");
|
|
|
65
66
|
Object.defineProperty(exports, "HITLManager", { enumerable: true, get: function () { return hitl_1.HITLManager; } });
|
|
66
67
|
var voice_1 = require("./channels/voice");
|
|
67
68
|
Object.defineProperty(exports, "VoiceChannel", { enumerable: true, get: function () { return voice_1.VoiceChannel; } });
|
|
69
|
+
var voice_2 = require("./channels/voice");
|
|
70
|
+
Object.defineProperty(exports, "WhisperSTTProvider", { enumerable: true, get: function () { return voice_2.WhisperSTTProvider; } });
|
|
71
|
+
Object.defineProperty(exports, "DeepgramSTTProvider", { enumerable: true, get: function () { return voice_2.DeepgramSTTProvider; } });
|
|
72
|
+
Object.defineProperty(exports, "EdgeTTSProvider", { enumerable: true, get: function () { return voice_2.EdgeTTSProvider; } });
|
|
73
|
+
Object.defineProperty(exports, "OpenAITTSProvider", { enumerable: true, get: function () { return voice_2.OpenAITTSProvider; } });
|
|
74
|
+
Object.defineProperty(exports, "ElevenLabsTTSProvider", { enumerable: true, get: function () { return voice_2.ElevenLabsTTSProvider; } });
|
|
75
|
+
Object.defineProperty(exports, "createVoiceProviders", { enumerable: true, get: function () { return voice_2.createVoiceProviders; } });
|
|
68
76
|
var webhook_1 = require("./channels/webhook");
|
|
69
77
|
Object.defineProperty(exports, "WebhookChannel", { enumerable: true, get: function () { return webhook_1.WebhookChannel; } });
|
|
70
78
|
var versioning_1 = require("./core/versioning");
|
|
@@ -169,6 +177,10 @@ Object.defineProperty(exports, "createEnhancedRateLimiterPlugin", { enumerable:
|
|
|
169
177
|
var content_filter_1 = require("./plugins/content-filter");
|
|
170
178
|
Object.defineProperty(exports, "contentFilterPlugin", { enumerable: true, get: function () { return content_filter_1.contentFilterPlugin; } });
|
|
171
179
|
Object.defineProperty(exports, "createContentFilterPlugin", { enumerable: true, get: function () { return content_filter_1.createContentFilterPlugin; } });
|
|
180
|
+
// v2.1.0 — Guardrails
|
|
181
|
+
var guardrails_1 = require("./security/guardrails");
|
|
182
|
+
Object.defineProperty(exports, "GuardrailManager", { enumerable: true, get: function () { return guardrails_1.GuardrailManager; } });
|
|
183
|
+
Object.defineProperty(exports, "createGuardrailsFromConfig", { enumerable: true, get: function () { return guardrails_1.createGuardrailsFromConfig; } });
|
|
172
184
|
// v1.1.0 modules
|
|
173
185
|
var feishu_1 = require("./channels/feishu");
|
|
174
186
|
Object.defineProperty(exports, "FeishuChannel", { enumerable: true, get: function () { return feishu_1.FeishuChannel; } });
|
|
@@ -240,4 +252,36 @@ Object.defineProperty(exports, "AGUIClient", { enumerable: true, get: function (
|
|
|
240
252
|
var agui_2 = require("./protocols/agui");
|
|
241
253
|
Object.defineProperty(exports, "AGUI_EVENT_TYPES", { enumerable: true, get: function () { return agui_2.AGUI_EVENT_TYPES; } });
|
|
242
254
|
Object.defineProperty(exports, "isValidEventType", { enumerable: true, get: function () { return agui_2.isValidEventType; } });
|
|
255
|
+
// v2.0.0 - Multi-agent collaboration patterns
|
|
256
|
+
var collaboration_1 = require("./core/collaboration");
|
|
257
|
+
Object.defineProperty(exports, "DebatePattern", { enumerable: true, get: function () { return collaboration_1.DebatePattern; } });
|
|
258
|
+
Object.defineProperty(exports, "VotingPattern", { enumerable: true, get: function () { return collaboration_1.VotingPattern; } });
|
|
259
|
+
Object.defineProperty(exports, "PipelinePattern", { enumerable: true, get: function () { return collaboration_1.PipelinePattern; } });
|
|
260
|
+
Object.defineProperty(exports, "HierarchyPattern", { enumerable: true, get: function () { return collaboration_1.HierarchyPattern; } });
|
|
261
|
+
Object.defineProperty(exports, "SharedContext", { enumerable: true, get: function () { return collaboration_1.SharedContext; } });
|
|
262
|
+
Object.defineProperty(exports, "ConversationProtocol", { enumerable: true, get: function () { return collaboration_1.ConversationProtocol; } });
|
|
263
|
+
// v2.0.0 - Pre-built tool integrations (20 tools)
|
|
264
|
+
var integrations_1 = require("./tools/integrations");
|
|
265
|
+
Object.defineProperty(exports, "SlackTool", { enumerable: true, get: function () { return integrations_1.SlackTool; } });
|
|
266
|
+
Object.defineProperty(exports, "EmailSendTool", { enumerable: true, get: function () { return integrations_1.EmailSendTool; } });
|
|
267
|
+
Object.defineProperty(exports, "WebhookTool", { enumerable: true, get: function () { return integrations_1.WebhookTool; } });
|
|
268
|
+
Object.defineProperty(exports, "NotionTool", { enumerable: true, get: function () { return integrations_1.NotionTool; } });
|
|
269
|
+
Object.defineProperty(exports, "GitHubTool", { enumerable: true, get: function () { return integrations_1.GitHubTool; } });
|
|
270
|
+
Object.defineProperty(exports, "JiraTool", { enumerable: true, get: function () { return integrations_1.JiraTool; } });
|
|
271
|
+
Object.defineProperty(exports, "CalendarTool", { enumerable: true, get: function () { return integrations_1.CalendarTool; } });
|
|
272
|
+
Object.defineProperty(exports, "TrelloTool", { enumerable: true, get: function () { return integrations_1.TrelloTool; } });
|
|
273
|
+
Object.defineProperty(exports, "WebSearchTool", { enumerable: true, get: function () { return integrations_1.WebSearchTool; } });
|
|
274
|
+
Object.defineProperty(exports, "WebScraperTool", { enumerable: true, get: function () { return integrations_1.WebScraperTool; } });
|
|
275
|
+
Object.defineProperty(exports, "DatabaseTool", { enumerable: true, get: function () { return integrations_1.DatabaseTool; } });
|
|
276
|
+
Object.defineProperty(exports, "VectorSearchTool", { enumerable: true, get: function () { return integrations_1.VectorSearchTool; } });
|
|
277
|
+
Object.defineProperty(exports, "CodeExecutionTool", { enumerable: true, get: function () { return integrations_1.CodeExecutionTool; } });
|
|
278
|
+
Object.defineProperty(exports, "GitTool", { enumerable: true, get: function () { return integrations_1.GitTool; } });
|
|
279
|
+
Object.defineProperty(exports, "NpmTool", { enumerable: true, get: function () { return integrations_1.NpmTool; } });
|
|
280
|
+
Object.defineProperty(exports, "ImageGenerationTool", { enumerable: true, get: function () { return integrations_1.ImageGenerationTool; } });
|
|
281
|
+
Object.defineProperty(exports, "PDFReaderTool", { enumerable: true, get: function () { return integrations_1.PDFReaderTool; } });
|
|
282
|
+
Object.defineProperty(exports, "CSVAnalyzerTool", { enumerable: true, get: function () { return integrations_1.CSVAnalyzerTool; } });
|
|
283
|
+
Object.defineProperty(exports, "SummarizerTool", { enumerable: true, get: function () { return integrations_1.SummarizerTool; } });
|
|
284
|
+
Object.defineProperty(exports, "TranslatorTool", { enumerable: true, get: function () { return integrations_1.TranslatorTool; } });
|
|
285
|
+
Object.defineProperty(exports, "getAllIntegrationTools", { enumerable: true, get: function () { return integrations_1.getAllIntegrationTools; } });
|
|
286
|
+
Object.defineProperty(exports, "getIntegrationTool", { enumerable: true, get: function () { return integrations_1.getIntegrationTool; } });
|
|
243
287
|
//# sourceMappingURL=index.js.map
|