<commit_before><beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
                           http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.5.xsd">

  <bean id="formBasedLoginUserNameValidator" class="edu.ucla.cens.awserver.validator.AwRequestUserNameValidator">
    <constructor-arg index="0"><value>abcdefghijklmnopqrstuvwxyz.</value></constructor-arg>
    <constructor-arg index="1"><ref bean="failedRequestAnnotator" /></constructor-arg>
  </bean>
  
  <bean id="sensorUploadUserNameValidator" class="edu.ucla.cens.awserver.validator.AwRequestUserNameValidator">
    <constructor-arg index="0"><value>abcdefghijklmnopqrstuvwxyz.</value></constructor-arg>
    <constructor-arg index="1"><ref bean="userNameFailedJsonRequestAnnotator" /></constructor-arg>
  </bean>
  
  <bean id="emptySubdomainValidator" class="edu.ucla.cens.awserver.validator.NonEmptyStringValidator">
    <constructor-arg index="0"><value>subdomain</value></constructor-arg>
  </bean>
  
  <bean id="failedRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedRequestAnnotator" /> 
  
  <bean id="userNameFailedJsonRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedJsonRequestAnnotator">
    <constructor-arg index="0"><value>[{"error_code":"0200","error_text":"malformed username"}]</value></constructor-arg>
  </bean>
  
  
</beans>


<commit_msg>added validators for data upload<commit_after><beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
                           http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.5.xsd">

  <bean id="formBasedLoginUserNameValidator" class="edu.ucla.cens.awserver.validator.AwRequestUserNameValidator">
    <constructor-arg index="0"><value>abcdefghijklmnopqrstuvwxyz.</value></constructor-arg>
    <constructor-arg index="1"><ref bean="failedRequestAnnotator" /></constructor-arg>
  </bean>
  
  <bean id="emptySubdomainValidator" class="edu.ucla.cens.awserver.validator.NonEmptyStringValidator">
    <constructor-arg index="0"><value>subdomain</value></constructor-arg>
  </bean>
  
  <bean id="failedRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedRequestAnnotator" /> 
  
  <bean id="sensorUploadUserNameValidator" class="edu.ucla.cens.awserver.validator.AwRequestUserNameValidator">
    <constructor-arg index="0"><value>abcdefghijklmnopqrstuvwxyz.</value></constructor-arg>
    <constructor-arg index="1"><ref bean="sensorUploadUserNameFailedJsonRequestAnnotator" /></constructor-arg>
  </bean>
  
  <bean id="sensorUploadRequestTypeValidator" class="edu.ucla.cens.awserver.validator.RequiredStringAnnotatingValidator">
    <constructor-arg index="0"><ref bean="sensorUploadRequestTypeFailedJsonRequestAnnotator" /></constructor-arg>
    <constructor-arg index="1"><value>requestType</value></constructor-arg>
    <constructor-arg index="2">
      <list>
        <value>mobility</value>
        <value>prompt</value>
      </list>
    </constructor-arg>
  </bean>
  
  <bean id="sensorUploadPhoneVersionValidator" class="edu.ucla.cens.awserver.validator.RequiredStringAnnotatingValidator">
    <constructor-arg index="0"><ref bean="sensorUploadPhoneVersionFailedJsonRequestAnnotator" /></constructor-arg>
    <constructor-arg index="1"><value>phoneVersion</value></constructor-arg>
    <constructor-arg index="2">
      <list>
        <value>0.9</value>
      </list>
    </constructor-arg>
  </bean>
  
  <bean id="sensorUploadProtocolVersionValidator" class="edu.ucla.cens.awserver.validator.RequiredStringAnnotatingValidator">
    <constructor-arg index="0"><ref bean="sensorUploadProtocolVersionFailedJsonRequestAnnotator" /></constructor-arg>
    <constructor-arg index="1"><value>protocolVersion</value></constructor-arg>
    <constructor-arg index="2">
      <list>
        <value>0.9</value>
      </list>
    </constructor-arg>
  </bean>
  
  <bean id="sensorUploadJsonDataExistsValidator" class="edu.ucla.cens.awserver.validator.NonEmptyStringAnnotatingValidator">
    <constructor-arg index="0"><ref bean="sensorUploadJsonDataFailedJsonRequestAnnotator" /></constructor-arg>
    <constructor-arg index="1"><value>jsonData</value></constructor-arg>
  </bean>
  
  <bean id="sensorUploadUserNameFailedJsonRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedJsonRequestAnnotator">
    <constructor-arg index="0"><value>[{"error_code":"0200","error_text":"unknown user"}]</value></constructor-arg>
  </bean>
  
  <bean id="sensorUploadRequestTypeFailedJsonRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedJsonRequestAnnotator">
    <constructor-arg index="0"><value>[{"error_code":"0301","error_text":"missing or unknown request type"}]</value></constructor-arg>
  </bean>
  
  <bean id="sensorUploadPhoneVersionFailedJsonRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedJsonRequestAnnotator">
    <constructor-arg index="0"><value>[{"error_code":"0302","error_text":"missing or unknown phone version"}]</value></constructor-arg>
  </bean>

  <bean id="sensorUploadProtocolVersionFailedJsonRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedJsonRequestAnnotator">
    <constructor-arg index="0"><value>[{"error_code":"0303","error_text":"missing or unknown protocol version"}]</value></constructor-arg>
  </bean>
  
  <bean id="sensorUploadJsonDataFailedJsonRequestAnnotator" class="edu.ucla.cens.awserver.validator.FailedJsonRequestAnnotator">
    <constructor-arg index="0"><value>[{"error_code":"0300","error_text":"missing json data"}]</value></constructor-arg>
  </bean>
  
</beans>



{'fraction_non_alphanumeric': 0.15878546540567445, 'fraction_numerical': 0.01211216193794591, 'mean_word_length': 5.587978142076503, 'pattern_counts': {'":': 12, '<': 149, '<?xml version=': 0, '>': 149, 'https://': 0, 'lorem ipsum': 0, 'www.': 12, 'xml': 4}, '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': '649516', 'n_tokens_mistral': 1903, 'n_tokens_neox': 1823, 'n_words': 189}