<commit_before># Esi

Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/esi`. To experiment with that code, run `bin/console` for an interactive prompt.

TODO: Delete this and the text above, and describe your gem

## Installation

Add this line to your application's Gemfile:

```ruby
gem 'esi'
```

And then execute:

    $ bundle

Or install it yourself as:

    $ gem install esi

## Usage

    esi = Esi::Client.new(token: '<PASSWORD>', refresh_token: '<PASSWORD>', token_expires_at: EXPIRE_TIMESTAMP)
    esi.character()

### You can optionally specify a callback that will be executed after a new token has been received using the refresh token

    esi.refresh_callback = -> (token, expires_at) {
      # save new token & expires at
    }

## Authentication

Register your application on [https://developers.eveonline.com/applications].
Add your client id and secret in an initializer or so.

    Esi.config.client_id = 'APP_CLIENT_ID'
    Esi.config.client_secret = 'APP_CLIENT_SECRET'

## Configuration

Create a file `config/initializers/esi.rb` with the following options:

    # Specify a custom log level
    Esi.config.log_level = :debug

    # Specify a custom log path
    Esi.config.log_target = Rails.root.join('log', 'esi.log')

    # Specify a custom logger
    Esi.config.logger = Rails.logger

    # Set esi api version to dev
    Esi.config.api_version = :dev<commit_msg>fix to documentation for creating a new Esi::Client<commit_after># Esi

Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/esi`. To experiment with that code, run `bin/console` for an interactive prompt.

TODO: Delete this and the text above, and describe your gem

## Installation

Add this line to your application's Gemfile:

```ruby
gem 'esi'
```

And then execute:

    $ bundle

Or install it yourself as:

    $ gem install esi

## Usage

    esi = Esi::Client.new(token: '<PASSWORD>', refresh_token: '<PASSWORD>', expires_at: EXPIRE_TIMESTAMP)
    esi.character()

### You can optionally specify a callback that will be executed after a new token has been received using the refresh token

    esi.refresh_callback = -> (token, expires_at) {
      # save new token & expires at
    }

## Authentication

Register your application on [https://developers.eveonline.com/applications].
Add your client id and secret in an initializer or so.

    Esi.config.client_id = 'APP_CLIENT_ID'
    Esi.config.client_secret = 'APP_CLIENT_SECRET'

## Configuration

Create a file `config/initializers/esi.rb` with the following options:

    # Specify a custom log level
    Esi.config.log_level = :debug

    # Specify a custom log path
    Esi.config.log_target = Rails.root.join('log', 'esi.log')

    # Specify a custom logger
    Esi.config.logger = Rails.logger

    # Set esi api version to dev
    Esi.config.api_version = :dev
{'fraction_non_alphanumeric': 0.0870988867059594, 'fraction_numerical': 0.0, 'mean_word_length': 3.5870870870870872, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, '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': '3643909', 'n_tokens_mistral': 943, 'n_tokens_neox': 901, 'n_words': 362}