Orpheus API Reference
Ask Pythia
POST Ask Pythia
https://api.wisecube.ai/orpheus/graphql
This API obtains related claims or information about the input reference, response and question, also the validators results.
Brief Explanation of Validators:
detect_factual_consistency: Checks if the content contradicts factual information
detect_relevance: Ensures the content is relevant to the prompt
detect_pii: Protects sensitive personal information from being exposed
detect_secrets: Ensures no secrets are transmitted in the input
detect_gibberish: Identifies and removes incoherent text
detect_toxicity: Prevents the dissemination of harmful or offensive content
BODY graphql
QUERY
query askPythia($reference: [String!], $response: String!, $question: String) {
askPythia(reference: $reference, response: $response, question: $question)
}
GRAPHQL VARIABLES
{
"reference": ["\nWJ Health Care\nAnatomic Pathology\n$21-14349\nOne Hospital Drive, Columbia, MO 65212\nPhone: (573) 882-1226 Fax. (573) 884-5948\nSURGICAL PATHOLOGY REPORT\n** FINAL **\nPatient:\nOperation Date:\n9/15/2021\nPatient ID: (am,\nAccession Date:\n9/16/2021\nService:\nGeneral Surgery Oncology\nSignout Date:\n9/21/2021\nLocation:\nOncology\nFacility:\nUniversity of MO Hospital (a\nAttending Physician:\nZihao Wu, M.D.\nDOB: ey\nOther Physician(s):\n{None Given}\nSex: GEE\nFINAL DIAGNOSIS:\n1. COLON AND OSTOMY, TAKEDOWN:\nBENIGN SKIN AND COLONIC TISSUE\nONE BENIGN LYMPH NODE (0/1)\n2. RECTUM AND ANUS, ABDOMINAL PERINEAL RESECTION:\nINVASIVE ADENOCARCINOMA, MODERATELY DIFFERENTIATED\nGREATEST DIMENSION INCLUDING TREATMENT EFFECTS - 4 CM\nADENOCARCINOMA INVADES THROUGH MUSCULARIS PROPRIA INTO PERICOLORECTAL TISSUE\nPARTIAL TREATMENT RESPONSE (SCORE 2)\nADENOCARCINOMA AND TREATMENT EFFECTS PRESENT AT CIRCUMFERENTIAL MARGIN\nONE OF NINETEEN LYMPH NODES, POSITIVE FOR ADENOCARCINOMA (1/19)\nPLEASE SEE ATTACHED TUMOR CHECKLIST FOR ADDITIONAL INFORMATION\n3. SOFT TISSUE, RIGHT ANTERIOR ADDITIONAL MARGIN, EXCISION:\nFOCALLY POSITIVE FOR ADENOCARCINOMA WITH ADJACENT TREATMENT EFFECTS\n4. SOFT TISSUE, RIGHT LATERAL SIDEWALL, EXCISION:\nFOCALLY POSITIVE FOR ADENOCARCINOMA WITH ADJACENT TREATMENT EFFECTS\nBy this signature, | attest that the above diagnosis is based upon my\npersonal examination of the tissue and slides (and/or other material indicated\nin the diagnosis), per policy. A resident was invoived in the pathologic\nevaluation of this case, | have reviewed and edited the findings of the\nresident.\nVan Thi Nguyen, M.D.\n** Electronically Signed Out **\nDiagnosis Comment\nSlides 2C and 2F: tumor at soft tissue circumferential margins.\nPage 1 of 4\n$21-14349\n$21-14349\na\nSpecimen(s) Received\n1: COLON AND OSTOMY\n2: ANUS AND RECTUM\n3: RIGHT ANTERIOR ADDITIONAL MARGIN\n4: RIGHT LATERAL SIDEWALL\nHisto\nNOT PROVIDED ON REQUISITION\nGross Description\nIn formalin are four specimens.\nSpecimen #1, labeled \u201ccolon and ostomy\" is an 8.5 cm long segment of colon with a circumference of 2.7 cm. The\nspecimen is closed on the ostomy side with a suture line, and the opposite side is open, with scant attached\nmesentery. Opening the bowel longitudinally reveals unremarkable mucosa. The ostomy end is inked blue, and the\nopposite end is inked black. There is a 0.6 x 0.5 x 0.3 cm polypoid lesion. Samples are submitted as follows:\n1A - longitudinal section of ostomy site\n1B - opposite resection margin, en face\n1C - polypoid lesion\n1D - five possible lymph nodes\n1E - representative section of unremarkable bowel\nSpecimen #2, labeled \u201canus and rectum\u201d is a 28.5 cm long segment of colon with a circumference of 2.6 cm. The\nproximal end is closed with a 3.7 cm long staple line, and the distal end is closed with a suture line. The mesorectal\nenvelope is incomplete. The proximal margin is inked blue and distal margin is inked green. The soft tissue below the\nperitoneal reflection margin is inked black. Surrounding the anus is a 5.5 x 2.5 cm piece of unremarkable skin.\nOpening the bowel longitudinally reveals an ill-defined, 4 x 2 x 2. cm, nearly circumferetial, erythemous lesion with a\n1.5 x 1.3 cm area of ulceration. The mass is 18.2 cm from the proximal resection margin, 5 cm from the distal\nresection margin, abuts the mesorectal margin, and 2 cm proximal to the dentate line. The mass is right below the\nanterior peritoneal reflection. The mass invades into the surrounding fat. The remainder of the colonic mucosa is\nunremarkable. In the pericolonic fat, twenty-six lymph nodes are found ranging in size from 0.9 x 0.7 x 0.4 to 0.3 x 0.3\nx 0.2 cm. Samples are submitted as foltows:\n2A - longitudinal proximal margin\n2B - longitudinal distal margin\n2C-2F - mass to area of deepest invasion\n2G-2H - sequential section of mass to adjacent mucosa\n21-2J - sequential section of mass to adjacent mucosa\n2K-2L - sequential section of mass to adjacent mucosa\n2M - uninvolved colon mucosa\n2N - five lymph nodes in total\n20 - seven lymph nodes in total\nqa.\nPage 2 of 4\n$21-14349\n$21-14349\naeiRD,\n2P - six lymph nodes in total\n2Q - six lymph nodes in total\n2R - two lymph nodes bisected, one inked green-black\nSpecimen #3, labeled \u201cright anterior additional margin\u201d is a 2.2 x 0.8 x 0.6 cm unoriented, tan-brown cauterized piece\nof soft tissue. Serial sections from along the long axis are submitted entirely in 3A.\nSpecimen #4, labeled \u201cright lateral sidewall\" is a 3.2 x 1.2 x 1.5 cm portion of tan-brown soft tissue, with one side\ncauterized. The cauterized side is inked black. The specimen is serially sectioned perpendicular to the cauterized\nside, and submitted entirely in 4A-4B.\n(Iw)\nLiangli Wang, M.D.\nMicroscopic Description\nSPECIMEN\nProcedure:\nRight hemicolectomy\nMacroscopic Evaluation of Mesorectum:\nIncomplete\nTUMOR\nTumor Site:\nRectum\nRectal Tumor Location:\nEntirely below anterior peritoneal reflection\nHistologic Type:\nAdenocarcinoma\nHistologic Grade:\nG2, moderately differentiated\nTumor Size:\nGreatest dimension (Centimeters): 4 cm\nTumor Extent:\nInvades through muscularis propria into pericolorectal tissue\nMacroscopic Tumor Perforation:\nNot identified\nLymphovascular Invasion:\nNot identified\nPerineural Invasion:\nNot identified\nTreatment Effect:\nPresent, with residual cancer showing evident tumor regression, but more than single\nCells or rare smail groups of cancer cells (partial response, score 2)\nMARGINS\nMargin Status for Invasive Carcinoma:\nCannot be determined: Additional right anterior and right lateral margins (part 3 and\n4) were focally positive for addenocarcinoma. However, due to the focal nature of the\ntumor present in these specimens, the true cicumferetial margin is probably free, but\nneeds to be correlated with operative findings.\nMargin Status for Non-Invasive Tumor:\nAll margins negative for high-grade dysplasia / intramucosal carcinoma and low-\ngrade dysplasia\nREGIONAL LYMPH NODES\nRegional Lymph Node Status:\nTumor present in regional lymph node(s)\nNumber of Lymph Nodes with Tumor:\n1\nNumber of Lymph Nodes Examined:\n20\nTumor Deposits:\nNot identified\nPATHOLOGIC STAGE CLASSIFICATION (pTNM, AJCC 8th Edition)\nTNM Descriptors:\ny (post-treatment)\npT Category:\npT3: Tumor invades through the muscularis propria into pericolorectal tissues\npN Category:\npN1a: One regional lymph node is positive\nPage 3 of 4\n$21-14349\n$21-14349\n\u2018The periormanca characteviancs of Oe\n1 staers ated i tes report (\u00a5 Bry) ware determined by the Unireraty af Masoun Department of Pathology They hava not oven cleared oF approved by the US Food and Orug Aanuristraton Tha FDA haa determeved that such\nlasrance or approvals not necemaary Tha teats for chnecal purposes should not be regarded ax invesbpatonat ot for feseatch Ths laboratory a carting\nthe Cirucal Laboratory impravement Amendments of 1988 (CLIA} ab quakked to perform hugh complexey chrical laboratory\ntevang\nUniess gross-cety i apecited a the ciagnows. the final depron\n\u2018ach wpecmen w bated on a micsoecapic examneton of hatolopec secbane of the basue from each aBecamen\nPage 4 of 4\n$21-14349\n"],
"response": "65 year old female presented with pT3 pN1a moderately differentiated adenocarcinoma of rectum on 9/15/2021.",
"question": "What was theTNM stage of the cancer?"
}
Example Request: Search Entities
POST /orpheus/graphql HTTP/1.1
Host: api.wisecube.ai
Content-Type: application/json
Content-Length: 381
{\"query\":\"query askPythia($reference: [String!], $response: String!, $question: String) {\\n askPythia(reference: $reference, response: $response, question: $question) \\n}\",\"variables\":{\"reference\":[\"\\nWJ Health Care\\nAnatomic Pathology\\n$21-14349\\nOne Hospital Drive, Columbia, MO 65212\\nPhone: (573) 882-1226 Fax. (573) 884-5948\\nSURGICAL PATHOLOGY REPORT\\n** FINAL **\\nPatient:\\nOperation Date:\\n9/15/2021\\nPatient ID: (am,\\nAccession Date:\\n9/16/2021\\nService:\\nGeneral Surgery Oncology\\nSignout Date:\\n9/21/2021\\nLocation:\\nOncology\\nFacility:\\nUniversity of MO Hospital (a\\nAttending Physician:\\nZihao Wu, M.D.\\nDOB: ey\\nOther Physician(s):\\n{None Given}\\nSex: GEE\\nFINAL DIAGNOSIS:\\n1. COLON AND OSTOMY, TAKEDOWN:\\nBENIGN SKIN AND COLONIC TISSUE\\nONE BENIGN LYMPH NODE (0/1)\\n2. RECTUM AND ANUS, ABDOMINAL PERINEAL RESECTION:\\nINVASIVE ADENOCARCINOMA, MODERATELY DIFFERENTIATED\\nGREATEST DIMENSION INCLUDING TREATMENT EFFECTS - 4 CM\\nADENOCARCINOMA INVADES THROUGH MUSCULARIS PROPRIA INTO PERICOLORECTAL TISSUE\\nPARTIAL TREATMENT RESPONSE (SCORE 2)\\nADENOCARCINOMA AND TREATMENT EFFECTS PRESENT AT CIRCUMFERENTIAL MARGIN\\nONE OF NINETEEN LYMPH NODES, POSITIVE FOR ADENOCARCINOMA (1/19)\\nPLEASE SEE ATTACHED TUMOR CHECKLIST FOR ADDITIONAL INFORMATION\\n3. SOFT TISSUE, RIGHT ANTERIOR ADDITIONAL MARGIN, EXCISION:\\nFOCALLY POSITIVE FOR ADENOCARCINOMA WITH ADJACENT TREATMENT EFFECTS\\n4. SOFT TISSUE, RIGHT LATERAL SIDEWALL, EXCISION:\\nFOCALLY POSITIVE FOR ADENOCARCINOMA WITH ADJACENT TREATMENT EFFECTS\\nBy this signature, | attest that the above diagnosis is based upon my\\npersonal examination of the tissue and slides (and/or other material indicated\\nin the diagnosis), per policy. A resident was invoived in the pathologic\\nevaluation of this case, | have reviewed and edited the findings of the\\nresident.\\nVan Thi Nguyen, M.D.\\n** Electronically Signed Out **\\nDiagnosis Comment\\nSlides 2C and 2F: tumor at soft tissue circumferential margins.\\nPage 1 of 4\\n$21-14349\\n$21-14349\\na\\nSpecimen(s) Received\\n1: COLON AND OSTOMY\\n2: ANUS AND RECTUM\\n3: RIGHT ANTERIOR ADDITIONAL MARGIN\\n4: RIGHT LATERAL SIDEWALL\\nHisto\\nNOT PROVIDED ON REQUISITION\\nGross Description\\nIn formalin are four specimens.\\nSpecimen #1, labeled “colon and ostomy\\\" is an 8.5 cm long segment of colon with a circumference of 2.7 cm. The\\nspecimen is closed on the ostomy side with a suture line, and the opposite side is open, with scant attached\\nmesentery. Opening the bowel longitudinally reveals unremarkable mucosa. The ostomy end is inked blue, and the\\nopposite end is inked black. There is a 0.6 x 0.5 x 0.3 cm polypoid lesion. Samples are submitted as follows:\\n1A - longitudinal section of ostomy site\\n1B - opposite resection margin, en face\\n1C - polypoid lesion\\n1D - five possible lymph nodes\\n1E - representative section of unremarkable bowel\\nSpecimen #2, labeled “anus and rectum” is a 28.5 cm long segment of colon with a circumference of 2.6 cm. The\\nproximal end is closed with a 3.7 cm long staple line, and the distal end is closed with a suture line. The mesorectal\\nenvelope is incomplete. The proximal margin is inked blue and distal margin is inked green. The soft tissue below the\\nperitoneal reflection margin is inked black. Surrounding the anus is a 5.5 x 2.5 cm piece of unremarkable skin.\\nOpening the bowel longitudinally reveals an ill-defined, 4 x 2 x 2. cm, nearly circumferetial, erythemous lesion with a\\n1.5 x 1.3 cm area of ulceration. The mass is 18.2 cm from the proximal resection margin, 5 cm from the distal\\nresection margin, abuts the mesorectal margin, and 2 cm proximal to the dentate line. The mass is right below the\\nanterior peritoneal reflection. The mass invades into the surrounding fat. The remainder of the colonic mucosa is\\nunremarkable. In the pericolonic fat, twenty-six lymph nodes are found ranging in size from 0.9 x 0.7 x 0.4 to 0.3 x 0.3\\nx 0.2 cm. Samples are submitted as foltows:\\n2A - longitudinal proximal margin\\n2B - longitudinal distal margin\\n2C-2F - mass to area of deepest invasion\\n2G-2H - sequential section of mass to adjacent mucosa\\n21-2J - sequential section of mass to adjacent mucosa\\n2K-2L - sequential section of mass to adjacent mucosa\\n2M - uninvolved colon mucosa\\n2N - five lymph nodes in total\\n20 - seven lymph nodes in total\\nqa.\\nPage 2 of 4\\n$21-14349\\n$21-14349\\naeiRD,\\n2P - six lymph nodes in total\\n2Q - six lymph nodes in total\\n2R - two lymph nodes bisected, one inked green-black\\nSpecimen #3, labeled “right anterior additional margin” is a 2.2 x 0.8 x 0.6 cm unoriented, tan-brown cauterized piece\\nof soft tissue. Serial sections from along the long axis are submitted entirely in 3A.\\nSpecimen #4, labeled “right lateral sidewall\\\" is a 3.2 x 1.2 x 1.5 cm portion of tan-brown soft tissue, with one side\\ncauterized. The cauterized side is inked black. The specimen is serially sectioned perpendicular to the cauterized\\nside, and submitted entirely in 4A-4B.\\n(Iw)\\nLiangli Wang, M.D.\\nMicroscopic Description\\nSPECIMEN\\nProcedure:\\nRight hemicolectomy\\nMacroscopic Evaluation of Mesorectum:\\nIncomplete\\nTUMOR\\nTumor Site:\\nRectum\\nRectal Tumor Location:\\nEntirely below anterior peritoneal reflection\\nHistologic Type:\\nAdenocarcinoma\\nHistologic Grade:\\nG2, moderately differentiated\\nTumor Size:\\nGreatest dimension (Centimeters): 4 cm\\nTumor Extent:\\nInvades through muscularis propria into pericolorectal tissue\\nMacroscopic Tumor Perforation:\\nNot identified\\nLymphovascular Invasion:\\nNot identified\\nPerineural Invasion:\\nNot identified\\nTreatment Effect:\\nPresent, with residual cancer showing evident tumor regression, but more than single\\nCells or rare smail groups of cancer cells (partial response, score 2)\\nMARGINS\\nMargin Status for Invasive Carcinoma:\\nCannot be determined: Additional right anterior and right lateral margins (part 3 and\\n4) were focally positive for addenocarcinoma. However, due to the focal nature of the\\ntumor present in these specimens, the true cicumferetial margin is probably free, but\\nneeds to be correlated with operative findings.\\nMargin Status for Non-Invasive Tumor:\\nAll margins negative for high-grade dysplasia / intramucosal carcinoma and low-\\ngrade dysplasia\\nREGIONAL LYMPH NODES\\nRegional Lymph Node Status:\\nTumor present in regional lymph node(s)\\nNumber of Lymph Nodes with Tumor:\\n1\\nNumber of Lymph Nodes Examined:\\n20\\nTumor Deposits:\\nNot identified\\nPATHOLOGIC STAGE CLASSIFICATION (pTNM, AJCC 8th Edition)\\nTNM Descriptors:\\ny (post-treatment)\\npT Category:\\npT3: Tumor invades through the muscularis propria into pericolorectal tissues\\npN Category:\\npN1a: One regional lymph node is positive\\nPage 3 of 4\\n$21-14349\\n$21-14349\\n‘The periormanca characteviancs of Oe\\n1 staers ated i tes report (¥ Bry) ware determined by the Unireraty af Masoun Department of Pathology They hava not oven cleared oF approved by the US Food and Orug Aanuristraton Tha FDA haa determeved that such\\nlasrance or approvals not necemaary Tha teats for chnecal purposes should not be regarded ax invesbpatonat ot for feseatch Ths laboratory a carting\\nthe Cirucal Laboratory impravement Amendments of 1988 (CLIA} ab quakked to perform hugh complexey chrical laboratory\\ntevang\\nUniess gross-cety i apecited a the ciagnows. the final depron\\n‘ach wpecmen w bated on a micsoecapic examneton of hatolopec secbane of the basue from each aBecamen\\nPage 4 of 4\\n$21-14349\\n\"],\"response\":\"65 year old female presented with pT3 pN1a moderately differentiated adenocarcinoma of rectum on 9/15/2021.\",\"question\":\"What was theTNM stage of the cancer?\"}}
Example response
{
"data": {
"askPythia": {
"claims": [
{
"claim": [
"65 year old female",
"presented on",
"9/15/2021"
],
"class": "neutral"
},
{
"claim": [
"pT3 pN1a moderately differentiated adenocarcinoma of rectum",
"TNM stage",
"pT3 pN1a"
],
"class": "entailment"
},
{
"claim": [
"65 year old female",
"presented with",
"pT3 pN1a moderately differentiated adenocarcinoma of rectum"
],
"class": "entailment"
}
],
"metrics": {
"accuracy": 0.8,
"contradiction": 0.0,
"entailment": 0.6666666666666666,
"neutral": 0.3333333333333333
},
"validatorsResults": [
{
"validatedField": "input_response",
"validator": {
"id": 7,
"name": "detect_factual_consistency",
"description": "This scanner is designed to assess if the given content contradicts or refutes a certain statement or prompt. It acts as a tool for ensuring the consistency and correctness of language model outputs, especially in contexts where logical contradictions can be problematic.",
"alwaysOn": true,
"input": null,
"output": "input_response"
},
"isValid": false,
"riskScore": 1.0,
"errorMessage": null
},
{
"validatedField": "input_response",
"validator": {
"id": 6,
"name": "detect_relevance",
"description": "This scanner ensures that output remains relevant and aligned with the given input prompt.",
"alwaysOn": true,
"input": null,
"output": "input_response"
},
"isValid": false,
"riskScore": 0.51,
"errorMessage": null
},
{
"validatedField": "input_response",
"validator": {
"id": 1,
"name": "detect_pii",
"description": "The Anonymize Scanner acts as your digital guardian, ensuring your user prompts remain confidential and free from sensitive data exposure.",
"alwaysOn": true,
"input": "input_reference",
"output": "input_response"
},
"isValid": true,
"riskScore": 0.0,
"errorMessage": null
},
{
"validatedField": "input_response",
"validator": {
"id": 8,
"name": "detect_secrets",
"description": "This scanner diligently examines user inputs, ensuring that they don't carry any secrets before they are processed by the language model.",
"alwaysOn": true,
"input": null,
"output": "input_response"
},
"isValid": true,
"riskScore": 0.0,
"errorMessage": null
},
{
"validatedField": "input_reference",
"validator": {
"id": 1,
"name": "detect_pii",
"description": "The Anonymize Scanner acts as your digital guardian, ensuring your user prompts remain confidential and free from sensitive data exposure.",
"alwaysOn": true,
"input": "input_reference",
"output": "input_response"
},
"isValid": false,
"riskScore": 1.0,
"errorMessage": null
},
{
"validatedField": "input_response",
"validator": {
"id": 4,
"name": "detect_gibberish",
"description": "This scanner is designed to identify and filter out gibberish or nonsensical inputs in English language text.",
"alwaysOn": true,
"input": null,
"output": "input_response"
},
"isValid": true,
"riskScore": 0.0,
"errorMessage": null
},
{
"validatedField": "input_response",
"validator": {
"id": 5,
"name": "detect_toxicity",
"description": "This provides a mechanism to analyze and mitigate the toxicity of text content, this tool is instrumental in preventing the dissemination of harmful or offensive content.",
"alwaysOn": true,
"input": null,
"output": "input_response"
},
"isValid": true,
"riskScore": 0.0,
"errorMessage": null
}
]
}
}
}