semvec/pypi-packages huggingface dataset:
django-related-field-display 0.1.3
A Django admin mixin for displaying related fields with clickable links.
Requires Python: >=3.9

# django-related-field-display

A simple Django admin mixin to easily display and link related model fields using `__` syntax.

This package allows you to use the double underscore (`__`) syntax in `list_display` and `list_filter` attributes of Django admin classes to display related model fields without needing to write custom methods or properties.

This project is inspired from [django-admin-related](https://github.com/PetrDlouhy/django-related-admin) package, but it is deprecated and not maintained anymore.

## Installation

```bash
pip install django-related-field-display
```

## Usage
```python
from django.contrib import admin
from related_field_display.admin import RelatedFieldDisplayMixin
from .models import YourModel

@admin.register(YourModel)
class YourModelAdmin(RelatedFieldDisplayMixin, admin.ModelAdmin):
    list_display = ('id', 'related_field__name', 'another_field')
    list_filter = ('related_field__category',)
    ordering = ('-id',)
```

## PyPI
[![PyPI version](https://badge.fury.io/py/django-related-field-display.svg)](https://pypi.org/project/django-related-field-display/)
twr-draft 0.2.0
一个功能完整的草稿管理MCP服务器，支持创建、读取、更新、删除和搜索草稿。专为单次对话设计，使用内存存储。
Requires Python: >=3.12
Keywords: draft, mcp, notes, text-editor

# TWR Draft MCP Server

一个功能完整的草稿管理MCP服务器，支持创建、读取、更新、删除和搜索草稿。**专为单次对话设计，使用内存存储，无需文件系统。**

## 功能特性

- ✅ 创建新草稿
- ✅ 读取草稿内容
- ✅ 更新草稿内容
- ✅ 删除草稿
- ✅ 列出所有草稿
- ✅ 搜索草稿（按名称、内容、分类和标签）
- ✅ 获取草稿详细信息（字符数、单词数、行数等）
- ✅ 草稿分类管理
- ✅ 标签系统
- ✅ 按分类和标签筛选草稿
- ✅ 创建和更新时间记录
- ✅ 内存存储（无需文件系统）
- ✅ 错误处理和用户友好的错误信息
- ✅ 内存管理功能（清空、计数）
- ✅ 专为单次对话优化

## 安装

### 使用 uv（推荐）

```bash
# 克隆仓库
git clone https://github.com/yourusername/twr-draft.git
cd twr-draft

# 安装依赖
uv sync

# 安装到系统
uv pip install -e .
```

### 使用 pip

```bash
pip install -e .
```

## 使用方法

### 作为MCP服务器

在您的MCP客户端配置中添加：

```json
{
  "mcpServers": {
    "twr-draft": {
      "command": "twr-draft-server",
      "args": []
    }
  }
}
```

### 可用的工具

#### 1. new_draft
创建新草稿

**参数：**
- `draft_name` (str): 草稿名称
- `draft_content` (str): 草稿内容
- `category` (str, 可选): 草稿分类，默认为"未分类"
- `tags` (str, 可选): 标签，用逗号分隔

**示例：**
```python
new_draft("我的想法", "这是一个关于项目的新想法...", "项目", "想法,计划")
```

#### 2. get_draft
获取草稿内容

**参数：**
- `draft_name` (str): 草稿名称

**示例：**
```python
get_draft("我的想法")
```

#### 3. update_draft
更新草稿内容

**参数：**
- `draft_name` (str): 草稿名称
- `draft_content` (str): 新的草稿内容
- `category` (str, 可选): 新的分类
- `tags` (str, 可选): 新的标签，用逗号分隔

**示例：**
```python
update_draft("我的想法", "更新后的想法内容...", "重要项目", "想法,计划,重要")
```

#### 4. delete_draft
删除草稿

**参数：**
- `draft_name` (str): 草稿名称

**示例：**
```python
delete_draft("我的想法")
```

#### 5. list_drafts
列出所有草稿

**示例：**
```python
list_drafts()
```

#### 6. search_drafts
搜索草稿

**参数：**
- `keyword` (str): 搜索关键词

**示例：**
```python
search_drafts("项目")
```

#### 7. get_draft_info
获取草稿详细信息

**参数：**
- `draft_name` (str): 草稿名称

**示例：**
```python
get_draft_info("我的想法")
```

#### 8. list_categories
列出所有分类

**示例：**
```python
list_categories()
```

#### 9. list_tags
列出所有标签

**示例：**
```python
list_tags()
```

#### 10. get_drafts_by_category
按分类获取草稿

**参数：**
- `category` (str): 分类名称

**示例：**
```python
get_drafts_by_category("项目")
```

#### 11. get_drafts_by_tag
按标签获取草稿

**参数：**
- `tag` (str): 标签名称

**示例：**
```python
get_drafts_by_tag("想法")
```

#### 12. clear_all_drafts
清空所有草稿

**示例：**
```python
clear_all_drafts()
```

#### 13. get_draft_count
获取草稿总数

**示例：**
```python
get_draft_count()
```

## 数据存储

草稿数据存储在内存中，无需文件系统：

- **存储方式**: 内存存储
- **生命周期**: 单次对话期间
- **优势**: 快速访问，无需文件I/O
- **特点**: 对话结束后自动清理

**注意**: 由于使用内存存储，草稿数据在对话结束后不会持久保存。这确保了数据的临时性和隐私性。

## 开发

### 运行测试

```bash
# 直接运行服务器
python -m draft_server.draft
```

### 项目结构

```
twr-draft/
├── pyproject.toml          # 项目配置
├── README.md              # 项目说明
├── src/
│   └── draft_server/
│       ├── __init__.py    # 包初始化
│       └── draft.py       # 主要实现
└── uv.lock                # 依赖锁定文件
```

## 许可证

MIT License

## 贡献

欢迎提交Issue和Pull Request！

## 更新日志

### v0.2.0
- 改为内存存储，专为单次对话优化
- 添加内存管理功能（清空、计数）
- 移除文件系统依赖

### v0.1.0
- 初始版本
- 基本的草稿CRUD操作
- 搜索和列表功能
- 文件系统存储
spotify-youtube-migrator 2.0.0
A Python package to migrate playlists between Spotify and YouTube Music.
Requires Python: >=3.6

```markdown
# Spotify-YouTube Playlist Migrator 🎵

A Python package to migrate playlists between Spotify and YouTube Music.

---

## Features ✨
- Migrate Spotify playlists to YouTube Music.
- Migrate YouTube Music playlists to Spotify.
- Migrate Spotify Liked Songs to YouTube Music.
- Set credentials interactively.
- Detailed logging and migration statistics.

---

## Installation 🛠️

1. Install the package via pip:
   ```bash
   pip install spotify-youtube-migrator
   ```

2. Set up your credentials:
   ```bash
   migrate-playlist set-creds --spotify
   migrate-playlist set-creds --youtube
   ```

---

## Usage 🚀

### Migrate Spotify Playlist to YouTube Music
```bash
migrate-playlist migrate --source spotify --destination youtube --playlist <playlist_url_or_liked_songs> --name "My Playlist"
```

### Migrate YouTube Music Playlist to Spotify
```bash
migrate-playlist migrate --source youtube --destination spotify --playlist <playlist_url> --name "My Playlist"
```

### Enable Logging and Statistics
```bash
migrate-playlist migrate --source spotify --destination youtube --playlist liked_songs --log --stats
```

---

## Commands 📜

| Command                          | Description                                                                 |
|----------------------------------|-----------------------------------------------------------------------------|
| `set-creds --spotify`            | Set Spotify credentials interactively.                                      |
| `set-creds --youtube`            | Set up YouTube Music authentication.                                        |
| `migrate --source <source>`      | Migrate playlists between platforms.                                        |
| `--destination <destination>`    | Specify the destination platform.                                           |
| `--playlist <url_or_liked_songs>`| Provide the playlist URL or use `liked_songs` for Spotify Liked Songs.      |
| `--name <playlist_name>`         | Specify a custom name for the new playlist.                                 |
| `--log`                          | Enable detailed logging.                                                    |
| `--stats`                        | Display migration statistics.                                               |

---

## Contributing 🤝

Contributions are welcome! Please follow these steps:
1. Fork the repository.
2. Create a new branch (`git checkout -b feature/YourFeature`).
3. Commit your changes (`git commit -m 'Add some feature'`).
4. Push to the branch (`git push origin feature/YourFeature`).
5. Open a pull request.

---

## License 📄

This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

---

## Support 💬

If you encounter any issues or have questions, please open an issue on [GitHub](https://github.com/manojk0303/spotify-youtube-migrator/issues).
```
InoCloudreve 0.1.3
Cloudreve api client
Requires Python: >=3.9

# Cloudreve Python Client

An **async** Python client for the [Cloudreve API](https://github.com/cloudreve/).  
Supports authentication, file operations, token management, and utilities—built on [httpx](https://www.python-httpx.org/) and [aiofiles](https://github.com/Tinche/aiofiles).

---

## Important Note
> **Active Development**  
> This client library is under active development and is not yet feature-complete. It was built to satisfy specific use-cases and may change without warning.
>
> **Not Production-Ready**  
> Use at your own risk. Do **not** deploy this in production environments unless you fully understand its internals and have thoroughly tested it for your needs.
>
> Contributions, feedback, and issue reports are welcome—but please be cautious if you plan to rely on this library for critical workloads.
---
## Features

- **Health check** (`ping()`)

- **Authentication**
  - `password_sign_in(email, password, captcha=None, ticket=None)`
  - `refresh_token(refresh_token)`
  - `is_token_valid()`
  - `validate_token()`

- **File operations**
  - `list_files(uri, page=0, page_size=50, order_by="created_at", order_direction="asc", next_page_token=None)`
  - `get_file_info(file_uri, file_id, extended=False, folder_summary=False)`
  - `create_download_url(uris, download=False, redirect=False, entity=None, use_primary_site_url=False, skip_error=False, archive=False, no_cache=False)`
  - `get_download_url(uris, download=False, redirect=False, entity=None, use_primary_site_url=False, skip_error=False, archive=False, no_cache=False)`
  - `update_file_content(file_uri, content, previous=None)`
  - `create_upload_session(uri, filename, size, chunk_size, expire_in, ...)`
  - `delete_upload_session(id, uri)`
  - `delete_file(uris, unlink=False, skip_soft_delete=False)`
  - `force_unlock(tokens)`
  - `get_last_folder_or_file(uri)`

- **Download & save**
  - `save_url_as_file(url, save_dir, filename, extension, overwrite=True)`

- **Utilities**
  - `read_file_as_bytes(path)`
  - `get_headers(include_auth=True, include_content_type=True)`


---

## Installation

```bash
# Install from PyPI
pip install InoCloudreve

# install locally:
git clone https://github.com/nobandegani/InoCloudreve.git
cd InoCloudreve
pip install -e .
```
---

## License
Mozilla Public License Version 2.0
phylofunc 2.0
Generate phylofunc to incorporate microbiome phylogeny to inform on metaproteomic functional distance.

# phylofunc

'phylofunc' is a Python package for generating phylofunc to incorporate microbiome phylogeny to inform on metaproteomic functional distance. 
It enables efficient calculation of functional beta-diversity distances between sample pairs and generates comprehensive distance metrics across multiple samples.

## Installation of package

You can install this package via pip:  
pip install phylofunc

## Usage
Once installed, you can use the phylofunc package in a Python script or an interactive environment.

### Quick Start

#### Import package

from phylofunc import PhyloFunc_distance  
from phylofunc import PhyloFunc_matrix

#### Script
Two input parameters are required. The first is a phylogenetic tree (default: bac120_iqtree_v2.0.1.nwk). The second is a phylogeny-informed Taxon-Function table, which includes columns labeled Taxon, Function, and the names of samples (default: Taxon_Function_distance.csvor Taxon_Function_matrix.csv).

#### 1. Calculate phylofunc distance between sample pairs
PhyloFunc_distance(tree_file='bac120_iqtree_v2.0.1.nwk', sample_file='Taxon_Function_distance.csv')

#### 2. Calculate phylofunc distance matrix across multiple samples
PhyloFunc_matrix(tree_file='bac120_iqtree_v2.0.1.nwk', sample_file='Taxon_Function_matrix.csv')

### Output
phylofunc distance or phylofunc distance matrix can be output.

## Performance optimization
This package improves performance by reducing disk I/O operations and processing data in memory. This enables faster computations with large datasets.

## Project structure
```
phylofunc/  
├── __init__.py  
├── phylofunc.py  
│  └── The main function code.  
├── data/  
│  ├── Taxon_Function_distance.csv
│  │  └── Data file for calculating the distance between two samples. 
│  ├── Taxon_Function_matrix.csv
│  │  └── Data file for calculating distances matrix across multiple samples.  
│  └── bac120_iqtree_v2.0.1.nwk  
│     └── Phylogenetic tree file.  
└── Phylofunc_Package_Tutorial.ipynb
   └── Demonstrates the specific application of this package.
```

## Contribution
Welcome code contributions and improvement suggestions! Feel free to submit an issue or a pull request on GitHub.

## License
This project uses an MIT license. For details, see the LICENSE file.

## Application
For more detailed usage instructions, please refer to the paper：
Wang and Li et al., PhyloFunc: Phylogeny-informed Functional Distance as a New Ecological Metric for Metaproteomic Data Analysis
doi: https://doi.org/10.1101/2024.05.28.596184
magnum-capi-helm 1.3.0
OpenStack Magnum driver using helm to create k8s clusters with Cluster API.
Requires Python: >=3.6

===============================
magnum-capi-helm
===============================

OpenStack Magnum driver using Helm to create k8s clusters
with Cluster API.

The driver uses `capi-helm-charts <https://github.com/azimuth-cloud/capi-helm-charts>`_
to create the k8s resources needed to provision a k8s cluster using
Cluster API, including various useful add-ons like a CNI and a monitoring
stack.


Note, the above Helm charts are intended to be
a way to share a reference method to create K8s
on OpenStack. The charts are not expected or
intended to be specific to Magnum. The hope is
they can also be used by ArgoCD, Flux or Azimuth
to create k8s clusters on OpenStack.

Work on this driver started upstream around October 2021.
After failing to get merged during Bobcat,
we created this downstream repo as a stop-gap to help
those wanting to use this driver now.
https://specs.openstack.org/openstack/magnum-specs/specs/bobcat/clusterapi-driver.html
burplabs 0.3.3
PortSwigger Lab Automation Tool
Requires Python: >=3.7

# Burplabs

**burplabs** is a modular, Python-based CLI tool that automates solving labs from [PortSwigger Web Security Academy](https://portswigger.net/web-security).  
Its like like `netexec`, but made for web apps.

Basically, this is a python package named 'burplabs' which is an PortSwigger's Web Security Academy labs soluction in the form of python script. Each script includes the lab's name, proxy settings, and step-by-step solution, as well as any additional notes. 

---

It currently has **148/230** labs (excluding expert labs) and I am adding rest of the labs daily.

This not something new but this helped me to get better with Python Scripting and I adjusted many other things. I recommend to try this when you know how lab is solved and just want to solve it. Please do not use this before understanding the concepts.

## Features

- CLI interface
- Modular architecture – each lab is a standalone Python file
- Custom Proxy and No Proxy also support (`--proxy`, `--no-proxy`)
- Docker-compatible
- Easily extensible - add your own code if you want!

---

## Installation

### Option 1: Install via pip (recommended)

Windows

```powershell
python -m venv burplabs-venv
.\burplabs-venv\scripts\Activate.ps1
pip install burplabs
```

### Option 2: Git clone

```bash
git clone https://github.com/spbavarva/portswigger-labs-scripts.git
cd portswiggerlab
pip install .
```

(Docker will be added soon)

---

## Usage

### View Help

```bash
burplabs -h
```

![burplabs help](burplabs-help.png)

### List All Available Labs

```bash
burplabs --list-labs
```

### Interactive Mode

```bash
burplabs --interactive
```
and then just follow the steps. You can even enter custom proxy when it prompts or if you want to use burp proxy then just open burp and hit 'Y' when it prompts for default proxy to get requests on your burp.

Or you can hit 'n' when it prompts and you don't need to open burp at all.

![Interactive Mode](interactive-mode.png)


---

## Adding New Labs

To add a new lab:

1. Create a new file in `burplabs/labs/name-of-the-folder`, e.g. `sql_lab3.py`
2. It must define a `run(url, payload, proxies=None)` function
3. That’s it! The lab will be auto-detected and usable like:

```bash
portswiggerlab sql_lab3 --url ... --payload ...
```


## Author and Support

Credit to Rana Khalil for inspiring me for this!

Built by [Sneh aka mystic_mido](https://github.com/spbavarva)
Portfolio: [snehbavarva.com](https://www.snehbavarva.com)
If you like it, give it a ⭐ on GitHub! That will really helps a lot to motivate me and show the significance of this small project. Thank you!


## License

MIT License