Classy-AI


NameClassy-AI JSON
Version 0.0.11 PyPI version JSON
download
home_pagehttps://github.com/Mrpi314tech/Classy
SummaryA python module that utilizes AI to classify natural language into categories for processing with other models.
upload_time2024-08-28 22:16:37
maintainerNone
docs_urlNone
authorMrpi314tech
requires_pythonNone
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Classy
## How to use
Install: 
<pre><code>pip install Classy-AI</code></pre>
Setup: **Only do this if you plan to run the model locally**
<pre><code>import Classy
Classy.download()</code></pre>
Downloads "data.pth" to your working directory. Also downloads the NLTK "punkt" tokenizer


Usage (Complete version for a server):
<pre><code>import Classy
Classy.init('/path/to/data.pth','OpenAI api key')
primary, secondary, stemmed, organized = Classy.server("hello, how are you?")</code></pre>
Usage (Just the classifier)
<pre><code>import Classy
intent, certainty = Classy.classify("hello, how are you?",'/path/to/data.pth')</code></pre>

## API

Usage
<pre><code>import Classy
intent, certainty = Classy.classify_api("hello, how are you?")</code></pre>


Go to http://chat.mrpi314.com/api to learn about how to use the api yourself.


## Other tools
GPT:<pre><code>Classy.chat_gpt(input,model,api_key)</code></pre>
DALL-E:<pre><code>Classy.dall_e(input,model,size,api_key)</code></pre>
Search:<pre><code>Classy.search(input,model,api_key)</code></pre>
Personal:<pre><code>Classy.personal(input)</code></pre>

## Example:
<pre><code>import Classy
api_key='sk-proj-api-key'
while True:
    var=input(': ')
    output,prob= Classy.classify_api(var)
    final=''
    secondary=''
    if output == 'GPT' and prob >= 0.7:
        final=Classy.chat_gpt(var,"gpt-4o-mini",api_key)
    elif output == 'Dall-e' and prob >= 0.7:
        final=Classy.dall_e(var,"dall-e-3","1024x1024",api_key)
    elif output == 'Search' and prob >= 0.7:
        final=Classy.search(var,"gpt-4o-mini",api_key)
    elif output == 'Personal' and prob >= 0.7:
        final,secondary,x,y=Classy.personal(var)
    print(final)
    if secondary:
        print(secondary)
</code></pre>

## I need more training data

Open a pull request if you have some and put it in unorganized data. I will format it. If you have organized data, put it directly in the intents.json file.

An easy way to contribute is by scrolling through your ChatGPT conversations/Google searches/DALL-E inputs and pasting some of your own data into the unformatted data file.
# Deployed here:
http://chat.mrpi314.com

Uses models gpt-4o-mini and dall-e-3.

I can add a custom password for you on the website if you add training data. Message me at 123scoring@gmail.com. Put in the description of the pull request that you want a custom password for your Openai key. 


