semvec/pypi-packages huggingface dataset:
immich-lib 0.2.1
A Python library and CLI tool for interacting with Immich
License: MIT
Requires Python: >=3.7
Keywords: immich, api, cli, photos

[![Coverage Status](coverage.svg)](coverage.svg)

# Immich Lib

A Python library and CLI tool for interacting with an Immich server.

## Installation

```bash
pip install .
```

## CLI Usage

After installation, you can use the `immich-tool` command:

```bash
immich-tool list-albums
immich-tool download-album "My Album"
```

You can also pass the URL and API key as arguments:

```bash
immich-tool --url http://immich.local:2283 --key YOUR_API_KEY list-albums
```

Or set them in your environment or a `.env` file:

```env
IMMICH_SERVER_URL=http://immich.local:2283
IMMICH_API_KEY=YOUR_API_KEY
```

## Library Usage

```python
from immich_lib import ImmichClient

client = ImmichClient("http://immich.local:2283", "YOUR_API_KEY")
albums = client.list_albums()
for album in albums:
    print(album['albumName'])
```
ChangeDotOrgScraper 0.1.0
Scrapes online petition data from change.org
License: MIT
Requires Python: >=3.8
Keywords: change.org, petitions, web scraping, selenium, beautifulsoup

`ChangeDotOrgScraper` is an Python package that allows you to scrape online petition data from [change.org](https://www.change.org/).

[![pypi package](https://img.shields.io/badge/pypi_package-v0.1.0-brightgreen)](https://pypi.org/project/ChangeDotOrgScraper/) [![GitHub Source Code](https://img.shields.io/badge/github_source_code-source_code?logo=github&color=green)](https://github.com/cja5553/change_org_scraper) 



## Installation
To install in python, simply do the following: 
```bash
pip install ChangeDotOrgScraper
```

## Quick Start
Here we provide a quick example on how you can use `ChangeDotOrgScraper` to scrape petition data right from [change.org](https://www.change.org/). 

```python
from ChangeDotOrgScraper import scrape_petitions

# Specify the url of your scrape.org searches
## for instance, we shall scrape petitions from the search "supplemental nutrition assistance program"
url='https://www.change.org/search?q=Supplemental%20Nutrition%20Assistance%20Program&offset=0'

# scrape the petition data from change.org
SNAP_petitions_df=scrape_petitions(url)
print(SNAP_petitions_df)
```
It returns a dataframe with all the petitions data, which contains details such as the petition(s) title, description, date created, target audience signature count, location created, victory status, etc. 



## Requirements
### Required packages
To use `ChangeDotOrgScraper`, you are required to have the following packages installed:  
- `requests`
- `beautifulsoup4`    
- `tqdm`
- `lxml`  
- `selenium`  
- `webdriver-manager`      
- `pandas`  
- `ast` (Python standard library)   
- `re` (Python standard library)   
- `json`  (Python standard library)  
- `time` (Python standard library)  


If you do not have these packages installed in python, you can do the following:
```bash
pip install requests beautifulsoup4 lxml tqdm pandas selenium webdriver-manager
```


## Citation
This package was made as part of a larger study on policy-related opinion mining.  

If you wish to cite, you may cite:

Alba, C., Warner, B. C., Saxena, A., Huang, J., & An, R. (2025, July). Towards robust sentiment analysis of temporally-sensitive policy-related online text. In Proceedings of the 63rd Annual Meeting of the Association for Computational Linguistics (Volume 4: Student Research Workshop) (pp. 958-976). doi: 10.18653/v1/2025.acl-srw.70   

## Questions?
Contact me at [alba@wustl.edu](mailto:alba@wustl.edu)
webhook-mannager 1.0.1
Expose local ports with custom DNS for webhook testing - TUI interface
License: MIT
Requires Python: >=3.8
Keywords: webhook, tunnel, ngrok, localhost, development, testing, port-forwarding, dns, tui

# Webhook Tunnel
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

A professional Python CLI to expose local ports with a custom hostname, ideal for testing webhooks and callbacks during development. Includes an interactive TUI (Text User Interface).

This version can also expose your local endpoint to the public internet (no account required) using **localtunnel** via **npm/npx**.

![Webhook Tunnel Demo](https://via.placeholder.com/800x400?text=Webhook+Tunnel+TUI)

## ✨ Key Features

- 🚀 **Fast local port exposure**
- 🌐 **Custom hostname** with subdomains
- 🌍 **Public internet URL** via npm/npx (**localtunnel**) for webhook testing
- 💻 **Interactive TUI**
- 📊 **Real-time monitoring** (CPU, memory, uptime)
- 🔍 **Built-in log viewer**
- 🎯 **Multiple tunnels** simultaneously
- 💾 **Automatic persistence** (config + tunnel registry)
- 🧹 **Dead process cleanup**

## 📦 Installation

### From PyPI (recommended)

```bash
pip install webhook-mannager
```

### With extras

```bash
# Full installation with an example webhook server
pip install webhook-mannager[webhook-server]

# Development extras
pip install webhook-mannager[dev]
```

## 🚀 Quick Start

### 1) Start your local service

Make sure your application is running locally, e.g.:

```bash
uvicorn app:app --port 8000
```

### 2) Create a tunnel

```bash
tunnel start teste 8000
```

You will get:
- **Hostname URL** (e.g. `http://teste.localhost:8001`) — requires DNS resolution of `teste.localhost`
- **Local URL** (always works) (e.g. `http://127.0.0.1:8001`) — works without any OS DNS changes

If your hostname does not resolve, use the printed `curl --resolve ...` example.

### 3) Expose publicly (for real webhook callbacks)

```bash
tunnel start teste 8000 --public
```

This will:
- keep the local gateway running (port forward)
- start **localtunnel** via **npx**
- print an **External URL** that can be called by third-party webhook providers

If `npx` is not available, the tool can automatically download a portable Node.js LTS runtime into:

```
~/.webhook-mannager/tools/node
```

## 🖥️ TUI (Interactive Interface)

```bash
tunnel-tui
```

Common keys:
- `c` create a tunnel
- `d` delete a tunnel
- `r` restart a tunnel
- `l` open logs
- `p` toggle public exposure (localtunnel)
- `q` quit

## 🧪 Testing your endpoint

If your local app has `GET /readyz`, you can test via:

- Local gateway:

```bash
curl -v http://127.0.0.1:8001/readyz
```

- Hostname without OS DNS changes:

```bash
curl -v http://127.0.0.1:8001/readyz -H "Host: teste.localhost"
```

- External URL (requires `--public`):

```bash
curl -v <external_url>/readyz
```

## 📚 Documentation

## 📄 License

MIT
trading-models 0.3.7
MLP, CNN, Transformer models for time-series trading predictions.
License: MIT
Requires Python: >=3.8
Keywords: trading models, neural networks, time-series, MLP, CNN, Transformer


## Intro

- Neural Network models for trading: MLP, CNN, Transformer
- Below shows the training process of my private model

![](https://raw.githubusercontent.com/SerenaTradingResearch/trading-models/main/test/train_model.gif)

## Usage

```bash
pip install trading-models
```

```py
import torch as tc
from torch.utils.data import DataLoader

from trading_models.simple_models import CNN, MLP, Transformer
from trading_models.utils import WindowDataset, model_size

"""
trading models

input: x.shape = (T, F)
output: a.shape = (T-W+1, A)

T: time
F: features
W: window length
A: actions

at each time step t in range(W-1, T),
the model looks at data in the window
x[t+1-W : t+1, :]
to make A actions
"""

T, F, W, A = 100, 2, 50, 1
device = tc.device("cuda" if tc.cuda.is_available() else "cpu")
x = tc.randn(T, F).to(device)

dataset = WindowDataset(x, W)
dataloader = DataLoader(dataset, batch_size=32, shuffle=False)

net1 = MLP([W * F, 64, 64, A]).to(device)
net2 = CNN([F, 64, 64, A]).to(device)
net3 = Transformer(W, F, A, d_model=64, d_ff=64, n_head=2, n_layer=2).to(device)

for net in [net1, net2, net3]:
    outputs = []
    for batch in dataloader:
        outputs.append(net(batch.to(device)).detach())
    output = tc.cat(outputs, dim=0)
    print(net, output.shape, model_size(net), "\n")

```

- Output

```bash
MLP(
  (mlp): Sequential(
    (0): Linear(in_features=100, out_features=64, bias=True)
    (1): SiLU()
    (2): Linear(in_features=64, out_features=64, bias=True)
    (3): SiLU()
    (4): Linear(in_features=64, out_features=1, bias=True)
  )
) torch.Size([51, 1]) trainable: 10689/10689 

CNN(
  (cnn): Sequential(
    (0): Conv1d(2, 64, kernel_size=(3,), stride=(1,), padding=(1,))
    (1): SiLU()
    (2): Conv1d(64, 64, kernel_size=(3,), stride=(1,), padding=(1,))
    (3): SiLU()
    (4): AdaptiveAvgPool1d(output_size=1)
  )
  (fc): Linear(in_features=64, out_features=1, bias=True)
) torch.Size([51, 1]) trainable: 12865/12865 

Transformer(
  (proj): Linear(in_features=2, out_features=64, bias=True)
  (trans): TransformerEncoder(
    (layers): ModuleList(
      (0-1): 2 x TransformerEncoderLayer(
        (self_attn): MultiheadAttention(
          (out_proj): NonDynamicallyQuantizableLinear(in_features=64, out_features=64, bias=True)
        )
        (linear1): Linear(in_features=64, out_features=64, bias=True)
        (dropout): Dropout(p=0.1, inplace=False)
        (linear2): Linear(in_features=64, out_features=64, bias=True)
        (norm1): LayerNorm((64,), eps=1e-05, elementwise_affine=True)
        (norm2): LayerNorm((64,), eps=1e-05, elementwise_affine=True)
        (dropout1): Dropout(p=0.1, inplace=False)
        (dropout2): Dropout(p=0.1, inplace=False)
      )
    )
  )
  (fc): Linear(in_features=64, out_features=1, bias=True)
) torch.Size([51, 1]) trainable: 50689/50689 
```