# Changelog

What changed in Agent Flywheel, by release. The Python SDK and the Node SDK ship the same version number in the same release.

## 0.5.0

### Added

-   **The Node SDK works with any JavaScript or TypeScript agent.** `npm install @percepteye/agent-flywheel`, then `flywheel()`, `fw.turn()` around each turn you serve and `fw.serve()` for practice tasks, with adapters for the Vercel AI SDK (`@percepteye/agent-flywheel/ai-sdk`) and LangChain.js / LangGraph.js (`@percepteye/agent-flywheel/langchain`), and `recordToolCall()` for anything else. The OpenClaw and DeepSeek Harness plugin is unchanged. See [Node SDK](https://docs.percepteye.ai/sdk-node.md).
-   **A customer can report how a turn or a conversation actually turned out:** `report_outcome()` (Python) and `reportOutcome()` (Node), with `resolved`, `escalated`, `reopened`, `abandoned`, `thumbs_up` or `thumbs_down`. Outcomes wait on disk and are uploaded with the turns.
-   **An outcome can name the episode it is the outcome of**, and one turn of an episode can be given feedback. Both SDKs, same wire.
-   **A rollout's report can say what the agent's own environment checked, how the episode ended and which seeds it ran under.**

### Requires

-   **Mission Control must serve `POST /api/flywheel/v1/outcomes`.** Against an older server, reported outcomes stay queued and are retried for up to a week.

## 0.4.0

### Changed

-   **An unset `PERCEPTEYE_AGENT_MODE` now means `production`; training is an explicit choice.** `serve()` with no mode set prints its production line and returns without opening a connection. Set `PERCEPTEYE_AGENT_MODE=training` on the process meant to run practice tasks. Both SDKs, same default. **Upgrading:** add the variable to every training deployment.
-   **Practice takes two switches, and the SDK names the one that is off.** When the agent's **Allow practice runs** switch in Mission Control is off, `serve()` (Python) and the rollout runner (Node) say so at registration. Mission Control refuses a practice round with `practice_needs_a_training_process` when no training process has checked in.

### Added

-   **An environment-backed agent knows the task it was handed:** `current_task_id()` and `PERCEPTEYE_TASK_ID`. A rollout's tool spans carry that task id in both SDKs.
-   **A rollout can reach non-policy models:** `hosted_model_url(provider)` and `PERCEPTEYE_HOSTED_URL`, for a user simulator, a judge or an embedding model. For OpenAI-compatible providers the URL is an OpenAI client's base as is.
-   **A command agent reports its own grade** by writing `$PERCEPTEYE_TRAJECTORY_DIR/outcome.json`.

## 0.3.0

### Added

-   **Get a key without leaving the terminal.** `agent-flywheel login --agent-id X` and `npx @percepteye/agent-flywheel login` start a device login, print a short code, open launch.percepteye.ai, and store the approved `pefw_` key in `$PERCEPTEYE_HOME/credentials.json` (0600), a file both SDKs share. `logout` forgets it. Resolution order: explicit key, then `PERCEPTEYE_API_KEY`, then the stored key.
-   **`serve()` offers a key in a terminal.** With no key and a person at the terminal, it asks `Create one now (free)? [Y/n]`. Never in CI, with `PERCEPTEYE_NO_PROMPT=1`, or without a terminal.
-   **No `pefw_` key in any request body.** Both SDKs replace one they find with `pefw_[REDACTED]`.

### Changed

-   **Every missing-key refusal says where a key comes from**, naming `agent-flywheel login` and the sign-up page.

## 0.2.0

### Added

-   **The control-plane URL has a default:** `https://launch.percepteye.ai/api/flywheel/v1`. The key is the one thing that can be missing.
-   **What the model saw, under its own consent tier.** With the model-content permission, the LangChain and Google ADK adapters observe each model call inside an `attach()` turn and upload it as one OpenTelemetry GenAI trace (`genai_trace`). Off by default; without the grant nothing is recorded, not even to disk.
-   **`rules=` on `serve()` and `attach()`** declares the Product's workflow rules once after registration. `None` sends nothing; `[]` retracts.
-   **A withdrawn model is given back.** When a person rolls an agent back with nothing to serve, the control plane answers `withdrawn: true` and `policy_source()` reverts to your own configuration, firing `on_change`. **Upgrading:** check `snap.withdrawn` in an `on_change` callback before building a client.

### Changed

-   **The goose hook claims practice tasks only in training mode.**
-   **`attach(retention_turns=...)`** refuses a value that is not a whole number 0 or more.
-   **Your flywheel key opens only the control plane's own gateway.** A `pefw_` key goes to an endpoint only when the control plane names `PERCEPTEYE_API_KEY` for it and it sits at your control plane's origin. `endpoint_kwargs()` gains `flywheel_key=` and `control_plane_url=`. **Upgrading:** an agent pointed at a self-hosted endpoint without the gateway projection keeps its own configuration.
-   **A `policy_source()` refresh that cannot reach the control plane is a failed refresh:** `last_refresh_ok` goes `False` and `stale_for_s` grows while the last good snapshot stands.
-   **Bounded tool and error bodies keep both ends**, 4000 characters each, with a marker counting what was elided.
-   **Artifacts travel only in the rollout report.**
-   **A rollout's outcome is never lost:** every terminal path reports, and model calls are bounded by a ceiling derived from the episode budget.
-   **A per-process socket no longer changes the agent's execution identity** (`volatile_command_values`).
-   **The Prime adapter seals its kernel** against the serving shell's Python environment.

## 0.1.2, 0.1.1, 0.1.0

First releases. `agent-flywheel` 0.1.0 was published to PyPI on 2026-09-14. See the `v0.1.0` to `v0.1.2` tags.

---
Source: https://docs.percepteye.ai/#changelog · Index: https://docs.percepteye.ai/llms.txt
