FastAPI backend powering NeoShell AI with Groq LLM integration for intelligent command generation.
This backend handles:
- AI prompt processing
- command generation
- API routing
- frontend communication
- Groq API integration
- AI-powered shell command generation
- FastAPI REST API
- Groq LLM integration
- Prompt engineering for safe command generation
- CORS-enabled frontend communication
- Lightweight and fast backend architecture
- Python
- FastAPI
- Groq API
- Uvicorn
- Groq API
- Meta Llama 3.1 8B Instant
neoShell_backend/
│
├── .env
├── .gitignore
├── LICENSE
├── README.md
├── requirements.txt
│
├── GenAI.py
├── server.py
└── utils.pyPOST /generate{
"input": "Show current logged in user"
}{
"message": "success",
"data": "whoami"
}Clone the repository:
git clone https://github.com/tichita7/neoshell-ai-backend.gitMove into the project directory:
cd neoshell-ai-backendCreate virtual environment:
python -m venv .venvActivate virtual environment:
.venv\\Scripts\\activateInstall dependencies:
pip install -r requirements.txtCreate .env file inside backend root:
GROQ_API_KEY=your_api_keyuvicorn server:app --port 8001Backend runs on:
http://127.0.0.1:8001Connected with NeoShell AI frontend built using:
- React
- Tailwind CSS
- Vite
Frontend communicates using REST API requests.
Show network configurationipconfig- Non-destructive command prompting
- Restricted AI behavior using prompt engineering
- Invalid request handling
- Controlled output generation
Tichita Dhiman
This project is licensed under the MIT License.