Metadata-Version: 2.4
Name: cliops
Version: 4.4.4
Summary: Advanced CLI tool for structured, pattern-based prompt optimization and state management
Home-page: https://github.com/cliops/cliops
Author: cliops by mabd
Author-email: iammabd@substack.com
Project-URL: Bug Reports, https://github.com/cliops/cliops/issues
Project-URL: Source, https://github.com/cliops/cliops
Project-URL: Documentation, https://cliops.readthedocs.io
Keywords: cli prompt optimization ai llm prompt-engineering patterns state-management
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: System Administrators
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Software Development :: Build Tools
Classifier: Topic :: System :: Systems Administration
Classifier: Topic :: Utilities
Classifier: Topic :: Text Processing :: Linguistic
Classifier: Environment :: Console
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: rich>=13.0.0
Requires-Dist: argparse>=1.4.0
Requires-Dist: pytest>=7.0.0
Requires-Dist: pytest-cov>=4.0.0
Requires-Dist: pytest-mock>=3.10.0
Requires-Dist: pyyaml>=6.0.0
Requires-Dist: psutil>=5.9.0
Provides-Extra: dev
Requires-Dist: pytest>=7.0.0; extra == "dev"
Requires-Dist: pytest-cov>=4.0.0; extra == "dev"
Requires-Dist: black>=22.0.0; extra == "dev"
Requires-Dist: flake8>=5.0.0; extra == "dev"
Provides-Extra: test
Requires-Dist: pytest>=7.0.0; extra == "test"
Requires-Dist: pytest-cov>=4.0.0; extra == "test"
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: keywords
Dynamic: license-file
Dynamic: project-url
Dynamic: provides-extra
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# cliops - Command Line Interface for Prompt Optimization

A powerful CLI tool for structured, pattern-based prompt optimization and state management.

[![GitHub](https://img.shields.io/badge/GitHub-thatmabd-blue)](https://github.com/thatmabd)
[![Documentation](https://img.shields.io/badge/Docs-cliops.fun-green)](https://cliops.fun/docs)
[![Community](https://img.shields.io/badge/Join-cliops.fun-orange)](https://cliops.fun/join)

## Features

- **Pattern-based optimization**: Apply proven prompt engineering patterns
- **State management**: Persistent CLI state for project context
- **Rich terminal UI**: Beautiful output with syntax highlighting
- **Extensible**: Add custom patterns and plugins
- **Cross-platform**: Works on Windows, macOS, and Linux
- **Performance optimized**: Advanced caching and memory management
- **Plugin system**: Extend functionality with custom plugins

## Quick Start

```bash
# Install
pip install .

# Initialize
cliops init

# Optimize a prompt
cliops "Create a user authentication endpoint"

# Analyze a prompt
cliops analyze "Make this code better"

# List patterns
cliops patterns
```

## Installation

```bash
pip install .
```

The installer will attempt to add the necessary directory to your system's PATH. Please restart your terminal after installation.

## Usage

### Basic Commands

```bash
# Direct prompt optimization
cliops "Fix this bug in my React component"

# With specific pattern
cliops optimize "Refactor this function" --pattern precision_engineering

# Analyze prompt for improvements
cliops analyze "Create API endpoint"

# List available patterns
cliops patterns

# Manage state
cliops state set ARCHITECTURE "React + Node.js"
cliops state show

# Plugin management
cliops plugin list
cliops plugin create my_plugin
```

### Advanced Features

```bash
# Context-aware optimization
cliops "Create dashboard" --context "React + TypeScript"

# Dry run to preview
cliops "Test prompt" --dry-run

# Override specific fields
cliops "API task" --constraints "RESTful design" --output-format "JSON"
```

## Configuration

cliops uses YAML-based configuration with environment support:

```yaml
# ~/.cliops/config.yaml
environment: production
logging:
  level: INFO
optimization:
  cache_enabled: true
  default_pattern: adaptive_generation
performance:
  memory_limit_mb: 512
```

## Plugin Development

Create custom plugins to extend cliops:

```bash
# Create plugin template
cliops plugin create my_plugin

# Edit the generated template
# ~/.cliops/plugins/my_plugin.py

# Enable plugin
cliops plugin enable my_plugin
```

## Documentation

- **Full Documentation**: [cliops.fun/docs](https://cliops.fun/docs)
- **API Reference**: Comprehensive module documentation
- **Plugin Development Guide**: Create custom extensions
- **Configuration Reference**: All settings explained

## Community

- **Join Community**: [cliops.fun/join](https://cliops.fun/join)
- **GitHub**: [github.com/thatmabd](https://github.com/thatmabd)
- **Issues & Support**: GitHub Issues
- **Contributions**: Pull requests welcome

## Testing

```bash
python run_tests.py
```

## License

MIT License

## Architecture

cliops is built with:
- **Intelligence System**: Domain detection and pattern suggestion
- **Context Optimizer**: Project-aware prompt enhancement
- **Performance Monitor**: Memory and execution optimization
- **Plugin Framework**: Extensible architecture
- **Configuration Manager**: Environment-based settings

For detailed architecture documentation, visit [cliops.fun/docs](https://cliops.fun/docs).
