<commit_before># Sparoku Drain

This is a Heroku log drain that connects to a Spark Core device running [Sparoku Status](https://github.com/heroku/sparoku-status) to render a visualization of how the app dynos are doing.

## Setup

```bash
$ npm install
$ cp .env.sample .env
```

## Running locally

Boot the server with `foreman start`, then make requests immitating the Heroku router, like:

```bash
$ curl -d "heroku router dyno=web.1 status=500" -H "Content-Type: application/logplex-1" http://localhost:5000/logs
```<commit_msg>add heroku button<commit_after># Sparoku Drain

This is a Heroku log drain that connects to a Spark Core device running [Sparoku Status](https://github.com/heroku/sparoku-status) to render a visualization of how the app dynos are doing.

[![Deploy](https://www.herokucdn.com/deploy/button.png)](https://heroku.com/deploy?template=https://github.com/heroku/sparoku-drain)

## Setup

```bash
$ npm install
$ cp .env.sample .env
```

## Running locally

Boot the server with `foreman start`, then make requests immitating the Heroku router, like:

```bash
$ curl -d "heroku router dyno=web.1 status=500" -H "Content-Type: application/logplex-1" http://localhost:5000/logs
```
{'fraction_non_alphanumeric': 0.12686567164179105, 'fraction_numerical': 0.014925373134328358, 'mean_word_length': 4.693396226415095, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 5, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5656740', 'n_tokens_mistral': 414, 'n_tokens_neox': 376, 'n_words': 131}