trc 1.3
TRC (Total Resource Control) is a comprehensive Python package for enhancing Python's capabilities with utility functions. It offers robust tools for data operations (manipulation, augmentation, processing), specialized functionalities for character sets/patterns, and an innovative agent-based framework to streamline complex workflows and automate tasks, making code more concise, readable, and efficient across various development stages.
License: MIT

# 💡 TRC - Total Resource Control

## Master Your Python Projects with `trc`!

TRC (Total Resource Control) is your all-in-one Python toolkit designed to empower developers with a vast collection of practical and efficient utility functions. From streamlining routine tasks to handling complex data manipulations, `trc` helps you write cleaner, more concise, and robust code, accelerating your development workflow.

---

## 🚀 Get Started in Seconds!

Installing `trc` is a breeze. Just open your terminal and run:

```bash
pip install trc
```

---

## ✨ Why `trc`?

*   **Comprehensive Toolkit:** A single package for diverse needs – connectivity, math, file handling, string operations, advanced data processing and complex AI-Agent's
*   **Boost Productivity:** Simplify complex tasks with easy-to-use functions, letting you focus on your core logic.
*   **Clean & Efficient Code:** Write less code for more functionality, leading to better readability and maintainability.
*   **Reliable & Tested:** Robust tools built for real-world scenarios.

---

## 📚 Dive into `trc`'s Power Features

`trc` is organized into intuitive categories, ensuring you find exactly what you need, when you need it.

### 🌐 Connectivity & System Insights

Seamlessly interact with your network and gain deep insights into your system:

*   **Web Operations:** Download files and images from URLs, and check network/URL reachability.
*   **System Diagnostics:** Retrieve detailed system information including IP/MAC addresses, CPU details, RAM usage, and OS specifics. Monitor system memory usage (percentage, total GB, used GB).
*   **Clipboard Control:** Effortlessly copy and retrieve text from the system clipboard.
*   **Network Utilities:** Ping network hosts to check reachability and measure response times.

### 🔢 Mathematical Marvels

Unleash a powerful suite of mathematical functions for various computations:

*   **Prime Number Operations:** Find the Nth prime number, or quickly check if any number is prime.
*   **Sequence Generators:** Generate Fibonacci numbers and determine if a number belongs to the sequence.
*   **Number Theory Essentials:** Factorize numbers, compute Greatest Common Divisor (GCD) and Least Common Multiple (LCM), find all divisors, and identify perfect numbers.
*   **Fundamental Calculations:** Compute factorials, binomial coefficients, digit sums, and determine if a number is a power or a perfect square. Calculate mean and median of numerical data.
*   **Geometric Helper:** Calculate sides of a right-angled triangle using the Pythagorean theorem.

### 🗄️ File & Data Streamlining

Simplify your file management and data serialization tasks:

*   **JSON Handling:** Convert Python dictionaries to JSON files and vice-versa with ease.
*   **File Operations:** Copy files across your system efficiently. Retrieve detailed metadata for files and directories.
*   **Directory Structure:** Read and represent directory structures programmatically.

### ⚡ Functional Enhancements

Elevate your Python functions with powerful decorators and execution utilities:

*   **Caching:** Boost performance by intelligently caching function results.
*   **Timing:** Accurately measure function execution times.
*   **Repetition:** Run functions multiple times for stress testing or iterative processes.
*   **Retries:** Implement robust error handling with automatic function retries on failure.

### 🔡 Variable & String Wizardry

Transform and process strings and various data types effortlessly:

*   **Text Cleaning:** Remove or retain specific characters, remove accents, and truncate text.
*   **Data Aggregation:** Merge lists or dictionaries, eliminate duplicates, and flatten nested lists.
*   **Random Generation:** Create unique random strings for various purposes.
*   **Pattern Matching:** Check for partial or complete element presence within collections.
*   **Formatting & Conversion:** Format durations, reverse objects (strings, lists), and convert text to URL-friendly slugs.
*   **Text Analysis:** Count words and characters, detect various case styles, split text into individual words, and extract unique words.
*   **Case Transformation:** Seamlessly convert text between `snake_case`, `kebab-case`, `PascalCase`, `camelCase`, `CONSTANT_CASE`, and `Title Case`. Detect case styles (e.g., snake_case, camelCase).
*   **Palindrome Checks:** Verify if a string or sequence is a palindrome.
*   **Dynamic Variable Management:** Manage variables dynamically within your code (get and set).

### 🖼️ Advanced Data & Image Processing

Specialized tools for handling images and large datasets with HDF5:

*   **Image Augmentation:** Apply a wide array of transformations to images (rotation, scaling, mirroring, blurring, noise, contrast, brightness, resizing, inversion) for data enhancement or creative effects.
*   **Image Analysis:** Calculate similarity between images and blend multiple images together.
*   **HDF5 Integration:** Efficiently read and write image and label data to and from HDF5 files, ideal for machine learning classification tasks.

### 🧠 The `trc` Agent: Your Intelligent Assistant (Total Resource Control!)

At the core of `trc`'s advanced capabilities lies its integrated AI Agent, truly embodying the "Total Resource Control" philosophy. This powerful agent is designed to interact with its environment and execute complex tasks autonomously, leveraging a diverse set of operational capabilities:

* **Interactive Problem-Solving:** The agent can dynamically engage in dialogues to seek clarification or gather necessary input, ensuring tasks are precisely aligned with user intent.
* **Comprehensive Resource Management:** It possesses extensive control over digital resources, including sophisticated handling of data structures, file systems, and system-level operations for advanced automation.
* **Dynamic Knowledge Integration:** The agent can acquire and process information from vast knowledge bases, enabling it to research and integrate relevant insights into its tasks.
* **Versatile Data Handling:** Capabilities to ingest and process a wide array of data formats, from traditional files to complex multimedia and large-scale information structures, for analysis and manipulation.
* **Adaptive Intelligence:** With robust internal mechanisms for persistent memory and learning, the agent can store and retrieve information, allowing for continuous improvement and more sophisticated decision-making over time.

This intelligent agent transforms `trc` from a mere collection of utilities into a dynamic, problem-solving entity, ready to tackle challenges that require adaptive decision-making and broad operational capabilities.

---

## 🎯 Quick Usage Examples

Here's a glimpse of what you can do with `trc`:

```python
    # Not finished yet...
```

---

## 👋 Contribute & Make `trc` Even Better!

We warmly welcome contributions from our community! If you discover a bug, have an idea for an improvement, or want to add an exciting new feature, please don't hesitate to:

*   Open an [issue](https://github.com/your-repo/trc/issues) to report bugs or suggest enhancements. # No finished yet
*   Submit a [pull request](https://github.com/your-repo/trc/pulls) with your code contributions. # No finished yet

Your input is invaluable in making `trc` a truly indispensable tool for everyone!

---

## 📄 License

This project is proudly licensed under the **MIT License**. For full details, please see the `LICENSE` file in the package.