@@ -0,0 +1,791 @@
+import concurrent.futures%0Afrom kb import KB%0Aimport time%0A%0Arounds = 100%0A%0Ahammer_idx = 0%0A%0A%0Adef hammer(idx):%0A%0A    kb = KB()%0A%0A    i = 0%0A%0A    while i %3C rounds:%0A        kb += %5B%0A            f%22s_%7Bidx%7D_%7Bi%7D rdf:type C_%7Bidx%7D_%7Bi%7D%22,%0A            f%22C_%7Bidx%7D_%7Bi%7D owl:equivalentClass C2_%7Bidx%7D_%7Bi%7D%22,%0A        %5D%0A        res = kb%5Bf%22* rdf:type C2_%7Bidx%7D_%7Bi%7D%22%5D%0A        assert len(res) == 1 and res%5B0%5D == f%22s_%7Bidx%7D_%7Bi%7D%22%0A        i += 1%0A%0A    kb.close()%0A%0A%0Astart = time.time()%0A%0ANB_PARALLEL_CLIENTS = 10%0A%0Awith concurrent.futures.ThreadPoolExecutor(max_workers=NB_PARALLEL_CLIENTS) as executor:%0A    future_hammers = %5B%0A        executor.submit(hammer, idx) for idx in range(NB_PARALLEL_CLIENTS)%0A    %5D%0A%0A    concurrent.futures.wait(future_hammers)%0A%0Aduration = time.time() - start%0Aprint(f%22Done. Execution time: %7Bduration:.2f%7Ds%22)%0A

add a concurrent 'stress test' for the knowledge base