@@ -187,9 +187,6 @@ def __init__(self, custom_template_dir: Optional[str] = None):
187187 # 2. Override with custom templates (if provided)
188188 if self .custom_dir and self .custom_dir .exists ():
189189 self ._load_from_directory (self .custom_dir )
190-
191- # 3. Minimal hardcoded fallbacks (for safety/compatibility)
192- self ._ensure_minimal_templates ()
193190
194191 def _load_from_directory (self , directory : Path ) -> None :
195192 """Load all templates and fragments from a directory"""
@@ -208,23 +205,6 @@ def _load_from_directory(self, directory: Path) -> None:
208205 with open (fragments_file , 'r' ) as f :
209206 loaded_fragments = json .load (f )
210207 self .fragments .update (loaded_fragments )
211-
212- def _ensure_minimal_templates (self ) -> None :
213- """Ensure critical templates exist (backward compatibility)"""
214- if "system_message" not in self .templates :
215- self .templates ["system_message" ] = "You are an AI assistant helping with code evolution."
216- if "diff_user" not in self .templates :
217- self .templates ["diff_user" ] = "# Task\n Improve the program:\n ```\n {current_program}\n ```"
218- if "full_rewrite_user" not in self .templates :
219- self .templates ["full_rewrite_user" ] = "# Task\n Rewrite the program:\n ```\n {current_program}\n ```"
220-
221- # Ensure critical fragments exist
222- if "fitness_improved" not in self .fragments :
223- self .fragments ["fitness_improved" ] = "Fitness improved: {prev} → {current}"
224- if "fitness_declined" not in self .fragments :
225- self .fragments ["fitness_declined" ] = "Fitness declined: {prev} → {current}"
226- if "no_specific_guidance" not in self .fragments :
227- self .fragments ["no_specific_guidance" ] = "Focus on improving fitness while maintaining diversity"
228208
229209 def get_template (self , name : str ) -> str :
230210 """Get a template by name"""
0 commit comments