         return AnyIterator {
             repeat {
                 guard let r = i.next() else { return nil }
-                guard let p = r[".predicate"] else { continue }
+                guard let p = r[predicate] else { continue }
                 guard !set.contains(p) else { continue }
                 return r.projected(variables: keys)
             } while true

open class SimpleQueryEvaluator<Q : QuadStoreProtocol> {
    var store : Q
    var defaultGraph : Term
    public init(store : Q, defaultGraph : Term) {
        self.store = store
        self.defaultGraph = defaultGraph
    }
    
    func evaluateUnion(_ patterns : [Algebra], activeGraph : Term) throws -> AnyIterator<TermResult> {
        var iters = try patterns.map { try self.evaluate(algebra: $0, activeGraph: activeGraph) }
        return AnyIterator {

    }
    
    func evaluateNPS(subject: Node, object: Node, graph: Node, not iris: [Term]) throws -> AnyIterator<TermResult> {
        let predicate = self.freshVariable()
        let quad = QuadPattern(subject: subject, predicate: predicate, object: object, graph: graph)
        let i = try store.results(matching: quad)
        // TODO: this can be made more efficient by adding an NPS function to the store,
