massgen 0.0.3__py3-none-any.whl → 0.1.0__py3-none-any.whl
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.
Potentially problematic release.
This version of massgen might be problematic. Click here for more details.
- massgen/__init__.py +142 -8
- massgen/adapters/__init__.py +29 -0
- massgen/adapters/ag2_adapter.py +483 -0
- massgen/adapters/base.py +183 -0
- massgen/adapters/tests/__init__.py +0 -0
- massgen/adapters/tests/test_ag2_adapter.py +439 -0
- massgen/adapters/tests/test_agent_adapter.py +128 -0
- massgen/adapters/utils/__init__.py +2 -0
- massgen/adapters/utils/ag2_utils.py +236 -0
- massgen/adapters/utils/tests/__init__.py +0 -0
- massgen/adapters/utils/tests/test_ag2_utils.py +138 -0
- massgen/agent_config.py +329 -55
- massgen/api_params_handler/__init__.py +10 -0
- massgen/api_params_handler/_api_params_handler_base.py +99 -0
- massgen/api_params_handler/_chat_completions_api_params_handler.py +176 -0
- massgen/api_params_handler/_claude_api_params_handler.py +113 -0
- massgen/api_params_handler/_response_api_params_handler.py +130 -0
- massgen/backend/__init__.py +39 -4
- massgen/backend/azure_openai.py +385 -0
- massgen/backend/base.py +341 -69
- massgen/backend/base_with_mcp.py +1102 -0
- massgen/backend/capabilities.py +386 -0
- massgen/backend/chat_completions.py +577 -130
- massgen/backend/claude.py +1033 -537
- massgen/backend/claude_code.py +1203 -0
- massgen/backend/cli_base.py +209 -0
- massgen/backend/docs/BACKEND_ARCHITECTURE.md +126 -0
- massgen/backend/{CLAUDE_API_RESEARCH.md → docs/CLAUDE_API_RESEARCH.md} +18 -18
- massgen/backend/{GEMINI_API_DOCUMENTATION.md → docs/GEMINI_API_DOCUMENTATION.md} +9 -9
- massgen/backend/docs/Gemini MCP Integration Analysis.md +1050 -0
- massgen/backend/docs/MCP_IMPLEMENTATION_CLAUDE_BACKEND.md +177 -0
- massgen/backend/docs/MCP_INTEGRATION_RESPONSE_BACKEND.md +352 -0
- massgen/backend/docs/OPENAI_GPT5_MODELS.md +211 -0
- massgen/backend/{OPENAI_RESPONSES_API_FORMAT.md → docs/OPENAI_RESPONSE_API_TOOL_CALLS.md} +3 -3
- massgen/backend/docs/OPENAI_response_streaming.md +20654 -0
- massgen/backend/docs/inference_backend.md +257 -0
- massgen/backend/docs/permissions_and_context_files.md +1085 -0
- massgen/backend/external.py +126 -0
- massgen/backend/gemini.py +1850 -241
- massgen/backend/grok.py +40 -156
- massgen/backend/inference.py +156 -0
- massgen/backend/lmstudio.py +171 -0
- massgen/backend/response.py +1095 -322
- massgen/chat_agent.py +131 -113
- massgen/cli.py +1560 -275
- massgen/config_builder.py +2396 -0
- massgen/configs/BACKEND_CONFIGURATION.md +458 -0
- massgen/configs/README.md +559 -216
- massgen/configs/ag2/ag2_case_study.yaml +27 -0
- massgen/configs/ag2/ag2_coder.yaml +34 -0
- massgen/configs/ag2/ag2_coder_case_study.yaml +36 -0
- massgen/configs/ag2/ag2_gemini.yaml +27 -0
- massgen/configs/ag2/ag2_groupchat.yaml +108 -0
- massgen/configs/ag2/ag2_groupchat_gpt.yaml +118 -0
- massgen/configs/ag2/ag2_single_agent.yaml +21 -0
- massgen/configs/basic/multi/fast_timeout_example.yaml +37 -0
- massgen/configs/basic/multi/gemini_4o_claude.yaml +31 -0
- massgen/configs/basic/multi/gemini_gpt5nano_claude.yaml +36 -0
- massgen/configs/{gemini_4o_claude.yaml → basic/multi/geminicode_4o_claude.yaml} +3 -3
- massgen/configs/basic/multi/geminicode_gpt5nano_claude.yaml +36 -0
- massgen/configs/basic/multi/glm_gemini_claude.yaml +25 -0
- massgen/configs/basic/multi/gpt4o_audio_generation.yaml +30 -0
- massgen/configs/basic/multi/gpt4o_image_generation.yaml +31 -0
- massgen/configs/basic/multi/gpt5nano_glm_qwen.yaml +26 -0
- massgen/configs/basic/multi/gpt5nano_image_understanding.yaml +26 -0
- massgen/configs/{three_agents_default.yaml → basic/multi/three_agents_default.yaml} +8 -4
- massgen/configs/basic/multi/three_agents_opensource.yaml +27 -0
- massgen/configs/basic/multi/three_agents_vllm.yaml +20 -0
- massgen/configs/basic/multi/two_agents_gemini.yaml +19 -0
- massgen/configs/{two_agents.yaml → basic/multi/two_agents_gpt5.yaml} +14 -6
- massgen/configs/basic/multi/two_agents_opensource_lmstudio.yaml +31 -0
- massgen/configs/basic/multi/two_qwen_vllm_sglang.yaml +28 -0
- massgen/configs/{single_agent.yaml → basic/single/single_agent.yaml} +1 -1
- massgen/configs/{single_flash2.5.yaml → basic/single/single_flash2.5.yaml} +1 -2
- massgen/configs/basic/single/single_gemini2.5pro.yaml +16 -0
- massgen/configs/basic/single/single_gpt4o_audio_generation.yaml +22 -0
- massgen/configs/basic/single/single_gpt4o_image_generation.yaml +22 -0
- massgen/configs/basic/single/single_gpt4o_video_generation.yaml +24 -0
- massgen/configs/basic/single/single_gpt5nano.yaml +20 -0
- massgen/configs/basic/single/single_gpt5nano_file_search.yaml +18 -0
- massgen/configs/basic/single/single_gpt5nano_image_understanding.yaml +17 -0
- massgen/configs/basic/single/single_gptoss120b.yaml +15 -0
- massgen/configs/basic/single/single_openrouter_audio_understanding.yaml +15 -0
- massgen/configs/basic/single/single_qwen_video_understanding.yaml +15 -0
- massgen/configs/debug/code_execution/command_filtering_blacklist.yaml +29 -0
- massgen/configs/debug/code_execution/command_filtering_whitelist.yaml +28 -0
- massgen/configs/debug/code_execution/docker_verification.yaml +29 -0
- massgen/configs/debug/skip_coordination_test.yaml +27 -0
- massgen/configs/debug/test_sdk_migration.yaml +17 -0
- massgen/configs/docs/DISCORD_MCP_SETUP.md +208 -0
- massgen/configs/docs/TWITTER_MCP_ENESCINAR_SETUP.md +82 -0
- massgen/configs/providers/azure/azure_openai_multi.yaml +21 -0
- massgen/configs/providers/azure/azure_openai_single.yaml +19 -0
- massgen/configs/providers/claude/claude.yaml +14 -0
- massgen/configs/providers/gemini/gemini_gpt5nano.yaml +28 -0
- massgen/configs/providers/local/lmstudio.yaml +11 -0
- massgen/configs/providers/openai/gpt5.yaml +46 -0
- massgen/configs/providers/openai/gpt5_nano.yaml +46 -0
- massgen/configs/providers/others/grok_single_agent.yaml +19 -0
- massgen/configs/providers/others/zai_coding_team.yaml +108 -0
- massgen/configs/providers/others/zai_glm45.yaml +12 -0
- massgen/configs/{creative_team.yaml → teams/creative/creative_team.yaml} +16 -6
- massgen/configs/{travel_planning.yaml → teams/creative/travel_planning.yaml} +16 -6
- massgen/configs/{news_analysis.yaml → teams/research/news_analysis.yaml} +16 -6
- massgen/configs/{research_team.yaml → teams/research/research_team.yaml} +15 -7
- massgen/configs/{technical_analysis.yaml → teams/research/technical_analysis.yaml} +16 -6
- massgen/configs/tools/code-execution/basic_command_execution.yaml +25 -0
- massgen/configs/tools/code-execution/code_execution_use_case_simple.yaml +41 -0
- massgen/configs/tools/code-execution/docker_claude_code.yaml +32 -0
- massgen/configs/tools/code-execution/docker_multi_agent.yaml +32 -0
- massgen/configs/tools/code-execution/docker_simple.yaml +29 -0
- massgen/configs/tools/code-execution/docker_with_resource_limits.yaml +32 -0
- massgen/configs/tools/code-execution/multi_agent_playwright_automation.yaml +57 -0
- massgen/configs/tools/filesystem/cc_gpt5_gemini_filesystem.yaml +34 -0
- massgen/configs/tools/filesystem/claude_code_context_sharing.yaml +68 -0
- massgen/configs/tools/filesystem/claude_code_flash2.5.yaml +43 -0
- massgen/configs/tools/filesystem/claude_code_flash2.5_gptoss.yaml +49 -0
- massgen/configs/tools/filesystem/claude_code_gpt5nano.yaml +31 -0
- massgen/configs/tools/filesystem/claude_code_single.yaml +40 -0
- massgen/configs/tools/filesystem/fs_permissions_test.yaml +87 -0
- massgen/configs/tools/filesystem/gemini_gemini_workspace_cleanup.yaml +54 -0
- massgen/configs/tools/filesystem/gemini_gpt5_filesystem_casestudy.yaml +30 -0
- massgen/configs/tools/filesystem/gemini_gpt5nano_file_context_path.yaml +43 -0
- massgen/configs/tools/filesystem/gemini_gpt5nano_protected_paths.yaml +45 -0
- massgen/configs/tools/filesystem/gpt5mini_cc_fs_context_path.yaml +31 -0
- massgen/configs/tools/filesystem/grok4_gpt5_gemini_filesystem.yaml +32 -0
- massgen/configs/tools/filesystem/multiturn/grok4_gpt5_claude_code_filesystem_multiturn.yaml +58 -0
- massgen/configs/tools/filesystem/multiturn/grok4_gpt5_gemini_filesystem_multiturn.yaml +58 -0
- massgen/configs/tools/filesystem/multiturn/two_claude_code_filesystem_multiturn.yaml +47 -0
- massgen/configs/tools/filesystem/multiturn/two_gemini_flash_filesystem_multiturn.yaml +48 -0
- massgen/configs/tools/mcp/claude_code_discord_mcp_example.yaml +27 -0
- massgen/configs/tools/mcp/claude_code_simple_mcp.yaml +35 -0
- massgen/configs/tools/mcp/claude_code_twitter_mcp_example.yaml +32 -0
- massgen/configs/tools/mcp/claude_mcp_example.yaml +24 -0
- massgen/configs/tools/mcp/claude_mcp_test.yaml +27 -0
- massgen/configs/tools/mcp/five_agents_travel_mcp_test.yaml +157 -0
- massgen/configs/tools/mcp/five_agents_weather_mcp_test.yaml +103 -0
- massgen/configs/tools/mcp/gemini_mcp_example.yaml +24 -0
- massgen/configs/tools/mcp/gemini_mcp_filesystem_test.yaml +23 -0
- massgen/configs/tools/mcp/gemini_mcp_filesystem_test_sharing.yaml +23 -0
- massgen/configs/tools/mcp/gemini_mcp_filesystem_test_single_agent.yaml +17 -0
- massgen/configs/tools/mcp/gemini_mcp_filesystem_test_with_claude_code.yaml +24 -0
- massgen/configs/tools/mcp/gemini_mcp_test.yaml +27 -0
- massgen/configs/tools/mcp/gemini_notion_mcp.yaml +52 -0
- massgen/configs/tools/mcp/gpt5_nano_mcp_example.yaml +24 -0
- massgen/configs/tools/mcp/gpt5_nano_mcp_test.yaml +27 -0
- massgen/configs/tools/mcp/gpt5mini_claude_code_discord_mcp_example.yaml +38 -0
- massgen/configs/tools/mcp/gpt_oss_mcp_example.yaml +25 -0
- massgen/configs/tools/mcp/gpt_oss_mcp_test.yaml +28 -0
- massgen/configs/tools/mcp/grok3_mini_mcp_example.yaml +24 -0
- massgen/configs/tools/mcp/grok3_mini_mcp_test.yaml +27 -0
- massgen/configs/tools/mcp/multimcp_gemini.yaml +111 -0
- massgen/configs/tools/mcp/qwen_api_mcp_example.yaml +25 -0
- massgen/configs/tools/mcp/qwen_api_mcp_test.yaml +28 -0
- massgen/configs/tools/mcp/qwen_local_mcp_example.yaml +24 -0
- massgen/configs/tools/mcp/qwen_local_mcp_test.yaml +27 -0
- massgen/configs/tools/planning/five_agents_discord_mcp_planning_mode.yaml +140 -0
- massgen/configs/tools/planning/five_agents_filesystem_mcp_planning_mode.yaml +151 -0
- massgen/configs/tools/planning/five_agents_notion_mcp_planning_mode.yaml +151 -0
- massgen/configs/tools/planning/five_agents_twitter_mcp_planning_mode.yaml +155 -0
- massgen/configs/tools/planning/gpt5_mini_case_study_mcp_planning_mode.yaml +73 -0
- massgen/configs/tools/web-search/claude_streamable_http_test.yaml +43 -0
- massgen/configs/tools/web-search/gemini_streamable_http_test.yaml +43 -0
- massgen/configs/tools/web-search/gpt5_mini_streamable_http_test.yaml +43 -0
- massgen/configs/tools/web-search/gpt_oss_streamable_http_test.yaml +44 -0
- massgen/configs/tools/web-search/grok3_mini_streamable_http_test.yaml +43 -0
- massgen/configs/tools/web-search/qwen_api_streamable_http_test.yaml +44 -0
- massgen/configs/tools/web-search/qwen_local_streamable_http_test.yaml +43 -0
- massgen/coordination_tracker.py +708 -0
- massgen/docker/README.md +462 -0
- massgen/filesystem_manager/__init__.py +21 -0
- massgen/filesystem_manager/_base.py +9 -0
- massgen/filesystem_manager/_code_execution_server.py +545 -0
- massgen/filesystem_manager/_docker_manager.py +477 -0
- massgen/filesystem_manager/_file_operation_tracker.py +248 -0
- massgen/filesystem_manager/_filesystem_manager.py +813 -0
- massgen/filesystem_manager/_path_permission_manager.py +1261 -0
- massgen/filesystem_manager/_workspace_tools_server.py +1815 -0
- massgen/formatter/__init__.py +10 -0
- massgen/formatter/_chat_completions_formatter.py +284 -0
- massgen/formatter/_claude_formatter.py +235 -0
- massgen/formatter/_formatter_base.py +156 -0
- massgen/formatter/_response_formatter.py +263 -0
- massgen/frontend/__init__.py +1 -2
- massgen/frontend/coordination_ui.py +471 -286
- massgen/frontend/displays/base_display.py +56 -11
- massgen/frontend/displays/create_coordination_table.py +1956 -0
- massgen/frontend/displays/rich_terminal_display.py +1259 -619
- massgen/frontend/displays/simple_display.py +9 -4
- massgen/frontend/displays/terminal_display.py +27 -68
- massgen/logger_config.py +681 -0
- massgen/mcp_tools/README.md +232 -0
- massgen/mcp_tools/__init__.py +105 -0
- massgen/mcp_tools/backend_utils.py +1035 -0
- massgen/mcp_tools/circuit_breaker.py +195 -0
- massgen/mcp_tools/client.py +894 -0
- massgen/mcp_tools/config_validator.py +138 -0
- massgen/mcp_tools/docs/circuit_breaker.md +646 -0
- massgen/mcp_tools/docs/client.md +950 -0
- massgen/mcp_tools/docs/config_validator.md +478 -0
- massgen/mcp_tools/docs/exceptions.md +1165 -0
- massgen/mcp_tools/docs/security.md +854 -0
- massgen/mcp_tools/exceptions.py +338 -0
- massgen/mcp_tools/hooks.py +212 -0
- massgen/mcp_tools/security.py +780 -0
- massgen/message_templates.py +342 -64
- massgen/orchestrator.py +1515 -241
- massgen/stream_chunk/__init__.py +35 -0
- massgen/stream_chunk/base.py +92 -0
- massgen/stream_chunk/multimodal.py +237 -0
- massgen/stream_chunk/text.py +162 -0
- massgen/tests/mcp_test_server.py +150 -0
- massgen/tests/multi_turn_conversation_design.md +0 -8
- massgen/tests/test_azure_openai_backend.py +156 -0
- massgen/tests/test_backend_capabilities.py +262 -0
- massgen/tests/test_backend_event_loop_all.py +179 -0
- massgen/tests/test_chat_completions_refactor.py +142 -0
- massgen/tests/test_claude_backend.py +15 -28
- massgen/tests/test_claude_code.py +268 -0
- massgen/tests/test_claude_code_context_sharing.py +233 -0
- massgen/tests/test_claude_code_orchestrator.py +175 -0
- massgen/tests/test_cli_backends.py +180 -0
- massgen/tests/test_code_execution.py +679 -0
- massgen/tests/test_external_agent_backend.py +134 -0
- massgen/tests/test_final_presentation_fallback.py +237 -0
- massgen/tests/test_gemini_planning_mode.py +351 -0
- massgen/tests/test_grok_backend.py +7 -10
- massgen/tests/test_http_mcp_server.py +42 -0
- massgen/tests/test_integration_simple.py +198 -0
- massgen/tests/test_mcp_blocking.py +125 -0
- massgen/tests/test_message_context_building.py +29 -47
- massgen/tests/test_orchestrator_final_presentation.py +48 -0
- massgen/tests/test_path_permission_manager.py +2087 -0
- massgen/tests/test_rich_terminal_display.py +14 -13
- massgen/tests/test_timeout.py +133 -0
- massgen/tests/test_v3_3agents.py +11 -12
- massgen/tests/test_v3_simple.py +8 -13
- massgen/tests/test_v3_three_agents.py +11 -18
- massgen/tests/test_v3_two_agents.py +8 -13
- massgen/token_manager/__init__.py +7 -0
- massgen/token_manager/token_manager.py +400 -0
- massgen/utils.py +52 -16
- massgen/v1/agent.py +45 -91
- massgen/v1/agents.py +18 -53
- massgen/v1/backends/gemini.py +50 -153
- massgen/v1/backends/grok.py +21 -54
- massgen/v1/backends/oai.py +39 -111
- massgen/v1/cli.py +36 -93
- massgen/v1/config.py +8 -12
- massgen/v1/logging.py +43 -127
- massgen/v1/main.py +18 -32
- massgen/v1/orchestrator.py +68 -209
- massgen/v1/streaming_display.py +62 -163
- massgen/v1/tools.py +8 -12
- massgen/v1/types.py +9 -23
- massgen/v1/utils.py +5 -23
- massgen-0.1.0.dist-info/METADATA +1245 -0
- massgen-0.1.0.dist-info/RECORD +273 -0
- massgen-0.1.0.dist-info/entry_points.txt +2 -0
- massgen/frontend/logging/__init__.py +0 -9
- massgen/frontend/logging/realtime_logger.py +0 -197
- massgen-0.0.3.dist-info/METADATA +0 -568
- massgen-0.0.3.dist-info/RECORD +0 -76
- massgen-0.0.3.dist-info/entry_points.txt +0 -2
- /massgen/backend/{Function calling openai responses.md → docs/Function calling openai responses.md} +0 -0
- {massgen-0.0.3.dist-info → massgen-0.1.0.dist-info}/WHEEL +0 -0
- {massgen-0.0.3.dist-info → massgen-0.1.0.dist-info}/licenses/LICENSE +0 -0
- {massgen-0.0.3.dist-info → massgen-0.1.0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
# Discord MCP Server Setup Guide (barryyip0625/mcp-discord)
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
This guide provides detailed instructions for setting up the Discord MCP (Model Context Protocol) server with MassGen and Claude Code. The Discord MCP server enables AI assistants to interact with Discord platform features including sending messages, managing channels, handling reactions, and more.
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
### 1. System Requirements
|
|
9
|
+
- **Node.js**: Version 16.0.0 or higher
|
|
10
|
+
- **npm**: Version 7.0.0 or higher
|
|
11
|
+
- **Operating System**: Windows, macOS, or Linux
|
|
12
|
+
|
|
13
|
+
### 2. Discord Bot Setup
|
|
14
|
+
|
|
15
|
+
#### Step 1: Create a Discord Application
|
|
16
|
+
1. Navigate to [Discord Developer Portal](https://discord.com/developers/applications)
|
|
17
|
+
2. Click "New Application" button
|
|
18
|
+
3. Enter a name for your application (e.g., "MCP Bot")
|
|
19
|
+
4. Click "Create"
|
|
20
|
+
|
|
21
|
+
#### Step 2: Create a Bot
|
|
22
|
+
1. In your application, go to the "Bot" section in the left sidebar
|
|
23
|
+
2. Click "Add Bot"
|
|
24
|
+
3. Customize your bot's username and avatar if desired
|
|
25
|
+
|
|
26
|
+
#### Step 3: Configure Bot Permissions
|
|
27
|
+
1. In the Bot section, scroll down to "Privileged Gateway Intents"
|
|
28
|
+
2. Enable the following intents:
|
|
29
|
+
- **Message Content Intent**: Required to read message content
|
|
30
|
+
- **Server Members Intent**: Required to access member information
|
|
31
|
+
- **Presence Intent**: Required to track user presence
|
|
32
|
+
|
|
33
|
+
#### Step 4: Get Your Bot Token
|
|
34
|
+
1. In the Bot section, click "Reset Token"
|
|
35
|
+
2. Copy the token immediately (you won't be able to see it again)
|
|
36
|
+
3. **Store this token securely** - never share it publicly
|
|
37
|
+
|
|
38
|
+
#### Step 5: Invite Bot to Your Server
|
|
39
|
+
1. Go to "OAuth2" → "URL Generator" in the left sidebar
|
|
40
|
+
2. Under "Scopes", select:
|
|
41
|
+
- `bot`
|
|
42
|
+
- `applications.commands` (if using slash commands)
|
|
43
|
+
3. Under "Bot Permissions", select the permissions your bot needs:
|
|
44
|
+
- Send Messages
|
|
45
|
+
- Read Messages/View Channels
|
|
46
|
+
- Manage Messages
|
|
47
|
+
- Add Reactions
|
|
48
|
+
- Manage Channels (if needed)
|
|
49
|
+
- Manage Webhooks (if needed)
|
|
50
|
+
4. Copy the generated URL and open it in your browser
|
|
51
|
+
5. Select the server you want to add the bot to
|
|
52
|
+
6. Click "Authorize"
|
|
53
|
+
|
|
54
|
+
## Configuration
|
|
55
|
+
|
|
56
|
+
### Using with MassGen Configuration File
|
|
57
|
+
|
|
58
|
+
#### Step 1: Create or Update Configuration File
|
|
59
|
+
Create a new YAML configuration file or use the provided example:
|
|
60
|
+
|
|
61
|
+
```yaml
|
|
62
|
+
agent:
|
|
63
|
+
id: "claude_code_discord_mcp"
|
|
64
|
+
backend:
|
|
65
|
+
type: "claude_code"
|
|
66
|
+
cwd: "claude_code_workspace_discord_mcp"
|
|
67
|
+
permission_mode: "bypassPermissions"
|
|
68
|
+
|
|
69
|
+
# Discord MCP server configuration
|
|
70
|
+
mcp_servers:
|
|
71
|
+
discord:
|
|
72
|
+
type: "stdio"
|
|
73
|
+
command: "npx"
|
|
74
|
+
args: ["-y", "mcp-discord", "--config", "YOUR_DISCORD_BOT_TOKEN_HERE"]
|
|
75
|
+
|
|
76
|
+
allowed_tools:
|
|
77
|
+
- "Read"
|
|
78
|
+
- "Write"
|
|
79
|
+
- "Bash"
|
|
80
|
+
- "LS"
|
|
81
|
+
- "WebSearch"
|
|
82
|
+
# MCP Discord tools will be auto-discovered
|
|
83
|
+
|
|
84
|
+
ui:
|
|
85
|
+
display_type: "rich_terminal"
|
|
86
|
+
logging_enabled: true
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
#### Step 2: Replace Token
|
|
90
|
+
Replace `YOUR_DISCORD_BOT_TOKEN_HERE` with your actual Discord bot token obtained earlier.
|
|
91
|
+
|
|
92
|
+
## Available MCP Tools
|
|
93
|
+
|
|
94
|
+
Once configured, the following Discord tools will be available:
|
|
95
|
+
|
|
96
|
+
### 1. Message Management
|
|
97
|
+
- **`mcp__discord__send_message`**: Send messages to channels
|
|
98
|
+
- **`mcp__discord__read_messages`**: Read messages from channels
|
|
99
|
+
- **`mcp__discord__delete_message`**: Delete messages
|
|
100
|
+
|
|
101
|
+
### 2. Channel Management
|
|
102
|
+
- **`mcp__discord__create_channel`**: Create new channels
|
|
103
|
+
- **`mcp__discord__delete_channel`**: Delete channels
|
|
104
|
+
- **`mcp__discord__list_channels`**: List available channels
|
|
105
|
+
|
|
106
|
+
### 3. Forum Posts
|
|
107
|
+
- **`mcp__discord__create_forum_post`**: Create forum posts
|
|
108
|
+
- **`mcp__discord__delete_forum_post`**: Delete forum posts
|
|
109
|
+
|
|
110
|
+
### 4. Reactions
|
|
111
|
+
- **`mcp__discord__add_reaction`**: Add reactions to messages
|
|
112
|
+
- **`mcp__discord__remove_reaction`**: Remove reactions from messages
|
|
113
|
+
|
|
114
|
+
### 5. Webhooks
|
|
115
|
+
- **`mcp__discord__create_webhook`**: Create webhooks
|
|
116
|
+
- **`mcp__discord__delete_webhook`**: Delete webhooks
|
|
117
|
+
|
|
118
|
+
## Usage
|
|
119
|
+
|
|
120
|
+
### Running with MassGen
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
# Navigate to MassGen directory
|
|
124
|
+
cd /path/to/MassGen
|
|
125
|
+
|
|
126
|
+
# Run with Discord MCP configuration
|
|
127
|
+
uv run python -m massgen.api --config massgen/configs/claude_code_discord_mcp_example.yaml "YOUR TASK"
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### Example Commands
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
# Send a message to a Discord channel
|
|
134
|
+
uv run python -m massgen.api --config massgen/configs/claude_code_discord_mcp_example.yaml "Send a message saying 'Hello from MCP!' to the general channel"
|
|
135
|
+
|
|
136
|
+
# Read recent messages
|
|
137
|
+
uv run python -m massgen.api --config massgen/configs/claude_code_discord_mcp_example.yaml "Read the last 10 messages from the announcements channel"
|
|
138
|
+
|
|
139
|
+
# Create a new channel
|
|
140
|
+
uv run python -m massgen.api --config massgen/configs/claude_code_discord_mcp_example.yaml "Create a new text channel called 'mcp-testing'"
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
## Security Best Practices
|
|
144
|
+
|
|
145
|
+
### 1. Token Management
|
|
146
|
+
- **Never commit tokens to version control**: Add config files with tokens to `.gitignore`
|
|
147
|
+
- **Rotate tokens regularly**: Regenerate bot tokens periodically
|
|
148
|
+
- **Limit bot permissions**: Only grant necessary permissions to your bot
|
|
149
|
+
|
|
150
|
+
### 32 Permission Scoping
|
|
151
|
+
- Only enable intents that your bot actually needs
|
|
152
|
+
- Regularly review and audit bot permissions
|
|
153
|
+
- Use role-based permissions in Discord servers
|
|
154
|
+
|
|
155
|
+
## Troubleshooting
|
|
156
|
+
|
|
157
|
+
### Common Issues and Solutions
|
|
158
|
+
|
|
159
|
+
#### 1. Authentication Failed
|
|
160
|
+
**Symptoms**: Bot can't connect or authenticate
|
|
161
|
+
**Solutions**:
|
|
162
|
+
- Verify the bot token is correct and hasn't been regenerated
|
|
163
|
+
- Check if the bot is properly invited to your server
|
|
164
|
+
- Ensure required intents are enabled in Discord Developer Portal
|
|
165
|
+
|
|
166
|
+
#### 2. Missing Permissions
|
|
167
|
+
**Symptoms**: Bot can't perform certain actions
|
|
168
|
+
**Solutions**:
|
|
169
|
+
- Review bot role permissions in Discord server settings
|
|
170
|
+
- Check OAuth2 permissions used when inviting the bot
|
|
171
|
+
- Verify the bot's role is high enough in the server hierarchy
|
|
172
|
+
|
|
173
|
+
#### 3. MCP Server Not Starting
|
|
174
|
+
**Symptoms**: MCP server fails to initialize
|
|
175
|
+
**Solutions**:
|
|
176
|
+
- Ensure Node.js and npm are installed: `node --version` and `npm --version`
|
|
177
|
+
- Check internet connectivity for npx to download packages
|
|
178
|
+
- Try installing globally: `npm install -g mcp-discord`
|
|
179
|
+
- Clear npm cache: `npm cache clean --force`
|
|
180
|
+
|
|
181
|
+
#### 4. Rate Limiting
|
|
182
|
+
**Symptoms**: Commands stop working after multiple uses
|
|
183
|
+
**Solutions**:
|
|
184
|
+
- Discord API has rate limits per endpoint
|
|
185
|
+
- Implement delays between bulk operations
|
|
186
|
+
- Check Discord's rate limit documentation
|
|
187
|
+
|
|
188
|
+
#### 5. Intent Errors
|
|
189
|
+
**Symptoms**: Bot can't read message content or see members
|
|
190
|
+
**Solutions**:
|
|
191
|
+
- Enable Message Content Intent in Discord Developer Portal
|
|
192
|
+
- Enable Server Members Intent if accessing member data
|
|
193
|
+
- Restart the bot after changing intents
|
|
194
|
+
|
|
195
|
+
## References and Resources
|
|
196
|
+
|
|
197
|
+
- **GitHub Repository**: [https://github.com/barryyip0625/mcp-discord](https://github.com/barryyip0625/mcp-discord)
|
|
198
|
+
- **Discord Developer Portal**: [https://discord.com/developers/applications](https://discord.com/developers/applications)
|
|
199
|
+
- **Discord.js Documentation**: [https://discord.js.org/](https://discord.js.org/)
|
|
200
|
+
- **Discord API Documentation**: [https://discord.com/developers/docs/intro](https://discord.com/developers/docs/intro)
|
|
201
|
+
- **MCP Protocol Specification**: [https://modelcontextprotocol.io/](https://modelcontextprotocol.io/)
|
|
202
|
+
|
|
203
|
+
## Support
|
|
204
|
+
|
|
205
|
+
For issues specific to:
|
|
206
|
+
- **mcp-discord**: Open an issue at [GitHub Issues](https://github.com/barryyip0625/mcp-discord/issues)
|
|
207
|
+
- **MassGen**: Check the MassGen documentation or repository
|
|
208
|
+
- **Discord API**: Refer to [Discord Developer Support](https://support.discord.com/hc/en-us)
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
# Twitter MCP Server Setup Guide (EnesCinr/twitter-mcp)
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
This guide explains how to set up the EnesCinr Twitter MCP server for use with MassGen and Claude Code.
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
### 1. Twitter Developer Account
|
|
9
|
+
1. Go to https://developer.twitter.com/
|
|
10
|
+
2. Sign up for a developer account if you don't have one
|
|
11
|
+
3. Create a new app in the developer portal
|
|
12
|
+
4. Generate your API credentials
|
|
13
|
+
|
|
14
|
+
### 2. Required API Credentials
|
|
15
|
+
You'll need four credentials from Twitter:
|
|
16
|
+
- **API Key**: Your app's API key
|
|
17
|
+
- **API Secret Key**: Your app's API secret key
|
|
18
|
+
- **Access Token**: User access token for your app
|
|
19
|
+
- **Access Token Secret**: User access token secret
|
|
20
|
+
|
|
21
|
+
## Configuration
|
|
22
|
+
|
|
23
|
+
### 1. Update the Configuration File
|
|
24
|
+
Edit `claude_code_twitter_example.yaml` and replace the placeholder values with your actual credentials:
|
|
25
|
+
|
|
26
|
+
```yaml
|
|
27
|
+
env:
|
|
28
|
+
API_KEY: "your_actual_api_key"
|
|
29
|
+
API_SECRET_KEY: "your_actual_api_secret_key"
|
|
30
|
+
ACCESS_TOKEN: "your_actual_access_token"
|
|
31
|
+
ACCESS_TOKEN_SECRET: "your_actual_access_token_secret"
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### 2. Security Best Practices
|
|
35
|
+
- **Never commit credentials to Git**: Add the config file to `.gitignore` if it contains real credentials
|
|
36
|
+
- **Use environment variables**: Consider using system environment variables instead of hardcoding
|
|
37
|
+
- **Rotate keys regularly**: Regenerate your API keys periodically for security
|
|
38
|
+
|
|
39
|
+
## Available Features
|
|
40
|
+
|
|
41
|
+
### 1. Post Tweet
|
|
42
|
+
- Tool name: `mcp__twitter__post_tweet`
|
|
43
|
+
- Functionality: Post a new tweet to your Twitter account
|
|
44
|
+
- Parameters: Tweet text content
|
|
45
|
+
|
|
46
|
+
### 2. Search Tweets
|
|
47
|
+
- Tool name: `mcp__twitter__search_tweets`
|
|
48
|
+
- Functionality: Search for tweets based on a query
|
|
49
|
+
- Parameters: Search query string
|
|
50
|
+
|
|
51
|
+
## Usage with MassGen
|
|
52
|
+
|
|
53
|
+
To use this configuration with MassGen:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
# Run with the EnesCinr Twitter MCP configuration
|
|
57
|
+
python -m massgen.api --config massgen/configs/claude_code_twitter_example.yaml "YOUR QUESTION"
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Troubleshooting
|
|
61
|
+
|
|
62
|
+
### Common Issues
|
|
63
|
+
|
|
64
|
+
1. **Authentication Failed**
|
|
65
|
+
- Verify all four credentials are correct
|
|
66
|
+
- Check if your app has the necessary permissions (read/write)
|
|
67
|
+
- Ensure your developer account is active
|
|
68
|
+
|
|
69
|
+
2. **Rate Limiting**
|
|
70
|
+
- Twitter API has rate limits
|
|
71
|
+
- Basic tier allows limited requests per 15-minute window
|
|
72
|
+
- Consider upgrading your Twitter API access tier if needed
|
|
73
|
+
|
|
74
|
+
3. **MCP Server Not Found**
|
|
75
|
+
- The server will be automatically downloaded via npx
|
|
76
|
+
- Ensure you have Node.js and npm installed
|
|
77
|
+
- Check internet connectivity
|
|
78
|
+
|
|
79
|
+
## References
|
|
80
|
+
- GitHub Repository: https://github.com/EnesCinr/twitter-mcp
|
|
81
|
+
- Twitter Developer Portal: https://developer.twitter.com/
|
|
82
|
+
- Twitter API Documentation: https://developer.twitter.com/en/docs
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Azure OpenAI Multi-Agent Configuration
|
|
2
|
+
# Usage: uv run python -m massgen.cli --config azure_openai_multi.yaml "Your question here"
|
|
3
|
+
|
|
4
|
+
# Multiple agents configuration
|
|
5
|
+
agents:
|
|
6
|
+
- id: "azure_gpt4"
|
|
7
|
+
backend:
|
|
8
|
+
type: "azure_openai"
|
|
9
|
+
model: "gpt-4.1" # Your Azure OpenAI deployment name for GPT-4.1
|
|
10
|
+
system_message: "You are an expert AI assistant powered by Azure OpenAI GPT-4. Focus on providing comprehensive and accurate responses."
|
|
11
|
+
|
|
12
|
+
- id: "azure_gpt5"
|
|
13
|
+
backend:
|
|
14
|
+
type: "azure_openai"
|
|
15
|
+
model: "gpt-5-chat" # Your Azure OpenAI deployment name for GPT-5-chat
|
|
16
|
+
system_message: "You are an expert AI assistant powered by Azure OpenAI GPT-5-chat. Collaborate with other agents to provide the best possible solution."
|
|
17
|
+
|
|
18
|
+
# Display configuration
|
|
19
|
+
ui:
|
|
20
|
+
display_type: "rich_terminal"
|
|
21
|
+
logging_enabled: true
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Azure OpenAI Single Agent Configuration
|
|
2
|
+
# Usage: uv run python -m massgen.cli --config azure_openai_single.yaml "Your question here"
|
|
3
|
+
|
|
4
|
+
# Single agent configuration
|
|
5
|
+
agent:
|
|
6
|
+
id: "azure_gpt4_agent"
|
|
7
|
+
backend:
|
|
8
|
+
type: "azure_openai"
|
|
9
|
+
model: "gpt-4.1" # This should be your Azure OpenAI deployment name
|
|
10
|
+
# Optional: override environment variables
|
|
11
|
+
# base_url: "https://your-resource.openai.azure.com/"
|
|
12
|
+
# api_key: "your-api-key"
|
|
13
|
+
# api_version: "2024-02-15-preview"
|
|
14
|
+
system_message: "You are a helpful AI assistant powered by Azure OpenAI."
|
|
15
|
+
|
|
16
|
+
# Display configuration
|
|
17
|
+
ui:
|
|
18
|
+
display_type: "rich_terminal"
|
|
19
|
+
logging_enabled: true
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# MassGen Configuration
|
|
2
|
+
# Usage:
|
|
3
|
+
# massgen --config @examples/providers/claude/claude "add_numbers with 46 and 52"
|
|
4
|
+
agents:
|
|
5
|
+
- id: "claude"
|
|
6
|
+
backend:
|
|
7
|
+
type: "claude"
|
|
8
|
+
model: "claude-sonnet-4-20250514" # Model name
|
|
9
|
+
|
|
10
|
+
system_message: "You are a helpful assistant"
|
|
11
|
+
|
|
12
|
+
ui:
|
|
13
|
+
display_type: "rich_terminal"
|
|
14
|
+
logging_enabled: true
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# MassGen Three Agent Configuration
|
|
2
|
+
# Gemini-2.5-flash, GPT-5-nano, and Claude-3.5-Haiku with builtin tools enabled
|
|
3
|
+
|
|
4
|
+
agents:
|
|
5
|
+
- id: "gemini2.5flash"
|
|
6
|
+
backend:
|
|
7
|
+
type: "gemini"
|
|
8
|
+
model: "gemini-2.5-flash"
|
|
9
|
+
enable_web_search: true
|
|
10
|
+
# enable_code_execution: true # Disabled by default - can preempt web search, resulting in weaker search capability
|
|
11
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
12
|
+
|
|
13
|
+
- id: "gpt-5-nano"
|
|
14
|
+
backend:
|
|
15
|
+
type: "openai"
|
|
16
|
+
model: "gpt-5-nano"
|
|
17
|
+
text:
|
|
18
|
+
verbosity: "medium"
|
|
19
|
+
reasoning:
|
|
20
|
+
effort: "medium"
|
|
21
|
+
summary: "auto"
|
|
22
|
+
enable_web_search: true
|
|
23
|
+
enable_code_interpreter: true
|
|
24
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
25
|
+
|
|
26
|
+
ui:
|
|
27
|
+
display_type: "rich_terminal"
|
|
28
|
+
logging_enabled: true
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# MassGen Single Agent Configuration for LM Studio (local OpenAI-compatible server)
|
|
2
|
+
agent:
|
|
3
|
+
id: "Qwen3-4b"
|
|
4
|
+
backend:
|
|
5
|
+
type: "lmstudio"
|
|
6
|
+
model: "qwen/qwen3-4b-2507" # Replace with the model name LM Studio exposes
|
|
7
|
+
system_message: "You are a helpful AI assistant running against a local LM Studio server."
|
|
8
|
+
ui:
|
|
9
|
+
display_type: "rich_terminal"
|
|
10
|
+
logging_enabled: true
|
|
11
|
+
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# MassGen Three Agent Configuration
|
|
2
|
+
# GPT-5, GPT-5-mini, and GPT-5-nano with reasoning, web search, and code execution enabled
|
|
3
|
+
|
|
4
|
+
agents:
|
|
5
|
+
- id: "gpt-5"
|
|
6
|
+
backend:
|
|
7
|
+
type: "openai"
|
|
8
|
+
model: "gpt-5"
|
|
9
|
+
text:
|
|
10
|
+
verbosity: "medium"
|
|
11
|
+
reasoning:
|
|
12
|
+
effort: "high"
|
|
13
|
+
summary: "auto"
|
|
14
|
+
enable_web_search: true
|
|
15
|
+
enable_code_interpreter: true
|
|
16
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
17
|
+
|
|
18
|
+
- id: "gpt-5-mini"
|
|
19
|
+
backend:
|
|
20
|
+
type: "openai"
|
|
21
|
+
model: "gpt-5-mini"
|
|
22
|
+
text:
|
|
23
|
+
verbosity: "medium"
|
|
24
|
+
reasoning:
|
|
25
|
+
effort: "medium"
|
|
26
|
+
summary: "auto"
|
|
27
|
+
enable_web_search: true
|
|
28
|
+
enable_code_interpreter: true
|
|
29
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
30
|
+
|
|
31
|
+
- id: "gpt-5-nano"
|
|
32
|
+
backend:
|
|
33
|
+
type: "openai"
|
|
34
|
+
model: "gpt-5-nano"
|
|
35
|
+
text:
|
|
36
|
+
verbosity: "medium"
|
|
37
|
+
reasoning:
|
|
38
|
+
effort: "low"
|
|
39
|
+
summary: "auto"
|
|
40
|
+
enable_web_search: true
|
|
41
|
+
enable_code_interpreter: true
|
|
42
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
43
|
+
|
|
44
|
+
ui:
|
|
45
|
+
display_type: "rich_terminal"
|
|
46
|
+
logging_enabled: true
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# MassGen Three Agent Configuration
|
|
2
|
+
# 3 GPT-5-nano models with reasoning, web search, and code execution
|
|
3
|
+
|
|
4
|
+
agents:
|
|
5
|
+
- id: "gpt-5-nano-1"
|
|
6
|
+
backend:
|
|
7
|
+
type: "openai"
|
|
8
|
+
model: "gpt-5-nano"
|
|
9
|
+
text:
|
|
10
|
+
verbosity: "medium"
|
|
11
|
+
reasoning:
|
|
12
|
+
effort: "low"
|
|
13
|
+
summary: "auto"
|
|
14
|
+
enable_web_search: true
|
|
15
|
+
enable_code_interpreter: true
|
|
16
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
17
|
+
|
|
18
|
+
- id: "gpt-5-nano-2"
|
|
19
|
+
backend:
|
|
20
|
+
type: "openai"
|
|
21
|
+
model: "gpt-5-nano"
|
|
22
|
+
text:
|
|
23
|
+
verbosity: "medium"
|
|
24
|
+
reasoning:
|
|
25
|
+
effort: "medium"
|
|
26
|
+
summary: "auto"
|
|
27
|
+
enable_web_search: true
|
|
28
|
+
enable_code_interpreter: true
|
|
29
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
30
|
+
|
|
31
|
+
- id: "gpt-5-nano-3"
|
|
32
|
+
backend:
|
|
33
|
+
type: "openai"
|
|
34
|
+
model: "gpt-5-nano"
|
|
35
|
+
text:
|
|
36
|
+
verbosity: "medium"
|
|
37
|
+
reasoning:
|
|
38
|
+
effort: "high"
|
|
39
|
+
summary: "auto"
|
|
40
|
+
enable_web_search: true
|
|
41
|
+
enable_code_interpreter: true
|
|
42
|
+
# system_message: "You are a helpful AI assistant with web search and code execution capabilities. For any question involving current events, recent information, or real-time data, ALWAYS use web search first."
|
|
43
|
+
|
|
44
|
+
ui:
|
|
45
|
+
display_type: "rich_terminal"
|
|
46
|
+
logging_enabled: true
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Usage: uv run python -m massgen.cli --config grok_single_agent.yaml "List today's news in Seattle"
|
|
2
|
+
agent:
|
|
3
|
+
id: "grok_agent"
|
|
4
|
+
backend:
|
|
5
|
+
type: "grok"
|
|
6
|
+
model: "grok-3-mini"
|
|
7
|
+
enable_web_search: false
|
|
8
|
+
extra_body:
|
|
9
|
+
search_parameters:
|
|
10
|
+
mode: "auto" # Search strategy (see Grok API docs for valid values)
|
|
11
|
+
return_citations: true # Include search result citations
|
|
12
|
+
max_search_results: 3 # Max number of search results to return
|
|
13
|
+
# enable_code_execution: true
|
|
14
|
+
system_message: "You are a helpful assistant"
|
|
15
|
+
|
|
16
|
+
# Display configuration
|
|
17
|
+
ui:
|
|
18
|
+
display_type: "rich_terminal"
|
|
19
|
+
logging_enabled: true
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# ZAI Coding Team - Four Agents (glm-4.5 / glm-4.5-air)
|
|
2
|
+
|
|
3
|
+
agents:
|
|
4
|
+
- id: "architecture_glm45"
|
|
5
|
+
backend:
|
|
6
|
+
type: "zai"
|
|
7
|
+
model: "glm-4.5"
|
|
8
|
+
base_url: "https://api.z.ai/api/paas/v4/"
|
|
9
|
+
temperature: 0.95
|
|
10
|
+
top_p: 0.7
|
|
11
|
+
system_message: |
|
|
12
|
+
You are a Senior Software Architect & Planner.
|
|
13
|
+
Your goal is to quickly turn vague product asks into a clear, shippable engineering plan.
|
|
14
|
+
Produce pragmatic designs that are easy to implement, test, and iterate.
|
|
15
|
+
|
|
16
|
+
Responsibilities:
|
|
17
|
+
- Clarify requirements and unknowns with explicit assumptions.
|
|
18
|
+
- Propose a minimal yet extensible architecture (modules, boundaries, data flow).
|
|
19
|
+
- Define public interfaces, input/output contracts, and error behavior.
|
|
20
|
+
- Outline an incremental delivery plan with checkpoints and rollback strategy.
|
|
21
|
+
- Consider performance baselines, memory constraints, and failure modes.
|
|
22
|
+
- Call out security/privacy implications and safe defaults.
|
|
23
|
+
- Identify edge cases and how to validate them.
|
|
24
|
+
|
|
25
|
+
Deliverables:
|
|
26
|
+
- A concise step-by-step implementation plan (<= 10 steps when possible).
|
|
27
|
+
- Module/function list with responsibilities and dependencies.
|
|
28
|
+
- Data structures and schemas (with types) and validation notes.
|
|
29
|
+
- Test strategy (unit/integration), clear acceptance criteria.
|
|
30
|
+
- Risks and mitigation options.
|
|
31
|
+
|
|
32
|
+
- id: "implementation_glm45"
|
|
33
|
+
backend:
|
|
34
|
+
type: "zai"
|
|
35
|
+
model: "glm-4.5"
|
|
36
|
+
base_url: "https://api.z.ai/api/paas/v4/"
|
|
37
|
+
temperature: 0.95
|
|
38
|
+
top_p: 0.7
|
|
39
|
+
system_message: |
|
|
40
|
+
You are an Implementation & Refactoring Engineer.
|
|
41
|
+
Write production-quality code that is readable, testable, and maintainable.
|
|
42
|
+
Optimize for clarity first, then performance where it matters.
|
|
43
|
+
|
|
44
|
+
Coding rules:
|
|
45
|
+
- Follow the existing project style; do not reformat unrelated code.
|
|
46
|
+
- Prefer explicit names; add type hints for public APIs.
|
|
47
|
+
- Use guard clauses and early returns; avoid deep nesting (>3 levels).
|
|
48
|
+
- Handle errors meaningfully; avoid bare except; include actionable messages.
|
|
49
|
+
- Replace magic numbers with named constants; make constraints explicit.
|
|
50
|
+
- Keep functions small and cohesive; extract helpers for repeated logic.
|
|
51
|
+
- Add docstrings for non-trivial functions explaining the "why".
|
|
52
|
+
- Include minimal but sufficient logging at boundaries and failures.
|
|
53
|
+
|
|
54
|
+
Testing & quality:
|
|
55
|
+
- Add unit tests for core logic and edge cases; ensure deterministic behavior.
|
|
56
|
+
- Maintain backward compatibility and avoid breaking public contracts.
|
|
57
|
+
- When changing behavior, document reasoning in the commit/PR description.
|
|
58
|
+
|
|
59
|
+
- id: "review_glm45_air"
|
|
60
|
+
backend:
|
|
61
|
+
type: "zai"
|
|
62
|
+
model: "glm-4.5-air"
|
|
63
|
+
base_url: "https://api.z.ai/api/paas/v4/"
|
|
64
|
+
temperature: 0.95
|
|
65
|
+
top_p: 0.7
|
|
66
|
+
system_message: |
|
|
67
|
+
You are a Reviewer & Test Engineer.
|
|
68
|
+
Your job is to catch defects early and raise the bar on code quality and reliability.
|
|
69
|
+
|
|
70
|
+
Review checklist:
|
|
71
|
+
- Correctness: inputs validated, errors handled, edge cases covered.
|
|
72
|
+
- Interfaces: clear contracts, stable semantics, minimal surface area.
|
|
73
|
+
- Complexity: no unnecessary abstractions; cyclomatic complexity kept low.
|
|
74
|
+
- Performance: obvious hot paths are efficient; avoid unnecessary I/O and copies.
|
|
75
|
+
- Security: sanitize external inputs, avoid injection, safe defaults for secrets.
|
|
76
|
+
- Concurrency: identify shared state, race conditions, and locking hazards.
|
|
77
|
+
- Dependencies: versions pinned where needed; no unnecessary additions.
|
|
78
|
+
|
|
79
|
+
Testing expectations:
|
|
80
|
+
- Propose or add tests that reproduce previous bugs and verify fixes.
|
|
81
|
+
- Cover boundary conditions and failure modes (timeouts, invalid inputs, partial results).
|
|
82
|
+
- Prefer small, focused tests over broad flaky ones; aim for high signal.
|
|
83
|
+
- Suggest minimal, well-scoped diffs—preserve unrelated behavior.
|
|
84
|
+
|
|
85
|
+
- id: "perf_reliability_glm45_air"
|
|
86
|
+
backend:
|
|
87
|
+
type: "zai"
|
|
88
|
+
model: "glm-4.5-air"
|
|
89
|
+
base_url: "https://api.z.ai/api/paas/v4/"
|
|
90
|
+
temperature: 0.95
|
|
91
|
+
top_p: 0.7
|
|
92
|
+
system_message: |
|
|
93
|
+
You are a Performance & Reliability Engineer.
|
|
94
|
+
Your mission is to keep the system fast, resource-efficient, and resilient under load.
|
|
95
|
+
|
|
96
|
+
Focus:
|
|
97
|
+
- Identify hot paths; reduce allocations, copies, and unnecessary I/O.
|
|
98
|
+
- Choose appropriate data structures and algorithms; avoid premature abstraction.
|
|
99
|
+
- Profile critical sections; measure before and after; document deltas.
|
|
100
|
+
- Enforce timeouts, retries with backoff, and circuit breakers for external I/O.
|
|
101
|
+
- Validate memory bounds and streaming behavior on large inputs/outputs.
|
|
102
|
+
- Provide lightweight observability hooks (metrics/events) for key operations.
|
|
103
|
+
|
|
104
|
+
ui:
|
|
105
|
+
display_type: "rich_terminal"
|
|
106
|
+
logging_enabled: true
|
|
107
|
+
|
|
108
|
+
|
|
@@ -5,9 +5,14 @@ agents:
|
|
|
5
5
|
- id: "storyteller"
|
|
6
6
|
backend:
|
|
7
7
|
type: "openai"
|
|
8
|
-
model: "gpt-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
model: "gpt-5-nano"
|
|
9
|
+
text:
|
|
10
|
+
verbosity: "high"
|
|
11
|
+
reasoning:
|
|
12
|
+
effort: "high"
|
|
13
|
+
summary: "auto"
|
|
14
|
+
enable_web_search: true
|
|
15
|
+
enable_code_interpreter: true
|
|
11
16
|
system_message: |
|
|
12
17
|
You are a creative storyteller who excels at crafting engaging narratives
|
|
13
18
|
with rich characters, vivid descriptions, and compelling plot structures.
|
|
@@ -20,9 +25,14 @@ agents:
|
|
|
20
25
|
- id: "editor"
|
|
21
26
|
backend:
|
|
22
27
|
type: "openai"
|
|
23
|
-
model: "gpt-
|
|
24
|
-
|
|
25
|
-
|
|
28
|
+
model: "gpt-5-nano"
|
|
29
|
+
text:
|
|
30
|
+
verbosity: "medium"
|
|
31
|
+
reasoning:
|
|
32
|
+
effort: "medium"
|
|
33
|
+
summary: "auto"
|
|
34
|
+
enable_web_search: true
|
|
35
|
+
enable_code_interpreter: true
|
|
26
36
|
system_message: |
|
|
27
37
|
You are a skilled editor who evaluates creative works for structure,
|
|
28
38
|
flow, and impact. You excel at identifying what makes a story compelling.
|