Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"name": "fxtr",
"source": "./plugins/fxtr",
"description": "Skills for writing, running, and viewing fxtr experiments, and for calling models from them with behaviors",
"version": "0.1.3",
"version": "0.1.4",
"author": {
"name": "TransluceAI"
},
Expand Down
2 changes: 1 addition & 1 deletion plugins/fxtr/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
"author": {
"name": "TransluceAI"
},
"version": "0.1.3"
"version": "0.1.4"
}
6 changes: 3 additions & 3 deletions plugins/fxtr/skills/behaviors/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: behaviors
description: Call language models from fxtr experiments with the behaviors Python library, covering one-shot requests and judge steps, multi-turn chat rollouts, scripted or custom user and tool policies, retries and failures, streaming, checkpoints, and storing conversations. Use whenever a fxtr experiment calls a model or holds a conversation, or when extending behaviors' model adapters or policies.
description: Call language models from fxtr experiments with the behaviors Python library, covering one-shot requests and judge steps, multi-turn chat rollouts, scripted, model-simulated, or custom users and tool policies, retries and failures, streaming, checkpoints, and storing conversations. Use whenever a fxtr experiment calls a model or holds a conversation, or when extending behaviors' model adapters or policies.
---

# behaviors
Expand All @@ -18,11 +18,11 @@ The pages below are its documentation. Read the ones a task needs before writing
| ------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------- |
| Add behaviors to a project; hold a conversation, judge outputs, and summarize verdicts in fxtr steps; test without credentials | [Calling language models](references/guides/language-models.mdx) |
| Pick a provider, an adapter, and an exact model ID | [Choosing models](references/guides/choosing-models.mdx) |
| Script users, offer tools, or write a custom conversation flow | [Policies and tools](references/guides/policies-and-tools.mdx) |
| Script users or simulate them with models (a base model, steered by a pilot), offer tools, or write a custom conversation flow | [Policies and tools](references/guides/policies-and-tools.mdx) |
| Rollout statuses and `max_turns`, failures, retries, streaming | [Rollout outcomes and retries](references/guides/rollout-outcomes.mdx) |
| Messages and content, stored records, transcripts, conversations in the viewer, checkpoints | [Conversation records and checkpoints](references/guides/conversation-records.mdx) |
| Run Docent readings, or convert records for Docent | [Docent readings](references/guides/docent-readings.mdx) |
| Choose a layer; imports, adapters, sampling settings, requests and responses | [API overview](references/reference/api.mdx) |
| Choose a layer; imports, adapters and their options, model providers, sampling and reasoning settings, requests and responses | [API overview](references/reference/api.mdx) |
| Steps, workflows, arrays, launching jobs, and the step cache | the adjacent [fxtr skill](../fxtr/SKILL.md) |

## Best practices
Expand Down
8 changes: 4 additions & 4 deletions plugins/fxtr/skills/behaviors/provenance.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
"skill": "behaviors",
"documentation": "https://docs.transluce.ai/behaviors",
"packages": {
"fxtr": "0.0.1a4",
"behaviors": "0.0.1a3"
"fxtr": "0.1.0a0",
"behaviors": "0.0.1a4"
},
"revision": "c3782b939f40b8fbffa00c43c984c0ff83087cb6",
"revision": "052f907cc35979930fda832a71aec0c2194e7e48",
"modified": false,
"content_sha256": "9ca8c278e92e77f29f281313b17717930e6ecc67e13027fedde3152fc37ea5b9"
"content_sha256": "a9a5b26e4b86c7b765f0d3c7ce1ce7bea062364e7112c5bec2ad86aed6ca2f1d"
}
4 changes: 2 additions & 2 deletions plugins/fxtr/skills/behaviors/references/INDEX.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ in the order of the site's navigation.
- [Conversation records and checkpoints](guides/conversation-records.mdx): What a rollout records, how conversations are stored as fxtr entities and flattened into transcripts, and how to checkpoint a session.
- [Docent readings](guides/docent-readings.mdx): Convert conversations to Docent's data models, and run a Docent reading against a transcript or agent run with a model you choose.
- [Calling language models](guides/language-models.mdx): Use the behaviors library to hold conversations and judge outputs in fxtr steps.
- [Policies and tools](guides/policies-and-tools.mdx): Decide what the model sees each turn: scripted users, tool policies, their combinations, and custom conversation flows.
- [Policies and tools](guides/policies-and-tools.mdx): Decide what the model sees each turn: scripted users, users simulated by a base model and steered by a pilot, tool policies, their combinations, and custom conversation flows.
- [Rollout outcomes and retries](guides/rollout-outcomes.mdx): How a rollout ends, how model call failures are retried, recorded, or raised, and how to watch a rollout as it runs.
- [API overview](reference/api.mdx): The layers of behaviors, where each is imported from, the provider adapters, and the request, response, and sampling types.
- [API overview](reference/api.mdx): The layers of behaviors, where each is imported from, the provider adapters and model providers, and the request, response, and sampling types.
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,14 @@ A new project's renderer package doesn't depend on it yet: add
[The renderer package](../../../fxtr/references/reference/renderers.mdx#the-renderer-package)). The package also exports
`ChatRolloutView`, for a rollout inside a view of your own, and `ComparedRollouts`.

A rollout's or a transcript's conversation view reads a `selector` param, `{ message: n }`, and
marks and scrolls to that message: the `n`th of the messages it draws, counting a transcript's
messages in order, and a rollout's turn by turn, each turn's context messages and then its model's
(not its initialization). A view of your own links to it with that selector, read from an entity
that stores one (see [Params of an entity's
views](../../../fxtr/references/reference/renderers.mdx#params-of-an-entitys-views)); `MessageSelector` and
`isMessageSelector` are exported for it. This selector is provisional.

## Checkpointing sessions

A serializable session can save its state and be restored from it. `await session.get_state()`
Expand All @@ -140,7 +148,9 @@ returns the state as `DynamicData`, tagged with the implementation's own state t
for a state that isn't its own. To keep a state as JSON, write
`json.dumps(thaw_fxtr_data(state.data))` (`thaw_fxtr_data` is in `fxtr.core.entity_data`), and
read it back with `DynamicData.from_data(json.loads(text))`.
The sessions of `chat_session_model_from_api` and of `ScriptedUserSimulator` support this, and the
The sessions of `chat_session_model_from_api`, `ScriptedUserSimulator`, and the
[simulated users](policies-and-tools.mdx#checkpointing-a-simulated-user)
(`BaseModelUserSimulator` and `PilotSteeredUserSimulator`) support this, and the
`serializable_context_policy_from_*` combinators build checkpointable policies when every component
they combine is checkpointable. Generator-based policies can't be checkpointed, because a
suspended generator can't be saved.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description: "Use the behaviors library to hold conversations and judge outputs

* model adapters for Anthropic, OpenAI, and OpenAI-compatible services;
* conversation sessions and **context policies**, which decide what the model sees next:
scripted user messages, tool results, or custom logic;
scripted or model-simulated user messages, tool results, or custom logic;
* retries for rate limits and server errors;
* conversation records that are fxtr entities, so they're stored, linked, and shown in the
viewer.
Expand Down
Loading
Loading