import os import yaml def load_prompt_templates(model_name): provider, model = model_name.split('.') file_path = os.path.join('config', 'prompts', provider, f'{model}.yaml') if not os.path.exists(file_path): raise FileNotFoundError(f"No prompt template file found for {model_name}") with open(file_path, 'r') as file: templates = yaml.safe_load(file) return templates