converse-mcp-server 1.0.1

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,736 @@
1
+ # Converse MCP Server - Usage Examples
2
+
3
+ ## ๐Ÿš€ Getting Started Examples
4
+
5
+ ### Basic Chat Interaction
6
+
7
+ ```json
8
+ {
9
+ "tool": "chat",
10
+ "arguments": {
11
+ "prompt": "Hello! Can you help me understand JavaScript promises?"
12
+ }
13
+ }
14
+ ```
15
+
16
+ **Response:**
17
+ ```json
18
+ {
19
+ "content": "I'd be happy to help you understand JavaScript promises! Promises are objects that represent the eventual completion or failure of an asynchronous operation...",
20
+ "continuation": {
21
+ "id": "conv_abc123",
22
+ "provider": "openai",
23
+ "model": "gpt-4o-mini",
24
+ "messageCount": 2
25
+ },
26
+ "metadata": {
27
+ "model": "gpt-4o-mini",
28
+ "usage": {
29
+ "input_tokens": 15,
30
+ "output_tokens": 145,
31
+ "total_tokens": 160
32
+ },
33
+ "response_time_ms": 1200,
34
+ "provider": "openai"
35
+ }
36
+ }
37
+ ```
38
+
39
+ ### Continuing a Conversation
40
+
41
+ ```json
42
+ {
43
+ "tool": "chat",
44
+ "arguments": {
45
+ "prompt": "Can you show me a practical example?",
46
+ "continuation_id": "conv_abc123"
47
+ }
48
+ }
49
+ ```
50
+
51
+ ## ๐Ÿ”ง Code Analysis Examples
52
+
53
+ ### Single File Analysis
54
+
55
+ ```json
56
+ {
57
+ "tool": "chat",
58
+ "arguments": {
59
+ "prompt": "Review this function for potential bugs and improvements",
60
+ "model": "o3",
61
+ "files": ["/project/src/auth.js"],
62
+ "reasoning_effort": "high",
63
+ "temperature": 0.1
64
+ }
65
+ }
66
+ ```
67
+
68
+ ### Multi-File Architecture Review
69
+
70
+ ```json
71
+ {
72
+ "tool": "chat",
73
+ "arguments": {
74
+ "prompt": "Analyze the overall architecture and suggest improvements for scalability",
75
+ "model": "gemini-2.5-pro",
76
+ "files": [
77
+ "/project/src/server.js",
78
+ "/project/src/routes/index.js",
79
+ "/project/src/middleware/auth.js",
80
+ "/project/config/database.js"
81
+ ],
82
+ "temperature": 0.2
83
+ }
84
+ }
85
+ ```
86
+
87
+ ## ๐ŸŽฏ Model-Specific Examples
88
+
89
+ ### Using O3 for Complex Reasoning
90
+
91
+ ```json
92
+ {
93
+ "tool": "chat",
94
+ "arguments": {
95
+ "prompt": "Design a distributed caching strategy for a social media platform with 10M+ users",
96
+ "model": "o3",
97
+ "reasoning_effort": "max",
98
+ "temperature": 0.1
99
+ }
100
+ }
101
+ ```
102
+
103
+ ### Using Flash for Quick Responses
104
+
105
+ ```json
106
+ {
107
+ "tool": "chat",
108
+ "arguments": {
109
+ "prompt": "What's the syntax for async/await in JavaScript?",
110
+ "model": "flash",
111
+ "temperature": 0.3
112
+ }
113
+ }
114
+ ```
115
+
116
+ ### Using Grok for Creative Solutions
117
+
118
+ ```json
119
+ {
120
+ "tool": "chat",
121
+ "arguments": {
122
+ "prompt": "Brainstorm creative ways to gamify a productivity app",
123
+ "model": "grok",
124
+ "temperature": 0.7
125
+ }
126
+ }
127
+ ```
128
+
129
+ ## ๐Ÿค Consensus Examples
130
+
131
+ ### Simple Technical Decision
132
+
133
+ ```json
134
+ {
135
+ "tool": "consensus",
136
+ "arguments": {
137
+ "prompt": "Should we use PostgreSQL or MongoDB for our e-commerce inventory system?",
138
+ "models": [
139
+ {"model": "o3"},
140
+ {"model": "gemini-2.5-pro"},
141
+ {"model": "grok"}
142
+ ],
143
+ "temperature": 0.2
144
+ }
145
+ }
146
+ ```
147
+
148
+ **Response Structure:**
149
+ ```json
150
+ {
151
+ "status": "consensus_complete",
152
+ "models_consulted": 3,
153
+ "successful_initial_responses": 3,
154
+ "refined_responses": 3,
155
+ "phases": {
156
+ "initial": [
157
+ {
158
+ "model": "o3",
159
+ "status": "success",
160
+ "response": "For an e-commerce inventory system, I recommend PostgreSQL because...",
161
+ "metadata": {"input_tokens": 50, "output_tokens": 180}
162
+ }
163
+ ],
164
+ "refined": [
165
+ {
166
+ "model": "o3",
167
+ "status": "success",
168
+ "initial_response": "For an e-commerce inventory system, I recommend PostgreSQL...",
169
+ "refined_response": "After considering the other perspectives on MongoDB's flexibility, I still lean towards PostgreSQL but acknowledge that MongoDB could work well if..."
170
+ }
171
+ ]
172
+ }
173
+ }
174
+ ```
175
+
176
+ ### Architecture Decision with Context
177
+
178
+ ```json
179
+ {
180
+ "tool": "consensus",
181
+ "arguments": {
182
+ "prompt": "Given our current system architecture, what's the best approach for implementing real-time notifications?",
183
+ "models": [
184
+ {"model": "o3"},
185
+ {"model": "gemini-2.5-flash"},
186
+ {"model": "grok-4-0709"}
187
+ ],
188
+ "relevant_files": [
189
+ "/docs/current_architecture.md",
190
+ "/src/server.js",
191
+ "/package.json"
192
+ ],
193
+ "enable_cross_feedback": true,
194
+ "temperature": 0.15
195
+ }
196
+ }
197
+ ```
198
+
199
+ ### Fast Consensus (No Cross-Feedback)
200
+
201
+ ```json
202
+ {
203
+ "tool": "consensus",
204
+ "arguments": {
205
+ "prompt": "What's the best CSS framework for rapid prototyping in 2024?",
206
+ "models": [
207
+ {"model": "flash"},
208
+ {"model": "gpt-4o-mini"},
209
+ {"model": "grok-3-fast"}
210
+ ],
211
+ "enable_cross_feedback": false,
212
+ "temperature": 0.3
213
+ }
214
+ }
215
+ ```
216
+
217
+ ## ๐Ÿ–ผ๏ธ Image Analysis Examples
218
+
219
+ ### Screenshot Analysis
220
+
221
+ ```json
222
+ {
223
+ "tool": "chat",
224
+ "arguments": {
225
+ "prompt": "Analyze this UI design and suggest improvements for user experience",
226
+ "model": "gpt-4o",
227
+ "images": ["/designs/dashboard_mockup.png"],
228
+ "temperature": 0.3
229
+ }
230
+ }
231
+ ```
232
+
233
+ ### Multi-Image Comparison
234
+
235
+ ```json
236
+ {
237
+ "tool": "consensus",
238
+ "arguments": {
239
+ "prompt": "Compare these three design options and recommend the best one for our mobile app",
240
+ "models": [
241
+ {"model": "gpt-4o"},
242
+ {"model": "gemini-2.5-pro"},
243
+ {"model": "grok"}
244
+ ],
245
+ "images": [
246
+ "/designs/option_a.png",
247
+ "/designs/option_b.png",
248
+ "/designs/option_c.png"
249
+ ],
250
+ "temperature": 0.2
251
+ }
252
+ }
253
+ ```
254
+
255
+ ### Code + Diagram Analysis
256
+
257
+ ```json
258
+ {
259
+ "tool": "chat",
260
+ "arguments": {
261
+ "prompt": "Review the implementation against the architecture diagram. Are we following the design correctly?",
262
+ "model": "o3",
263
+ "files": ["/src/services/payment.js", "/src/models/transaction.js"],
264
+ "images": ["/docs/payment_flow_diagram.png"],
265
+ "reasoning_effort": "high"
266
+ }
267
+ }
268
+ ```
269
+
270
+ ## ๐Ÿ” Debugging & Problem Solving
271
+
272
+ ### Error Investigation
273
+
274
+ ```json
275
+ {
276
+ "tool": "chat",
277
+ "arguments": {
278
+ "prompt": "Help me debug this error. The application crashes intermittently with this stack trace.",
279
+ "model": "o3",
280
+ "files": [
281
+ "/src/server.js",
282
+ "/logs/error.log",
283
+ "/src/middleware/error-handler.js"
284
+ ],
285
+ "reasoning_effort": "high",
286
+ "temperature": 0.1
287
+ }
288
+ }
289
+ ```
290
+
291
+ ### Performance Analysis
292
+
293
+ ```json
294
+ {
295
+ "tool": "consensus",
296
+ "arguments": {
297
+ "prompt": "Our API response times are degrading. What could be the root causes?",
298
+ "models": [
299
+ {"model": "o3"},
300
+ {"model": "gemini-2.5-pro"},
301
+ {"model": "grok"}
302
+ ],
303
+ "relevant_files": [
304
+ "/monitoring/performance_report.json",
305
+ "/src/database/queries.js",
306
+ "/src/api/routes.js"
307
+ ],
308
+ "cross_feedback_prompt": "Focus on the most likely performance bottlenecks based on the data"
309
+ }
310
+ }
311
+ ```
312
+
313
+ ## ๐Ÿ“š Learning & Documentation
314
+
315
+ ### Concept Explanation
316
+
317
+ ```json
318
+ {
319
+ "tool": "chat",
320
+ "arguments": {
321
+ "prompt": "Explain microservices architecture with pros, cons, and when to use it",
322
+ "model": "gemini-2.5-pro",
323
+ "temperature": 0.4
324
+ }
325
+ }
326
+ ```
327
+
328
+ ### Code Review & Learning
329
+
330
+ ```json
331
+ {
332
+ "tool": "chat",
333
+ "arguments": {
334
+ "prompt": "Review this code and explain what it does, then suggest best practices improvements",
335
+ "model": "o3",
336
+ "files": ["/src/utils/encryption.js"],
337
+ "reasoning_effort": "medium",
338
+ "temperature": 0.2
339
+ }
340
+ }
341
+ ```
342
+
343
+ ### Technology Comparison
344
+
345
+ ```json
346
+ {
347
+ "tool": "consensus",
348
+ "arguments": {
349
+ "prompt": "Compare Next.js, Nuxt.js, and SvelteKit for our new web application project",
350
+ "models": [
351
+ {"model": "o3"},
352
+ {"model": "flash"},
353
+ {"model": "grok"}
354
+ ],
355
+ "relevant_files": ["/docs/project_requirements.md"],
356
+ "temperature": 0.25
357
+ }
358
+ }
359
+ ```
360
+
361
+ ## ๐Ÿ› ๏ธ Development Workflows
362
+
363
+ ### Feature Planning
364
+
365
+ ```json
366
+ {
367
+ "tool": "consensus",
368
+ "arguments": {
369
+ "prompt": "Plan the implementation of user authentication with social login support",
370
+ "models": [
371
+ {"model": "o3"},
372
+ {"model": "gemini-2.5-pro"},
373
+ {"model": "grok"}
374
+ ],
375
+ "relevant_files": [
376
+ "/docs/user_requirements.md",
377
+ "/src/models/user.js"
378
+ ],
379
+ "cross_feedback_prompt": "Consider security, scalability, and user experience in your refinement"
380
+ }
381
+ }
382
+ ```
383
+
384
+ ### Code Generation
385
+
386
+ ```json
387
+ {
388
+ "tool": "chat",
389
+ "arguments": {
390
+ "prompt": "Generate a React component for a responsive image gallery with lazy loading",
391
+ "model": "gemini-2.5-flash",
392
+ "files": ["/src/styles/globals.css"],
393
+ "temperature": 0.3
394
+ }
395
+ }
396
+ ```
397
+
398
+ ### Refactoring Guidance
399
+
400
+ ```json
401
+ {
402
+ "tool": "chat",
403
+ "arguments": {
404
+ "prompt": "Help me refactor this legacy code to use modern ES6+ features and improve readability",
405
+ "model": "o3",
406
+ "files": ["/src/legacy/data-processor.js"],
407
+ "reasoning_effort": "medium",
408
+ "temperature": 0.2
409
+ }
410
+ }
411
+ ```
412
+
413
+ ## ๐Ÿš€ Advanced Use Cases
414
+
415
+ ### Multi-Step Problem Solving
416
+
417
+ ```json
418
+ {
419
+ "tool": "chat",
420
+ "arguments": {
421
+ "prompt": "I need to migrate our monolith to microservices. What's the step-by-step approach?",
422
+ "model": "o3",
423
+ "files": ["/src/app.js", "/docs/current_architecture.md"],
424
+ "reasoning_effort": "max",
425
+ "temperature": 0.1
426
+ }
427
+ }
428
+ ```
429
+
430
+ ### Cross-Technology Analysis
431
+
432
+ ```json
433
+ {
434
+ "tool": "consensus",
435
+ "arguments": {
436
+ "prompt": "Should we migrate from Python Django to Node.js Express for better performance?",
437
+ "models": [
438
+ {"model": "o3"},
439
+ {"model": "gemini-2.5-pro"},
440
+ {"model": "grok"}
441
+ ],
442
+ "relevant_files": [
443
+ "/backend/requirements.txt",
444
+ "/monitoring/performance_metrics.json",
445
+ "/docs/team_skills.md"
446
+ ],
447
+ "cross_feedback_prompt": "Consider team expertise, migration costs, and long-term maintainability"
448
+ }
449
+ }
450
+ ```
451
+
452
+ ### Research & Investigation
453
+
454
+ ```json
455
+ {
456
+ "tool": "chat",
457
+ "arguments": {
458
+ "prompt": "Research the latest trends in web development for 2024 and how they apply to our project",
459
+ "model": "grok",
460
+ "use_websearch": true,
461
+ "temperature": 0.5
462
+ }
463
+ }
464
+ ```
465
+
466
+ ## ๐ŸŽ›๏ธ Configuration Examples
467
+
468
+ ### Custom Temperature Settings
469
+
470
+ ```json
471
+ {
472
+ "tool": "chat",
473
+ "arguments": {
474
+ "prompt": "Generate creative marketing copy for our new product launch",
475
+ "model": "grok",
476
+ "temperature": 0.8
477
+ }
478
+ }
479
+ ```
480
+
481
+ ```json
482
+ {
483
+ "tool": "chat",
484
+ "arguments": {
485
+ "prompt": "Fix this bug in my authentication logic",
486
+ "model": "o3",
487
+ "files": ["/src/auth.js"],
488
+ "temperature": 0.0,
489
+ "reasoning_effort": "high"
490
+ }
491
+ }
492
+ ```
493
+
494
+ ### Different Reasoning Levels
495
+
496
+ ```json
497
+ {
498
+ "tool": "chat",
499
+ "arguments": {
500
+ "prompt": "Quick syntax check - is this JavaScript valid?",
501
+ "model": "o3",
502
+ "reasoning_effort": "minimal",
503
+ "temperature": 0.1
504
+ }
505
+ }
506
+ ```
507
+
508
+ ```json
509
+ {
510
+ "tool": "chat",
511
+ "arguments": {
512
+ "prompt": "Design a comprehensive testing strategy for this complex system",
513
+ "model": "o3",
514
+ "files": ["/src/", "/tests/"],
515
+ "reasoning_effort": "max",
516
+ "temperature": 0.1
517
+ }
518
+ }
519
+ ```
520
+
521
+ ## ๐Ÿ”„ Continuation Examples
522
+
523
+ ### Long Research Session
524
+
525
+ ```json
526
+ // First request
527
+ {
528
+ "tool": "chat",
529
+ "arguments": {
530
+ "prompt": "I'm building a real-time chat application. What architecture should I consider?",
531
+ "model": "o3"
532
+ }
533
+ }
534
+
535
+ // Response includes: "continuation": {"id": "conv_research_123"}
536
+
537
+ // Follow-up questions
538
+ {
539
+ "tool": "chat",
540
+ "arguments": {
541
+ "prompt": "What about handling file uploads in real-time?",
542
+ "continuation_id": "conv_research_123"
543
+ }
544
+ }
545
+
546
+ {
547
+ "tool": "chat",
548
+ "arguments": {
549
+ "prompt": "How would you implement message encryption?",
550
+ "continuation_id": "conv_research_123"
551
+ }
552
+ }
553
+ ```
554
+
555
+ ### Iterative Development
556
+
557
+ ```json
558
+ // Initial code review
559
+ {
560
+ "tool": "chat",
561
+ "arguments": {
562
+ "prompt": "Review this API endpoint implementation",
563
+ "model": "o3",
564
+ "files": ["/src/api/users.js"]
565
+ }
566
+ }
567
+
568
+ // Implementation improvement
569
+ {
570
+ "tool": "chat",
571
+ "arguments": {
572
+ "prompt": "Now help me implement the error handling you suggested",
573
+ "continuation_id": "conv_dev_456",
574
+ "files": ["/src/api/users.js"]
575
+ }
576
+ }
577
+
578
+ // Testing guidance
579
+ {
580
+ "tool": "chat",
581
+ "arguments": {
582
+ "prompt": "What unit tests should I write for this endpoint?",
583
+ "continuation_id": "conv_dev_456"
584
+ }
585
+ }
586
+ ```
587
+
588
+ ## ๐ŸŽจ Creative & Brainstorming
589
+
590
+ ### Feature Ideation
591
+
592
+ ```json
593
+ {
594
+ "tool": "consensus",
595
+ "arguments": {
596
+ "prompt": "Brainstorm innovative features for a fitness tracking app that would differentiate us from competitors",
597
+ "models": [
598
+ {"model": "grok"},
599
+ {"model": "gemini-2.5-pro"},
600
+ {"model": "gpt-4o"}
601
+ ],
602
+ "temperature": 0.7,
603
+ "cross_feedback_prompt": "Build on each other's ideas and suggest combinations"
604
+ }
605
+ }
606
+ ```
607
+
608
+ ### UI/UX Improvements
609
+
610
+ ```json
611
+ {
612
+ "tool": "chat",
613
+ "arguments": {
614
+ "prompt": "Suggest creative ways to improve user onboarding for this interface",
615
+ "model": "grok",
616
+ "images": ["/designs/current_onboarding.png"],
617
+ "temperature": 0.6
618
+ }
619
+ }
620
+ ```
621
+
622
+ ## ๐Ÿงช Testing Examples
623
+
624
+ ### Test Strategy Planning
625
+
626
+ ```json
627
+ {
628
+ "tool": "consensus",
629
+ "arguments": {
630
+ "prompt": "What testing strategy should we implement for this e-commerce checkout flow?",
631
+ "models": [
632
+ {"model": "o3"},
633
+ {"model": "gemini-2.5-pro"},
634
+ {"model": "flash"}
635
+ ],
636
+ "relevant_files": [
637
+ "/src/checkout/payment.js",
638
+ "/src/checkout/validation.js",
639
+ "/docs/business_requirements.md"
640
+ ],
641
+ "temperature": 0.2
642
+ }
643
+ }
644
+ ```
645
+
646
+ ### Test Generation
647
+
648
+ ```json
649
+ {
650
+ "tool": "chat",
651
+ "arguments": {
652
+ "prompt": "Generate comprehensive unit tests for this user authentication module",
653
+ "model": "gemini-2.5-flash",
654
+ "files": ["/src/auth/index.js"],
655
+ "temperature": 0.3
656
+ }
657
+ }
658
+ ```
659
+
660
+ ## ๐Ÿ“Š Error Handling Examples
661
+
662
+ ### Graceful Degradation
663
+
664
+ ```json
665
+ {
666
+ "tool": "consensus",
667
+ "arguments": {
668
+ "prompt": "One of our models is unavailable, but we still need consensus",
669
+ "models": [
670
+ {"model": "available-model-1"},
671
+ {"model": "available-model-2"}
672
+ ],
673
+ "temperature": 0.2
674
+ }
675
+ }
676
+ ```
677
+
678
+ ### Partial Success Response
679
+
680
+ ```json
681
+ {
682
+ "status": "consensus_partial",
683
+ "models_consulted": 2,
684
+ "successful_initial_responses": 2,
685
+ "failed_responses": 1,
686
+ "failed_models": ["unavailable-model"],
687
+ "phases": {
688
+ "initial": [...],
689
+ "refined": [...],
690
+ "failed": [
691
+ {
692
+ "model": "unavailable-model",
693
+ "error": "Provider not available. Check API key configuration.",
694
+ "status": "failed"
695
+ }
696
+ ]
697
+ }
698
+ }
699
+ ```
700
+
701
+ ## ๐Ÿ”ง Integration Examples
702
+
703
+ ### CI/CD Pipeline Integration
704
+
705
+ ```bash
706
+ # Use in GitHub Actions
707
+ - name: Code Review
708
+ run: |
709
+ echo '{
710
+ "tool": "chat",
711
+ "arguments": {
712
+ "prompt": "Review this pull request for security issues and best practices",
713
+ "model": "o3",
714
+ "files": ["src/modified-file.js"],
715
+ "reasoning_effort": "high"
716
+ }
717
+ }' | npx converse-mcp-server
718
+ ```
719
+
720
+ ### Automated Documentation
721
+
722
+ ```bash
723
+ # Generate documentation
724
+ echo '{
725
+ "tool": "chat",
726
+ "arguments": {
727
+ "prompt": "Generate API documentation for these endpoints",
728
+ "model": "gemini-2.5-flash",
729
+ "files": ["src/api/routes.js"]
730
+ }
731
+ }' | npx converse-mcp-server > docs/api.md
732
+ ```
733
+
734
+ ---
735
+
736
+ These examples demonstrate the flexibility and power of the Converse MCP Server across various development scenarios, from simple queries to complex multi-model consensus gathering.