Journeys

A Journey is a parameterized, deterministic, replayable recording plus metadata. It is the one artifact everything in Jevitate produces or consumes.

The artifact

A Journey wraps a parameterized recording with:

  • A name and a param-schema derived from its variables
  • Postconditions that decide whether a step really succeeded
  • Provenance, retention, and promotion state
  • Secret references — a manager key + bound origin + field, never the value

1. Record by demonstration

Step through your app in a headed browser; Jevitate captures a take — a durable, descriptor-based recording (semantic locators, not brittle selectors). Capture a few takes of the same task to generalize the variable parts.

jevitate record --url http://localhost:3000 --intent "Check out with a saved card"

The authorized-target guard runs before any browser opens, and the capture ends when you press Enter. Add --allow <origin> (repeatable) to permit navigation beyond the start origin, or --out <dir> to change where the Recording is written (default ~/.jevitate/recordings). See the flags on MCP & CLI.

2. Parameterize

Bind the variable values and fold multiple takes into one parameterized Journey:

jevitate recording diff takeA.json takeB.json   # see what varies
jevitate recording fit take.json                # bind variables
jevitate recording postdoc take.json --out journey.json

3. Promote

Promotion is the approval gate. Only a promoted Journey is runnable and discoverable over MCP — nothing auto-publishes.

jevitate recording promote journey.json

4. Run

jevitate journey list
jevitate journey run <id> --param email=you@example.com

Replay is deterministic — the same descriptors, the same steps, no model in the loop.

5. Share (optional)

A promoted Journey can be published into a distributed source (a remote git repo of shared Journeys) and consumed from one behind an explicit trust + Terms-of-Use gate. Publishing lands on a new publish/<id> branch (never a default branch) and requires the Journey to be promoted first:

jevitate source add acme https://github.com/acme/jevitate-journeys.git --accept-tou
jevitate source trust acme checkout          # trust one Journey, content-hash-bound
jevitate journey publish checkout --to acme  # share a promoted Journey

See MCP & CLI for every source verb and the publish flags.

The run context

A single immutable RunPolicy is threaded through every step, segmented into narrow sub-policies. It's a required parameter. There is no default construction, and the fallback is never permissive:

RunPolicy (required — no permissive default)
├── SelfHealPolicy   fail-closed | hybrid | full
├── DirectionPolicy  deterministic ↔ Jev-directed ↔ goal-based
├── SecretPolicy     vault-autofill | visible-handback | fail-closed
├── PacingPolicy     human-speed profile
└── Budget           max-steps · per-run/day · concurrency

Safe default: fail-closed self-heal, deterministic direction, fail-closed secret handling.

Self-healing

In-flight self-healing is gated by SelfHealPolicy, chosen per run with --self-heal:

jevitate journey run <id> --self-heal fail-closed   # default
jevitate journey run <id> --self-heal hybrid --real
jevitate journey run <id> --self-heal full --real
  • fail-closed (default) — on divergence the run stops and quarantines rather than guessing. No AI gateway is wired; behavior is identical to a plain deterministic replay.
  • hybrid / full — on divergence Jev does a scoped re-learn of just the broken step and splices the recovered step back into the Journey, gated by policy. Both need an AI gateway (--real or --fake-ai); requesting a heal mode without one fails closed, never a silent unhealed run.

In every mode, write, irreversible, or real-send steps never auto-heal — the runtime's write floor holds regardless of policy. A recovered run is reported as healed (a success); only an unrecoverable divergence is quarantined.

LM-driving

Instead of recording by hand, let Jev drive: it makes typed op + target decisions while a generative model supplies text only, emitting the same deterministic Journey. Drive a goal and author a promotable (never auto-promoted) Journey in one step:

jevitate explore-author-journey --url http://localhost:3000 \
  --goal "Add a product to the cart and reach checkout" \
  --success urlIncludes:/checkout \
  --id checkout --name "Checkout flow" --real

The authored Journey lands unpromoted in the store — promote it through the same approval gate as a hand-recorded one. This is the Testing Modes engine, and the DirectionPolicy above places it on the spectrum.