<commit_before>require 'omniauth/strategies/oauth2'

module OmniAuth
  module Strategies
    class Notes < OmniAuth::Strategies::OAuth2
      option :name, :notes

      option :client_options, {
        :site => "http://notes18.com",
        :authorize_url => "/oauth/authorize"
      }

      uid { raw_info["id"] }

      info do
        {
          email: raw_info["email"]
          # and anything else you want to return to your API consumers
        }
      end

      def raw_info
        @raw_info ||= access_token.get('/api/me.json').parsed<commit_msg>change to u.notes18.com as user_center url<commit_after>require 'omniauth/strategies/oauth2'

module OmniAuth
  module Strategies
    class Notes < OmniAuth::Strategies::OAuth2
      option :name, :notes

      option :client_options, {
        :site => "http://u.notes18.com",
        :authorize_url => "/oauth/authorize"
      }

      uid { raw_info["id"] }

      info do
        {
          email: raw_info["email"]
          # and anything else you want to return to your API consumers
        }
      end

      def raw_info
        @raw_info ||= access_token.get('/api/me.json').parsed
{'fraction_non_alphanumeric': 0.11168831168831168, 'fraction_numerical': 0.008658008658008658, 'mean_word_length': 2.2200557103064065, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 0, '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': '4717159', 'n_tokens_mistral': 370, 'n_tokens_neox': 358, 'n_words': 84}