* @return a list of the backchaining implication rules which might apply to the given predicate
   *
   * @throws UnknownHostException if cyc server host not found on the network
   * @throws IOException if a data communication error occurs
   * @throws CycApiException if the api request results in a cyc server error
   */
  public CycList getBackchainRules(CycConstant predicate, CycObject mt)
          throws UnknownHostException, IOException, CycApiException {
    StringBuilder command = new StringBuilder();
    if (makeELMt(mt).equals(inferencePSC) || makeELMt(mt).equals(
            everythingPSC)) {
      command.append("(clet (backchain-rules) ");
      command.append("  (with-all-mts ");
      command.append("    (do-predicate-rule-index (rule ").append(predicate.stringApiValue()).append(" ");
      command.append("                                :sense :pos ");
      command.append("                                :done nil ");
      command.append("                                :direction :backward) ");
      command.append("       (pwhen (eq (first (assertion-el-formula rule)) #$implies) ");
      command.append("         (cpush (assertion-el-formula rule) backchain-rules)))) ");
      command.append("   backchain-rules)");
    } else {
      command.append("(clet (backchain-rules) ");
      command.append("  (with-inference-mt-relevance ").append(makeELMt(mt).stringApiValue()).append(" ");
      command.append("    (do-predicate-rule-index (rule ").append(predicate.stringApiValue()).append(" ");
      command.append("                                :sense :pos ");
      command.append("                                :done nil ");
      command.append("                                :direction :backward) ");
      command.append("       (pwhen (eq (first (assertion-el-formula rule)) #$implies) ");
      command.append("         (cpush (assertion-el-formula rule) backchain-rules)))) ");
      command.append("   backchain-rules)");
    }

    //this.traceOn();
    return converseList(command.toString());
  }