Agents

Choose the excerpts Botie can actually use

BOTIE

Filter the ranked chunk records by membership of their asset field in the allowed list. Preserve their order and other fields.
Ready to test
0 passed · 0 failed · 2 not run

An empty floor. Start with the information your machine needs.

Received result

Your answer will arrive here.

Examples, experiments and workspace controls
Live values

Connect a tool's inputs to see what it produces. You can try a branch before connecting it to Result.

Try your own inputs

Use a copy of the example to try your own data. Keep the problem's assumptions in mind, and predict the effect of a change before checking the output. You can also add another branch to compare two ways of doing the calculation.

Start at an output arrow, then click or drag to an input. Drag empty space to pan. Delete removes a selection. Ctrl/Cmd+Z undoes a change.
Context for this challenge

Filter the ranked chunk records by membership of their asset field in the allowed list. Preserve their order and other fields.

The candidate manuals are already ranked. Some belong to other assets, and the model request has limited room.

Inspect the component calculation
Keep permitted records(
  Records: Ranked candidate excerpts with supplied costs
  Allowed field values: Assets this caller may read
  Field to match: asset
)
Examples and results
Ranked candidate excerpts with supplied costs
[
  {
    "id": "M9",
    "asset": "P-9",
    "tokens": 4,
    "text": "P-9 installation."
  },
  {
    "id": "M2a",
    "asset": "P-2",
    "tokens": 6,
    "text": "P-2 seal inspection."
  },
  {
    "id": "M2b",
    "asset": "P-2",
    "tokens": 5,
    "text": "P-2 bearing inspection."
  }
]
Assets this caller may read
  1. 0P-2
Required result
[
  {
    "id": "M2a",
    "asset": "P-2",
    "tokens": 6,
    "text": "P-2 seal inspection."
  },
  {
    "id": "M2b",
    "asset": "P-2",
    "tokens": 5,
    "text": "P-2 bearing inspection."
  }
]
Ranked candidate excerpts with supplied costs
[
  {
    "id": "A",
    "asset": "P-2",
    "tokens": 3,
    "text": "Seal."
  },
  {
    "id": "B",
    "asset": "P-2",
    "tokens": 5,
    "text": "Bearing."
  }
]
Assets this caller may read
  1. 0P-2
Required result
[
  {
    "id": "A",
    "asset": "P-2",
    "tokens": 3,
    "text": "Seal."
  },
  {
    "id": "B",
    "asset": "P-2",
    "tokens": 5,
    "text": "Bearing."
  }
]
Try a fresh construction

This clears this draft, including its undo history. Earlier successful attempts stay recorded. Build again without opening hints to record an independent attempt.

Stuck? Inspect a worked construction

The tools below form one possible solution. You can assemble it, follow its signals, and undo that change to return to your own construction.

Assumptions and test precision

Costs are supplied, ranking is already done, and the prefix rule is deliberately simple. No selected-ID list proves relevance or factual support. Numerical tests allow a difference of 0.001. Lists and structures must also have the right shape.

Your last tested pieces can start the full construction. An existing draft there keeps its own pieces.

A longer answer leaves room for only one passage

This check uses the pieces from “Spend the context allowance on permitted passages”.

BOTIE

Botie needs more room for a detailed answer. Apply the increased output reserve, remove the restricted passage, then select the ordered prefix of permitted excerpts.
Ranked candidate excerpts with supplied costs
[
  {
    "id": "private",
    "asset": "P-9",
    "tokens": 1,
    "text": "Restricted record."
  },
  {
    "id": "seal",
    "asset": "P-2",
    "tokens": 4,
    "text": "Inspect the seal."
  },
  {
    "id": "bearing",
    "asset": "P-2",
    "tokens": 3,
    "text": "Inspect the bearing."
  }
]
Assets this caller may read
  1. 0P-2
Total token allowance
20
Non-evidence input reserve
8
Output token reserve
7

Use a number, text, or an array matching the requested result. For a matrix, put each row in brackets. Saving your prediction runs your current construction on these inputs and checks the earlier examples too.

Build a construction in the workspace above first. This case will test those pieces.

If the only selected passage is irrelevant, which stage should you inspect before changing the prompt?

Separate candidate retrieval, permission, selection and answer support so a trace can explain where the evidence was lost.

Costs are supplied, ranking is already done, and the prefix rule is deliberately simple. No selected-ID list proves relevance or factual support.

Work through the Python challenges →
Continue the courseWhat Should Botie Do After a Tool Replies? →