semvec/pypi-packages huggingface dataset:
convmodel 0.3.0
convmodel provides a conversation model based on decoders models.

# convmodel

![](https://github.com/colorfulscoop/convmodel/workflows/unittest/badge.svg)

**convmodel** provides a conversation model based on [transformers](https://github.com/huggingface/transformers) GPT-2 model :wink:

:sparkles: Features :sparkles:

* Utilizes GPT2 model to generate response
* Handles multi-turn conversation
* Provides useuful interfaces to fine-tune model and generate a response from a given context

A simple example of fine-tune GPT-2 model and generate a response:

```py
from convmodel import ConversationModel
from convmodel import ConversationExample

# Load model on GPU
model = ConversationModel.from_pretrained("gpt2")

# Define training/validation examples
train_iterator = [
    ConversationExample(conversation=[
        "Hello",
        "Hi, how are you?",
        "Good, thank you, how about you?",
        "Good, thanks!"
    ]),
    ConversationExample(conversation=[
        "I am hungry",
        "How about eating pizza?"
    ]),
]
valid_iterator = [
    ConversationExample(conversation=[
        "Tired...",
        "Let's have a break!",
        "Nice idea!"
    ]),
]

# Fine-tune model
model.fit(train_iterator=train_iterator, valid_iterator=valid_iterator)

# Generate response
model.generate(context=["Hello", "How are you"], do_sample=True, top_p=0.95, top_k=50)
# Output could be like below if sufficient examples were given.
# => ConversationModelOutput(responses=['Good thank you'], context=['Hello', 'How are you'])
```

Please refer to [document](docs/en/docs/index.md) for more details of installation, model architecture and usage.

* [Install](docs/en/docs/install.md)
* [Model Architecture Overview](docs/en/docs/model_architecture_overview.md)
* [Model Training](docs/en/docs/model_training.md)
* [Response Generation](docs/en/docs/response_generation.md)
* [CLI (Experimental)](docs/en/docs/cli.md)

Enjoy talking with your conversational AI :wink:
time-series-transformer 1.0.2
Time Series Transformer
Requires Python: >=3.6

# Transformers for Time Series
[![PyPI version](https://badge.fury.io/py/time-series-transformer.svg)](https://badge.fury.io/py/time-series-transformer) [![travis](https://app.travis-ci.com/DanielAtKrypton/time_series_transformer.svg?branch=master)](https://app.travis-ci.com/github/DanielAtKrypton/time_series_transformer) [![codecov](https://codecov.io/gh/DanielAtKrypton/time_series_transformer/branch/master/graph/badge.svg)](https://codecov.io/gh/DanielAtKrypton/time_series_transformer) [![GitHub license](https://img.shields.io/github/license/DanielAtKrypton/time_series_transformer)](https://github.com/DanielAtKrypton/time_series_transformer) [![Requirements Status](https://requires.io/github/DanielAtKrypton/time_series_transformer/requirements.svg?branch=master)](https://requires.io/github/DanielAtKrypton/time_series_transformer/requirements/?branch=master)

Based on [timeseriestransformer](https://readthedocs.org/projects/timeseriestransformer/badge/?version=latest).

## Installation

### Windows:
```powershell
.\scripts\init-env.ps1
```

### MacOS / Linux
```bash
./scripts/init-env.sh
```

## Usage

```python
from flights_time_series_dataset import FlightsDataset
from time_series_predictor import TimeSeriesPredictor
from time_series_transformer import Transformer

tsp = TimeSeriesPredictor(
    Transformer(),
    max_epochs=50,
    train_split=None,
)

tsp.fit(FlightsDataset())
```

### Test

To test the package simply run the following command from project's root folder.

```bash
pytest -s
```