MCPcopy Create free account
hub / github.com/EverMind-AI/MSA / compose_input

Function compose_input

src/utils/tools.py:95–98  ·  view source on GitHub ↗

组建reference的 input

(doc, doc_idx, tokenizer)

Source from the content-addressed store, hash-verified

93 self.condition.notify()
94
95def compose_input(doc, doc_idx, tokenizer):
96 """组建reference的 input"""
97 new_doc = "<|im_start|>" + f"[{doc_idx}]. {doc}[{doc_idx}]<|im_end|>"
98 return new_doc,tokenizer(new_doc, add_special_tokens=False)
99
100
101class TimePoint:

Callers 2

_sort_referenceMethod · 0.90
_prepare_block_inputsMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected