         return serialized
     }
     
-    private func updateDescription() {
+    public var description: String {
         var arr = [final ? "1" : "0"]
-        arr.appendContentsOf(edges.map({ "\($0.0)_\($0.1)" }))
-        descr = arr.joinWithSeparator("_")
-    }
-    
-    internal func setEdge(letter: Character, node: DawgNode) {
-        edges[letter] = node
-        updateDescription()
-    }
-    
-    public var description: String {
-        return descr
+        arr.appendContentsOf(edges.map({ "\($0.0)_\($0.1.hashValue)" }))
+        return arr.joinWithSeparator("_")
     }
     
     public var hashValue: Int {
-        return descr.hashValue
+        return self.description.hashValue
     }
 }
 
 public class Dawg {
     private var rootNode: DawgNode
-    private var previousWord = ""
+    private var previousWord: String = ""
+    private var previousChars: [Character] = []
     
     private lazy var uncheckedNodes = [(parent: DawgNode, letter: Character, child: DawgNode)]()
     private lazy var minimizedNodes = [DawgNode: DawgNode]()

    /// - parameter downTo: Iterate from count to this number (truncates these items).
    private func minimize(downTo: Int) {
        for i in (downTo..<uncheckedNodes.count).reverse() {
            let (_, letter, child) = uncheckedNodes[i]
            if let minNode = minimizedNodes[child] {
                uncheckedNodes[i].parent.setEdge(letter, node: minNode)
            } else {
                minimizedNodes[child] = child
            }

    
    typealias Edges = [Character: DawgNode]
    
    private lazy var edges = Edges()
    internal var final: Bool = false
    internal var id: Int
    
    public init() {
        self.id = self.dynamicType.nextId
        self.dynamicType.nextId += 1
    }
    
    private init(withId id: Int, final: Bool, edges: Edges?) {
        self.dynamicType.nextId = max(self.dynamicType.nextId, id)
        self.id = id
        self.final = final
        if edges?.count > 0 { self.edges = edges! }
    }
    
    public class func deserialize(serialized: NSArray, inout cached: [Int: DawgNode]) -> DawgNode {
        let id = serialized.firstObject! as! Int
        guard let cache = cached[id] else {
            var edges = Edges()
            if serialized.count == 3 {
                edges = Edges()
                if let serializedEdges = serialized.objectAtIndex(2) as? [String: NSArray] {
                    for (letter, array) in serializedEdges {
                        edges[Character(letter)] = DawgNode.deserialize(array, cached: &cached)
                    }
                }
            }
