MCPcopy Create free account
hub / github.com/InternScience/InternAgent / contexts

Function contexts

tasks/AutoTTS/code/experiment/prompter/multihop.py:322–332  ·  view source on GitHub ↗
(obj: dict, dataset: str)

Source from the content-addressed store, hash-verified

320
321# utilization
322def contexts(obj: dict, dataset: str):
323 if dataset == "hotpotqa":
324 context = []
325 for i in range(len(obj["context"]["sentences"])):
326 context.append(" ".join(obj["context"]["sentences"][i]))
327 return context
328 # return obj["context"]
329 elif dataset == "longbench":
330 return obj["context"]
331 else:
332 raise ValueError("Unknown dataset format: neither 'context' nor 'paragraphs' field found")
333
334def check(name: str, result: dict, *args):
335 if name == "cot":

Callers 2

gather_resultsMethod · 0.90
process_itemFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected