Metadata-Version: 2.4
Name: iitjp
Version: 0.2.12
Summary: A CLI tutor library for Statistics with audio-visual interactions
Home-page: https://github.com/yutkarsh.brainstorm/ourusername/IITJP
Author: Utkarsh Yadav
Author-email: Utkarsh Yadav <utkarsh.brainstorm@gmail.com>
License: Custom
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Education
Classifier: License :: Other/Proprietary License
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Classifier: Topic :: Education
Classifier: Topic :: Software Development :: Libraries
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pydub>=0.25.1
Requires-Dist: setuptools>=44.0.0
Requires-Dist: pyaudioop; python_version >= "3.13"
Provides-Extra: windows
Provides-Extra: macos
Requires-Dist: pyobjc-framework-Cocoa; extra == "macos"
Provides-Extra: linux
Requires-Dist: python-dbus; extra == "linux"
Dynamic: author
Dynamic: home-page
Dynamic: license-file
Dynamic: requires-python

# IITJP Python Library

A Python library for an interactive quiz assistant named RajLaxmi, featuring audio-visual interactions for learning Statistics.

## Installation

### Quick Install from PyPI

```bash
# Install from PyPI (when available)
pip install iitjp

# Or install directly from GitHub
pip install git+https://github.com/yutkarsh.brainstorm/ourusername/IITJP.git
```

### Install from Source

```bash
# Clone the repository
git clone https://github.com/yutkarsh.brainstorm/ourusername/IITJP.git
cd IITJP

# Install in development mode
pip install -e .
```

## Requirements

- Python 3.7+
- pydub (automatically installed, used for audio format conversion)
- Platform-specific dependencies (automatically installed):
  - **Windows**: Uses native winsound library (no additional dependencies)
  - **macOS**: pyobjc-framework-Cocoa
  - **Linux**: python-dbus

## Usage

### Python API

```python
import iitjp

# Basic usage with audio
from iitjp import mam

# Greet the user
mam.greetings()

# Start a quiz
mam.quiz()

# End the quiz with a farewell
mam.thanks()
```

### Command Line Interface

The library also provides a command-line interface:

```bash
# Show welcome message
iitjp greetings

# Start an interactive quiz
iitjp quiz

# Display thank you message
iitjp thanks

# Show version information
iitjp version

# Enable silent mode (no audio)
iitjp --silent quiz
```

### Silent Mode

If you experience audio playback issues, you can enable silent mode:

```python
import iitjp

# Enable silent mode to avoid audio playback
iitjp.enable_silent_mode(True)

# Now use the library as normal
iitjp.mam.greetings()  # This will not play audio
```

## Cross-Platform Support

The library is designed to work across Windows, macOS, and Linux with appropriate audio playback methods for each platform:

- **Windows**: Uses native winsound library for reliable audio playback
- **macOS**: Uses afplay and native macOS audio capabilities 
- **Linux**: Tries multiple common audio players (aplay, paplay, ffplay)

## Troubleshooting

If you encounter issues with audio playback:

1. **Check audio system**: Make sure your system's audio is working properly
2. **Check dependencies**: Ensure platform-specific dependencies are installed
3. **Enable silent mode**: If audio issues persist, use silent mode

```python
import iitjp
iitjp.enable_silent_mode(True)
```

4. **Update the library**: Make sure you're using the latest version

```bash
pip install --upgrade iitjp
```

## Project Structure

- `iitjp/`: Main package directory
  - `__init__.py`: Package initialization with exposed functions
  - `rajlaxmi.py`: Core functionality for the virtual teacher
  - `__main__.py`: Command-line interface
- `data/`: Contains audio files and quiz questions
  - `greeting.mp3`: Welcome message
  - `start_quiz.mp3`: Quiz introduction
  - `end_quiz.mp3`: Quiz conclusion
  - `farewell.mp3`: Goodbye message
  - `questions.json`: Quiz questions and answers
- `temp/`: Temporary directory for audio processing

## Development

```bash
# Clone the repository
git clone https://your-repo-url.git
cd iitjp

# Create temp directory if it doesn't exist
mkdir -p temp

# Install in development mode
pip install -e .

# Run the demo
python simple_demo.py
```
