Skip to main content
Before the first Adapt-1 call, define the workflow’s input contract and state lifecycle. Record calls in execution order, including the returned result and the consequence observed by the application. Adapt-1 updates retained learner state from admitted observations and feedback. The application supplies the inputs and executes operations using the selected route’s response. Keep the following records for each interaction:
  1. input supplied
  2. Adapt-1 result
  3. application commitment
  4. exact execution
  5. observable consequence
  6. information returned

Application boundary

Send source data directly when it matches the route contract. An adapter translates the observable interface; keep preferred answers and the consequence relation to be learned outside its output.

State lifecycle

Choose the state history before the first write: Use the clear or reset route for the applicable state. Domain state, session state, and interval-policy state have different scopes. Do not clear state between interactions that share learning. Use one writer for ordered online state. Concurrent writers can change the event order. This change can affect the evidence available to later calls.

Input contract

Version the parts of the application boundary that determine what Adapt-1 receives:
  • Domain and schema.
  • Event boundary.
  • Input and target paths.
  • Numeric normalization and categorical representation.
  • Grouping context.
  • Adapter or feature extractor.
  • Action dictionary.
  • Consequence translation.
  • Response field consumed by the application.
A Domain declares the public task interface, including available operations and result fields. Keep private target state, preferred procedures, and the consequence relation to be learned outside the learner’s inputs. For transition learning, keep the operational record, learner view, and application-only context separate. See Design Domains for transition learning.

Ordered provenance

Use stable identifiers that the selected request contract accepts. Keep an application interaction record:
Keep this JSON object in the application’s interaction log. Build API requests from the fields accepted by the selected route. If a value changes between steps, keep the original value and the final value.

Transition-event admission

Event storage and transition-learner admission are recorded separately. Before using transition output, inspect the available admission fields:
  • Event or memory ID.
  • Required input, target, action, and grouping paths.
  • Accepted or skipped learner status.
  • Sample-count change.
  • Skip reason.
  • Learner or subsystem version.

Read-only inspection

Use the applicable Domain query and /explain to examine a result. Include the query and grouping context that the application normally supplies. If the route supports these fields, disable exploration and memory-state updates:
Keep both complete responses. Confirm that the documented learner-state hash and applicable versions do not change during the read-only calls. Inspect:
  • The result used by the application.
  • Evidence memory IDs and support.
  • Selection or abstention reason.
  • Missing evidence and disagreement.
  • Hypothesis evidence when configured.
  • Domain, schema, model, and subsystem versions.
See Explain and audit a result.

Ambiguous-write recovery

A gateway timeout can occur after the upstream service accepts an event or feedback write. Until the route specifies idempotency:
  1. Send stable logical identifiers.
  2. Persist the last response confirmed by the client.
  3. Examine current state before repeating a write that could duplicate a learner update.
  4. Resume from the last confirmed logical interaction.
See Operate stateful and adaptive workflows.

Generated language

If the application generates language alongside the structured workflow, record its operation, latency, and cost separately.

Workflow readiness checklist

  • State lifecycle chosen explicitly
  • Correct clear or reset route identified
  • One writer for ordered state
  • Domain, schema, adapter, and action contract versioned
  • Application-private information kept outside the learner view
  • Stable workflow, interaction, and event identifiers
  • Complete route response preserved
  • Returned value connected to application commitment
  • Exact execution and observable consequence recorded
  • Feedback returned to Adapt-1 kept separate from application-only consequence data
  • Learner admission confirmed for transition events
  • Read-only inspection leaves learner state unchanged
  • Ambiguous writes reconciled before resubmission