tachibot-mcp 2.0.2

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.
Files changed (214) hide show
  1. package/.env.example +260 -0
  2. package/CHANGELOG.md +54 -0
  3. package/CODE_OF_CONDUCT.md +56 -0
  4. package/CONTRIBUTING.md +54 -0
  5. package/Dockerfile +36 -0
  6. package/LICENSE +644 -0
  7. package/README.md +201 -0
  8. package/SECURITY.md +95 -0
  9. package/dist/personality/komaai-expressions.js +12 -0
  10. package/dist/profiles/balanced.json +33 -0
  11. package/dist/profiles/code_focus.json +33 -0
  12. package/dist/profiles/full.json +33 -0
  13. package/dist/profiles/minimal.json +33 -0
  14. package/dist/profiles/research_power.json +33 -0
  15. package/dist/scripts/build-profiles.js +46 -0
  16. package/dist/src/application/services/focus/FocusModeRegistry.js +46 -0
  17. package/dist/src/application/services/focus/FocusTool.service.js +109 -0
  18. package/dist/src/application/services/focus/ModeRegistry.js +46 -0
  19. package/dist/src/application/services/focus/modes/focus-deep.mode.js +27 -0
  20. package/dist/src/application/services/focus/modes/status.mode.js +50 -0
  21. package/dist/src/application/services/focus/modes/tachibot-status.mode.js +50 -0
  22. package/dist/src/collaborative-orchestrator.js +391 -0
  23. package/dist/src/config/model-constants.js +188 -0
  24. package/dist/src/config/model-defaults.js +57 -0
  25. package/dist/src/config/model-preferences.js +382 -0
  26. package/dist/src/config/timeout-config.js +130 -0
  27. package/dist/src/config.js +173 -0
  28. package/dist/src/domain/interfaces/IFocusMode.js +5 -0
  29. package/dist/src/domain/interfaces/IProvider.js +6 -0
  30. package/dist/src/domain/interfaces/ITool.js +5 -0
  31. package/dist/src/focus-deep.js +245 -0
  32. package/dist/src/infrastructure/ascii/art/robots.ascii.js +16 -0
  33. package/dist/src/mcp-client.js +90 -0
  34. package/dist/src/memory/index.js +17 -0
  35. package/dist/src/memory/memory-config.js +135 -0
  36. package/dist/src/memory/memory-interface.js +174 -0
  37. package/dist/src/memory/memory-manager.js +383 -0
  38. package/dist/src/memory/providers/devlog-provider.js +385 -0
  39. package/dist/src/memory/providers/hybrid-provider.js +399 -0
  40. package/dist/src/memory/providers/local-provider.js +388 -0
  41. package/dist/src/memory/providers/mem0-provider.js +337 -0
  42. package/dist/src/modes/architect.js +477 -0
  43. package/dist/src/modes/auditor.js +362 -0
  44. package/dist/src/modes/challenger.js +841 -0
  45. package/dist/src/modes/code-reviewer.js +382 -0
  46. package/dist/src/modes/commit-guardian.js +424 -0
  47. package/dist/src/modes/documentation-writer.js +572 -0
  48. package/dist/src/modes/scout.js +587 -0
  49. package/dist/src/modes/shared/helpers/challenger-helpers.js +454 -0
  50. package/dist/src/modes/shared/helpers/index.js +17 -0
  51. package/dist/src/modes/shared/helpers/scout-helpers.js +270 -0
  52. package/dist/src/modes/shared/helpers/verifier-helpers.js +332 -0
  53. package/dist/src/modes/test-architect.js +767 -0
  54. package/dist/src/modes/verifier.js +378 -0
  55. package/dist/src/monitoring/performance-monitor.js +435 -0
  56. package/dist/src/optimization/batch-executor.js +121 -0
  57. package/dist/src/optimization/context-pruner.js +196 -0
  58. package/dist/src/optimization/cost-monitor.js +338 -0
  59. package/dist/src/optimization/index.js +65 -0
  60. package/dist/src/optimization/model-router.js +264 -0
  61. package/dist/src/optimization/result-cache.js +114 -0
  62. package/dist/src/optimization/token-optimizer.js +257 -0
  63. package/dist/src/optimization/token-tracker.js +118 -0
  64. package/dist/src/orchestrator-instructions.js +128 -0
  65. package/dist/src/orchestrator-lite.js +139 -0
  66. package/dist/src/orchestrator.js +191 -0
  67. package/dist/src/orchestrators/collaborative/interfaces/IToolExecutionEngine.js +1 -0
  68. package/dist/src/orchestrators/collaborative/interfaces/IToolExecutionStrategy.js +5 -0
  69. package/dist/src/orchestrators/collaborative/interfaces/IVisualizationRenderer.js +1 -0
  70. package/dist/src/orchestrators/collaborative/registries/ModelProviderRegistry.js +95 -0
  71. package/dist/src/orchestrators/collaborative/registries/ToolAdapterRegistry.js +64 -0
  72. package/dist/src/orchestrators/collaborative/services/tool-execution/ToolExecutionService.js +502 -0
  73. package/dist/src/orchestrators/collaborative/services/visualization/VisualizationService.js +206 -0
  74. package/dist/src/orchestrators/collaborative/types/session-types.js +5 -0
  75. package/dist/src/profiles/balanced.js +37 -0
  76. package/dist/src/profiles/code_focus.js +37 -0
  77. package/dist/src/profiles/debug_intensive.js +59 -0
  78. package/dist/src/profiles/full.js +37 -0
  79. package/dist/src/profiles/minimal.js +37 -0
  80. package/dist/src/profiles/research_code.js +59 -0
  81. package/dist/src/profiles/research_power.js +37 -0
  82. package/dist/src/profiles/types.js +5 -0
  83. package/dist/src/profiles/workflow_builder.js +53 -0
  84. package/dist/src/prompt-engineer-lite.js +78 -0
  85. package/dist/src/prompt-engineer.js +399 -0
  86. package/dist/src/reasoning-chain.js +508 -0
  87. package/dist/src/sequential-thinking.js +291 -0
  88. package/dist/src/server-diagnostic.js +74 -0
  89. package/dist/src/server-raw.js +158 -0
  90. package/dist/src/server-simple.js +58 -0
  91. package/dist/src/server.js +514 -0
  92. package/dist/src/session/session-logger.js +617 -0
  93. package/dist/src/session/session-manager.js +571 -0
  94. package/dist/src/session/session-tools.js +400 -0
  95. package/dist/src/tools/advanced-modes.js +200 -0
  96. package/dist/src/tools/claude-integration.js +356 -0
  97. package/dist/src/tools/consolidated/ai-router.js +174 -0
  98. package/dist/src/tools/consolidated/ai-tool.js +48 -0
  99. package/dist/src/tools/consolidated/brainstorm-tool.js +87 -0
  100. package/dist/src/tools/consolidated/environment-detector.js +80 -0
  101. package/dist/src/tools/consolidated/index.js +50 -0
  102. package/dist/src/tools/consolidated/search-tool.js +110 -0
  103. package/dist/src/tools/consolidated/workflow-tool.js +238 -0
  104. package/dist/src/tools/gemini-tools.js +329 -0
  105. package/dist/src/tools/grok-enhanced.js +376 -0
  106. package/dist/src/tools/grok-tools.js +299 -0
  107. package/dist/src/tools/lmstudio-tools.js +223 -0
  108. package/dist/src/tools/openai-tools.js +498 -0
  109. package/dist/src/tools/openrouter-tools.js +317 -0
  110. package/dist/src/tools/optimized-wrapper.js +204 -0
  111. package/dist/src/tools/perplexity-tools.js +294 -0
  112. package/dist/src/tools/pingpong-tool.js +343 -0
  113. package/dist/src/tools/qwen-wrapper.js +74 -0
  114. package/dist/src/tools/tool-router.js +444 -0
  115. package/dist/src/tools/unified-ai-provider.js +260 -0
  116. package/dist/src/tools/workflow-runner.js +425 -0
  117. package/dist/src/tools/workflow-validator-tool.js +107 -0
  118. package/dist/src/types.js +23 -0
  119. package/dist/src/utils/input-validator.js +130 -0
  120. package/dist/src/utils/model-router.js +91 -0
  121. package/dist/src/utils/progress-stream.js +255 -0
  122. package/dist/src/utils/provider-router.js +88 -0
  123. package/dist/src/utils/smart-api-client.js +146 -0
  124. package/dist/src/utils/table-builder.js +218 -0
  125. package/dist/src/utils/timestamp-formatter.js +134 -0
  126. package/dist/src/utils/tool-compressor.js +257 -0
  127. package/dist/src/utils/tool-config.js +201 -0
  128. package/dist/src/validators/dependency-graph-validator.js +147 -0
  129. package/dist/src/validators/interpolation-validator.js +222 -0
  130. package/dist/src/validators/output-usage-validator.js +151 -0
  131. package/dist/src/validators/syntax-validator.js +102 -0
  132. package/dist/src/validators/tool-registry-validator.js +123 -0
  133. package/dist/src/validators/tool-types.js +97 -0
  134. package/dist/src/validators/types.js +8 -0
  135. package/dist/src/validators/workflow-validator.js +134 -0
  136. package/dist/src/visualizer-lite.js +42 -0
  137. package/dist/src/visualizer.js +179 -0
  138. package/dist/src/workflows/circuit-breaker.js +199 -0
  139. package/dist/src/workflows/custom-workflows.js +451 -0
  140. package/dist/src/workflows/engine/AutoSynthesizer.js +97 -0
  141. package/dist/src/workflows/engine/StepParameterResolver.js +74 -0
  142. package/dist/src/workflows/engine/VariableInterpolator.js +123 -0
  143. package/dist/src/workflows/engine/WorkflowDiscovery.js +125 -0
  144. package/dist/src/workflows/engine/WorkflowExecutionEngine.js +485 -0
  145. package/dist/src/workflows/engine/WorkflowExecutor.js +113 -0
  146. package/dist/src/workflows/engine/WorkflowFileManager.js +244 -0
  147. package/dist/src/workflows/engine/WorkflowHelpers.js +114 -0
  148. package/dist/src/workflows/engine/WorkflowOutputFormatter.js +83 -0
  149. package/dist/src/workflows/engine/events/WorkflowEventBus.js +132 -0
  150. package/dist/src/workflows/engine/events/interfaces/IEventBus.js +5 -0
  151. package/dist/src/workflows/engine/handlers/ErrorRecoveryHandler.js +162 -0
  152. package/dist/src/workflows/engine/handlers/PromptEnhancementHandler.js +115 -0
  153. package/dist/src/workflows/engine/handlers/SessionPersistenceHandler.js +167 -0
  154. package/dist/src/workflows/engine/handlers/StepExecutionHandler.js +231 -0
  155. package/dist/src/workflows/engine/handlers/ToolInvocationHandler.js +46 -0
  156. package/dist/src/workflows/engine/interfaces/IAutoSynthesizer.js +5 -0
  157. package/dist/src/workflows/engine/interfaces/IStepParameterResolver.js +5 -0
  158. package/dist/src/workflows/engine/interfaces/IVariableInterpolator.js +5 -0
  159. package/dist/src/workflows/engine/interfaces/IWorkflowDiscovery.js +4 -0
  160. package/dist/src/workflows/engine/interfaces/IWorkflowFileManager.js +5 -0
  161. package/dist/src/workflows/engine/interfaces/IWorkflowOutputFormatter.js +5 -0
  162. package/dist/src/workflows/engine/state/WorkflowStateMachine.js +194 -0
  163. package/dist/src/workflows/engine/state/interfaces/IStateMachine.js +17 -0
  164. package/dist/src/workflows/fallback-strategies.js +373 -0
  165. package/dist/src/workflows/message-queue.js +455 -0
  166. package/dist/src/workflows/model-router.js +189 -0
  167. package/dist/src/workflows/orchestrator-examples.js +174 -0
  168. package/dist/src/workflows/orchestrator-integration.js +200 -0
  169. package/dist/src/workflows/self-healing.js +524 -0
  170. package/dist/src/workflows/tool-mapper.js +407 -0
  171. package/dist/src/workflows/tool-orchestrator.js +796 -0
  172. package/dist/src/workflows/workflow-engine.js +573 -0
  173. package/dist/src/workflows/workflow-parser.js +283 -0
  174. package/dist/src/workflows/workflow-types.js +95 -0
  175. package/dist/src/workflows.js +568 -0
  176. package/dist/test-workflow-file-output.js +93 -0
  177. package/docs/API_KEYS.md +570 -0
  178. package/docs/CLAUDE_CODE_SETUP.md +181 -0
  179. package/docs/CLAUDE_DESKTOP_MANUAL.md +127 -0
  180. package/docs/CONFIGURATION.md +745 -0
  181. package/docs/FOCUS_MODES.md +240 -0
  182. package/docs/INSTALLATION_BOTH.md +145 -0
  183. package/docs/TERMS.md +352 -0
  184. package/docs/TOOLS_REFERENCE.md +1622 -0
  185. package/docs/TOOL_PARAMETERS.md +496 -0
  186. package/docs/TOOL_PROFILES.md +236 -0
  187. package/docs/WORKFLOWS.md +987 -0
  188. package/docs/WORKFLOW_OUTPUT.md +198 -0
  189. package/docs/WORKFLOW_PROGRESS_TRACKING.md +305 -0
  190. package/docs/workflows/design-brainstorm.md +335 -0
  191. package/package.json +97 -0
  192. package/profiles/balanced.json +37 -0
  193. package/profiles/code_focus.json +37 -0
  194. package/profiles/debug_intensive.json +34 -0
  195. package/profiles/full.json +37 -0
  196. package/profiles/minimal.json +37 -0
  197. package/profiles/research_power.json +37 -0
  198. package/profiles/workflow_builder.json +37 -0
  199. package/smithery.yaml +66 -0
  200. package/start.sh +8 -0
  201. package/tools.config.json +81 -0
  202. package/tsconfig.json +18 -0
  203. package/workflows/accessibility-code-audit.yaml +92 -0
  204. package/workflows/code-architecture-review.yaml +202 -0
  205. package/workflows/code-review.yaml +142 -0
  206. package/workflows/core/iterative-problem-solver.yaml +283 -0
  207. package/workflows/creative-brainstorm-yaml.yaml +215 -0
  208. package/workflows/pingpong.yaml +141 -0
  209. package/workflows/system/README.md +412 -0
  210. package/workflows/system/challenger.yaml +175 -0
  211. package/workflows/system/scout.yaml +164 -0
  212. package/workflows/system/verifier.yaml +133 -0
  213. package/workflows/ultra-creative-brainstorm.yaml +318 -0
  214. package/workflows/ux-research-flow.yaml +92 -0
