<commit_before>import Foundation

public struct Instance {
    /// URI of the current instance.
    public let uri: String
    /// The instance's title.
    public let title: String
    /// A description for the instance.
    public let description: String
    /// An email address which can be used to contact the instance administrator.
    public let email: String
    /// The Mastodon version used by instance.
    public let version: String
}

extension Instance {
    init?(from dictionary: JSONDictionary) {
        guard
            let uri = dictionary["uri"] as? String,
            let title = dictionary["title"] as? String,
            let description = dictionary["description"] as? String,
            let email = dictionary["email"] as? String,
            let version = dictionary["version"] as? String
            else {
                return nil
        }

        self.uri = uri
        self.title = title
        self.description = description
        self.email = email
        self.version = version
    }
}<commit_msg>Changes Mastodon version to String?<commit_after>import Foundation

public struct Instance {
    /// URI of the current instance.
    public let uri: String
    /// The instance's title.
    public let title: String
    /// A description for the instance.
    public let description: String
    /// An email address which can be used to contact the instance administrator.
    public let email: String
    /// The Mastodon version used by instance (as of version 1.3).
    public let version: String?
}

extension Instance {
    init?(from dictionary: JSONDictionary) {
        guard
            let uri = dictionary["uri"] as? String,
            let title = dictionary["title"] as? String,
            let description = dictionary["description"] as? String,
            let email = dictionary["email"] as? String
            else {
                return nil
        }

        self.uri = uri
        self.title = title
        self.description = description
        self.email = email
        self.version = dictionary["version"] as? String
    }
}
{'fraction_non_alphanumeric': 0.08261700095510983, 'fraction_numerical': 0.0009551098376313276, 'mean_word_length': 2.089970501474926, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '7046398', 'n_tokens_mistral': 503, 'n_tokens_neox': 495, 'n_words': 205}