<commit_before>require 'jmespath'
require 'seahorse'

Seahorse::Util.irregular_inflections({
  'ARNs' => 'arns',
  'CNAMEs' => 'cnames',
  'Ec2' => 'ec2',
  'ElastiCache' => 'elasticache',
  'iSCSI' => 'iscsi',
  'ACLs' => 'acls',
  #'SSEKMS' => 'sse_kms',
})

module Aws

  # @api private
  API_DIR = File.join(File.dirname(File.dirname(__FILE__)), 'apis')

  # @api private
  # services
  SERVICE_MODULE_NAMES = %w(
    ACM
    APIGateway
    AutoScaling
    CloudFormation
    CloudFront
    CloudHSM
    CloudSearch
    CloudSearchDomain
    CloudTrail
    CloudWatch
    CloudWatchEvents
    CloudWatchLogs
    CodeCommit
    CodeDeploy
    CodePipeline
    CognitoIdentity
    CognitoIdentityProvider
    CognitoSync
    ConfigService
    DatabaseMigrationService
    DataPipeline
    DeviceFarm
    DirectConnect
    DirectoryService
    DynamoDB
    DynamoDBStreams
    EC2
    ECR
    ECS
    EFS
    ElastiCache
    ElasticBeanstalk
    ElasticLoadBalancing
    ElasticsearchService
    ElasticTranscoder
    EMR
    Firehose
    GameLift
    Glacier
    IAM
    ImportExport
    Inspector
    IoT
    IoTDataPlane
    Kinesis
    KMS
    Lambda
    LambdaPreview
    MachineLearning
    MarketplaceCommerceAnalytics
    MarketplaceMetering
    OpsWorks
    RDS
    Redshift
    Route53
    Route53Domains
    S3
    SES
    SimpleDB
    SNS
    SQS
    SSM
    StorageGateway
    STS
    Support
    SWF
    WAF
    WorkSpaces
  )

  @config = {}
  @services = {}
  @service_added_callbacks = []

  SERVICE_MODULE_NAMES.each do |const_name|
    autoload const_name, "aws-sdk-core/#{const_name.downcase}"
  end

  autoload :DefaultList, 'aws-sdk-core/default_list'
  autoload :DefaultMap, 'aws-sdk-core/default_map'
  autoload :Struct2Hash, 'aws-sdk-core/struct_2_hash'
  autoload :StructureType, 'aws-sdk-core/structure_type'
  autoload :ResourceCollection, 'aws-sdk-core/resource_collection'

  autoload :AssumeRoleCredentials, 'aws-sdk-core/assume_role_credentials'
  autoload :Client, 'aws-sdk-core/client'
  autoload :ClientStubs, 'aws-sdk-core/client_stubs'
  autoload :ClientWaiters, 'aws-sdk-core/client_waiters'
  autoload :CredentialProvider, 'aws-sdk-core/credential_provider'
  autoload :CredentialProviderChain, 'aws-sdk-core/credential_provider_chain'
  autoload :Credentials, 'aws-sdk-core/credentials'
  autoload :Deprecations, 'aws-sdk-core/deprecations'
  autoload :EagerLoader, 'aws-sdk-core/eager_loader'
  autoload :EmptyStructure, 'aws-sdk-core/empty_structure'
  autoload :EndpointProvider, 'aws-sdk-core/endpoint_provider'<commit_msg>Added a chunk service customization to keep track of them.<commit_after>require 'jmespath'
require 'seahorse'

Seahorse::Util.irregular_inflections({
  'ARNs' => 'arns',
  'CNAMEs' => 'cnames',
  'Ec2' => 'ec2',
  'ElastiCache' => 'elasticache',
  'iSCSI' => 'iscsi',
  'ACLs' => 'acls',
  #'SSEKMS' => 'sse_kms',
})

