hylo.codeagents.agents¶
Package: hylo-code-agents · Core contracts
agents ¶
Code-writing agents (RFC-0006 parts 4 and 5).
code.llm: a chat model writes one Python block per turn against the toolkit (robot), in a persistent restricted
namespace; it sees what the block printed, errors, the robot's status and images it asked for, never the task's
score. It ends the episode with finish() or when a budget runs out.
agent: {type: code.llm, params: {model: {backend: ollama, model: qwen3.5:35b-a3b, vision: true},
max_turns: 30, max_cost_usd: 1.0, block_timeout_s: 60,
skills: {type: skill_library, params: {path: runs/skills/manip, frozen: true}}}}
code.program: runs a frozen solve(robot) (from a sealed program artifact, or source in params for experiments)
with the same toolkit and no model: free to run and reproducible.
agent: {type: code.program, params: {artifact: artifact:pick-place-sub2@1a2b3c4d}}
Both drive the robot through EpisodeBridge, so every motion is an ActionChunk the kernel executes step by step
through the SafetyShield. tools names the toolkit factory (default hylo.manip.tools:Tools; tests use
hylo.codeagents.fakes:FakeTools); it is called as factory(robot_spec, executor, control_hz=..., show=..., **params).
CodeLLMAgent ¶
CodeLLMAgent(model: str | Mapping[str, Any] | ChatModel = 'ollama:qwen3.5:35b-a3b', tools: str | Mapping[str, Any] | None = None, max_turns: int = 30, max_tokens: int | None = None, max_cost_usd: float | None = None, max_steps: int | None = None, block_timeout_s: float = 60.0, reply_tokens: int | None = None, act_wait_s: float = 21600.0, demonstration: str | None = None, skills: str | Mapping[str, Any] | Any | None = None, max_skills: int = 3, min_skill_similarity: float = 0.2, max_history_turns: int = 24, max_context_chars: int | None = 80000)
CodeProgramAgent ¶
CodeProgramAgent(artifact: str | None = None, source: str | None = None, entry: str = 'solve', tools: str | Mapping[str, Any] | None = None, timeout_s: float = 300.0, act_wait_s: float = 600.0, kwargs: Mapping[str, Any] | None = None, record_output: int = 4000)
Bases: _CodeAgentBase
digest
instance-attribute
¶
tool_status ¶
The robot's status for feedback; with the reason the last plan() failed when the toolkit says (robot.why()).
make_tools ¶
make_tools(tools: str | Mapping[str, Any] | None, env_spec: EnvSpec, executor: Any, show: Callable[[Any, str], None] | None) -> Any