package/README.md ADDED
@@ -0,0 +1,201 @@
1
+ # TachiBot MCP - Universal AI Orchestrator
2
+
3
+ [![Version](https://img.shields.io/badge/version-2.0.0-blue.svg)](https://github.com/byPawel/tachibot-mcp)
4
+ [![License](https://img.shields.io/badge/license-Apache%202.0-green.svg)](LICENSE)
5
+ [![Node](https://img.shields.io/badge/node-%3E%3D18.0.0-brightgreen.svg)](https://nodejs.org)
6
+ [![MCP](https://img.shields.io/badge/MCP-Compatible-purple.svg)](https://modelcontextprotocol.io)
7
+
8
+ Multi-model AI orchestration platform with 31 tools (32 with competitive mode), advanced workflows, and intelligent prompt engineering. Works with Claude Code, Claude Desktop, Cursor, and any MCP-compatible client.
9
+
10
+ ---
11
+
12
+ ## šŸ“š Documentation
13
+
14
+ **🌐 Full Documentation:** [tachibot.com/docs](https://tachibot.com/docs)
15
+
16
+ ### Quick Links
17
+
18
+ - **[Installation Guide](docs/INSTALLATION_BOTH.md)** - Get started in 5 minutes
19
+ - **[Configuration](docs/CONFIGURATION.md)** - Profiles, API keys, settings
20
+ - **[Tools Reference](docs/TOOLS_REFERENCE.md)** - All 31 tools explained
21
+ - **[Workflows](docs/WORKFLOWS.md)** - Multi-step AI orchestration
22
+ - **[API Keys Guide](docs/API_KEYS.md)** - Where to get API keys
23
+
24
+ ---
25
+
26
+ ## ✨ Key Features
27
+
28
+ ### šŸ¤– Multi-Model Intelligence
29
+ - **31 AI Tools:** Perplexity, Grok, GPT-5, Gemini, Qwen, Kimi (32 with competitive mode)
30
+ - **Multi-Model Reasoning:** Challenger, Verifier, Scout modes
31
+ - **Smart Routing:** Automatic model selection for optimal results
32
+
33
+ ### šŸ”„ Advanced Workflows
34
+ - **YAML-Based Workflows:** Define complex multi-step AI processes
35
+ - **Prompt Engineering:** 14 research-backed techniques built-in
36
+ - **Auto-Synthesis:** Prevents token overflow on large workflows
37
+ - **Parallel Execution:** Run multiple models simultaneously
38
+
39
+ ### šŸŽÆ Tool Profiles
40
+ - **Minimal** (8 tools) - Budget-friendly, token-constrained
41
+ - **Research Power** (15 tools) - Default, best balance
42
+ - **Code Focus** (13 tools) - Software development
43
+ - **Balanced** (17 tools) - General-purpose
44
+ - **Full** (31 tools, 32 with competitive) - Maximum capability
45
+
46
+ ### šŸ”§ Developer Experience
47
+ - **Claude Code Native** - First-class support
48
+ - **Claude Desktop** - Full integration
49
+ - **Cursor** - Works seamlessly
50
+ - **TypeScript** - Fully typed
51
+ - **Extensible** - Add custom tools & workflows
52
+
53
+ ---
54
+
55
+ ## šŸš€ Quick Start
56
+
57
+ ### Installation
58
+
59
+ ```bash
60
+ # Via NPM (recommended)
61
+ npm install -g tachibot-mcp
62
+
63
+ # Verify installation
64
+ tachibot --version
65
+ ```
66
+
67
+ ### Setup
68
+
69
+ 1. **Add API Keys** (at least one):
70
+ ```bash
71
+ cp .env.example .env
72
+ # Edit .env and add your API keys
73
+ ```
74
+
75
+ 2. **Configure Profile** (optional):
76
+ ```bash
77
+ # Edit .env
78
+ TACHIBOT_PROFILE=research_power # or minimal, code_focus, balanced, full
79
+ ```
80
+
81
+ 3. **Add to Claude Code/Desktop**:
82
+ ```json
83
+ {
84
+ "mcpServers": {
85
+ "tachibot": {
86
+ "command": "tachibot",
87
+ "env": {
88
+ "PERPLEXITY_API_KEY": "your-key",
89
+ "GROK_API_KEY": "your-key",
90
+ "OPENAI_API_KEY": "your-key",
91
+ "GEMINI_API_KEY": "your-key",
92
+ "OPENROUTER_API_KEY": "your-key"
93
+ }
94
+ }
95
+ }
96
+ }
97
+ ```
98
+
99
+ 4. **Restart Claude** and you're ready! šŸŽ‰
100
+
101
+ See [Installation Guide](docs/INSTALLATION_BOTH.md) for detailed instructions.
102
+
103
+ ---
104
+
105
+ ## šŸ“¦ What's Included
106
+
107
+ ### Core Tools
108
+ - šŸ” **Research:** `perplexity_ask`, `perplexity_research`, `grok_search`, `scout`
109
+ - 🧠 **Reasoning:** `grok_reason`, `kimi_thinking`, `openai_brainstorm`, `focus`
110
+ - šŸ’” **Analysis:** `gemini_brainstorm`, `gemini_analyze_text`, `qwen_coder`
111
+ - āœ… **Validation:** `verifier`, `challenger`
112
+ - šŸ’­ **Meta:** `think`, `nextThought`
113
+
114
+ ### Advanced Modes
115
+ - **Focus** - Deep collaborative reasoning (4+ models)
116
+ - **Scout** - Multi-source information gathering
117
+ - **Challenger** - Critical analysis with fact-checking
118
+ - **Verifier** - Multi-model consensus verification
119
+
120
+ ### Workflows
121
+ - **Ultra Creative Brainstorm** - 15 steps, 10 techniques
122
+ - **Iterative Problem Solver** - Research → Analyze → Solve
123
+ - **Code Architecture Review** - Systematic code analysis
124
+ - **Accessibility Audit** - WCAG compliance checking
125
+ - **Custom Workflows** - Build your own in YAML
126
+
127
+ ---
128
+
129
+ ## 🌟 Example Usage
130
+
131
+ ### Quick Research
132
+ ```typescript
133
+ // In Claude Code
134
+ perplexity_ask({
135
+ query: "What are the latest developments in transformer architecture?"
136
+ })
137
+ ```
138
+
139
+ ### Multi-Model Reasoning
140
+ ```typescript
141
+ focus({
142
+ query: "Design a scalable microservice architecture",
143
+ mode: "deep-reasoning",
144
+ models: ["grok-3", "gpt-5", "gemini-2.5"],
145
+ rounds: 5
146
+ })
147
+ ```
148
+
149
+ ### Run Workflow
150
+ ```bash
151
+ workflow --name ultra-creative-brainstorm --query "AI-powered code review system"
152
+ ```
153
+
154
+ ---
155
+
156
+ ## šŸŽ“ Learn More
157
+
158
+ ### Documentation
159
+ - šŸ“– [Full Documentation](https://tachibot.com/docs)
160
+ - šŸ”§ [Configuration Guide](docs/CONFIGURATION.md)
161
+ - šŸ› ļø [Tool Parameters](docs/TOOL_PARAMETERS.md)
162
+ - šŸŽÆ [Tool Profiles](docs/TOOL_PROFILES.md)
163
+ - šŸ” [API Keys Guide](docs/API_KEYS.md)
164
+ - ⚔ [Focus Modes](docs/FOCUS_MODES.md)
165
+ - šŸ“ [Workflows Guide](docs/WORKFLOWS.md)
166
+
167
+ ### Setup Guides
168
+ - [Claude Code Setup](docs/CLAUDE_CODE_SETUP.md)
169
+ - [Claude Desktop Setup](docs/CLAUDE_DESKTOP_MANUAL.md)
170
+ - [Both Platforms](docs/INSTALLATION_BOTH.md)
171
+
172
+ ---
173
+
174
+ ## šŸ¤ Contributing
175
+
176
+ We welcome contributions! See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
177
+
178
+ - šŸ› [Report Issues](https://github.com/byPawel/tachibot-mcp/issues)
179
+ - šŸ’” [Request Features](https://github.com/byPawel/tachibot-mcp/issues/new?template=feature_request.md)
180
+ - šŸ“– [Improve Docs](https://github.com/byPawel/tachibot-mcp/pulls)
181
+
182
+ ---
183
+
184
+ ## šŸ“„ License
185
+
186
+ Apache License 2.0 - see [LICENSE](LICENSE) for details.
187
+
188
+ ---
189
+
190
+ ## šŸ”— Links
191
+
192
+ - **Website:** [tachibot.com](https://tachibot.com)
193
+ - **Documentation:** [tachibot.com/docs](https://tachibot.com/docs)
194
+ - **GitHub:** [github.com/byPawel/tachibot-mcp](https://github.com/byPawel/tachibot-mcp)
195
+ - **Issues:** [Report a Bug](https://github.com/byPawel/tachibot-mcp/issues)
196
+
197
+ ---
198
+
199
+ **Made with ā¤ļø by the TachiBot Team**
200
+
201
+ *Transform your AI workflow with intelligent multi-model orchestration.*
package/SECURITY.md ADDED
@@ -0,0 +1,95 @@
1
+ # Security Policy
2
+
3
+ ## Supported Versions
4
+
5
+ Currently supported versions for security updates:
6
+
7
+ | Version | Supported |
8
+ | ------- | ------------------ |
9
+ | 2.0.x | :white_check_mark: |
10
+ | < 2.0 | :x: |
11
+
12
+ ## Reporting a Vulnerability
13
+
14
+ We take security vulnerabilities seriously. If you discover a security vulnerability within TachiBot MCP, please follow these steps:
15
+
16
+ ### How to Report
17
+
18
+ 1. **DO NOT** create a public GitHub issue for security vulnerabilities
19
+ 2. Instead, please report vulnerabilities via:
20
+ - Email: `tachibotmcp [at] gmail [dot] com`
21
+ - GitHub Security Advisory: [Report a vulnerability](https://github.com/pavveu/tachibot-mcp/security/advisories/new)
22
+
23
+ ### What to Include
24
+
25
+ Please provide:
26
+ - Description of the vulnerability
27
+ - Steps to reproduce
28
+ - Potential impact
29
+ - Suggested fix (if any)
30
+
31
+ ### Response Timeline
32
+
33
+ - Acknowledgment: Within 48 hours
34
+ - Initial assessment: Within 1 week
35
+ - Fix timeline: Depends on severity
36
+
37
+ ## Security Best Practices
38
+
39
+ When using TachiBot MCP:
40
+
41
+ ### API Key Management
42
+ - **Never** commit API keys to version control
43
+ - Always use `.env` files for sensitive data
44
+ - Keep `.env` in `.gitignore`
45
+ - Rotate API keys regularly
46
+ - Use minimal required permissions for API keys
47
+
48
+ ### Environment Variables
49
+ - All sensitive data should be in environment variables
50
+ - Never hardcode credentials in source code
51
+ - Review `.env.example` for required variables
52
+
53
+ ### Dependencies
54
+ - Keep dependencies updated
55
+ - Run `npm audit` regularly
56
+ - Fix vulnerabilities with `npm audit fix`
57
+
58
+ ### MCP Server Security
59
+ - Only install MCP servers from trusted sources
60
+ - Review server permissions before installation
61
+ - Understand what data servers can access
62
+
63
+ ## Known Security Considerations
64
+
65
+ ### API Key Exposure
66
+ - TachiBot MCP requires multiple API keys
67
+ - Each key should have minimal required permissions
68
+ - Monitor API usage for unusual activity
69
+
70
+ ### Tool Execution
71
+ - Tools can make external API calls
72
+ - Review tool actions before execution
73
+ - Understand cost implications of tool usage
74
+
75
+ ### Data Privacy
76
+ - TachiBot may send data to external AI providers
77
+ - Review privacy policies of used services
78
+ - Don't process sensitive/personal data
79
+
80
+ ## Security Updates
81
+
82
+ Security updates will be released as:
83
+ - Patch versions for minor fixes
84
+ - Minor versions for significant security improvements
85
+ - Announced in GitHub releases
86
+
87
+ ## Contact
88
+
89
+ For security-related inquiries:
90
+ - Email: `tachibotmcp [at] gmail [dot] com`
91
+ - GitHub Security Advisory: [Report a vulnerability](https://github.com/pavveu/tachibot-mcp/security/advisories/new)
92
+
93
+ ## Acknowledgments
94
+
95
+ We appreciate responsible disclosure of security vulnerabilities and will acknowledge security researchers who help improve TachiBot MCP's security.
@@ -0,0 +1,12 @@
1
+ export function getKomaAIForStep(step) {
2
+ return {
3
+ message: "TachiBot thinking...",
4
+ ascii: "@@@@@@@@@\n@ ā— ā— @\n@ ā—” @\n@@@@@@@@@"
5
+ };
6
+ }
7
+ export function getRandomKomaAI() {
8
+ return getKomaAIForStep(0);
9
+ }
10
+ export function getKomaAIState() {
11
+ return "active";
12
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "description": "Balanced set for general use (~10-11k tokens, 17 tools)",
3
+ "tools": {
4
+ "think": true,
5
+ "focus": true,
6
+ "nextThought": true,
7
+ "perplexity_ask": true,
8
+ "perplexity_reason": true,
9
+ "grok_reason": true,
10
+ "grok_code": true,
11
+ "openai_brainstorm": true,
12
+ "gemini_brainstorm": true,
13
+ "gemini_analyze_code": true,
14
+ "qwen_coder": true,
15
+ "verifier": true,
16
+ "scout": true,
17
+ "challenger": true,
18
+ "workflow": true,
19
+ "list_workflows": true,
20
+ "pingpong": true,
21
+ "perplexity_research": false,
22
+ "grok_debug": false,
23
+ "grok_architect": false,
24
+ "grok_brainstorm": false,
25
+ "grok_search": false,
26
+ "openai_compare": false,
27
+ "gemini_analyze_text": false,
28
+ "kimi_thinking": false,
29
+ "create_workflow": false,
30
+ "visualize_workflow": false,
31
+ "qwen_competitive": false
32
+ }
33
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "description": "Code-heavy work with debugging and analysis (~8-9k tokens, 13 tools)",
3
+ "tools": {
4
+ "think": true,
5
+ "focus": true,
6
+ "nextThought": true,
7
+ "perplexity_ask": true,
8
+ "grok_reason": true,
9
+ "grok_code": true,
10
+ "grok_debug": true,
11
+ "gemini_analyze_code": true,
12
+ "gemini_brainstorm": true,
13
+ "qwen_coder": true,
14
+ "verifier": true,
15
+ "workflow": true,
16
+ "list_workflows": true,
17
+ "perplexity_reason": false,
18
+ "perplexity_research": false,
19
+ "grok_architect": false,
20
+ "grok_brainstorm": false,
21
+ "grok_search": false,
22
+ "openai_compare": false,
23
+ "openai_brainstorm": false,
24
+ "gemini_analyze_text": false,
25
+ "kimi_thinking": false,
26
+ "scout": false,
27
+ "challenger": false,
28
+ "create_workflow": false,
29
+ "visualize_workflow": false,
30
+ "pingpong": false,
31
+ "qwen_competitive": false
32
+ }
33
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "description": "All tools enabled for maximum capability (~18-19k tokens, 26 tools)",
3
+ "tools": {
4
+ "think": true,
5
+ "focus": true,
6
+ "nextThought": true,
7
+ "perplexity_ask": true,
8
+ "perplexity_reason": true,
9
+ "perplexity_research": true,
10
+ "grok_reason": true,
11
+ "grok_code": true,
12
+ "grok_debug": true,
13
+ "grok_architect": true,
14
+ "grok_brainstorm": true,
15
+ "grok_search": true,
16
+ "openai_compare": true,
17
+ "openai_brainstorm": true,
18
+ "gemini_brainstorm": true,
19
+ "gemini_analyze_code": true,
20
+ "gemini_analyze_text": true,
21
+ "qwen_coder": true,
22
+ "kimi_thinking": true,
23
+ "verifier": true,
24
+ "scout": true,
25
+ "challenger": true,
26
+ "workflow": true,
27
+ "list_workflows": true,
28
+ "create_workflow": true,
29
+ "visualize_workflow": true,
30
+ "pingpong": true,
31
+ "qwen_competitive": false
32
+ }
33
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "description": "Minimal tool set for basic tasks (~4-5k tokens, 8 tools)",
3
+ "tools": {
4
+ "think": true,
5
+ "focus": true,
6
+ "nextThought": true,
7
+ "perplexity_ask": true,
8
+ "grok_reason": true,
9
+ "gemini_brainstorm": true,
10
+ "qwen_coder": true,
11
+ "workflow": true,
12
+ "perplexity_reason": false,
13
+ "perplexity_research": false,
14
+ "grok_code": false,
15
+ "grok_debug": false,
16
+ "grok_architect": false,
17
+ "grok_brainstorm": false,
18
+ "grok_search": false,
19
+ "openai_compare": false,
20
+ "openai_brainstorm": false,
21
+ "gemini_analyze_code": false,
22
+ "gemini_analyze_text": false,
23
+ "kimi_thinking": false,
24
+ "verifier": false,
25
+ "scout": false,
26
+ "challenger": false,
27
+ "list_workflows": false,
28
+ "create_workflow": false,
29
+ "visualize_workflow": false,
30
+ "pingpong": false,
31
+ "qwen_competitive": false
32
+ }
33
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "description": "Research-focused with Grok search + all Perplexity + brainstorming (~9-10k tokens, 15 tools)",
3
+ "tools": {
4
+ "think": true,
5
+ "focus": true,
6
+ "nextThought": true,
7
+ "perplexity_ask": true,
8
+ "perplexity_reason": true,
9
+ "perplexity_research": true,
10
+ "grok_search": true,
11
+ "grok_reason": true,
12
+ "openai_brainstorm": true,
13
+ "gemini_brainstorm": true,
14
+ "scout": true,
15
+ "verifier": true,
16
+ "challenger": true,
17
+ "qwen_coder": true,
18
+ "kimi_thinking": true,
19
+ "workflow": true,
20
+ "list_workflows": true,
21
+ "grok_code": false,
22
+ "grok_debug": false,
23
+ "grok_architect": false,
24
+ "grok_brainstorm": false,
25
+ "openai_compare": false,
26
+ "gemini_analyze_code": false,
27
+ "gemini_analyze_text": false,
28
+ "create_workflow": false,
29
+ "visualize_workflow": false,
30
+ "pingpong": false,
31
+ "qwen_competitive": false
32
+ }
33
+ }
@@ -0,0 +1,46 @@
1
+ /**
2
+ * Build Profiles Script
3
+ * Converts TypeScript profile definitions to JSON files
4
+ * Run during npm run build
5
+ */
6
+ import { writeFileSync, mkdirSync, existsSync } from 'fs';
7
+ import { join, dirname } from 'path';
8
+ import { fileURLToPath } from 'url';
9
+ // Get __dirname equivalent in ES modules
10
+ const __filename = fileURLToPath(import.meta.url);
11
+ const __dirname = dirname(__filename);
12
+ // Import profile definitions
13
+ import { minimalProfile } from '../src/profiles/minimal.js';
14
+ import { researchPowerProfile } from '../src/profiles/research_power.js';
15
+ import { codeFocusProfile } from '../src/profiles/code_focus.js';
16
+ import { balancedProfile } from '../src/profiles/balanced.js';
17
+ import { fullProfile } from '../src/profiles/full.js';
18
+ const profiles = {
19
+ minimal: minimalProfile,
20
+ research_power: researchPowerProfile,
21
+ code_focus: codeFocusProfile,
22
+ balanced: balancedProfile,
23
+ full: fullProfile,
24
+ };
25
+ // Output directory - write to root profiles/ (not dist/profiles/)
26
+ const outputDir = join(__dirname, '../..', 'profiles');
27
+ // Ensure output directory exists
28
+ if (!existsSync(outputDir)) {
29
+ mkdirSync(outputDir, { recursive: true });
30
+ }
31
+ console.log('šŸ”Ø Building profile JSON files...\n');
32
+ // Convert each profile to JSON
33
+ for (const [name, profile] of Object.entries(profiles)) {
34
+ const outputPath = join(outputDir, `${name}.json`);
35
+ // Count enabled tools
36
+ const enabledCount = Object.values(profile.tools).filter(Boolean).length;
37
+ // Update description with actual count (replace any existing count)
38
+ const updatedProfile = {
39
+ ...profile,
40
+ description: profile.description.replace(/\d+ tools\)/, `${enabledCount} tools)`)
41
+ };
42
+ const jsonContent = JSON.stringify(updatedProfile, null, 2);
43
+ writeFileSync(outputPath, jsonContent, 'utf-8');
44
+ console.log(`āœ… ${name}.json (${enabledCount} tools)`);
45
+ }
46
+ console.log(`\n✨ Built ${Object.keys(profiles).length} profile files in ${outputDir}`);
@@ -0,0 +1,46 @@
1
+ /**
2
+ * FocusModeRegistry - Registry pattern for Focus modes
3
+ * Follows Open/Closed Principle - add new modes without modifying this class
4
+ */
5
+ export class FocusModeRegistry {
6
+ constructor() {
7
+ this.modes = new Map();
8
+ }
9
+ /**
10
+ * Register a focus mode
11
+ * @param mode Mode implementation to register
12
+ */
13
+ register(mode) {
14
+ this.modes.set(mode.modeName, mode);
15
+ }
16
+ /**
17
+ * Get a focus mode by name
18
+ * @param name Mode name
19
+ * @returns Mode implementation or undefined
20
+ */
21
+ get(name) {
22
+ return this.modes.get(name);
23
+ }
24
+ /**
25
+ * Get all registered mode names
26
+ * @returns Array of mode names
27
+ */
28
+ getAllNames() {
29
+ return Array.from(this.modes.keys());
30
+ }
31
+ /**
32
+ * Check if a mode is registered
33
+ * @param name Mode name
34
+ * @returns true if mode exists
35
+ */
36
+ has(name) {
37
+ return this.modes.has(name);
38
+ }
39
+ /**
40
+ * Get count of registered modes
41
+ * @returns Number of modes
42
+ */
43
+ get size() {
44
+ return this.modes.size;
45
+ }
46
+ }
@@ -0,0 +1,109 @@
1
+ /**
2
+ * FocusTool Service - Orchestrator for Focus modes
3
+ * Uses Strategy Pattern + Registry + Delegate Map for mode management
4
+ * Phase 2 of SOLID refactoring (reduces 431-line switch statement)
5
+ *
6
+ * Architecture:
7
+ * 1. FocusModeRegistry - For complex extracted modes (FocusDeepMode, TachibotStatusMode)
8
+ * 2. Delegate Map - For simple orchestrator calls
9
+ * 3. Legacy fallback - For modes with complex conditional logic (handled by server.ts)
10
+ */
11
+ import { TechnicalDomain } from '../../../reasoning-chain.js';
12
+ export class FocusToolService {
13
+ constructor(modeRegistry, collaborativeOrchestrator) {
14
+ this.modeRegistry = modeRegistry;
15
+ this.collaborativeOrchestrator = collaborativeOrchestrator;
16
+ this.name = 'focus';
17
+ this.description = 'Multi-model reasoning with various modes';
18
+ this.delegateHandlers = this.createDelegateHandlers();
19
+ }
20
+ async execute(params) {
21
+ const modeName = params.mode || 'simple';
22
+ // 1. Try extracted modes first (Strategy Pattern)
23
+ const mode = this.modeRegistry.get(modeName);
24
+ if (mode) {
25
+ return mode.execute(params);
26
+ }
27
+ // 2. Try delegate handlers (simple orchestrator calls)
28
+ const handler = this.delegateHandlers.get(modeName);
29
+ if (handler) {
30
+ const output = await handler(params);
31
+ return {
32
+ output,
33
+ metadata: {
34
+ mode: modeName,
35
+ timestamp: Date.now()
36
+ }
37
+ };
38
+ }
39
+ // 3. Mode not found in service - fallback to legacy server.ts
40
+ // This allows gradual migration of complex conditional modes
41
+ throw new Error(`Mode "${modeName}" not handled by FocusToolService. ` +
42
+ `Available: [${[...this.modeRegistry.getAllNames(), ...this.delegateHandlers.keys()].join(', ')}]`);
43
+ }
44
+ validate(params) {
45
+ const mode = params.mode;
46
+ return typeof mode === 'string' && mode.length > 0;
47
+ }
48
+ /**
49
+ * Create delegate handlers for simple orchestrator modes
50
+ * These modes just call a single collaborativeOrchestrator method
51
+ */
52
+ createDelegateHandlers() {
53
+ const handlers = new Map();
54
+ // Helper to parse domain parameter
55
+ const parseDomain = (domainParam) => {
56
+ if (!domainParam || typeof domainParam !== 'string') {
57
+ return TechnicalDomain.ARCHITECTURE; // Default fallback
58
+ }
59
+ const domainKey = domainParam.toUpperCase();
60
+ return TechnicalDomain[domainKey] || TechnicalDomain.ARCHITECTURE;
61
+ };
62
+ // Deep reasoning & code brainstorming
63
+ handlers.set('deep-reasoning', async (params) => {
64
+ const query = params.query;
65
+ const domain = parseDomain(params.domain);
66
+ const plan = await this.collaborativeOrchestrator.startDeepReasoning(query, domain);
67
+ const title = "🧠 **DEEP COLLABORATIVE REASONING**";
68
+ return `${title}\n\n${plan}\n\nšŸ”„ **How it works**: Models collaborate, critique, and build upon each other's ideas to find optimal solutions.`;
69
+ });
70
+ handlers.set('code-brainstorm', async (params) => {
71
+ const query = params.query;
72
+ const domain = parseDomain(params.domain);
73
+ const plan = await this.collaborativeOrchestrator.startDeepReasoning(query, domain);
74
+ const title = "šŸ’” **CODE BRAINSTORMING SESSION**";
75
+ return `${title}\n\n${plan}\n\nšŸ”„ **How it works**: Models collaborate, critique, and build upon each other's ideas to find optimal solutions.`;
76
+ });
77
+ // Dynamic debate
78
+ handlers.set('dynamic-debate', async (params) => {
79
+ const query = params.query;
80
+ const domain = parseDomain(params.domain);
81
+ const plan = await this.collaborativeOrchestrator.startDynamicDebate(query, domain);
82
+ return `āš”ļø **DYNAMIC DEBATE SESSION**\n\n${plan}\n\n🄊 **How it works**: Models take opposing positions, argue their cases, provide rebuttals, and engage in intellectual combat to explore all angles of complex problems.`;
83
+ });
84
+ // Template-based modes
85
+ const templateModes = [
86
+ ['architecture-debate', 'architecture_debate'],
87
+ ['algorithm-optimize', 'algorithm_optimize'],
88
+ ['security-audit', 'security_audit'],
89
+ ['api-design', 'api_design'],
90
+ ['debug-detective', 'debug_detective'],
91
+ ['performance-council', 'performance_council']
92
+ ];
93
+ for (const [modeName, templateKey] of templateModes) {
94
+ handlers.set(modeName, async (params) => {
95
+ const query = params.query;
96
+ const domain = parseDomain(params.domain);
97
+ return await this.collaborativeOrchestrator.startTemplateSession(templateKey, query, domain);
98
+ });
99
+ }
100
+ // Simple utility modes
101
+ handlers.set('list-templates', async () => {
102
+ return this.collaborativeOrchestrator.getAvailableTemplates();
103
+ });
104
+ handlers.set('examples', async () => {
105
+ return this.collaborativeOrchestrator.getExampleWorkflows();
106
+ });
107
+ return handlers;
108
+ }
109
+ }