@wundr.io/autogen-orchestrator 1.0.3

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.
@@ -0,0 +1,569 @@
1
+ "use strict";
2
+ /**
3
+ * Speaker Selection Strategies for AutoGen-style Group Chat
4
+ *
5
+ * Implements various strategies for selecting the next speaker in a
6
+ * multi-agent conversation, including round-robin, LLM-selected, and priority-based.
7
+ */
8
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.SpeakerSelectionManager = exports.AutoSelector = exports.ManualSelector = exports.PrioritySelector = exports.LLMSelector = exports.RandomSelector = exports.RoundRobinSelector = void 0;
10
+ exports.createSpeakerSelector = createSpeakerSelector;
11
+ /**
12
+ * Factory function to create speaker selection strategies
13
+ * @param method - The speaker selection method to use
14
+ * @returns The appropriate speaker selection strategy
15
+ */
16
+ function createSpeakerSelector(method) {
17
+ switch (method) {
18
+ case 'round_robin':
19
+ return new RoundRobinSelector();
20
+ case 'random':
21
+ return new RandomSelector();
22
+ case 'llm_selected':
23
+ return new LLMSelector();
24
+ case 'priority':
25
+ return new PrioritySelector();
26
+ case 'manual':
27
+ return new ManualSelector();
28
+ case 'auto':
29
+ return new AutoSelector();
30
+ default:
31
+ return new RoundRobinSelector();
32
+ }
33
+ }
34
+ /**
35
+ * Round-robin speaker selection - cycles through participants in order
36
+ */
37
+ class RoundRobinSelector {
38
+ currentIndex = 0;
39
+ /**
40
+ * Select the next speaker using round-robin ordering
41
+ * @param participants - Available participants
42
+ * @param messages - Message history
43
+ * @param context - Current chat context
44
+ * @param _config - Optional configuration (unused)
45
+ * @returns Speaker selection result
46
+ */
47
+ async selectSpeaker(participants, messages, _context, _config) {
48
+ const activeParticipants = participants.filter(p => p.status === 'active' || p.status === 'idle');
49
+ if (activeParticipants.length === 0) {
50
+ throw new Error('No active participants available for selection');
51
+ }
52
+ // Find the last speaker and get the next one
53
+ const lastMessage = messages[messages.length - 1];
54
+ if (lastMessage) {
55
+ const lastSpeakerIndex = activeParticipants.findIndex(p => p.name === lastMessage.name);
56
+ if (lastSpeakerIndex !== -1) {
57
+ this.currentIndex = (lastSpeakerIndex + 1) % activeParticipants.length;
58
+ }
59
+ }
60
+ const selectedParticipant = activeParticipants[this.currentIndex];
61
+ if (!selectedParticipant) {
62
+ throw new Error('Failed to select participant in round-robin');
63
+ }
64
+ return {
65
+ speaker: selectedParticipant.name,
66
+ reason: `Round-robin selection: position ${this.currentIndex + 1} of ${activeParticipants.length}`,
67
+ confidence: 1.0,
68
+ alternatives: activeParticipants
69
+ .filter(p => p.name !== selectedParticipant.name)
70
+ .map(p => p.name),
71
+ };
72
+ }
73
+ /**
74
+ * Reset the round-robin index
75
+ */
76
+ reset() {
77
+ this.currentIndex = 0;
78
+ }
79
+ }
80
+ exports.RoundRobinSelector = RoundRobinSelector;
81
+ /**
82
+ * Random speaker selection - randomly selects from available participants
83
+ */
84
+ class RandomSelector {
85
+ /**
86
+ * Select the next speaker randomly
87
+ * @param participants - Available participants
88
+ * @param messages - Message history
89
+ * @param context - Current chat context
90
+ * @param config - Optional configuration
91
+ * @returns Speaker selection result
92
+ */
93
+ async selectSpeaker(participants, messages, context, config) {
94
+ const activeParticipants = participants.filter(p => p.status === 'active' || p.status === 'idle');
95
+ if (activeParticipants.length === 0) {
96
+ throw new Error('No active participants available for selection');
97
+ }
98
+ // Optionally exclude the last speaker
99
+ const lastMessage = messages[messages.length - 1];
100
+ let eligibleParticipants = activeParticipants;
101
+ if (lastMessage && activeParticipants.length > 1) {
102
+ eligibleParticipants = activeParticipants.filter(p => p.name !== lastMessage.name);
103
+ }
104
+ // Apply weights if configured
105
+ let selectedParticipant;
106
+ if (config?.weights && Object.keys(config.weights).length > 0) {
107
+ selectedParticipant = this.weightedSelection(eligibleParticipants, config.weights);
108
+ }
109
+ else {
110
+ const randomIndex = Math.floor(Math.random() * eligibleParticipants.length);
111
+ selectedParticipant = eligibleParticipants[randomIndex];
112
+ }
113
+ return {
114
+ speaker: selectedParticipant.name,
115
+ reason: 'Random selection from eligible participants',
116
+ confidence: 1 / eligibleParticipants.length,
117
+ alternatives: eligibleParticipants
118
+ .filter(p => p.name !== selectedParticipant.name)
119
+ .map(p => p.name),
120
+ };
121
+ }
122
+ /**
123
+ * Perform weighted random selection
124
+ * @param participants - Participants to select from
125
+ * @param weights - Weight for each participant
126
+ * @returns Selected participant
127
+ */
128
+ weightedSelection(participants, weights) {
129
+ const totalWeight = participants.reduce((sum, p) => sum + (weights[p.name] || 1), 0);
130
+ let random = Math.random() * totalWeight;
131
+ for (const participant of participants) {
132
+ const weight = weights[participant.name] || 1;
133
+ random -= weight;
134
+ if (random <= 0) {
135
+ return participant;
136
+ }
137
+ }
138
+ // Fallback to last participant
139
+ return participants[participants.length - 1];
140
+ }
141
+ }
142
+ exports.RandomSelector = RandomSelector;
143
+ /**
144
+ * LLM-based speaker selection - uses an LLM to determine the best next speaker
145
+ */
146
+ class LLMSelector {
147
+ /**
148
+ * Select the next speaker using LLM reasoning
149
+ * @param participants - Available participants
150
+ * @param messages - Message history
151
+ * @param context - Current chat context
152
+ * @param config - Configuration including LLM settings
153
+ * @returns Speaker selection result
154
+ */
155
+ async selectSpeaker(participants, messages, context, config) {
156
+ const activeParticipants = participants.filter(p => p.status === 'active' || p.status === 'idle');
157
+ if (activeParticipants.length === 0) {
158
+ throw new Error('No active participants available for selection');
159
+ }
160
+ // Build the selection prompt
161
+ const selectionPrompt = this.buildSelectionPrompt(activeParticipants, messages, context, config);
162
+ // Simulate LLM selection (in real implementation, call actual LLM)
163
+ const selectedName = await this.simulateLLMSelection(selectionPrompt, activeParticipants, messages);
164
+ const selectedParticipant = activeParticipants.find(p => p.name === selectedName);
165
+ if (!selectedParticipant) {
166
+ // Fallback to first active participant
167
+ const fallback = activeParticipants[0];
168
+ return {
169
+ speaker: fallback.name,
170
+ reason: 'LLM selection fallback: invalid selection returned',
171
+ confidence: 0.5,
172
+ alternatives: activeParticipants
173
+ .filter(p => p.name !== fallback.name)
174
+ .map(p => p.name),
175
+ };
176
+ }
177
+ return {
178
+ speaker: selectedParticipant.name,
179
+ reason: 'LLM selected based on conversation context and participant capabilities',
180
+ confidence: 0.85,
181
+ alternatives: activeParticipants
182
+ .filter(p => p.name !== selectedParticipant.name)
183
+ .map(p => p.name),
184
+ };
185
+ }
186
+ /**
187
+ * Build the prompt for LLM speaker selection
188
+ * @param participants - Available participants
189
+ * @param messages - Message history
190
+ * @param context - Chat context
191
+ * @param config - Selection configuration
192
+ * @returns Formatted prompt string
193
+ */
194
+ buildSelectionPrompt(participants, messages, context, config) {
195
+ const participantDescriptions = participants
196
+ .map(p => `- ${p.name}: ${p.description || p.systemPrompt.slice(0, 100)}...`)
197
+ .join('\n');
198
+ const recentMessages = messages
199
+ .slice(-5)
200
+ .map(m => `${m.name}: ${m.content.slice(0, 200)}`)
201
+ .join('\n');
202
+ const basePrompt = config?.selectorPrompt ||
203
+ 'You are a conversation moderator. Select the most appropriate next speaker.';
204
+ return `${basePrompt}
205
+
206
+ ## Available Participants:
207
+ ${participantDescriptions}
208
+
209
+ ## Recent Conversation:
210
+ ${recentMessages}
211
+
212
+ ## Context:
213
+ - Current round: ${context.currentRound}
214
+ - Previous speaker: ${context.previousSpeaker || 'None'}
215
+
216
+ Based on the conversation flow and participant expertise, who should speak next?
217
+ Return only the participant name.`;
218
+ }
219
+ /**
220
+ * Simulate LLM selection (placeholder for actual LLM call)
221
+ * @param prompt - Selection prompt
222
+ * @param participants - Available participants
223
+ * @param messages - Message history
224
+ * @returns Selected participant name
225
+ */
226
+ async simulateLLMSelection(_prompt, participants, messages) {
227
+ // In a real implementation, this would call an actual LLM
228
+ // For now, use heuristics to simulate intelligent selection
229
+ const lastMessage = messages[messages.length - 1];
230
+ // Find participant most relevant to the last message content
231
+ if (lastMessage) {
232
+ const relevantParticipant = this.findMostRelevantParticipant(lastMessage.content, participants);
233
+ if (relevantParticipant) {
234
+ return relevantParticipant.name;
235
+ }
236
+ }
237
+ // Exclude last speaker and select randomly
238
+ const eligibleParticipants = lastMessage
239
+ ? participants.filter(p => p.name !== lastMessage.name)
240
+ : participants;
241
+ const randomIndex = Math.floor(Math.random() * eligibleParticipants.length);
242
+ return eligibleParticipants[randomIndex]?.name || participants[0].name;
243
+ }
244
+ /**
245
+ * Find the participant most relevant to the given content
246
+ * @param content - Message content to analyze
247
+ * @param participants - Available participants
248
+ * @returns Most relevant participant or null
249
+ */
250
+ findMostRelevantParticipant(content, participants) {
251
+ const contentLower = content.toLowerCase();
252
+ // Score each participant based on capability match
253
+ let bestMatch = null;
254
+ let bestScore = 0;
255
+ for (const participant of participants) {
256
+ let score = 0;
257
+ // Check capabilities
258
+ for (const capability of participant.capabilities) {
259
+ if (contentLower.includes(capability.toLowerCase())) {
260
+ score += 2;
261
+ }
262
+ }
263
+ // Check if participant is mentioned
264
+ if (contentLower.includes(participant.name.toLowerCase())) {
265
+ score += 5;
266
+ }
267
+ // Check description keywords
268
+ if (participant.description) {
269
+ const descWords = participant.description.toLowerCase().split(/\s+/);
270
+ for (const word of descWords) {
271
+ if (word.length > 4 && contentLower.includes(word)) {
272
+ score += 1;
273
+ }
274
+ }
275
+ }
276
+ if (score > bestScore) {
277
+ bestScore = score;
278
+ bestMatch = participant;
279
+ }
280
+ }
281
+ return bestScore > 0 ? bestMatch : null;
282
+ }
283
+ }
284
+ exports.LLMSelector = LLMSelector;
285
+ /**
286
+ * Priority-based speaker selection - selects based on configured priority order
287
+ */
288
+ class PrioritySelector {
289
+ /**
290
+ * Select the next speaker based on priority order
291
+ * @param participants - Available participants
292
+ * @param messages - Message history
293
+ * @param context - Current chat context
294
+ * @param config - Configuration with priority order
295
+ * @returns Speaker selection result
296
+ */
297
+ async selectSpeaker(participants, messages, context, config) {
298
+ const activeParticipants = participants.filter(p => p.status === 'active' || p.status === 'idle');
299
+ if (activeParticipants.length === 0) {
300
+ throw new Error('No active participants available for selection');
301
+ }
302
+ const priorityOrder = config?.priorityOrder || [];
303
+ const lastMessage = messages[messages.length - 1];
304
+ // Check transition rules first
305
+ if (config?.transitionRules && lastMessage) {
306
+ const nextSpeaker = this.applyTransitionRules(lastMessage.name, config.transitionRules, activeParticipants);
307
+ if (nextSpeaker) {
308
+ return {
309
+ speaker: nextSpeaker.name,
310
+ reason: `Transition rule: ${lastMessage.name} -> ${nextSpeaker.name}`,
311
+ confidence: 0.9,
312
+ alternatives: activeParticipants
313
+ .filter(p => p.name !== nextSpeaker.name)
314
+ .map(p => p.name),
315
+ };
316
+ }
317
+ }
318
+ // Check allowed transitions
319
+ if (config?.allowedTransitions && lastMessage) {
320
+ const allowed = config.allowedTransitions[lastMessage.name];
321
+ if (allowed && allowed.length > 0) {
322
+ const eligibleParticipants = activeParticipants.filter(p => allowed.includes(p.name));
323
+ if (eligibleParticipants.length > 0) {
324
+ const selected = eligibleParticipants[0];
325
+ return {
326
+ speaker: selected.name,
327
+ reason: `Allowed transition from ${lastMessage.name}`,
328
+ confidence: 0.85,
329
+ alternatives: eligibleParticipants.slice(1).map(p => p.name),
330
+ };
331
+ }
332
+ }
333
+ }
334
+ // Select based on priority order
335
+ for (const priorityName of priorityOrder) {
336
+ const participant = activeParticipants.find(p => p.name === priorityName);
337
+ if (participant &&
338
+ (!lastMessage || participant.name !== lastMessage.name)) {
339
+ return {
340
+ speaker: participant.name,
341
+ reason: `Priority selection: rank ${priorityOrder.indexOf(priorityName) + 1}`,
342
+ confidence: 0.95,
343
+ alternatives: activeParticipants
344
+ .filter(p => p.name !== participant.name)
345
+ .map(p => p.name),
346
+ };
347
+ }
348
+ }
349
+ // Fallback to first available participant
350
+ const fallback = activeParticipants.find(p => !lastMessage || p.name !== lastMessage.name) || activeParticipants[0];
351
+ return {
352
+ speaker: fallback.name,
353
+ reason: 'Priority fallback: no priority match found',
354
+ confidence: 0.5,
355
+ alternatives: activeParticipants
356
+ .filter(p => p.name !== fallback.name)
357
+ .map(p => p.name),
358
+ };
359
+ }
360
+ /**
361
+ * Apply transition rules to determine next speaker
362
+ * @param fromSpeaker - Current speaker name
363
+ * @param rules - Transition rules
364
+ * @param participants - Available participants
365
+ * @returns Next speaker or null
366
+ */
367
+ applyTransitionRules(fromSpeaker, rules, participants) {
368
+ // Find rules matching the current speaker
369
+ const matchingRules = rules.filter(rule => rule.from === fromSpeaker);
370
+ if (matchingRules.length === 0) {
371
+ return null;
372
+ }
373
+ // Sort by weight if available
374
+ matchingRules.sort((a, b) => (b.weight || 0) - (a.weight || 0));
375
+ // Find the first valid transition
376
+ for (const rule of matchingRules) {
377
+ for (const toName of rule.to) {
378
+ const participant = participants.find(p => p.name === toName && (p.status === 'active' || p.status === 'idle'));
379
+ if (participant) {
380
+ return participant;
381
+ }
382
+ }
383
+ }
384
+ return null;
385
+ }
386
+ }
387
+ exports.PrioritySelector = PrioritySelector;
388
+ /**
389
+ * Manual speaker selection - expects explicit selection from context
390
+ */
391
+ class ManualSelector {
392
+ /**
393
+ * Select the next speaker from manual specification
394
+ * @param participants - Available participants
395
+ * @param messages - Message history
396
+ * @param context - Current chat context with manual selection
397
+ * @returns Speaker selection result
398
+ */
399
+ async selectSpeaker(participants, _messages, context) {
400
+ const activeParticipants = participants.filter(p => p.status === 'active' || p.status === 'idle');
401
+ if (activeParticipants.length === 0) {
402
+ throw new Error('No active participants available for selection');
403
+ }
404
+ // Check for manually specified next speaker in context state
405
+ const manualSelection = context.state['nextSpeaker'];
406
+ if (manualSelection) {
407
+ const participant = activeParticipants.find(p => p.name === manualSelection);
408
+ if (participant) {
409
+ return {
410
+ speaker: participant.name,
411
+ reason: 'Manual selection from context',
412
+ confidence: 1.0,
413
+ alternatives: activeParticipants
414
+ .filter(p => p.name !== participant.name)
415
+ .map(p => p.name),
416
+ };
417
+ }
418
+ }
419
+ // If no manual selection, wait or use fallback
420
+ throw new Error('Manual selection mode requires nextSpeaker in context state');
421
+ }
422
+ }
423
+ exports.ManualSelector = ManualSelector;
424
+ /**
425
+ * Auto speaker selection - intelligently chooses selection strategy based on context
426
+ */
427
+ class AutoSelector {
428
+ roundRobin = new RoundRobinSelector();
429
+ llm = new LLMSelector();
430
+ priority = new PrioritySelector();
431
+ /**
432
+ * Automatically select the best strategy and next speaker
433
+ * @param participants - Available participants
434
+ * @param messages - Message history
435
+ * @param context - Current chat context
436
+ * @param config - Selection configuration
437
+ * @returns Speaker selection result
438
+ */
439
+ async selectSpeaker(participants, messages, context, config) {
440
+ const activeParticipants = participants.filter(p => p.status === 'active' || p.status === 'idle');
441
+ if (activeParticipants.length === 0) {
442
+ throw new Error('No active participants available for selection');
443
+ }
444
+ // Determine best strategy based on context
445
+ const strategy = this.determineStrategy(activeParticipants, messages, context, config);
446
+ let result;
447
+ switch (strategy) {
448
+ case 'priority':
449
+ result = await this.priority.selectSpeaker(participants, messages, context, config);
450
+ break;
451
+ case 'llm':
452
+ result = await this.llm.selectSpeaker(participants, messages, context, config);
453
+ break;
454
+ case 'round_robin':
455
+ default:
456
+ result = await this.roundRobin.selectSpeaker(participants, messages, context, config);
457
+ break;
458
+ }
459
+ return {
460
+ ...result,
461
+ reason: `Auto-selected ${strategy} strategy: ${result.reason}`,
462
+ };
463
+ }
464
+ /**
465
+ * Determine the best selection strategy for current context
466
+ * @param participants - Active participants
467
+ * @param messages - Message history
468
+ * @param context - Chat context
469
+ * @param config - Selection configuration
470
+ * @returns Strategy name to use
471
+ */
472
+ determineStrategy(participants, messages, context, config) {
473
+ // Use priority if transition rules or priority order are configured
474
+ if (config?.transitionRules?.length ||
475
+ config?.priorityOrder?.length ||
476
+ config?.allowedTransitions) {
477
+ return 'priority';
478
+ }
479
+ // Use LLM for complex conversations with many participants
480
+ if (participants.length > 3 && messages.length > 5) {
481
+ return 'llm';
482
+ }
483
+ // Use LLM if participants have distinct capabilities
484
+ const uniqueCapabilities = new Set(participants.flatMap(p => p.capabilities));
485
+ if (uniqueCapabilities.size > participants.length * 2) {
486
+ return 'llm';
487
+ }
488
+ // Default to round-robin for simple cases
489
+ return 'round_robin';
490
+ }
491
+ }
492
+ exports.AutoSelector = AutoSelector;
493
+ /**
494
+ * Speaker selection manager that wraps all strategies
495
+ */
496
+ class SpeakerSelectionManager {
497
+ strategies = new Map();
498
+ currentStrategy;
499
+ method;
500
+ /**
501
+ * Create a new speaker selection manager
502
+ * @param method - Initial selection method
503
+ */
504
+ constructor(method = 'round_robin') {
505
+ this.method = method;
506
+ this.currentStrategy = createSpeakerSelector(method);
507
+ this.initializeStrategies();
508
+ }
509
+ /**
510
+ * Initialize all available strategies
511
+ */
512
+ initializeStrategies() {
513
+ this.strategies.set('round_robin', new RoundRobinSelector());
514
+ this.strategies.set('random', new RandomSelector());
515
+ this.strategies.set('llm_selected', new LLMSelector());
516
+ this.strategies.set('priority', new PrioritySelector());
517
+ this.strategies.set('manual', new ManualSelector());
518
+ this.strategies.set('auto', new AutoSelector());
519
+ }
520
+ /**
521
+ * Select the next speaker using the current strategy
522
+ * @param participants - Available participants
523
+ * @param messages - Message history
524
+ * @param context - Chat context
525
+ * @param config - Selection configuration
526
+ * @returns Speaker selection result
527
+ */
528
+ async selectSpeaker(participants, messages, context, config) {
529
+ return this.currentStrategy.selectSpeaker(participants, messages, context, config);
530
+ }
531
+ /**
532
+ * Change the selection method
533
+ * @param method - New selection method
534
+ */
535
+ setMethod(method) {
536
+ this.method = method;
537
+ const strategy = this.strategies.get(method);
538
+ if (strategy) {
539
+ this.currentStrategy = strategy;
540
+ }
541
+ else {
542
+ this.currentStrategy = createSpeakerSelector(method);
543
+ this.strategies.set(method, this.currentStrategy);
544
+ }
545
+ }
546
+ /**
547
+ * Get the current selection method
548
+ * @returns Current method
549
+ */
550
+ getMethod() {
551
+ return this.method;
552
+ }
553
+ /**
554
+ * Get a specific strategy instance
555
+ * @param method - Selection method
556
+ * @returns Strategy instance
557
+ */
558
+ getStrategy(method) {
559
+ const strategy = this.strategies.get(method);
560
+ if (!strategy) {
561
+ const newStrategy = createSpeakerSelector(method);
562
+ this.strategies.set(method, newStrategy);
563
+ return newStrategy;
564
+ }
565
+ return strategy;
566
+ }
567
+ }
568
+ exports.SpeakerSelectionManager = SpeakerSelectionManager;
569
+ //# sourceMappingURL=speaker-selection.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"speaker-selection.js","sourceRoot":"","sources":["../src/speaker-selection.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAkBH,sDAmBC;AAxBD;;;;GAIG;AACH,SAAgB,qBAAqB,CACnC,MAA8B;IAE9B,QAAQ,MAAM,EAAE,CAAC;QACf,KAAK,aAAa;YAChB,OAAO,IAAI,kBAAkB,EAAE,CAAC;QAClC,KAAK,QAAQ;YACX,OAAO,IAAI,cAAc,EAAE,CAAC;QAC9B,KAAK,cAAc;YACjB,OAAO,IAAI,WAAW,EAAE,CAAC;QAC3B,KAAK,UAAU;YACb,OAAO,IAAI,gBAAgB,EAAE,CAAC;QAChC,KAAK,QAAQ;YACX,OAAO,IAAI,cAAc,EAAE,CAAC;QAC9B,KAAK,MAAM;YACT,OAAO,IAAI,YAAY,EAAE,CAAC;QAC5B;YACE,OAAO,IAAI,kBAAkB,EAAE,CAAC;IACpC,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAa,kBAAkB;IACrB,YAAY,GAAG,CAAC,CAAC;IAEzB;;;;;;;OAOG;IACH,KAAK,CAAC,aAAa,CACjB,YAA+B,EAC/B,QAAmB,EACnB,QAAqB,EACrB,OAAgC;QAEhC,MAAM,kBAAkB,GAAG,YAAY,CAAC,MAAM,CAC5C,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,QAAQ,IAAI,CAAC,CAAC,MAAM,KAAK,MAAM,CAClD,CAAC;QAEF,IAAI,kBAAkB,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YACpC,MAAM,IAAI,KAAK,CAAC,gDAAgD,CAAC,CAAC;QACpE,CAAC;QAED,6CAA6C;QAC7C,MAAM,WAAW,GAAG,QAAQ,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;QAClD,IAAI,WAAW,EAAE,CAAC;YAChB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