<commit_before># pageclip-ruby

A simple gem to interface with pageclip API.

## Example

```
require 'pageclip'

Pageclip.configure do |config|
  config.api_key = 'your-secret-api-key'
end

begin
  data = Pageclip.screenshot('http://www.example.com')
  File.open('screenshot.png') do |f|
    f.write(data)
  end
  puts 'The screenshot is done!'
rescue Pageclip::Timeout
  puts 'Sorry I couldn't find a screenshot
rescue Pageclip::UnauthorizedError
  puts 'You don't have a valid API key'
rescue Pageclip::RateLimitedError
  puts 'Too many requests, wait before trying again'<commit_msg>Update description<commit_after># pageclip-ruby

A simple ruby gem to interface with the Pageclip API.

## Example

```
require 'pageclip'

Pageclip.configure do |config|
  config.api_key = 'your-secret-api-key'
end

begin
  data = Pageclip.screenshot('http://www.example.com')
  File.open('screenshot.png') do |f|
    f.write(data)
  end
  puts 'The screenshot is done!'
rescue Pageclip::Timeout
  puts 'Sorry I couldn't find a screenshot
rescue Pageclip::UnauthorizedError
  puts 'You don't have a valid API key'
rescue Pageclip::RateLimitedError
  puts 'Too many requests, wait before trying again'
{'fraction_non_alphanumeric': 0.10437710437710437, 'fraction_numerical': 0.0, 'mean_word_length': 4.6084905660377355, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '2905608', 'n_tokens_mistral': 393, 'n_tokens_neox': 387, 'n_words': 124}