Metadata-Version: 2.4
Name: kodelet-subagent
Version: 0.6.6
Summary: Durable background-agent extension for Kodelet
Keywords: kodelet,extension,agents,background-tasks
Author: Jingkai He
Author-email: Jingkai He <jingkai@hey.com>
License-Expression: MIT
License-File: LICENSE
Requires-Dist: alembic>=1.16,<2
Requires-Dist: kodelet-sdk>=0.5.5,<0.6
Requires-Python: >=3.11
Project-URL: Repository, https://github.com/jingkaihe/kodelet-subagent
Project-URL: Issues, https://github.com/jingkaihe/kodelet-subagent/issues
Description-Content-Type: text/markdown

# Kodelet subagent

A Kodelet extension for running named background agents that you can wait on, steer, cancel, and give follow-up work.

## Tools

| Tool | Purpose |
| --- | --- |
| `spawn_agent` | Start a named background agent and return immediately. |
| `wait_agent` | Wait for an agent's current run, with live progress, and return its result. |
| `list_agents` | List the current conversation's agents and their status. |
| `followup_agent` | Give an idle, failed, interrupted, or canceled agent a new task. |
| `steer_agent` | Send guidance to a running agent. |
| `cancel_agent` | Cancel an agent. It can be resumed later with `followup_agent`. |

By default, a new agent starts from a fork of the current conversation. Pass `context_mode="fresh"` to start without the parent's context. Only fresh agents can run in a different `cwd`, subject to runner policy. Forks and follow-ups keep their saved directory. Background agents cannot spawn agents of their own.

Agents are stored in SQLite, so an agent interrupted by an extension restart can still be resumed with `followup_agent`.

## Model profiles

Fresh agents use the parent conversation's model profile. To use a different profile, set `KODELET_SUBAGENT_PROFILE` (for example, `generic`) in the environment of the runner that hosts the extension, then restart that runner. Forked agents and follow-ups keep the conversation's saved settings.

## Installation

```bash
uvx kodelet-subagent install
```

Or install from GitHub:

```bash
uvx --from git+https://github.com/jingkaihe/kodelet-subagent kodelet-subagent install
```

Verify that the runner discovers the extension:

```bash
kodelet extension inspect jingkaihe@kodelet-subagent/subagent
```

## License

Licensed under the MIT License. See `LICENSE`.
