Transform your terminal into an intelligent, safety-conscious DevOps mentor powered by multi-provider AI (Gemini, OpenAI, Anthropic, and Ollama).
Smart Intent Classification - ClioraOps now understands what you really want:
> show me running containers # COMMAND: Generates docker ps -a
> what is docker? # REQUEST: Explains what Docker is
> list the benefits of microservices # AMBIGUOUS: Asks what you need- ๐ฏ Intent Classification - Distinguishes commands vs requests automatically
- ๐ฌ Better NL Understanding - Question words โ explanations, action verbs โ commands
- ๐ Smart Routing - Commands go to generator, questions go to explain
- ๐ค Production Ready - 149 tests, 100% pass rate (104 NL tests + 48 intent tests)
- Python 3.10+
- One AI Provider (choose one):
- ๐ Gemini (Free tier): Get API Key โ Recommended
- ๐ค OpenAI (Paid): Get API Key
- ๐งช Anthropic (Paid): Get API Key
- ๐ฆ Ollama (Free, local): Install Ollama
# Clone the repository
git clone https://github.com/CloudFay/clioraOps.git
cd clioraOps
# Create virtual environment (recommended)
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install in editable mode
pip install -e .
# Run interactive setup
python scripts/setup_ai.py# Test clioraops
clioraops start
# You'll see:
# ๐ ClioraOps Session Started (beginner mode)
# ๐ฌ Conversational mode: ENABLED
# Type 'exit' to quit-
๐ฌ Natural Language Commands:
- Smart intent classification: Commands vs Requests vs Ambiguous
- Ask questions naturally in plain English
- Automatic detection of dangerous patterns
- Confidence scoring for generated commands
- All commands reviewed for safety before execution
- Learn more โ
-
๐ Dual Modes:
- Beginner: Analogies, simple explanations, and safety warnings.
- Architect: Technical depth, production best practices, and trade-offs.
-
๐ก๏ธ Safety First:
- Intelligent
trycommand checks for dangerous operations (e.g.,rm -rf /,kubectl deletein prod). - Risk analysis and safe alternative suggestions.
- 15+ dangerous pattern detection
- Intelligent
-
๐ค AI-Powered:
- Explain: Deep dive into concepts or commands.
- Generate: Create Dockerfiles, K8s manifests, and CI pipelines tailored to your stack.
- Debug: Analyze error messages to find root causes and fixes.
-
๐ Visualizer:
- Generate ASCII architecture diagrams for mental models (Microservices, K8s, etc.).
-
๐ Code Review:
- Scan scripts for security risks and bad practices before running them.
Once inside the session (clioraops start), try these:
ClioraOps automatically classifies what you need:
COMMAND Intent (Generates shell commands):
๐ฑ beginner > show me running containers
๐ฏ Intent: COMMAND (90% confidence)
๐ก Generated: docker ps -a
โ
Safety: SAFE
๐ฑ beginner > find all python files in src
๐ฏ Intent: COMMAND (90% confidence)
๐ก Generated: find ./src -name '*.py' -type f
โ
Safety: SAFEREQUEST Intent (Provides explanations):
๐ฑ beginner > what is docker?
๐ฏ Intent: REQUEST (95% confidence)
๐ Docker is a containerization platform that packages applications...
๐ฑ beginner > how does kubernetes work?
๐ฏ Intent: REQUEST (95% confidence)
๐ Kubernetes orchestrates container deployment across clusters...
๐ฑ beginner > explain microservices
๐ฏ Intent: REQUEST (88% confidence)
๐ Microservices break applications into small independent services...AMBIGUOUS Intent (Asks for clarification):
๐ฑ beginner > show kubernetes concepts
๐ฏ Intent: AMBIGUOUS (60% confidence)
โ I'm not sure if you want to:
1. Generate a shell command
2. Get information/explanation
Your input: "show kubernetes concepts"
What would you like? (1/2): 2
๐ Kubernetes is an orchestration platform...| Command | Description | Example |
|---|---|---|
try <cmd> |
Check if a command is safe to run | try docker run -it ubuntu |
explain <query> |
Get a detailed explanation | explain kubernetes pods |
design <pattern> |
Visualize an architecture | design microservices |
generate <type> |
Generate boilerplate code | generate dockerfile python fastapi |
debug <error> |
Analyze an error message | debug connection refused |
review <file> |
Scan a script for issues | review deploy.sh |
learn <topic> |
Start a learning session | learn ci/cd |
switch to <mode> |
Change learning mode | switch to architect |
Choose the environment that best fits your workflow:
| Method | Best For | Setup Time | Complexity |
|---|---|---|---|
| ๐ Local CLI | Development & Learning | 5 min | Simple |
| ๐ Web Interface | Demos & Browser Access | 5 min | Simple |
| ๐ณ Docker | Production & Consistency | 5 min | Simple |
| ๐ฆ Standalone | Portable Distribution | 10 min | Moderate |
| โ๏ธ Dev Container | Cloud/Remote Dev | 3 min | Simple |
Local CLI (Development):
python3 -m venv venv && source venv/bin/activate
pip install -e .
python scripts/setup_ai.py
clioraops startWeb Interface (Browser):
pip install -e .
python clioraOps_cli/web_interface.py
# Open http://localhost:7860Docker (Production):
docker-compose up -dDev Container (Cloud):
- Open in VS Code with Dev Container extension
- Or click "Open in Codespaces" on GitHub
For detailed deployment instructions, see:
- CLI & Docker: DEPLOYMENT_GUIDE.md
- Web Interface: WEB_INTERFACE_GUIDE.md
- Docker Details: DOCKER_SETUP_GUIDE.md
| Command | Description | Example |
|---|---|---|
clioraops init |
Prepare your project and scan for secrets | clioraops init . |
clioraops start |
Enter the interactive conversational session | clioraops start |
clioraops review |
Perform a standalone safety review of a file | clioraops review script.sh |
clioraops generate |
Create Dockerfiles, K8s manifests, or workflows | clioraops generate dockerfile |
ClioraOps includes several example workflows demonstrating different features:
- basic_flow.py - Overview of all main features (5 min)
- advanced_learn_flow.py - Progressive learning through multiple topics (15 min)
- code_generation_flow.py - Design to implementation workflow (10 min)
- safety_review_flow.py - Safety-first operations approach (10 min)
- ci_cd_from_scratch.py - Complete CI/CD pipeline setup (25 min)
Run any example with:
python examples/basic_flow.pySee examples/README.md for detailed descriptions and learning paths.
Never lose progress. On every session exit, ClioraOps generates a Markdown summary in ~/.clioraops/summaries/ documenting:
- Concepts you mastered
- Diagrams designed
- Critical security findings
# Run all tests
pytest tests/ -v
# Run with coverage report
pytest tests/ --cov=clioraOps_cli --cov-report=html --cov-report=term-missing
# Run specific test file
pytest tests/test_nl_detector.py -v# Format code with black
black clioraOps_cli tests
# Lint with flake8
flake8 clioraOps_cli
# Type check with mypy
mypy clioraOps_cli --ignore-missing-imports- Total Tests: 56+ (all passing)
- NL Detector Tests: 33/33 passing
- Command Generator Tests: 23/23 passing
- Pass Rate: 100%
See docs/NL_FEATURE_TEST_SUMMARY.md for comprehensive testing details.
Contributions are welcome! Please feel free to submit a Pull Request.
For detailed contribution guidelines, see CONTRIBUTING.md.
For architecture details, see docs/architecture.md.
MIT ยฉ Faith Omobude