## FillMe with dummy data!!!
This python package helps you to populate your database with
fake data generated by ChatGPT. This will ensure the tables
relationships will be provisioned and also you have better data to work
with rather than random chars and integers!


### How to install
you can use PIP to install it by simply using
```text
pip install FillMe
```
or, you can clone this repository, create you virtual environment 
and then run
```text
python setup.py install
```

### How to use it
as this repository is relying on ChatGPT to generate data, you first need to create an account on OpenAI
and get an API token. Then all you need is to add it to your OS enevironment variable or
by passing it to FillMe and it will do the rest of job!(check next steps)

then, you can use FillMe in two ways:

1- using in CLI and by passing one mandatory argument and two optional arguments:
```shell
python -m FillMe --db-url your_db_url_here --schema your_schema_name_here --openai-token your_openai_token_here
```

2- or by importing package in your python code or jupyter notebook
```python
from fillme import FillMe
from sqlalchemy import create_engine

engine = create_engine(
    url='postgresql+psycopg2://user:pass@db_host:db_port/db_name', # postgres url
    connect_args={'options': f"-csearch_path=schema_name"}, # schema if applicable
)

# creating instance
fillme_obj = FillMe(
    engine
)
# getting tables and relationships
fillme_obj.get_tables()
# generating dummy data and storing in the tables
fillme_obj.generate_dummies()
```