semvec/pypi-packages huggingface dataset:
jsfuzz 1.0.0
Inspect json data and fuzzy search for values or key names
License: MIT
Requires Python: >=3.9

# Fuzzy matching for JSON payload. Find json_path that matches best for your provided value

## Demo: https://huggingface.co/spaces/3cham/jsfuzz

## Install
```bash
$ pip install jsfuzz
```

## Examples:


```json
{
  "id": 11,
  "title": "perfume Oil",
  "description": "Mega Discount, Impression of A...",
  "price": 13,
  "discountPercentage": 8.4,
  "rating": 4.26,
  "stock": 65,
  "brand": "Impression of Acqua Di Gio",
  "category": "fragrances",
  "thumbnail": "https://i.dummyjson.com/data/products/11/thumbnail.jpg",
  "images": [
    "https://i.dummyjson.com/data/products/11/1.jpg",
    "https://i.dummyjson.com/data/products/11/2.jpg",
    "https://i.dummyjson.com/data/products/11/3.jpg",
    "https://i.dummyjson.com/data/products/11/thumbnail.jpg"
  ]
}
```

```python
from jsfuzz import inspector

# Default top_k=5 json paths will be returned
result = inspector.search(payload, "brand")

pprint(result)
====================

Returns:

[('$.brand', 'Impression of Acqua Di Gio', 75.80645161290323),
 ('$.rating', '4.26', 38.18181818181817),
 ('$.category', 'fragrances', 22.769230769230766),
 ('$.thumbnail',
  'https://i.dummyjson.com/data/products/11/thumbnail.jpg',
  22.033898305084744),
 ('$.description', 'Mega Discount, Impression of A...', 20.657894736842106)]
```


```python
result = inspector.search(payload, "65", top_k=10)

pprint(result)
====================

Returns:

[('$.stock', '65', 30.0),
 ('$.rating', '4.26', 20.0),
 ('$.thumbnail', 'https://i.dummyjson.com/data/products/11/thumbnail.jpg', 0.0),
 ('$.category', 'fragrances', 0.0),
 ('$.brand', 'Impression of Acqua Di Gio', 0.0),
 ('$.discountPercentage', '8.4', 0.0),
 ('$.price', '13', 0.0),
 ('$.description', 'Mega Discount, Impression of A...', 0.0),
 ('$.title', 'perfume Oil', 0.0),
 ('$.id', '11', 0.0)]
```
pyemerald 0.5.2
A package to modify save files from Pokemon Emerald
License: MIT
Requires Python: >=3.8,<4.0

# pyemerald

Pyemerald is a python package which lets you modify save files from Pokemon Emerald (Sapphire, Ruby, Leaf Green and Fire Red to come). It lets you modify Pokemon in your team and on the PC, and lets you modify items on the PC. It can also be used to inspect a Pokemons attributes like EV's (IV's to come).

Other and more advanced projects exist e.g. [pkHex](https://projectpokemon.org/home/files/file/1-pkhex/) which inspired this project. However, it annoyed me that I was unable to run pkHex on Linux, and thus pyemerald was created.

Please make sure to never overwrite your original save file, as this software could accidentially make an invalid save file. You are responsible for using the software correctly.
## Installation

Pyemerald can be installed from pypi with the following command:

```
pip install pyemerald
```

It has no dependencies so it should be a simple install.

## Usage

Several examples are available in the `examples` folder. But basically it works by loading an `.sav` file using a `Save` object, which can then emit a `Game` object that is modifiable. Once modification is done, the `Game` object is passed back to the `Save` object and saved to a new file (Please always save to a new file, so you don't accidentially delete your current save file!).

```python
from pyemerald.save import Save
from pyemerald.pokemon import PCPokemon
from pyemerald.moves import Move

save = Save.from_file("data/marie_treecko_pokedex_pc.sav")

game = save.to_game()

# Simple create pokemon
flygon = PCPokemon.from_name(
    name="Flygon",
    level=48,
    move_1=Move.from_name("Thunder"),
    move_2=Move.from_name("Thunder Punch"),
    move_3=Move.from_name("Ice Beam"),
    move_4=Move.from_name("Fly"),
)

# Add Pokemon to user PC
game.add_pc_pokemon(flygon)

# Put modification back to the Save Object
save.update_from_game(game)

# Write new Save file
save.to_file("data/emerald.sav")

```