Skip to content

Pandi2352/MindRoute

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MindRoute

🧠 MindRoute

Strategic Thinking Assistant — Guided AI Conversations, Your Way

Node.js Electron Ollama Mermaid MIT License

🚀 Stop getting walls of text. Start thinking strategically, step by step.



🎯 What is MindRoute?

MindRoute is an Electron desktop chatbot that revolutionizes how you interact with LLMs. Instead of getting a single monolithic AI response, MindRoute generates multiple thinking paths — and lets you control exactly how deep the AI explores each one, step by step.

💡 Think of it like GPS for your thoughts — multiple routes to your answer, you pick the path and how far to go.


✨ How It Works

┌─────────────────────────────────────────────────────────────────┐
│  🔵 You ask a question                                         │
│       ↓                                                        │
│  🧠 AI generates 4 unique thinking approaches                  │
│       ↓                                                        │
│  🎯 You click a step → AI executes ONLY up to that point       │
│       ↓                                                        │
│  📊 Get code blocks, diagrams, or structured analysis           │
│       ↓                                                        │
│  🔄 New paths auto-generate based on the conversation           │
│       ↓                                                        │
│  🔁 Keep exploring, switch directions, go deeper                │
└─────────────────────────────────────────────────────────────────┘
Step What Happens
1️⃣ Type your question
2️⃣ Get 4 thinking approaches (Analytical, Creative, Practical, Visual Flowchart)
3️⃣ Click Step 1, Step 2, or Step 3 to control depth
4️⃣ Get structured responses with code blocks, Mermaid diagrams, or detailed analysis
5️⃣ New paths appear — keep exploring or change direction

🌟 Features

🧭 Guided Thinking Paths

  • 🔹 4 unique approaches per question
  • 🔹 Click any step to control depth
  • 🔹 Visual progress — green highlights on executed steps
  • 🔹 Smart fallbacks for code, analysis, or general queries

🔄 Adaptive Conversation

  • 🔸 Auto-updating paths after each response
  • 🔸 Context-aware — builds on conversation history
  • 🔸 Manual refresh button to regenerate approaches
  • 🔸 Continuation focus — always moves forward

📊 Visual Flowcharts

  • 🟠 Mermaid.js diagrams rendered inline
  • 🟠 Auto-generated from "Visual Flowchart" approach
  • 🟠 Interactive SVG — zoom, pan, inspect
  • 🟠 Smart sanitization — auto-fixes LLM syntax errors

💻 Code Block Rendering

  • 🟣 Syntax-highlighted code blocks with language labels
  • 🟣 One-click copy button on every code block
  • 🟣 Inline code styling for quick references
  • 🟣 Monospace fonts — Cascadia Code, Fira Code, JetBrains Mono

☁️ Cloud + Local LLM

  • 🔵 Ollama Cloudgpt-oss:120b via API
  • 🔵 Local mode — run any Ollama model offline
  • 🔵 Model flexible — Gemma, Llama, Mistral, etc.
  • 🔵 Easy switching between cloud and local

🎨 Dark Glassmorphism UI

  • 🟢 Side-by-side layout — chat + paths sidebar
  • 🟢 Custom title bar with window controls
  • 🟢 Live connection status with glowing indicator
  • 🟢 Smooth animations — slide-in messages, hover effects

🖥️ UI Layout

┌──────────────────────────────────────────────────────────────────┐
│  ● ● ●          MindRoute              ● Connected              │
├────────────────────────────────────┬─────────────────────────────┤
│                                    │  ✦ THINKING PATHS           │
│   💬 Chat Messages                 │                             │
│                                    │  ┌─ ANALYTICAL ──────────┐  │
│   Welcome to MindRoute...          │  │  ① Break down question │  │
│                                    │  │  ② Examine components  │  │
│   ┌──────────────────────────┐     │  │  ③ Synthesize insights │  │
│   │ 🧠 Following "Analytical"│     │  └───────────────────────┘  │
│   │                          │     │  ┌─ CREATIVE ────────────┐  │
│   │  ```python               │     │  │  ① Brainstorm ideas   │  │
│   │  def solve():            │     │  │  ② Explore options     │  │
│   │      return answer       │     │  │  ③ Refine concepts     │  │
│   │  ```                     │     │  └───────────────────────┘  │
│   │                          │     │  ┌─ PRACTICAL ───────────┐  │
│   │  ┌──────────────────┐    │     │  │  ① Implementation     │  │
│   │  │ 📊 Mermaid Diagram│    │     │  │  ② Constraints        │  │
│   │  │  A → B → C       │    │     │  │  ③ Action steps        │  │
│   │  └──────────────────┘    │     │  └───────────────────────┘  │
│   └──────────────────────────┘     │  ┌─ VISUAL FLOWCHART ────┐  │
│                                    │  │  ① Map process flow    │  │
│                                    │  │  ② Decision points     │  │
│                                    │  │  ③ Diagram connections  │  │
│                                    │  └───────────────────────┘  │
├────────────────────────────────────┤                             │
│  [What would you like to think...] │  ↻ Regenerate Approaches   │
│                            [Send]  │                             │
└────────────────────────────────────┴─────────────────────────────┘

