semvec/pypi-packages huggingface dataset:
snstextscraper 0.7.0
Scrapes text data about the store/company from Naver Place.
License: MIT
Keywords: python,sns,scraper,crawler

# SNS text scraper

네이버 플레이스에 게시된 업체의 리뷰 데이터들를 추출해 주는 봇.

## Installation

```shell
$ pip install snstextscraper
```

## Usage

자세한 사용 방법은 [example](https://github.com/cho2ji/sns-text-scraper/tree/master/example) 디렉터리에 사용 예제 노트북 참고.

### Naver place

네이버 플레이스에 등록된 업체들의 description 데이터과 review 데이터를 추출.

#### Quick start

**Search by name**

네이버 플레이스에 검색 결과에서 가장 첫번째 결과를 추출.

네이버 지도의 첫번째 검색결과로 검색되는 업체 데이터를 가져오기 때문에 검색결과에 따라 원하는 업체의 데이터가 뽑히지 않을 수 있음. 그럴땐 `store.info['search_results']` 로 검색 결과를 확인해보고 검색하길 원하는 업체의 id로 검색.

```python
from snstextscraper.naverplace import Store

store = Store('<store name>', location='제주')  # location defaults to '서울'
description = store.get_description()
reviews = store.get_reviews()  # defaults to 100 reviews.

search_results = store.info['search_results']  # list of search results
```

**Search by id**

업체의 id를 알때 사용.

```python
from snstextscraper.naverplace import Store

store = Store('21270438', location='제주', by_id=True)
description = store.get_description()
reviews = store.get_reviews()
```

#### Output

```
description: str

'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.'

reviews: pandas.DataFrame

| author | review |
|--------|--------|
|   xxxx | xxxxxx |
```

## Credit

좌표를 설정하는데 사용된 [kor_coordinates.txt](https://github.com/cho2ji/sns-text-scraper/blob/master/data/kor_coordinates.txt)는 [cubensys](https://github.com/cubensys)님의 [Korea_District](https://github.com/cubensys/Korea_District)에 있는 [대한민국*기초자치단체*중심점\_2017.csv](https://github.com/cubensys/Korea_District/blob/master/2_%EB%8C%80%ED%95%9C%EB%AF%BC%EA%B5%AD_%EA%B8%B0%EC%B4%88%EC%9E%90%EC%B9%98%EB%8B%A8%EC%B2%B4/%EB%8C%80%ED%95%9C%EB%AF%BC%EA%B5%AD_%EA%B8%B0%EC%B4%88%EC%9E%90%EC%B9%98%EB%8B%A8%EC%B2%B4_%EC%A4%91%EC%8B%AC%EC%A0%90_2017.csv)를 사용하였습니다.

## Disclaimer

이 프로젝트는 비상업적 용도를 위해 제작되었습니다. 용도에 맞게 사용해주시길 바랍니다.
schema-validator 0.2.5
A flask/quart extension to provide schema validation with pydantic.
License: MIT
Requires Python: >=3.7

schema-validator
============

#### Generate from quart-schema


### Install

 - `pip install schema-validator`

<details>
<summary>How to use</summary>

```
    from dataclasses import dataclass
    from datetime import datetime
    from typing import Optional
    from pydantic import BaseModel

    from flask import Flask
    from quart import Quart
    from schema_validator import SchemaValidator
    from schema_validator.flask import validate
    # from schema_validator.quart import validate


    app = Flask(__name__)

    # or 
    app = Quart(__name__)
    
    
    OR
    
    schema = SchemaValidator(app)
    schema.init_app(app)

    @dataclass
    class Todo:
        task: str
        due: Optional[datetime]

    class TodoResponse(BaseModel):
        id: int
        name: str

    @app.post("/")
    @validate(body=Todo, responses=TodoResponse)
    def create_todo():
        # balabala
        return dict(id=1, name="2")
        
    @app.get("/")
    @validate(
        query=Todo,
        responses={200: TodoResponse, 400: TodoResponse}
    )
    def update_todo():
        # balabala
        return TodoResponse(id=1, name="123")

    @app.delete("/")
    @validate(
        body=Todo,
        responses={200: TodoResponse}
    )
    def delete():
        # balabala
        return jsonify(id=1)

    @tags("SOME-TAG", "OTHER-TAG")  # only for swagger
    class View(MethodView):
        @validate(...)
        def get(self):
            return {}
       
    
```
</details>

<details>
<summary>How to show the swagger </summary>

```

app.config["SWAGGER_ROUTE"] = True

http://yourhost/swagger/docs   -> show the all swagger

http://yourhost/swagger/docs/{tag} -> show the swagger which include tag

```
</details>

<details>
<summary>How to export the swagger </summary>

```
add command in flask/quart:
    app.cli.add_command(generate_schema_command)

Export all swagger to json file:

 - flask/quart schema -o swagger.json

Export the swagger which include the ACCOUNT tag:

 - flask/quart schema -o swagger.json -t ACCOUNT

```
</details>
TicTacToe4fun 0.0.6
A Fun Experiment of Tic-Tac-Toe!
License: MIT
Requires Python: >=3.8

.. -*- mode: rst -*-

|BuildTest|_ |PyPi|_ |License|_ |Downloads|_ |PythonVersion|_

.. |BuildTest| image:: https://travis-ci.com/tank-overlord/TicTacToe4fun.svg?branch=main
.. _BuildTest: https://travis-ci.com/tank-overlord/TicTacToe4fun

.. |PythonVersion| image:: https://img.shields.io/badge/python-3.8%20%7C%203.9-blue
.. _PythonVersion: https://img.shields.io/badge/python-3.8%20%7C%203.9-blue

.. |PyPi| image:: https://img.shields.io/pypi/v/TicTacToe4fun
.. _PyPi: https://pypi.python.org/pypi/TicTacToe4fun

.. |Downloads| image:: https://pepy.tech/badge/TicTacToe4fun
.. _Downloads: https://pepy.tech/project/TicTacToe4fun

.. |License| image:: https://img.shields.io/pypi/l/TicTacToe4fun
.. _License: https://pypi.python.org/pypi/TicTacToe4fun


================================
A Fun Experiment of Tic Tac Toe!
================================

Install
-------

.. code-block::

   pip install TicTacToe4fun


Run
---

>>> from TicTacToe4fun import game
>>> g = game()
>>> g.trials(n_trials = 10000,  verbosity = 0, board_dims = (3, 3))
board_dims = (3, 3), X won #: 0, O won #: 0, Draw #: 10,000, Elapsed time: 0.869 sec
>>> g.trials(n_trials = 1,      verbosity = 1, board_dims = (3, 3))
board_dims = (3, 3), X won #: 0, O won #: 0, Draw #: 1, Elapsed time: 0.001 sec
>>> ...
>>> g.trials(n_trials = 10000,  verbosity = 0, board_dims = (4, 4))
board_dims = (4, 4), X won #: 0, O won #: 0, Draw #: 10,000, Elapsed time: 10.039 sec
>>> g.trials(n_trials = 1,      verbosity = 1, board_dims = (4, 4))
board_dims = (4, 4), X won #: 0, O won #: 0, Draw #: 1, Elapsed time: 0.002 sec

Sample Screenshot
-----------------
|image1|


.. |image1| image:: https://github.com/tank-overlord/TicTacToe4fun/raw/main/TicTacToe4fun/examples/game1.png



Have fun!!!
-----------