semvec/pypi-packages huggingface dataset:
extslash 0.1.8
Integrates slash commands with discord.py 2.0
Requires Python: >=3.6, <4
Keywords: discord.py,slash-commands,extslash-commands,python-discord-bot

# ExtSlash 
A module to integrate Slash Commands into your bot written in *discord.py 2.0*

### Installation:
Before working with it, you need to install the core dependency - **discord.py(2.0)**

`pip install -U git+https://github.com/Rapptz/discord.py`

Then you can install the module:

`pip install extslash`

### Create a new instance of the bot:

```python
import discord
import extslash


intents = discord.Intents.default()
intents.members = True


class MyBot(extslash.Bot):
    def __init__(self):
        super().__init__(command_prefix='-', intents=intents)

    async def on_ready(self):
        print(f'Logged in as {self.user} (ID: {self.user.id})')
        print('------')
        
bot = MyBot()
# here you can pass in both command cog and slash cog extension
bot.load_extension('your_extension_name')
bot.run('YOUR_TOKEN')
```
### Making a slash cog:
```python
import discord
import extslash

# Create a new cog class subclassing from extslash.Cog
class Echo(extslash.Cog):
    
    @extslash.Cog.command(
        command =  SlashCommand(
            name='echo',
            description='echos back a given message',
            options=[
                StrOption(name='anything', description='message to echo back')
                # you can add choices to these options too 
                ],
            # by default, command will be accessible to everyone
            # if you want to limit the command to certain roles/users, you can add them here,
            permissions=[
                SlashPermission.for_user(516649677001719819),
                SlashPermission.for_role(921001978916642856, allow=False),
            ],
        ),
        guild_id=None, # None means it will be available globally
        # add guild id to restrict the command to certain guild
    )
   # you can use ctx to get the arguments, the message, the channel, etc.
    async def command(self, ctx: extslash.ApplicationContext):
        await ctx.send_response(f'{ctx.options[0].value}')
    
    @extslash.Cog.listener
    async def on_command_error(self, ctx: extslash.ApplicationContext, error):
        # this implements the global error handler for slash commands only 
        # you can use ctx to get the arguments, the message, the channel, etc.
        # you can use error to get the error
        # you can use ctx.send_response to send a message
        pass


# this setup method is mandatory for loading the cog
def setup(bot: extslash.Bot):
    # `add_slash_cog` will add the cog to the bot
    # it takes the SlashCog class as an argument
    bot.add_slash_cog(Echo())

```
stack-alert 0.2.1
Be notified when interesting questions are posted to Stack Exchange sites.
Requires Python: ~=3.6

***********
Stack Alert
***********

Stack Alert is a program to notify you when a question matching certain filters 
is asked on a Stack Exchange site.  Stack Exchange has a feature that allows 
you to be notified when questions matching certain tags are asked, but this is 
often so broad as to be useless.  Stack Alert instead allows you to filter 
using regular expressions against the title and body of the question.

.. image:: https://img.shields.io/pypi/v/stack_alert.svg
   :target: https://pypi.python.org/pypi/stack_alert

.. image:: https://img.shields.io/pypi/pyversions/stack_alert.svg
   :target: https://pypi.python.org/pypi/stack_alert

.. image:: https://img.shields.io/readthedocs/stack_alert.svg
   :target: https://stack_alert.readthedocs.io/en/latest/?badge=latest

.. image:: https://img.shields.io/github/workflow/status/kalekundert/stack_alert/Test%20and%20release/master
   :target: https://github.com/kalekundert/stack_alert/actions

.. image:: https://img.shields.io/coveralls/kalekundert/stack_alert.svg
   :target: https://coveralls.io/github/kalekundert/stack_alert?branch=master

Getting Started
===============
Install ``stack_alert`` using ``pip``, preferably into a clean virtual environment::

    $ python -m venv ~/stack_alert_venv
    $ ~/stack_alert_venv/bin/activate
    $ pip install stack_alert

Specify which questions you want to receive alerts for::

  $ vi ~/.config/stack_alert/config.toml
  [[query]]
  site = 'stackoverflow'
  tag = 'python'
  keywords = '(num|sci)py'  # regular expression
  recipient = 'alice@example.com'
  
Configure `cron` to call ``stack_alert`` at 5:00 PM every day.  Log messages 
are written to stderr.  I recommend using `ts 
<http://joeyh.name/code/moreutils/>`__ and `tinylog 
<http://b0llix.net/perp/site.cgi?page=tinylog.8>`__ to collect and rotate these 
messages::

  $ which sendmail
  /usr/sbin/sendmail
  $ crontab -e
  PATH=$HOME/stack_alert_venv/bin:/usr/sbin:/usr/bin:/bin
  0 17 * * * stack_alert 2>&1 | ts | tinylog /path/to/log/dir
toolfeb16 0.0.17
data processing & modeling function
Requires Python: >=3.6

## Functions included in data processing:

### 1. remove outlier  
### data.remove_outlier(df, column_name, n_outlier=0.25)    
|parameter|data type|description|default value|
|:---|:---|:---|:---| 
|**df**|dataframe|which need to filter the outlier|-|  
|**column_name**|string|column which need to filter the outlier|-|
|**n_outlier**|float|range (0, 1), quantile number|0.25|
|**return**|dataframe|new dataframe|-|  
  
example:  
```
from toolfeb16 import data
new_df = main.remove_outlier(df, 'column_name', 0.25)
```  
  
### 2. Transfor period column into datetime   
### data.add_period_to_time(df, date_column_name='DATE', period_column_name='PERIOD', period_minutes=30)  
|parameter|data type|description|default value|  
|:---|:---|:---|:---|  
|**df**|dataframe|which need to transfer period columns into datetime|-|  
|**date_column_name**|string|date column|'DATE'|  
|**period_column_name**|string|period column|'PERIOD'|  
|**period_minutes**|int|time period|30|  
|**return**|dataframe|new dataframe|-|   
  
## Functions included in model: