semvec/pypi-packages huggingface dataset:
runcmd-mcp 0.1.4
A Model Context Protocol (MCP) service for executing system commands asynchronously
License: MIT

# runcmd-mcp

**版本**: 0.1.4

runcmd-mcp 是一个Model Context Protocol (MCP) 服务，提供异步执行系统命令的功能。

## 功能特点

- **异步执行**: 命令在后台线程中执行，不会阻塞主线程
- **状态查询**: 可随时查询命令执行状态和结果
- **超时控制**: 支持设置命令执行超时时间
- **资源管理**: 自动管理命令执行状态
- **MCP兼容**: 与MCP协议兼容，可与其他MCP客户端集成

## 工具说明

### run_command

异步执行系统命令，立即返回 token。命令将在后台执行，可通过 query_command_status 查询结果。

**参数:**
- `command` (string, required): 要执行的命令字符串
- `timeout` (integer, optional, default: 30): 超时秒数 (1-3600)
- `working_directory` (string, optional): 工作目录（可选，默认为当前目录）

**返回:**
- `token` (string): 任务 token (GUID 字符串)
- `status` (string): 任务状态 ("pending")
- `message` (string): 提交状态消息 ("submitted")

### query_command_status

查询命令执行状态和结果。返回命令的当前状态、退出码、输出等信息。

**参数:**
- `token` (string, required): 任务 token (GUID 字符串)

**返回:**
- `token` (string): 任务 token (GUID 字符串)
- `status` (string): 任务状态 ("pending", "running", "completed", "not_found")
- `exit_code` (integer, optional): 命令退出码
- `stdout` (string, optional): 标准输出
- `stderr` (string, optional): 标准错误输出
- `execution_time` (number, optional): 执行时间（秒）
- `timeout_occurred` (boolean, optional): 是否发生超时

## 安装和使用

安装:
```bash
pip install runcmd-mcp
```

或者从源码安装:
```bash
pip install -e .
```
### MCP 配置
在 MCP 客户端配置中添加：
``` json
{
  "mcpServers": {
    "runcmd-mcp": {
      "command": "uvx",
      "args": [
        "runcmd-mcp"
      ]
    }
  }
}
```
启动MCP服务器:
```bash
runcmd-mcp
```

## 使用示例

1. 调用 `run_command` 提交命令并获取token
2. 使用 `query_command_status` 查询命令执行状态和结果
3. 命令在后台异步执行，不会阻塞主线程
rust-accel 0.1.5
Safe, fast Rust kernels exposed to Python via PyO3
License: MIT
Requires Python: >=3.11

# rust_accel

**rust_accel** is a Rust-accelerated Python extension module built with **PyO3** and **maturin**, designed to speed up computation-heavy numerical workloads while keeping a clean, Python-native API.

It is ideal for performance-critical paths in data processing, numerical optimization, and machine-learning pipelines where Python ergonomics and Rust speed are both required.

---

## Features

-  High-performance Rust kernels exposed to Python
-  Seamless NumPy-compatible API
-  Parallelized computation using Rayon
-  Clean `python/` source layout (no import shadowing)
-  Prebuilt wheels via maturin
-  Memory-safe Rust implementation

---

## Installation

### From PyPI (recommended)

```bash
pip install rust-accel
```
#### From source (development)

```bash
git clone https://github.com/0rlych1kk4/rust_accel.git
cd rust_accel
python -m venv .venv
source .venv/bin/activate
pip install -U pip maturin
maturin develop
```
---

## Usage

### optimize_reconstruction
Computes a batched dot-product–style loss between an input matrix and multiple gradient matrices.

```python

import numpy as np
import rust_accel

x = np.ones((2, 3), dtype=np.float32)

grads = np.stack([
    np.full((2, 3), 2, np.float32),
    np.full((2, 3), 3, np.float32),
], axis=0)

loss = rust_accel.optimize_reconstruction(x, grads)
print(loss)  # 30.0

### clone_grad
Creates a Rust-side copy of a NumPy array and returns it as a flat Python list.

```python
import numpy as np
import rust_accel

x = np.ones((2, 3), dtype=np.float32)
flat = rust_accel.clone_grad(x)

print(len(flat))     # 6
print(flat[:3])      # [1.0, 1.0, 1.0]
```

---
## Real-World Use Cases
-  Accelerating inner loops in ML / optimization pipelines
-  High-frequency numerical aggregation
-  Scientific computing with Python frontends
-  Hybrid Python–Rust systems where correctness and speed matter
-  Safe native extensions without manual memory management

---

## Contributing

We welcome contributions to the `rust_accel` project! If you'd like to contribute, please follow these steps:

1. Fork this repository to your GitHub account.
2. Clone your forked repository to your local machine:
   ```bash
   git clone https://github.com/yourusername/rust_accel.git
   ```
colight-prose 2025.7.7.dev202601161520
Static site generator for Colight visualizations
License: MIT
Requires Python: >=3.10

# Colight Site

Static site generator for Colight visualizations.

Converts `.py` files into markdown/HTML documents where:

- Comments become narrative markdown
- Code blocks are executed to generate Colight visualizations
- Output is embedded as interactive `.colight` files

## Usage

```bash
# Build a single file
colight-prose build src/post.py --output build/post.md

# Watch for changes
colight-prose watch src/ --output build/

# Initialize new project
colight-prose init my-blog/
```

## File Format

`.py` files mix comments (markdown) with executable Python code:

```python
# My Data Visualization
# This creates an interactive plot...

import numpy as np
x = np.linspace(0, 10, 100)

# The sine wave
np.sin(x)  # This expression generates a colight visualization
```

## Pragma Directives

Control the output format and visibility of content using pragma comments:

### File-level pragmas

Begin with `hide-all-`, at the beginning of the file:

```python
# | hide-all-code

# Your content here...
```

### Form-level pragmas

Place directly before a code block:

```python
# | show-code
x = np.array([1, 2, 3])
```

### Available pragmas

- `hide-code` / `show-code` - Hide or show code blocks
- `hide-statements` / `show-statements` - Hide or show Python statements (imports, assignments)
- `hide-visuals` / `show-visuals` - Hide or show results/visuals
- `hide-prose` / `show-prose` - Hide or show markdown prose (comments)
- `format-html` - Output in HTML format
- `format-markdown` - Output in Markdown format

### Pragma formats

```python
# %% hide-code          # Double percent format
# | show-visuals        # Pipe format
#| colight: hide-prose  # Legacy format (still supported)
```

### Precedence

1. Form-level pragmas (highest priority)
2. CLI options
3. File-level pragmas
4. Defaults (lowest priority)

`show-*` pragmas always override corresponding `hide-*` pragmas.