semvec/pypi-packages huggingface dataset:
jua-python-sdk 0.1.0
Access Jua's API with ease
Requires Python: >=3.11

# Jua Python SDK

Access industry-leading weather forecasts wtih ease

## Getting Started 🚀

### Install

We strongly recommend using [uv](https://docs.astral.sh/uv/) to manage dependencies. `python>=3.11` is required.
TODO: Create PyPI entry

### Authentication

TODO: After installing run `jua auth`. This will open your webbrowser for authentication.

Alternatively, generate an API Key [here](https://app.jua.sh/api-keys) and copy the file to `~/.jua/default/api-key.json`.

### Access the latest 20-day forecast for a specific point

```python
import matplotlib.pyplot as plt
from jua.client import JuaClient
from jua.types.geo import LatLon
from jua.weather.models import Models
from jua.weather.variables import Variables

client = JuaClient()
model = client.weather.get_model(Models.EPT1_5)
zurich = LatLon(lat=47.3769, lon=8.5417)
# Get latest forecast
forecast = model.forecast.get_forecast(
    points=[zurich]
)
temp_data = forecast.to_xarray()[Variables.AIR_TEMPERATURE_AT_HEIGHT_LEVEL_2M]
temp_data.jua.to_celcius().plot()
```

### Plot the global forecast with 10h lead time

```python
import matplotlib.pyplot as plt
from jua.client import JuaClient
from jua.types.geo import LatLon
from jua.weather.models import Models
from jua.weather.variables import Variables

client = JuaClient()
model = client.weather.get_model(Models.EPT1_5)

lead_time = 10 # hours
dataset = model.forecast.get_forecast(
    prediction_timedelta=lead_time,
    variables=[
        Variables.WIND_SPEED_AT_HEIGHT_LEVEL_10M,
    ],
)
dataset[Variables.WIND_SPEED_AT_HEIGHT_LEVEL_10M].plot()
plt.show()
```

### Access historical data with ease

```python
import matplotlib.pyplot as plt
from jua.client import JuaClient
from jua.types.geo import LatLon
from jua.weather.models import Models
from jua.weather.variables import Variables

client = JuaClient()
model = client.weather.get_model(Models.EPT1_5_EARLY)

time = "2024-02-01T06:00:00.000000000"
hindcast = model.hindcast.get_hindcast(
    variables=[Variables.AIR_TEMPERATURE_AT_HEIGHT_LEVEL_2M],
    time=time,
    prediction_timedelta=0,
    # Select Europe
    latitude=slice(71, 36),  # Note: slice is inverted
    longitude=slice(-15, 50),
    method="nearest",
)

data = hindcast.to_xarray()[Variables.AIR_TEMPERATURE_AT_HEIGHT_LEVEL_2M]
data.plot()
plt.show()
```

## Development

To install all dependencies run

```
uv sync --all-extras
```

Enable pre-commit for linting and formatting:

```
uv run pre-commit install && uv run pre-commit install-hooks
```
aapt-mcp-server 1.0.0
An MCP server that provides APK analysis capabilities using the Android Asset Packaging Tool (aapt)
Requires Python: >=3.12

# AAPT-MCP

A tool for analyzing Android APK files using the Android Asset Packaging Tool (AAPT) with MCP integration.

## Description

AAPT-MCP is a tool that leverages the Android Asset Packaging Tool (AAPT) to analyze APK files and provide detailed insights about their contents, size, and structure. It uses MCP (Model Control Protocol) to process and analyze the APK data through an LLM (Large Language Model).

## Features

- APK content listing using AAPT
- Detailed size analysis of APK contents
- Categorization of files by type (resources, native libraries, dex files, etc.)
- Identification of largest files and directories
- Optimization recommendations
- Potential issues detection

## Prerequisites

- Python 3.7+
- Android SDK (for AAPT tool)
- MCP server

## Installation

1. Clone the repository:
```bash
git clone https://github.com/yourusername/aapt-mcp.git
cd aapt-mcp
```

2. Install dependencies:
```bash
pip install -r requirements.txt
```

3. Ensure AAPT is in your system PATH:
   - AAPT is part of the Android SDK build tools
   - Add the Android SDK build tools directory to your system PATH

## Usage

1. Run the MCP server:
```bash
python main.py
```

2. The tool provides two main functions:
   - `aapt_tool`: Lists contents of an APK file
   - `analyze_table`: Analyzes the APK contents and provides detailed insights

## Output Format

The analysis provides:
- Total APK Size
- Size Breakdown by category
- Top 5 Largest Files
- Optimization Recommendations
- Potential Issues

## Example

```python
from mcp.server.fastmcp import FastMCP

# Initialize the tool
aapt = FastMCP("aapt-mcp")

# Analyze an APK
result = aapt.analyze_table("path/to/your.apk")
```

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## License

This project is licensed under the MIT License - see the LICENSE file for details.

## Acknowledgments

- Android Asset Packaging Tool (AAPT)
- MCP Framework