## Thanks
Thanks to [Patrick Loeber](https://github.com/patrickloeber) for teaching me PyTorch

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/Mrpi314tech/Classy",
    "name": "Classy-AI",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": null,
    "author": "Mrpi314tech",
    "author_email": "123scoring@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/b2/fa/76f98a41332ed7828e8ec7b83ff1c22c310f417a4d4f2e4259697a5b34fa/Classy-AI-0.0.11.tar.gz",
    "platform": null,
    "description": "# Classy\n## How to use\nInstall: \n<pre><code>pip install Classy-AI</code></pre>\nSetup: **Only do this if you plan to run the model locally**\n<pre><code>import Classy\nClassy.download()</code></pre>\nDownloads \"data.pth\" to your working directory. Also downloads the NLTK \"punkt\" tokenizer\n\n\nUsage (Complete version for a server):\n<pre><code>import Classy\nClassy.init('/path/to/data.pth','OpenAI api key')\nprimary, secondary, stemmed, organized = Classy.server(\"hello, how are you?\")</code></pre>\nUsage (Just the classifier)\n<pre><code>import Classy\nintent, certainty = Classy.classify(\"hello, how are you?\",'/path/to/data.pth')</code></pre>\n\n## API\n\nUsage\n<pre><code>import Classy\nintent, certainty = Classy.classify_api(\"hello, how are you?\")</code></pre>\n\n\nGo to http://chat.mrpi314.com/api to learn about how to use the api yourself.\n\n\n## Other tools\nGPT:<pre><code>Classy.chat_gpt(input,model,api_key)</code></pre>\nDALL-E:<pre><code>Classy.dall_e(input,model,size,api_key)</code></pre>\nSearch:<pre><code>Classy.search(input,model,api_key)</code></pre>\nPersonal:<pre><code>Classy.personal(input)</code></pre>\n\n## Example:\n<pre><code>import Classy\napi_key='sk-proj-api-key'\nwhile True:\n    var=input(': ')\n    output,prob= Classy.classify_api(var)\n    final=''\n    secondary=''\n    if output == 'GPT' and prob >= 0.7:\n        final=Classy.chat_gpt(var,\"gpt-4o-mini\",api_key)\n    elif output == 'Dall-e' and prob >= 0.7:\n        final=Classy.dall_e(var,\"dall-e-3\",\"1024x1024\",api_key)\n    elif output == 'Search' and prob >= 0.7:\n        final=Classy.search(var,\"gpt-4o-mini\",api_key)\n    elif output == 'Personal' and prob >= 0.7:\n        final,secondary,x,y=Classy.personal(var)\n    print(final)\n    if secondary:\n        print(secondary)\n</code></pre>\n\n## I need more training data\n\nOpen a pull request if you have some and put it in unorganized data. I will format it. If you have organized data, put it directly in the intents.json file.\n\nAn easy way to contribute is by scrolling through your ChatGPT conversations/Google searches/DALL-E inputs and pasting some of your own data into the unformatted data file.\n# Deployed here:\nhttp://chat.mrpi314.com\n\nUses models gpt-4o-mini and dall-e-3.\n\nI can add a custom password for you on the website if you add training data. Message me at 123scoring@gmail.com. Put in the description of the pull request that you want a custom password for your Openai key. \n\n\n## Thanks\nThanks to [Patrick Loeber](https://github.com/patrickloeber) for teaching me PyTorch\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A python module that utilizes AI to classify natural language into categories for processing with other models.",
    "version": "0.0.11",
    "project_urls": {
        "Homepage": "https://github.com/Mrpi314tech/Classy"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "59d026293c4780905d975e691bf1c87a62b745d330d72e545594e51790f3668b",
                "md5": "25d793d288da09634f115900caef6caf",
                "sha256": "605865e8002f0828ced9b7dd578d448f82a720ff51a92a8e0adf9705d9600325"
            },
            "downloads": -1,
            "filename": "Classy_AI-0.0.11-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "25d793d288da09634f115900caef6caf",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 13306,
            "upload_time": "2024-08-28T22:16:36",
            "upload_time_iso_8601": "2024-08-28T22:16:36.127995Z",
            "url": "https://files.pythonhosted.org/packages/59/d0/26293c4780905d975e691bf1c87a62b745d330d72e545594e51790f3668b/Classy_AI-0.0.11-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b2fa76f98a41332ed7828e8ec7b83ff1c22c310f417a4d4f2e4259697a5b34fa",
                "md5": "3710cb0aac453ff30d0fd15b88310f1b",
                "sha256": "56321c0e7369e352637f0a8dcd32e464f6cdec200b943b37f11530c460cd414b"
            },
            "downloads": -1,
            "filename": "Classy-AI-0.0.11.tar.gz",
            "has_sig": false,
            "md5_digest": "3710cb0aac453ff30d0fd15b88310f1b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 8831,
            "upload_time": "2024-08-28T22:16:37",
            "upload_time_iso_8601": "2024-08-28T22:16:37.539485Z",
            "url": "https://files.pythonhosted.org/packages/b2/fa/76f98a41332ed7828e8ec7b83ff1c22c310f417a4d4f2e4259697a5b34fa/Classy-AI-0.0.11.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-08-28 22:16:37",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Mrpi314tech",
    "github_project": "Classy",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "classy-ai"
}
        
Elapsed time: 0.57932s