module Aws

  # @api private
  API_DIR = File.join(File.dirname(File.dirname(__FILE__)), 'apis')

  # @api private
  # services
  SERVICE_MODULE_NAMES = %w(
    ACM
    APIGateway
    AutoScaling
    CloudFormation
    CloudFront
    CloudHSM
    CloudSearch
    CloudSearchDomain
    CloudTrail
    CloudWatch
    CloudWatchEvents
    CloudWatchLogs
    CodeCommit
    CodeDeploy
    CodePipeline
    CognitoIdentity
    CognitoIdentityProvider
    CognitoSync
    ConfigService
    DatabaseMigrationService
    DataPipeline
    DeviceFarm
    DirectConnect
    DirectoryService
    DynamoDB
    DynamoDBStreams
    EC2
    ECR
    ECS
    EFS
    ElastiCache
    ElasticBeanstalk
    ElasticLoadBalancing
    ElasticsearchService
    ElasticTranscoder
    EMR
    Firehose
    GameLift
    Glacier
    IAM
    ImportExport
    Inspector
    IoT
    IoTDataPlane
    Kinesis
    KMS
    Lambda
    LambdaPreview
    MachineLearning
    MarketplaceCommerceAnalytics
    MarketplaceMetering
    OpsWorks
    RDS
    Redshift
    Route53
    Route53Domains
    S3
    SES
    SimpleDB
    SNS
    SQS
    SSM
    StorageGateway
    STS
    Support
    SWF
    WAF
    WorkSpaces
  )

  @config = {}
  @services = {}
  @service_added_callbacks = []

  SERVICE_MODULE_NAMES.each do |const_name|
    autoload const_name, "aws-sdk-core/#{const_name.downcase}"
  end

  #module S3
  #  autoload :Presigner, 'aws-sdk-core/s3/presigner'
  #  autoload :BucketRegionCache, 'aws-sdk-core/s3/bucket_region_cache'
  #  # @api private
  #  BUCKET_REGIONS = BucketRegionCache.new
  #end

  #module DynamoDB
  #  autoload :AttributeValue, 'aws-sdk-core/dynamodb/attribute_value'
  #  class Client
  #    def data_to_http_resp(operation_name, data)
  #      api = config.api
  #      operation = api.operation(operation_name)
  #      translator = Plugins::DynamoDBSimpleAttributes::ValueTranslator
  #      translator = translator.new(operation.output, :marshal)
  #      data = translator.apply(data)
  #      ParamValidator.validate!(operation.output, data)
  #      protocol_helper.stub_data(api, operation, data)
  #    end
#
#      def stub_data(operation_name, data = {})
#        if config.simple_attributes
#          rules = config.api.operation(operation_name).output
#          translator = Plugins::DynamoDBSimpleAttributes::ValueTranslator
#          data = translator.apply(rules, :marshal, data)
#          data = super(operation_name, data)
#          translator.apply(rules, :unmarshal, data)
#        else
#          super
#        end
#      end
#    end
#  end

  autoload :DefaultList, 'aws-sdk-core/default_list'
  autoload :DefaultMap, 'aws-sdk-core/default_map'
  autoload :Struct2Hash, 'aws-sdk-core/struct_2_hash'
  autoload :StructureType, 'aws-sdk-core/structure_type'
  autoload :ResourceCollection, 'aws-sdk-core/resource_collection'

  autoload :AssumeRoleCredentials, 'aws-sdk-core/assume_role_credentials'
  autoload :Client, 'aws-sdk-core/client'
  autoload :ClientStubs, 'aws-sdk-core/client_stubs'
  autoload :ClientWaiters, 'aws-sdk-core/client_waiters'
  autoload :CredentialProvider, 'aws-sdk-core/credential_provider'
  autoload :CredentialProviderChain, 'aws-sdk-core/credential_provider_chain'
  autoload :Credentials, 'aws-sdk-core/credentials'
  autoload :Deprecations, 'aws-sdk-core/deprecations'
  autoload :EagerLoader, 'aws-sdk-core/eager_loader'
  autoload :EmptyStructure, 'aws-sdk-core/empty_structure'
  autoload :EndpointProvider, 'aws-sdk-core/endpoint_provider'
{'fraction_non_alphanumeric': 0.09052466718872357, 'fraction_numerical': 0.003602192638997651, 'mean_word_length': 3.2887844190732034, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 17, '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': '4310237', 'n_tokens_mistral': 2280, 'n_tokens_neox': 2236, 'n_words': 387}