<commit_before>execution
execute 
	| preSelection selected |
	
	preSelection := OrderedCollection new.
	(repository collectionAt: queryClass) selectAllWithId do: [ :eachAssoc | 
		preSelection add: (eachAssoc value 
			at: VoEJDBJSONSerializer fieldId put: eachAssoc key;
			yourself) ].
	
	selected := preSelection collect: [ :each | 
		repository 
			retrieveQueriedInstanceOf: queryClass 
			serialized: each ].
	sortBlock ifNotNil: [ selected sort: sortBlock ].

	^ selected<commit_msg>filtering results if query is not for root class but a subclass<commit_after>execution
execute 
	| preSelection selected |
	
	preSelection := OrderedCollection new.
	(repository collectionAt: queryClass) selectAllWithId do: [ :eachAssoc | 
		preSelection add: (eachAssoc value 
			at: VoEJDBJSONSerializer fieldId put: eachAssoc key;
			yourself) ].
	
	selected := preSelection collect: [ :each | 
		repository 
			retrieveQueriedInstanceOf: queryClass 
			serialized: each ].
	queryClass = queryClass persistentClass ifFalse: [ 
		selected := selected select: [ :each | 
			each isKindOf: queryClass ] ].
	sortBlock ifNotNil: [ selected sort: sortBlock ].

	^ selected
{'fraction_non_alphanumeric': 0.07851596203623813, 'fraction_numerical': 0.0, 'mean_word_length': 4.395348837209302, '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': '3873995', 'n_tokens_mistral': 383, 'n_tokens_neox': 339, 'n_words': 99}