MCPcopy Create free account
hub / github.com/FastMAS/KVCOMM / __init__

Method __init__

KVCOMM/agents/code_writing.py:15–29  ·  view source on GitHub ↗
(
        self,
        id: str | None = None,
        role: str = None,
        domain: str = "",
        llm_name: str = "",
        llm_config: KVCommConfig | None = None,
    )

Source from the content-addressed store, hash-verified

13class CodeWriting(Node):
14 """Programming agent that validates peers with internal tests."""
15 def __init__(
16 self,
17 id: str | None = None,
18 role: str = None,
19 domain: str = "",
20 llm_name: str = "",
21 llm_config: KVCommConfig | None = None,
22 ):
23 super().__init__(id, "CodeWriting" ,domain, llm_name)
24 prefix = ""
25 self.llm = LLMRegistry.get(llm_name, prefix=prefix, llm_config=llm_config)
26 self.prompt_set = PromptSetRegistry.get(domain)
27 self.role = self.prompt_set.get_role() if role is None else role
28 self.constraint = self.prompt_set.get_constraint(self.role)
29 self.llm.set_id(self.id, self.role)
30
31 async def _process_inputs(
32 self,

Callers

nothing calls this directly

Calls 4

set_idMethod · 0.80
getMethod · 0.45
get_roleMethod · 0.45
get_constraintMethod · 0.45

Tested by

no test coverage detected