https://github.com/yogsec/hacker-ai
This tool combines the power of Ollama (Mistral) with your terminal to turn natural language into real shell commands. Whether you want to scan websites with nmap or ping a server, just type what you want β HackerAI handles the rest. All locally, without any API costs!
https://github.com/yogsec/hacker-ai
bugbountytools burpsuite chatgpt cyber-security cybersec cybersecurity deep-learning deepseek forensics hackerai hackergpt hackgpt hacking-tools infosec machinelearning mitre openai osint wireshark
Last synced: about 1 month ago
JSON representation
This tool combines the power of Ollama (Mistral) with your terminal to turn natural language into real shell commands. Whether you want to scan websites with nmap or ping a server, just type what you want β HackerAI handles the rest. All locally, without any API costs!
- Host: GitHub
- URL: https://github.com/yogsec/hacker-ai
- Owner: yogsec
- License: mit
- Created: 2025-03-04T10:21:53.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-04T10:29:57.000Z (about 1 year ago)
- Last Synced: 2025-03-04T11:31:55.869Z (about 1 year ago)
- Topics: bugbountytools, burpsuite, chatgpt, cyber-security, cybersec, cybersecurity, deep-learning, deepseek, forensics, hackerai, hackergpt, hackgpt, hacking-tools, infosec, machinelearning, mitre, openai, osint, wireshark
- Language: Python
- Homepage: https://linktr.ee/yogsec
- Size: 200 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# HackerAI - Your Local AI Security Assistant
Welcome to **HackerAI**! This tool combines the power of **Ollama (Mistral)** with **your terminal** to turn natural language into real shell commands. Whether you want to **scan websites with nmap** or **ping a server**, just type what you want β HackerAI handles the rest. All locally, without any API costs!

---
## Installation Guide
### 1. Install Ollama
Ollama is the core engine that runs the AI model **Mistral** locally.
Install Ollama from: [https://ollama.com/download](https://ollama.com/download)
For Linux:
```bash
curl -fsSL https://ollama.com/install.sh | sh
```
For Windows:
Install via: [https://ollama.com/download](https://ollama.com/download)
---
### 2. Download the Mistral Model
After installing Ollama, pull Mistral (recommended lightweight model):
```bash
ollama pull mistral
```
---
### 3. Clone or Download HackerAI
```bash
git clone https://github.com/yogsec/Hacker-AI.git
cd Hacker-AI
```
Or download `hackerai.py` manually if you want.
---
### 4. Install Python Requirements
Make sure you have Python 3.8+ and install required libraries:
```bash
pip install -r requirements.txt
```
**Create `requirements.txt`:**
```
requests
```
---
### 5. Run HackerAI
Start **Ollama** (if not already running):
```bash
ollama serve
```
Then run:
```bash
python3 hackerai.py
```
---
## Usage
Just type natural language commands like:
```
What do you want to do? (e.g., scan google.com with nmap): scan google.com with nmap
```
HackerAI will think and execute:
```bash
nmap google.com
```
### π Other Examples
| Input | Action |
|---|---|
| scan google.com with nikto | Runs `nikto -h google.com` |
| ping example.com | Runs `ping -c 4 example.com` |
| curl example.com | Runs `curl example.com` |
---
## Common Problems & Solutions
| Problem | Cause | Solution |
|---|---|---|
| `Error communicating with Ollama` | Ollama is not running | Start Ollama with `ollama serve` |
| `Model mistral not found` | Mistral not downloaded | Run `ollama pull mistral` |
| `This request doesn't translate into a valid shell command` | Non-technical request (like "who is the richest man") | Only ask for commands related to hacking or sysadmin work. |
| Syntax Error in Command | Mistral hallucinated something wrong | Rephrase the question or ask in simpler terms |
---
## Supported Commands (Examples)
Scan websites with `nmap`
Scan vulnerabilities with `nikto`
Perform `ping` tests
Fetch URLs with `curl`
Extendable to any command you want!
---
## Important Note
> HackerAI only supports **practical shell commands**. It **does not answer general knowledge questions** like "who is the richest person". Itβs focused only on commands you can run in a terminal.