Spaces:
Sleeping
Sleeping
| # TRACE Evaluation Metric Constants | |
| RELEVANCE_SCORE = "relevance_score" | |
| UTILIZATION_SCORE = "utilization_score" | |
| COMPLETENESS_SCORE = "completeness_score" | |
| ADHERENCE_SCORE = "adherence_score" | |
| HF_DATASET_REPO_NAME = "maddiaks/RAG26Dataset" | |
| HF_REPO_TYPE = "dataset" | |
| GENERAL_PURPOSE = 'GeneralPurpose' | |
| CHARACTER = 'Character' | |
| TOKEN_BASED = 'TokenBased' | |
| SENTENCE_BASED_LANGCHAIN = 'SentenceBasedLangchain' | |
| SENTENCE_BASED_LLAMA = 'SentenceBasedLlama' | |
| SMALL2BIG = 'Small2Big' | |
| HYBRID = 'HybridChunking' | |
| CHUNKING_STRATEGIES = [ | |
| GENERAL_PURPOSE, | |
| CHARACTER, | |
| TOKEN_BASED, | |
| SENTENCE_BASED_LANGCHAIN, | |
| # SENTENCE_BASED_LLAMA, | |
| SMALL2BIG, | |
| # HYBRID | |
| ] | |
| EMBEDDING_MODELS = [ | |
| "BAAI/bge-large-en-v1.5", | |
| "intfloat/e5-large-v2", | |
| "all-MiniLM-L6-v2" | |
| ] | |
| RELEVANCE_SCORE = "relevance_score" | |
| UTILIZATION_SCORE = "utilization_score" | |
| COMPLETENESS_SCORE = "completeness_score" | |
| ADHERENCE_SCORE = "adherence_score" | |
| default_json = { | |
| "relevance_explanation": "Documents 1 and 4 contain useful information for answering the question. Document 1 mentions 'Signal Information' and 'Self Diagnosis', which are relevant to finding signal information. Document 4 provides additional context about signal information, such as it being only available for digital channels.", | |
| "all_relevant_sentence_keys": [ | |
| "1aJUNK", | |
| "1b", | |
| "4d", | |
| "4e" | |
| ], | |
| "overall_supported_explanation": "The response claims that signal information can be found in the 'Signal Information' or 'Self Diagnosis' section, and that the current channel must be a digital channel. Document 1 supports the first claim, and Document 4 supports the second claim. However, the response also mentions removing protective stickers, which is not directly related to finding signal information. Document 4 mentions removing stickers, but it is not directly supporting the response's claim.", | |
| "overall_supported": True, | |
| "sentence_support_information": [ | |
| { | |
| "response_sentence_key": "a.", | |
| "explanation": "Document 1 supports this sentence, as it mentions 'Signal Information' and 'Self Diagnosis' which are relevant to finding signal information.", | |
| "supporting_sentence_keys": [ | |
| "1a", | |
| "1b" | |
| ], | |
| "fully_supported": True | |
| }, | |
| { | |
| "response_sentence_key": "b.", | |
| "explanation": "Document 4 supports this sentence, as it mentions that signal information is only available for digital channels. Additionally, Document 4 mentions removing protective stickers, which is also mentioned in the response.", | |
| "supporting_sentence_keys": [ | |
| "4d", | |
| "4e", | |
| "4g" | |
| ], | |
| "fully_supported": True | |
| }, | |
| { | |
| "response_sentence_key": "c.", | |
| "explanation": "Document 4 supports this sentence, as it explicitly states that signal information is only available for digital channels.", | |
| "supporting_sentence_keys": [ | |
| "4e" | |
| ], | |
| "fully_supported": True | |
| } | |
| ], | |
| "all_utilized_sentence_keys": [ | |
| "1a", | |
| "1b", | |
| "4d", | |
| "4e", | |
| "4g" | |
| ] | |
| } |