<commit_before>/**
 * Copyright 2015 IBM Corp. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

import Foundation

// MARK: RequestType Enum
public extension AlchemyLanguageConstants {
    
    public enum RequestType {
        
        case URL
        case HTML
        case Text
        
    }
    
    /** Input Parameter Keys */
    public enum OutputMode: String {
        
        case JSON = "json"
        case HTML = "html"
        case XML = "xml"
        case RDF = "rdf"
        
    }
    
    public enum SourceText {
        
        case cleaned_or_raw
        case cleaned
        case raw
        case cquery
        case xpath
        case xpath_or_raw
        case cleaned_and_xpath
        
    }
    
    /**
     Used to build the base URI for each call
     */
    public enum WatsonURI: String {
        case URL = "url"
        case APIKey = "apikey"
    }
    
    /**
     Used to build the full URL
     */
    public enum LanguageURI: String {
        case OutputMode = "outputMode"
        case KnowledgeGraph = "knowledgeGraph"
    }
    
    /**
     Used in getText
    */
}

public final class AlchemyLanguageConstants {
    
    // static methods
    static func Calls() -> String { return "/calls" }

    // private
    static private func Prefix(fromRequestType requestType: AlchemyLanguageConstants.RequestType) -> String {
        <commit_msg>adds a TextType enum for GetText<commit_after>/**
 * Copyright 2015 IBM Corp. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

import Foundation

// MARK: RequestType Enum
public extension AlchemyLanguageConstants {
    
    public enum RequestType {
        
        case URL
        case HTML
        case Text
        
    }
    
    /** Input Parameter Keys */
    public enum OutputMode: String {
        
        case JSON = "json"
        case HTML = "html"
        case XML = "xml"
        case RDF = "rdf"
        
    }
    
    public enum SourceText {
        
        case cleaned_or_raw
        case cleaned
        case raw
        case cquery
        case xpath
        case xpath_or_raw
        case cleaned_and_xpath
        
    }
    
    /**
     Used to build the base URI for each call
     */
    public enum WatsonURI: String {
        case URL = "url"
        case APIKey = "apikey"
    }
    
    /**
     Used to build the full URL
     */
    public enum LanguageURI: String {
        case OutputMode = "outputMode"
        case KnowledgeGraph = "knowledgeGraph"
    }
    
    /**
     Used in getText
    */
    public enum TextType {
        case Normal
        case Raw
    }
    
}

public final class AlchemyLanguageConstants {
    
    // static methods
    static func Calls() -> String { return "/calls" }

    // private
    static private func Prefix(fromRequestType requestType: AlchemyLanguageConstants.RequestType) -> String {
        
{'fraction_non_alphanumeric': 0.06659888154550077, 'fraction_numerical': 0.004067107269954245, 'mean_word_length': 1.9409566517189836, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 2}, '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': '6957266', 'n_tokens_mistral': 1049, 'n_tokens_neox': 1022, 'n_words': 406}