semvec/pypi-packages huggingface dataset:
leo-cli 0.4.0
leo.org command line tool
Requires Python: >=3.6

# leo-cli

leo-cli is a command line tool which can be used to translate words or phrases from several languages to german. It uses the open dictionary [dict.leo.org][]. I wrote this because visiting their website, choosing the language, typing the word and clicking the submit button required several too many steps. I am a lazy person.

[dict.leo.org]: http://dict.leo.org



## Installation
This tool requires beatiful soup, the wonderful requests library and the tabulate library.

### Install leo-cli
pip install leo-cli

### Update
There has been a layout change on leo.org so you might have to 
pip install leo-cli --upgrade

## Usage:

    leo -h
    usage: leo [-h] [-l {en,pt,fr,de,es,ru}] [-i] [-s] [-p {all,n,v,adj}] [-d] [-v]
               words [words ...]
    Retrieve word information via the Leo website
    positional arguments:
      words                 the words to look up on the LEO website
    optional arguments:
      -h, --help            show this help message and exit
      -l {en,pt,fr,de,es,ru}, --lang {en,pt,fr,de,es,ru}
                            source language, 2 chars (e.g. 'en')
      -i, --inflect         print inflection tables for all homonyms
      -s, --similar         show similar words
      -p {all,n,v,adj}, --pos {all,n,v,adj}
                            Part of speech of words to translate/inflect.
      -d, --define          print dictionary definitions. True by default if -i is
                            not specified.
      -v, --verbose         Print debug messages

### Examples

    leo example
    leo another example
    leo "hang out"
    leo -l fr bonne gout
    leo -l ru книга
    leo -l pt ação
    leo -i reden
    leo ii -p n reden

## TODO
* print non-German plurals
* allow specifying target and source languages separately
* (maybe) don't print conjugation labels in translation header for conjugations
* alternative conjugations with labels for usage (hängen)
* label haupt/nebensätzlich sections for verbs
PyWeatherKit 0.0.4
A Python wrapper for the WeatherKit API
Requires Python: >=3.11
Keywords: weather,kit,weatherkit,api

# PyWeatherKit
A simple Python wrapper for [Apple's WeatherKit REST API](https://developer.apple.com/documentation/weatherkitrestapi).

You need an Apple developer account to use this library and you should first follow the [setup instructions](https://developer.apple.com/documentation/weatherkitrestapi/request_authentication_for_weatherkit_rest_api) in their documentation.

It has a simple interface for retrieving a raw dictionary of weather data from the API, and a method for retrieving simplified daily forecasts as Pythonic objects. Pull requests are welcome!

## Install

```bash
pip install pyweatherkit
```

## Simple Forecast Usage

```python
from weatherkit.client import WKClient 
client = WKClient("YOUR TEAM ID", "YOUR SERVICE ID", "YOUR KEY ID", "PATH TO YOUR PRIVATE KEY FILE")
forecast = client.get_simple_forecast(latitude, longitude)
for day in forecast:
    print(f"{day.day_of_week}: {day.daytime_icon} with a high of {round(day.temperature_high)} and a low of {round(day.temperature_low)}")
```

Assuming you input all of the correct client authentication parameters and a valid latitude and longitude, this should result in something like:

```bash
Thursday: 🌤️ with a high of 38 and a low of 23
Friday: 🌧️ with a high of 45 and a low of 22
Saturday: 🌧️ with a high of 67 and a low of 40
...
```

## Pulling Full Data Sets

```python
from weatherkit.client import WKClient 
client = WKClient("YOUR TEAM ID", "YOUR SERVICE ID", "YOUR KEY ID", "PATH TO YOUR PRIVATE KEY FILE")
res = client.get_weather(44.50572, -73.24026)
```

You can also specify the language of the response, the timezone, and the specific datasets you need.

### Historical Data Pull 
Only available from dates after 08/01/2021 (as of 2023-03-23)
```python
from weatherkit.client import WKClient
from datetime import datetime

# Set dates 
dailyStart = datetime.strptime("2022-11-29", "%Y-%m-%d")
dailyEnd = datetime.strptime("2022-11-30", "%Y-%m-%d")
currentAsOf = datetime.strptime("2022-11-29", "%Y-%m-%d")

client = WKClient("YOUR TEAM ID", "YOUR SERVICE ID", "YOUR KEY ID", "PATH TO YOUR PRIVATE KEY FILE")
res = client.get_weather(44.50572, -73.24026, dailyStart=dailyStart, dailyEnd=dailyEnd, currentAsOf=currentAsOf)
```

## Test/Example Program

Try running simple_test.py from the same directory as this package.

```bash
python3 simple_test.py your_team_id your_service_id your_key_id your_key_path your_latitude your_longitude
```