<commit_before>;;; Extends lisp prettyprinter to print out Metaslang term representations readably

(defpackage :MetaSlang)
(in-package :MetaSlang)

;(list-all-packages)
;(setq *print-pprint-dispatch* (copy-pprint-dispatch nil))

(defun print_term (strm term)
  (let ((*standard-output* strm)
	(AnnSpecPrinter::useXSymbols? nil))
    (AnnSpecPrinter::printTermToTerminal term)))

(defvar *print-constructors?* t)
(defvar *print-metaslang-terms?* t)
;(setq metaslang::*print-metaslang-terms?* nil)

(defun term_symbol? (s)
  (and *print-constructors?* *print-metaslang-terms?*
       (member s '(:|Apply| :|ApplyN| :|Record| :|Bind| :|Let| :|LetRec| :|Var|
		   :|Fun| :|Lambda| :|IfThenElse| :|Seq| ))))

(deftype term_symbol ()<commit_msg>Ensure that we don't use x-symbols<commit_after>;;; Extends lisp prettyprinter to print out Metaslang term representations readably

(defpackage :MetaSlang)
(in-package :MetaSlang)

;(list-all-packages)
;(setq *print-pprint-dispatch* (copy-pprint-dispatch nil))

(defun print_term (strm term)
  (let ((*standard-output* strm)
	(AnnSpecPrinter::useXSymbols? nil))
    (declare (special AnnSpecPrinter::useXSymbols?))
    (AnnSpecPrinter::printTermToTerminal term)))

(defvar *print-constructors?* t)
(defvar *print-metaslang-terms?* t)
;(setq metaslang::*print-metaslang-terms?* nil)

(defun term_symbol? (s)
  (and *print-constructors?* *print-metaslang-terms?*
       (member s '(:|Apply| :|ApplyN| :|Record| :|Bind| :|Let| :|LetRec| :|Var|
		   :|Fun| :|Lambda| :|IfThenElse| :|Seq| ))))

(deftype term_symbol ()
{'fraction_non_alphanumeric': 0.1743886743886744, 'fraction_numerical': 0.0, 'mean_word_length': 5.941964285714286, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '976851', 'n_tokens_mistral': 618, 'n_tokens_neox': 601, 'n_words': 130}