from sentence_transformers import SentenceTransformer from sentence_transformers.sentence_transformer.evaluation import ( RerankingEvaluator, ) samples = [ { "query": "How do I reset a forgotten password?", "positive": [ "Reset a lost account password from the profile security page.", ], "negative": [ "Generate quarterly revenue charts from a CSV export.", "Tune the database connection pool for a busy API server.", "Schedule a sales demo with the accounts team.", ], }, { "query": "How can I rotate API keys?", "positive": [ "Rotate API tokens before sharing a new integration.", ], "negative": [ "Download a password reset email from account settings.", "Create a dashboard with monthly revenue charts.", "Archive old support tickets after closing a case.", ], }, ]