MCPcopy Create free account
hub / github.com/FSoft-AI4Code/HyperAgent / __call__

Method __call__

src/hyperagent/agents/llms.py:122–132  ·  view source on GitHub ↗
(self, prompt: str)

Source from the content-addressed store, hash-verified

120 )
121
122 def __call__(self, prompt: str):
123 # prompt = truncate_tokens(prompt, encoding_name=self.config["model"], max_length=self.config["max_tokens"])
124 response = self.client.chat.completions.create(
125 temperature=0,
126 model=self.config["model"],
127 messages=[
128 {"role": "system", "content": self.system_prompt},
129 {"role": "user", "content": prompt},
130 ]
131 )
132 return response.choices[0].message.content
133
134class VLLM(LLM):
135 def __init__(self, config):

Callers

nothing calls this directly

Calls 1

createMethod · 0.45

Tested by

no test coverage detected