📂 Project Structure

MindRoute/
├── 🔧 main.js          → Electron main process, Ollama SDK, optimized prompts
├── 🎨 index.html        → Dark UI, code blocks, Mermaid rendering, sidebar layout
├── 📦 package.json      → Dependencies and scripts
├── 📄 LICENSE           → MIT License
├── 🚫 .gitignore        → Node modules, build artifacts
└── 📖 readme.md         → You are here!

⚡ Quick Start

Prerequisites

Requirement Version
Node.js v18+
Ollama Latest (for local mode)

Installation

# 1️⃣ Clone the repo
git clone https://github.com/pandi-selvam/MindRoute.git
cd MindRoute

# 2️⃣ Install dependencies
npm install

# 3️⃣ Start the app
npm start

Development Mode

# Auto-reload on changes
npm run dev

⚙️ Configuration

🔑 Cloud Mode (Default)

MindRoute connects to Ollama Cloud using gpt-oss:120b. To use your own API key, update main.js:

// main.js — initOllama()
ollama = new Ollama({
  host: "https://ollama.com",
  headers: {
    Authorization: "Bearer YOUR_API_KEY_HERE",
  },
});

🏠 Local Mode

To switch to a local Ollama instance, update initOllama() in main.js:

ollama = new Ollama({
  host: "http://localhost:11434",
});

And change the model in all handlers:

model: "llama3.1:8b"  // or gemma3:1b, mistral:7b, etc.

🎨 UI Customization

What Where
Dark theme colors index.html:root CSS variables
Sidebar width .paths-panelwidth: 360px
Color accents --purple, --blue, --cyan, --green vars
Window size main.jswidth: 1200, height: 800

⌨️ Keyboard Shortcuts

Shortcut Action
Enter 📨 Send message
Ctrl/Cmd + W ❌ Close window
Ctrl/Cmd + M ➖ Minimize window
F11 🔲 Toggle maximize
Ctrl/Cmd + R 🔄 Refresh thinking paths

🛠️ Tech Stack

Component Technology
🖥️ Desktop Electron v27+
🤖 LLM Backend Ollama (Cloud + Local)
📡 API Client Ollama SDK
📊 Diagrams Mermaid.js v10
🎨 Frontend Vanilla HTML / CSS / JS (dark glassmorphism)
🔧 Dev Tools concurrently, nodemon

💡 Use Cases

Domain How MindRoute Helps
💻 Development Debug with controllable depth, get code blocks with copy button, explore architecture with flowcharts
📚 Research Break complex topics into structured, step-by-step exploration with visual diagrams
🎯 Decision Making Evaluate options through analytical, creative, and practical lenses
🔍 Problem Solving Systematic root-cause investigation with Mermaid flowcharts mapping the process
📝 Writing & Planning Outline strategies with incremental, guided thinking and visual flow mapping

🔮 Roadmap

  • 📊 Mermaid.js flowchart diagrams
  • 💻 Syntax-highlighted code blocks with copy
  • 🎨 Dark glassmorphism sidebar layout
  • ☁️ Ollama Cloud integration
  • 🎛️ Multi-model support — different models per path
  • 📋 Custom thinking templates — save & reuse approaches
  • 💾 Conversation export — save sessions as documents
  • ⚡ Streaming responses — tokens as they arrive
  • 🔌 Plugin system — extend with custom tools

🤝 Contributing

Contributions are welcome!

# 1. Fork the repo
# 2. Create your branch
git checkout -b feature/awesome-feature

# 3. Commit your changes
git commit -m "Add awesome feature"

# 4. Push and open a PR
git push origin feature/awesome-feature

📜 License

MIT License — see LICENSE for details.


🙏 Acknowledgments

  • 🦙 Ollama — Making LLM deployment accessible
  • Electron — Cross-platform desktop framework
  • 📊 Mermaid.js — Diagrams and flowcharts from text
  • 💭 Inspired by consulting methodologies and structured problem-solving

Built with 💜 by Pandi Selvam P

🧠 Think smarter. Explore deeper. Control your AI conversations.

About

Strategic Thinking Assistant — Guided AI Conversations, Your Way

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors