Skip to content

Sid0004/neuroshell-ai-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 

Repository files navigation

███╗   ██╗ ███████╗ ██╗   ██╗ ██████╗   ██████╗  ███████╗ ██╗  ██╗ ███████╗ ██╗      ██╗     
████╗  ██║ ██╔════╝ ██║   ██║ ██╔══██╗ ██╔═══██╗ ██╔════╝ ██║  ██║ ██╔════╝ ██║      ██║     
██╔██╗ ██║ █████╗   ██║   ██║ ██████╔╝ ██║   ██║ ███████╗ ███████║ █████╗   ██║      ██║     
██║╚██╗██║ ██╔══╝   ██║   ██║ ██╔══██╗ ██║   ██║ ╚════██║ ██╔══██║ ██╔══╝   ██║      ██║     
██║ ╚████║ ███████╗ ╚██████╔╝ ██║  ██║ ╚██████╔╝ ███████║ ██║  ██║ ███████╗ ███████╗ ███████╗
╚═╝  ╚═══╝ ╚══════╝  ╚═════╝  ╚═╝  ╚═╝  ╚═════╝  ╚══════╝ ╚═╝  ╚═╝ ╚══════╝ ╚══════╝ ╚══════╝

A Modern, GPU-Rendered Terminal with AI-Powered Command Translation

License C++ Platform


✨ Features

  • 🎨 Modern GPU-Rendered UI - Built with Dear ImGui + OpenGL for smooth, beautiful interface
  • 🤖 AI-Powered Commands - Translate natural language to shell commands using OpenAI, Groq, Gemini, or Ollama
  • 📦 Command Blocks - Warp-style command history with clear visual separation
  • 🎯 Native Desktop App - Standalone executable, no browser required
  • 🌈 Beautiful Themes - Tokyo Night theme with customizable colors
  • Fast & Responsive - Hardware-accelerated rendering

🚀 Quick Start

Prerequisites

  • Windows 10/11
  • Visual Studio 2022 with C++ Desktop Development
  • CMake 3.15+
  • Git

Build Instructions

  1. Clone the repository
git clone https://github.com/yourusername/neuroshell-cli.git
cd neuroshell-cli
  1. Setup dependencies

The project requires the following libraries in the thirdparty directory:

  • ImGui (docking branch)
  • GLFW
  • GLAD
  • nlohmann/json
# Clone ImGui (docking branch)
cd thirdparty
git clone -b docking https://github.com/ocornut/imgui.git

# Clone GLFW
git clone https://github.com/glfw/glfw.git

# Clone nlohmann/json
git clone https://github.com/nlohmann/json.git

# GLAD - Already included in thirdparty/glad/
cd ..
  1. Build the project
build.bat
  1. Run NeuroShell
run.bat

Or manually:

cd build\bin\Release
neuroshell.exe

⚙️ Configuration

AI Setup (Optional)

To enable AI-powered command translation, edit config/settings.json:

{
  "ai": {
    "provider": "openai",
    "model": "gpt-4",
    "apiKey": "YOUR_API_KEY_HERE",
    "temperature": 0.7,
    "maxTokens": 500
  }
}

Supported AI Providers:

  • OpenAI (gpt-4, gpt-3.5-turbo)
  • Groq (llama3-70b, mixtral-8x7b)
  • Gemini (gemini-pro)
  • Ollama (llama2, codellama) - Local, no API key needed

Enabling CURL for AI Features

AI features require CURL library. To enable:

  1. Install CURL via vcpkg:
vcpkg install curl:x64-windows
  1. Rebuild with CURL enabled:
cd build
cmake -DENABLE_CURL=ON -DCMAKE_TOOLCHAIN_FILE=path\to\vcpkg\scripts\buildsystems\vcpkg.cmake ..
cmake --build . --config Release

⌨️ Keyboard Shortcuts

Shortcut Action
Ctrl+L Clear screen
Ctrl+Shift+C Clear history
Ctrl+J Toggle AI panel
Ctrl+K Focus command input
↑/↓ Navigate command history

🎨 Project Structure

NeuroShell/
├── src/
│   ├── main.cpp              # Application entry point
│   ├── ui/                   # UI implementation (ImGui)
│   ├── terminal/             # Terminal logic and command executor
│   ├── ai/                   # AI client (OpenAI, Groq, etc.)
│   └── utils/                # Utilities (config, logger, safety)
├── include/                  # Header files
├── thirdparty/               # Third-party libraries
│   ├── imgui/
│   ├── glfw/
│   ├── glad/
│   └── json/
├── config/                   # Configuration files
│   └── settings.json
├── build.bat                 # Build script
├── run.bat                   # Run script
└── CMakeLists.txt           # CMake configuration

🛠️ Development

Building for Development

mkdir build && cd build
cmake -G "Visual Studio 17 2022" -A x64 ..
cmake --build . --config Debug

Adding Features

  1. UI components: Modify src/ui/ui.cpp
  2. Terminal logic: Modify src/terminal/terminal.cpp
  3. Command execution: Modify src/terminal/command_executor.cpp
  4. AI integration: Modify src/ai/ai_client.cpp

🐛 Troubleshooting

Build Errors

Missing Dependencies

ERROR: ImGui not found
Fix: cd thirdparty && git clone -b docking https://github.com/ocornut/imgui.git

CMake Configuration Failed

  • Ensure Visual Studio 2022 is installed with C++ Desktop Development
  • Ensure CMake is in your PATH
  • Check that all dependencies are in thirdparty/

Runtime Errors

Window doesn't appear

  • Update graphics drivers
  • Ensure OpenGL 3.3+ is supported
  • Run as administrator

AI not working

  • Verify API key in config/settings.json
  • Check internet connection
  • For Ollama: ensure ollama serve is running
  • Rebuild with CURL enabled

📄 License

MIT License - see LICENSE file for details.


🙏 Acknowledgments


📞 Support


Made with ❤️ for developers who love beautiful terminals