!7 p { AI_SubSpace subSpace = new(1000); ai_setSubSpace(subSpace); //S q = "is 10 bigger than 9?"; S q = "is 10 bigger than 11?"; ai_postTriple(q, "should be", "answered"); for (int i = 0; i < 10; i++) { int n = l(subSpace.webs); pcall-short { for (S term : concatLists(keys(subSpace.index), keys(subSpace.websByID))) ai_speculate(term); } L newWebs = cloneSubList(subSpace.webs, n); ai_spec_possiblyToActually(newWebs); newWebs = subList(subSpace.webs, n); print("SubSpace size: " + l(subSpace.websByID)); for (Web web : newWebs) print("> " + webToStringShort(web)); S a = ai_text("$X", "answers", q); if (a != null) { print("Answer found! >> " + a); print("SubSpace size: " + l(subSpace.webs) + ", steps: " + (i+1)); break; } if (subSpace.limitReached()) break; } ai_saveSubSpace(subSpace, print(programFile("subspace.gz"))); setRegularGCCountdown(1); // one last GC, then stop }