etoile-pixtral-safety


Nameetoile-pixtral-safety JSON
Version 0.0.1 PyPI version JSON
download
home_pageNone
SummaryNone
upload_time2024-10-06 04:06:02
maintainerNone
docs_urlNone
authorEugene Evstafev
requires_python>=3.6
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            [![PyPI version](https://badge.fury.io/py/etoile_pixtral_safety.svg)](https://badge.fury.io/py/etoile_pixtral_safety)
[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)
[![Downloads](https://static.pepy.tech/badge/etoile_pixtral_safety)](https://pepy.tech/project/etoile_pixtral_safety)

# etoile_pixtral_safety

`etoile_pixtral_safety` is a Python package developed as part of the Mistral Étoile project during the London Hackathon. This package provides tools for detecting various types of potentially harmful content in images using advanced machine learning models, tailored specifically for online safety and content monitoring.

## Installation

To install `etoile_pixtral_safety`, use pip:

```bash
pip install etoile_pixtral_safety
```

## Usage

This package contains functions to check for harmful content and locate specific sections within images that may contain undesirable elements. It utilizes LangChain and HuggingFace technologies for deep learning inference.

### Setting Up the Model

```python
from langchain_mistralai import ChatMistralAI

CVISION_MODEL = "pixtral-12b-2409"

llm = ChatMistralAI(
    model=CVISION_MODEL,
    temperature=0,
    max_retries=2,
)
```

### Checking for Harmful Content

```python
from etoile_pixtral_safety import check_image

# `display_url` should be a string containing the URL to the image you want to check.
display_url = "https://example.com/path/to/image.jpg"
result = check_image(llm, display_url, verbose=True)
print(result)
```

### Finding Location of Harmful Content

```python
from etoile_pixtral_safety import find_location

result = find_location(llm, display_url, verbose=True)
print(result)
```

## Features

- Detects a wide range of harmful content in images including explicit material, violence, and other undesirable elements.
- Provides precise location data for identified content within images.
- Integrates seamlessly with state-of-the-art machine learning platforms.

## Contributing

Contributions, issues, and feature requests are welcome! Feel free to check the [issues page](https://github.com/chigwell/Mistral-Etoile-London-Hackathon/issues).

## License

`etoile_pixtral_safety` is licensed under the [MIT License](https://choosealicense.com/licenses/mit/).

## Acknowledgements

This package was developed by [Evgenii (Eugene) Evstafev](https://www.linkedin.com/in/eugene-evstafev-716669181/) as part of the comprehensive suite of tools for the Mistral Étoile project at the London Hackathon. More details about the project can be found on the [GitHub repository](https://github.com/chigwell/Mistral-Etoile-London-Hackathon).

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "etoile-pixtral-safety",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": null,
    "author": "Eugene Evstafev",
    "author_email": "chigwel@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/d3/1b/8f445e59aff99112d98099f5e49ccf962705f544d1cee8224a74deda1e6f/etoile_pixtral_safety-0.0.1.tar.gz",
    "platform": null,
    "description": "[![PyPI version](https://badge.fury.io/py/etoile_pixtral_safety.svg)](https://badge.fury.io/py/etoile_pixtral_safety)\n[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)\n[![Downloads](https://static.pepy.tech/badge/etoile_pixtral_safety)](https://pepy.tech/project/etoile_pixtral_safety)\n\n# etoile_pixtral_safety\n\n`etoile_pixtral_safety` is a Python package developed as part of the Mistral \u00c9toile project during the London Hackathon. This package provides tools for detecting various types of potentially harmful content in images using advanced machine learning models, tailored specifically for online safety and content monitoring.\n\n## Installation\n\nTo install `etoile_pixtral_safety`, use pip:\n\n```bash\npip install etoile_pixtral_safety\n```\n\n## Usage\n\nThis package contains functions to check for harmful content and locate specific sections within images that may contain undesirable elements. It utilizes LangChain and HuggingFace technologies for deep learning inference.\n\n### Setting Up the Model\n\n```python\nfrom langchain_mistralai import ChatMistralAI\n\nCVISION_MODEL = \"pixtral-12b-2409\"\n\nllm = ChatMistralAI(\n    model=CVISION_MODEL,\n    temperature=0,\n    max_retries=2,\n)\n```\n\n### Checking for Harmful Content\n\n```python\nfrom etoile_pixtral_safety import check_image\n\n# `display_url` should be a string containing the URL to the image you want to check.\ndisplay_url = \"https://example.com/path/to/image.jpg\"\nresult = check_image(llm, display_url, verbose=True)\nprint(result)\n```\n\n### Finding Location of Harmful Content\n\n```python\nfrom etoile_pixtral_safety import find_location\n\nresult = find_location(llm, display_url, verbose=True)\nprint(result)\n```\n\n## Features\n\n- Detects a wide range of harmful content in images including explicit material, violence, and other undesirable elements.\n- Provides precise location data for identified content within images.\n- Integrates seamlessly with state-of-the-art machine learning platforms.\n\n## Contributing\n\nContributions, issues, and feature requests are welcome! Feel free to check the [issues page](https://github.com/chigwell/Mistral-Etoile-London-Hackathon/issues).\n\n## License\n\n`etoile_pixtral_safety` is licensed under the [MIT License](https://choosealicense.com/licenses/mit/).\n\n## Acknowledgements\n\nThis package was developed by [Evgenii (Eugene) Evstafev](https://www.linkedin.com/in/eugene-evstafev-716669181/) as part of the comprehensive suite of tools for the Mistral \u00c9toile project at the London Hackathon. More details about the project can be found on the [GitHub repository](https://github.com/chigwell/Mistral-Etoile-London-Hackathon).\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": null,
    "version": "0.0.1",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "85909b7a0028d11a44b343708522edac8b3eb5983b506d0764da2af454560d7a",
                "md5": "9d6c481fdf34fee1a82fe25fa4cc02f1",
                "sha256": "d1144826886529a287a8aa52587ef7d39577b349b4a0e73c1d08e52be53d7c6b"
            },
            "downloads": -1,
            "filename": "etoile_pixtral_safety-0.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "9d6c481fdf34fee1a82fe25fa4cc02f1",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 4957,
            "upload_time": "2024-10-06T04:06:00",
            "upload_time_iso_8601": "2024-10-06T04:06:00.598530Z",
            "url": "https://files.pythonhosted.org/packages/85/90/9b7a0028d11a44b343708522edac8b3eb5983b506d0764da2af454560d7a/etoile_pixtral_safety-0.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d31b8f445e59aff99112d98099f5e49ccf962705f544d1cee8224a74deda1e6f",
                "md5": "18cc0efa7c41cf988d3c2dccbca22619",
                "sha256": "bd1d24876a567fdeb553c1253e74637c22ffe7d2f9768e67ec1613927ec47174"
            },
            "downloads": -1,
            "filename": "etoile_pixtral_safety-0.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "18cc0efa7c41cf988d3c2dccbca22619",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 4176,
            "upload_time": "2024-10-06T04:06:02",
            "upload_time_iso_8601": "2024-10-06T04:06:02.443991Z",
            "url": "https://files.pythonhosted.org/packages/d3/1b/8f445e59aff99112d98099f5e49ccf962705f544d1cee8224a74deda1e6f/etoile_pixtral_safety-0.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-06 04:06:02",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "etoile-pixtral-safety"
}
        
Elapsed time: 0.68979s