> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reilabs.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Choose an execution pattern

> Choose numeric control interfaces, observation boundaries, and execution timing for a task-specific integration.

Use this guide after choosing the task your application should perform. The patterns describe control interfaces and execution timing; [application ideas](/docs/neuroadapt/goals) describes possible product workflows. Keep the learner's control values, the fixed execution machinery, and the measured outcome explicit.

## Choose the control interface

| Control interface example | One command contains                                | Useful pre-action observations                       | Measured consequence                           |
| ------------------------- | --------------------------------------------------- | ---------------------------------------------------- | ---------------------------------------------- |
| Manipulation              | Tool position, orientation, and gripper value       | Image-derived object and goal positions; robot state | Contact, lift, transfer, stable release        |
| Aiming                    | Horizontal rate, vertical rate, and firing value    | Joint state and target-relative geometry             | Hit or measured miss quality                   |
| Load positioning          | One signed carriage velocity request                | Carriage state, goal, load motion                    | Arrival, stopping, and sustained settling      |
| Mobile platform           | Left and right wheel commands                       | Target-relative position, heading, velocity          | Positioning and stopping outcome               |
| Interactive control       | Movement, aim, and task-specific interaction values | State available at the next proposal boundary        | Progress and terminal events during the window |

Control width does not determine sequence length. A one-coordinate actuator can have delayed physical consequences; a seven-coordinate command applies its values together. Choose the smallest useful control interface that leaves the intended behavior for Adapt-1 to acquire.

## Manipulation through pose targets

Use this pattern when fixed actuation software can execute a requested pose, while Adapt-1 learns how to coordinate the poses.

1. Measure the object and goal using the declared sensing pipeline, together with robot proprioception.
2. Request a bounded sequence of position, orientation, and gripper controls.
3. Execute each target through fixed inverse kinematics and joint actuation.
4. Record the applied controls and measured successor states.
5. Report progress or stable placement, then let the next attempt use retained experience.

For a seven-coordinate interface, a horizon of twenty permits at most 140 scalar control values. It does not describe the number of sensors or robot joints, and it is not a universal Machina sequence length. Set the horizon and row width for your own contract in [configuration](/docs/machina/configuration).

Define coordinate frames, orientation conventions, gripper scaling, and hold duration before execution. If a retained sequence is retargeted to a new observed frame, keep that geometric transform explicit and consistent. The executor translates targets; the acquired sequence determines which targets to request.

## Aiming with finite-speed controls

Return rates for the aiming axes and a firing value. The executor applies these over time; it does not turn a target location into an analytical shooting solution.

The starting context should describe the current joint state and target-relative geometry. A whole-attempt proposal commits the commands before movement. Contextual refinement can then learn how to adjust the acquired sequence for a different target observation.

Define the objective separately from the controls. A hit is a completion outcome; continuous miss quality provides more detailed feedback. Record the actual projectile and actuator dynamics as part of the environment contract. Start with [acquisition](/docs/machina/acquisition), then [refinement](/docs/machina/refinement).

## Control delayed physical effects

A carriage can move a suspended load through a single velocity request. Swing is a consequence of carriage motion, so the observation and outcome contract need to account for what continues after a command changes.

Supply measured position, velocity, and relevant load motion. Define success over a settling interval, including speed or sway tolerances when the task requires them. Reaching the target at one instant is a different objective from remaining settled there.

Keep command holds, neutral padding, and the assessment interval fixed across candidate comparisons. Removing a command must follow the declared time convention. See [structural stages](/docs/machina/structural-stages) for comparing shortened and reordered executions.

## Short execution windows

Use short blocks when the environment needs another observation before the full task is over. Each block remains an ordered numeric sequence.

<Steps>
  <Step title="Observe at the boundary">
    Measure the current environment state. Request a sequence with the configured horizon and the current goal.
  </Step>

  <Step title="Execute the window">
    Apply commands with the fixed cadence. Stop if the environment terminates; record only the executed prefix.
  </Step>

  <Step title="Report the measured consequence">
    During learning, return the actual controls, successor states, and attributable outcome. Reconcile the acknowledgement before the next learning request.
  </Step>

  <Step title="Continue from the resulting state">
    If the task is still active, observe again and request the next window. Reset only at the environment's real episode boundary.
  </Step>
</Steps>

An eight-command proposal may execute only six commands if a terminal event occurs. Return six action rows and seven state rows for that observation. Keep the full proposal separately; its unexecuted suffix contributes no observed action.

Your application owns the episode identity, block index, command duration, and reset semantics. Use a distinct request ID per new proposal and keep the same compatible learner Domain across windows. The `episode_credit` mechanism name alone does not establish credit across every block in an application episode; provide the outcome contract supported by your integration.

The [acquisition guide](/docs/machina/acquisition#align-the-observation-arrays) gives the observation body. For a named discrete action after each observation, use [Sequential Discovery](/docs/neuroadapt/discovery-sequential).

## Compose maneuvers through continuous state

Use this pattern when your application supplies a sequence of objectives and each acquired maneuver must accept the state produced by its predecessor.

| During learning                                            | During composed execution                                 |
| ---------------------------------------------------------- | --------------------------------------------------------- |
| Collect real successful arrivals from the earlier maneuver | Carry forward position, velocity, and relevant task state |
| Train the next maneuver on those incoming conditions       | Measure the handoff before choosing its controls          |
| Keep objective order and handoff rules explicit            | Execute the next maneuver without resetting the world     |
| Evaluate the full composition after stage development      | Apply the same actuator, termination, and scoring rules   |

Supplying an objective order is part of the application contract. It does not establish that the learner discovered that decomposition. Avoid training each maneuver only from an artificial stationary start if it must later accept a moving handoff.

Keep each maneuver's Domain, selected base, context encoding, and executor version together. Separate Domains make these contracts inspectable; composition itself runs through the continuous environment state.

## Correct an acquired behavior

Preserve a useful base, then learn a bounded correction from the incoming state. Include the observations that can explain the needed change: target-relative position, velocity, changed actuator strength when measured, or another pre-action condition.

Use the [contextual refinement workflow](/docs/machina/refinement) to execute complete candidate comparisons. When earlier behavior must remain reliable, include original conditions in the practice mix and compare the corrected policy with its unchanged base on the same reserved cases.

Check three properties separately:

| Question                                       | Check                                                              |
| ---------------------------------------------- | ------------------------------------------------------------------ |
| Does continued practice improve the behavior?  | Compare before and after practice on reserved cases                |
| Does frozen execution use the current context? | Compare the fixed base with the contextual policy on matched cases |
| Can a fresh client reuse what was retained?    | Reconnect to the same Domain and repeat use without feedback       |

The [retained-use guide](/docs/machina/retained-use) covers the API calls and the manifest needed for reuse.

## Choose feedback that describes the outcome

Use a binary completion value when that is the only dependable measurement. Use measured stage progress or a graded physical error when your application can supply it consistently. More informative feedback can make initial acquisition easier; it still describes the consequence of an attempt rather than providing the successful controls.

Keep the success rule separate from the learning score. A distance score may improve while the required stopping or release condition still fails. Intermediate outcomes must come from actual measurements; if you only measure a final outcome, omit `step_outcomes`.

## Build your integration

Start with one routine your application can execute and measure, then follow the [configuration guide](/docs/machina/configuration). The control interfaces here are implementation examples. Current evidence comes from simulation studies with task-specific policies; using them on another environment or a physical machine requires separate evaluation.
