| name | labnb |
|---|---|
| description | Create and maintain a concurrency-safe global lab notebook outside project roots, with idea capture, startup summaries of prior work, append-only indexing, and isolated experiment workspaces across projects, investigations, and tasks. |
Use this skill when the user wants a reusable lab notebook that survives across tasks, projects, investigations, and sessions.
The key difference from repo-local .lab/ workflows is that the lab root lives in a general location and must stay safe under parallel use.
This skill must inherit and obey any higher-level constitution, parent skill, project policy, task instruction, or user constraint already in scope.
Before taking action:
- Review the parent instructions that govern the current task.
- Review the notebook index for related ideas and experiments.
- If you are resuming an existing idea or experiment, review its local rules, checklist, and durable memory in
idea.md,plan.md, andmemory.mdbefore acting. - If the parent rules are stricter than this skill, follow the stricter rule.
- If this skill is missing a guardrail required by the parent context, add the missing guardrail locally in your plan instead of assuming it is safe.
This skill never overrides:
- user instructions
- project-specific safety or contribution rules
- higher-level constitutions about writes, approvals, secrets, or external side effects
Use these focused companion skills when a narrower task is enough:
labnb-resume: summarize prior ideas and experiments for a project and decide where to pick uplabnb-idea: register an unimplemented experiment idea in the shared notebooklabnb-promote: turn an existing idea into a concrete experiment with explicit budgets and provenancelabnb-run: create and run a concrete experiment with budgets, isolated workspace, and iteration logging
Each focused action installs as its own flat top-level labnb-* skill directory rather than as a skill nested inside this one. Keeping every skill flat (no SKILL.md nested under another skill) is what lets the whole skills/ tree install into agents such as Claude Code that do not support skills nested inside other skills, while Codex and other agents discover the same flat entries directly.
The commands below write paths like skills/labnb/scripts/<name>.py. That is the path inside this repository, and it only resolves when you run from the repo root. When this skill is installed into an agent, the helpers live next to this SKILL.md, under <this-skill-dir>/scripts/<name>.py — for example ~/.claude/skills/labnb/scripts/ or ~/.agents/skills/labnb/scripts/. Resolve the script path relative to wherever this SKILL.md actually lives rather than assuming the repository layout, e.g.:
# Directory of the installed labnb skill (the folder containing this SKILL.md).
LABNB_SCRIPTS="<this-skill-dir>/scripts"
python "$LABNB_SCRIPTS/register_experiment.py" --helpThe labnb-* companion skills do not bundle these scripts; they call the ones from the installed labnb skill.
Use this location unless the user explicitly wants another path:
${LAB_NOTEBOOK_ROOT:-${XDG_STATE_HOME:-$HOME/.local/state}/lab-notebook}This keeps the notebook outside any single project tree and outside any specific agent runtime, while still making it easy to override.
Before starting a new experiment, gather or infer these fields:
- Goal
- Mechanical metric
- Direction: higher or lower is better
- Verify command
- Writable scope
- Workspace placement: use the default notebook workspace path, or link the workspace to a different location for large worktrees, datasets, or rich outputs
- Time budget or timebox, if the user gave one
- Stop condition: target metric, iteration count, checkpoint, or manual stop
If any of the first four are missing and cannot be inferred safely, ask before starting. The notebook is global, but the experiment loop still needs a clear local objective.
If the user gives a time budget, treat it as a hard ceiling, not a target to consume.
The setup must answer three planning questions early:
- What is the smallest useful iteration that can produce information or a decision?
- What checkpoint would justify continuing into a second iteration?
- If the budget is too small for even one useful iteration, say so clearly instead of pretending the work fits.
Treat the budget as applying to the whole proposed path, including any parallel branches, delegated work, or downstream follow-up experiments that you are suggesting now.
- Never use a fixed experiment directory name.
- Never let two runs compete to rewrite the central index without a lock.
- Never store the only copy of experiment state inside the project being studied.
- Never delete or rewrite prior experiment rows from the central index.
- Prefer deterministic helpers in
scripts/register_experiment.pyandscripts/summarize_index.pyinstead of ad hoc shell snippets. - Track labnb-managed creates and updates with best-effort provenance using W3C PROV-O terms inside each entry directory.
- Require explicit user confirmation before labnb performs deletions.
- Treat provenance as the source of truth for monitored slice state; do not rely on a separate mutable loop-state file.
- Let
monitor_slice.py checkdecide when to break a slice, and honor a break: it can stop on governance (unauthorized, policy-violating, or drifted), budget, engineering (pace, stall, resource), correctness (repeated failures), or validity (no improvement, guardrail) signals, and a non-zero exit means stop rather than start another iteration.
Apply these guardrails even when the parent constitution does not spell them out explicitly:
- Review the notebook index and the active task constitution before starting new work.
- Never edit the original source tree directly when the experiment is supposed to use an isolated workspace.
- If project files may change and the source is a git repository, create a dedicated git worktree in the experiment workspace first and do the edits there. If the source is not a git repository, copy it instead.
- Never let two active experiments write to the same worktree, checkout, branch working tree, or results directory.
- Treat parallel operations as potentially conflicting until the write scopes are proven disjoint.
- If multiple experiments touch the same upstream source, keep their workspaces separate and link them only through notebook metadata, not shared writes.
- Preserve append-only notebook history; record new state with new rows or child entries instead of rewriting prior conclusions.
- Before resuming or branching, summarize related entries so you understand what has already been tried and what constraints still apply.
- If the safe workspace strategy is unclear, pause and choose the safer option rather than writing into an ambiguous location.
- Keep secrets, auth state, and external credentials outside experiment artifacts unless the parent constitution explicitly allows otherwise.
- Treat provenance as best-effort only: external changes or deletions may still occur without labnb observing them.
- Do not perform notebook-managed deletions without explicit confirmation from the user.
- Unless absolutely necessary, do not run work blindly; instrument it well enough to inspect logs, checkpoints, progress, and resource consumption from outside the running process.
Before any action that writes, waits, launches background work, or hands off control:
- Review the parent constitution, notebook summary, and the entry-local rules/checklist plus
memory.md. - Confirm that you have actually completed those checks; do not rely on memory from an earlier step.
- If the local rules or checklist are stale, incomplete, or newly contradicted by the current situation, update them before proceeding.
- Check whether there is already a pending wait job for this entry before creating another one.
- Confirm the run is instrumented enough that you can inspect logs, checkpoints, progress, and resource usage periodically without guessing.
- If the action changes the local operating rules or durable memory, write the updated rules and memory back into the idea or experiment entry and note the change in
log.mdwhen applicable.
lab-notebook/
ideas/
<idea-id>/
metadata.json
idea.md
memory.md
provenance.jsonl
provenance.md
experiments/
<experiment-id>/
metadata.json
plan.md
memory.md
log.md
provenance.jsonl
provenance.md
results.tsv
summary.md
artifacts/
workspaces/
<experiment-id>/
index/
experiments.tsv
index.md
locks/
ideas/<idea-id>/: not-yet-started or not-yet-promoted experiment ideasexperiments/<experiment-id>/: one experiment per directory; no sharing across active runsprovenance.jsonl: best-effort append-only provenance log using W3C PROV-O terms for labnb-managed actionsprovenance.md: human-readable provenance policy and caveatsmemory.md: durable local memory that should be re-read and updated as rules, waits, or resume points changeexperiments/<experiment-id>/plan.md: the setup gate plus current hypothesisexperiments/<experiment-id>/results.tsv: local iteration ledger for this experimentworkspaces/<experiment-id>/: per-experiment working area for an isolated git worktree or copied source treeindex/experiments.tsv: append-only registry of ideas and experimentsindex/index.md: generated readable summary of known entrieslocks/: lock directories used for central updates
Each experiment id must be unique and stable:
<utc-timestamp>--<project-slug>--<experiment-slug>--<random-suffix>
Example:
20260411T154512Z--speech-foundations--prosody-ablation--a1b2c3d4
The random suffix is mandatory. A timestamp plus slug alone is not enough for parallel work.
- Resolve the global lab root.
- Review the parent constitution, project rules, and any task-specific guardrails that apply to this run.
- Derive a
project_slugfrom the current project, investigation, source tree, or working directory name. - Pick an
experiment_slugthat describes the current investigation. - Before creating a new experiment, summarize the existing notebook entries for the project:
python skills/labnb/scripts/summarize_index.py \
--lab-root "$LAB_ROOT" \
--project-slug "$PROJECT_SLUG"- Use that summary to decide whether to:
- resume an existing experiment
- promote an existing idea into an experiment
- create a child experiment from a prior run
- or start a new experiment
- Create the entry by running the helper:
python skills/labnb/scripts/register_experiment.py \
--lab-root "$LAB_ROOT" \
--project-root "$PWD" \
--project-slug "$PROJECT_SLUG" \
--experiment-slug "$EXPERIMENT_SLUG" \
--objective "Short statement of the experiment goal" \
--entry-kind experiment \
--metric-name "$METRIC_NAME" \
--direction "$DIRECTION" \
--verify-command "$VERIFY_COMMAND" \
--overall-budget "$OVERALL_BUDGET" \
--loop-budget "$LOOP_BUDGET" \
--source-id "$SOURCE_ENTRY_ID"- To record an idea that is not yet being run, use
--entry-kind ideaand omit experiment-only fields that are still unknown. - To promote an existing idea into a concrete experiment, use the dedicated helper:
python skills/labnb/scripts/promote_idea.py \
--lab-root "$LAB_ROOT" \
--idea-id "$IDEA_ID" \
--project-root "$PROJECT_ROOT" \
--experiment-slug "$EXPERIMENT_SLUG" \
--metric-name "$METRIC_NAME" \
--direction "$DIRECTION" \
--verify-command "$VERIFY_COMMAND" \
--overall-budget "$OVERALL_BUDGET" \
--loop-budget "$LOOP_BUDGET"- Experiments must be created with explicit
--overall-budgetand--loop-budget; do not leave them unspecified. - Use one or more
--source-idflags when an experiment stems from prior ideas or experiments. - Start the monitored loop slice before the first write-bearing iteration:
python skills/labnb/scripts/monitor_slice.py start \
--experiment-dir "$EXPERIMENT_DIR"- Use
monitor_slice.py checkbefore another iteration or long-running verify step, andmonitor_slice.py finishwhen the slice ends. - If the user wants the editable worktree or large outputs elsewhere, pass
--workspace-root "$WORKSPACE_ROOT"and let the notebook create a stable link underworkspaces/<experiment-id>/. - If code changes are involved and the source is a git repository, create a dedicated git worktree in the experiment's workspace before editing. If the source is not under git, copy it into the workspace instead.
- If multiple agents are working on the same codebase, each agent must use its own separate worktree location. Never share a single git worktree or checkout across active agents.
- Record baseline iteration
0inresults.tsvbefore code changes. - Work inside the returned experiment directory for notes, artifacts, and summaries.
- Log progress inside that experiment directory, not in shared files.
The skill has two kinds of configurable inputs: notebook root settings and per-experiment registration options.
LAB_NOTEBOOK_ROOT: override the default global notebook locationXDG_STATE_HOME: fallback base for the default notebook root whenLAB_NOTEBOOK_ROOTis unset
Use these helper flags when creating an experiment:
--lab-root: explicit notebook root--project-root: source tree or task directory being studied; optional for ideas that are still abstract or for work that will create a new repo later--project-slug: stable short name for the project--experiment-slug: short name for this idea or experiment entry--objective: concise goal statement--entry-kind:experimentoridea--status: optional explicit state; defaults tostartedfor experiments andideationfor ideas--metric-name: optional metric label--direction: optional optimization direction such ashigherorlower--verify-command: optional mechanical check command--overall-budget: required for experiments; total budget for the whole experiment path, including proposed follow-up or parallel work unless deferred--loop-budget: required for experiments; budget or timebox for the current loop or iteration slice--workspace-root: optional external root for the real workspace location--source-id: repeatable link to one or more upstream ideas or experiments that this run stems from--parent-id: optional parent experiment id for child experiments
If --metric-name, --direction, or --verify-command are omitted, the helper records TBD in plan.md. For experiments, --overall-budget and --loop-budget must be specified at creation time.
Recommended statuses include:
ideationplannedstartedstoppedbudget_exhaustedcompletedterminatedcrasheddeferredpromotedarchived
The summary helper also supports:
--lab-root: explicit notebook root--project-slug: project to summarize--limit: maximum number of recent matching entries to show
The slice monitor helper supports:
start: begin a monitored loop slicecheck: refresh elapsed state, evaluate break conditions, update status, and exit non-zero when it decides to breakfinish: close the active slice with a final status
monitor_slice.py check is the loop's circuit breaker. It reads the provenance state plus results.tsv (and, optionally, a con/duct usage log) and returns a decision of continue, warn, or break. On break it moves the entry to a terminal status and exits with a non-zero code (default 4) so a shell loop stops on its own:
while python skills/labnb/scripts/monitor_slice.py check \
--experiment-dir "$EXPERIMENT_DIR" \
--reserve-seconds 120 --patience 3 --stall-seconds 600 \
--max-failures 2 --usage-file "$DUCT_INFO_JSON"; do
run_one_iteration # observe -> modify -> verify -> keep/discard -> log
done # the loop ends the moment check decides to breakA check can break the slice for five classes of reason, not just elapsed time:
- Governance (
governancecategory, highest priority): the agent is unauthorized, policy-violating, or drifted from its approved definition. Point--governance-fileat a JSON verdict (decision/trust_score/drift) written by a governance tool such as thekyaskill;--min-trust-scoreand--break-on-driftturn it into breaks. labnb stays dependency-free and only consumes the verdict. This gate fails closed: once--governance-fileis set, a missing, unreadable, or malformed verdict is treated as ablockrather than silently skipped. - Budget (
budget): the loop or overall budget is spent. Use--reserve-secondsto break while slack remains for verification, logging, and summary, and--warn-fraction(default0.8) to get an advisorywarnbefore the cap. - Engineering (
engineering): the slice is too slow or wasteful even if time remains. Pace projection breaks when another iteration at the recent cadence will not fit the remaining loop budget (disable with--no-pace);--stall-secondsbreaks when no newresults.tsvrow has appeared for too long;--usage-filewith--max-rss-bytes/--max-pmembreaks on runaway memory read from a con/duct log. - Correctness (
correctness):--max-failuresbreaks after that many consecutive failed/crashed iterations. - Validity (
validity):--patiencebreaks when the metric has not improved for that many logged iterations (a plateau or drift, using the recordeddirection), and--metric-guardrailbreaks when the latest metric crosses a hard bound in the wrong direction.
When several conditions trip at once, governance outranks correctness, then budget, then engineering, then validity, and that primary reason chooses the terminal status (blocked for governance, crashed for correctness, budget_exhausted for budget, stopped otherwise). Override the status with --status-on-break, keep the legacy always-exit-0 behavior with --exit-zero, and treat a warn decision as advisory (it does not change status and exits 0). The full decision, signals, and diagnostics are written into the provenance state snapshot for later review.
Notes on the break semantics:
- A break does not close the slice. After handling it, call
monitor_slice.py finish(for example--final-status stoppedor--final-status crashed) before starting a new slice; a freshstarton an unclosed slice errors with "slice already running". - The per-slice signals (stall age, pace cadence, consecutive failures) are scoped to the rows logged at or after the current slice started, so a resumed slice is not penalized for a previous one. The no-improvement /
--patiencesignal is intentionally cumulative across the whole experiment — it asks whether the metric has improved at all lately. --patiencetreats a tie as non-improving (the comparison is strict). A long run of equal-metric iterations will therefore break as a plateau; raise--patience, or rely on--metric-guardrail, if tied-but-acceptable iterations should keep the loop alive.
For ideas:
metadata.json: creation metadata, status, budgets, provenance mode, and linkage to future workidea.md: rationale, prior evidence to revisit, pickup criteria for promotion, and entry-local rules/checklistmemory.md: durable memory for future pickup, waits, and resume conditionsidea.md: also carries entry-specific rules and a pre-action checklist that should be reviewed and updated as the idea evolvesprovenance.jsonl: append-only best-effort PROV-O event logprovenance.md: provenance rules and deletion policy
For experiments:
metadata.json: creation metadata, source path context, objective, ids, status, provenance mode, andsource_idsplan.md: goal, metric, direction, verify command, scope, next hypothesis, and entry-local rules/checklistmemory.md: durable memory for future pickup, waits, and resume conditionsplan.md: also carries entry-specific rules and a pre-action checklist that must be reviewed before each substantive actionlog.md: chronological notes for the experimentprovenance.jsonl: append-only best-effort PROV-O event logprovenance.md: provenance rules and deletion policyresults.tsv: one row per iteration or thought with status and metric outcomesummary.md: final concise outcomeartifacts/: scratch outputs, plots, reports, and temporary files worth keeping- dedicated workspace path: a safe place to edit without colliding with another agent's git state, preferably via a dedicated git worktree
- optional workspace link path under the notebook: a stable pointer when the real workspace lives elsewhere
Keep detailed notes local to the idea or experiment directory. The global index should stay compact.
Use the same tight loop pattern that powers autoresearch, but anchor it in the global notebook:
- Observe: run the index summary first if you have not already done so for this project, then read
plan.mdoridea.md,memory.md, especially the entry-specific rules and pre-action checklist, plus the tail oflog.md,results.tsv, and relevant project state. - Re-check the parent constitution and project rules before any write-bearing step.
- Start or check the monitored slice with
monitor_slice.py; use provenance as the source of truth for remaining time. - Confirm you are working inside the experiment's dedicated worktree if project files will change and the source is under git. Otherwise confirm you are in the copied workspace.
- Convert any user time budget into a bounded iteration plan:
- pick the smallest useful first slice
- define the checkpoint for continuing
- leave explicit slack for logging, verification, and handoff
- if no useful slice fits, record that the budget is insufficient
- if the task compares two alternatives by a metric, where one side may be one or more prior runs, plan the smallest route that can produce a trustworthy comparison even if the full loop is not finished
- Pick one focused change. Prefer atomic edits so the outcome is explainable.
- If tracked project files change, commit before verification so rollback is cheap.
- Run the verify command and capture the metric.
- if the metric comparison can be produced asynchronously, prefer launching the minimal measurement path plus an explicit wait/checkpoint over keeping the whole loop in the foreground
- if useful, delegate follow-up measurements or comparisons to subagents running in parallel experiments, but count the actual resource usage of those subagents against the stated budget
- Keep or discard:
- keep when the metric improves
- keep when the metric ties and the result is clearly simpler
- discard or revert when the metric regresses or the run crashes
- Log the outcome in both
results.tsvandlog.md. - Unless absolutely necessary, do not launch a long-running command blindly. Add enough logging, checkpointing, and external observability that you can inspect what it is doing while it runs.
- Before any background command or long-running job is left unattended, run
monitor_slice.py checkand decide whether the run needs a timer, watchdog, scheduler, or other explicit follow-up tied to the remaining budget. - Before scheduling any new wait job, check whether this experiment already has a pending timer, watchdog, scheduler entry, or other wait condition:
- if the existing wait already covers the needed follow-up, do not schedule a duplicate; just wait on the existing one
- if the new wait supersedes the old one, cancel or replace the earlier wait first
- never leave multiple overlapping wait jobs for the same experiment without a clear reason recorded in
log.md
- Probe the run periodically from outside the main process by checking logs, checkpoint files, progress signals, and resource/consumption indicators rather than assuming it is healthy.
- If no timer or watchdog is appropriate or available, do not leave the run implicitly hanging:
- finish the current slice with
monitor_slice.py finish --final-status stopped - record a resume checkpoint in
log.md - note what command to restart or re-check on resume
- Run
monitor_slice.py checkbefore continuing, andmonitor_slice.py finishwhen the slice ends. Pass the break conditions that matter for this run (--reserve-seconds,--patience,--stall-seconds,--max-failures,--metric-guardrail,--usage-file); ifcheckexits non-zero, stop the slice instead of starting another iteration. See "Breaking A Slice Early". - Decide whether another iteration is justified, rather than expanding work to fill the remaining budget.
- Repeat until
checkbreaks the slice, the stop condition is reached, the next checkpoint fails, or the user interrupts. A break can come from governance (unauthorized or drifted), budget, engineering (too slow, stalled, or resource-hungry), correctness (repeated failures), or validity (no improvement or a guardrail breach), not only from elapsed time.
When the work diverges materially, register a child experiment instead of overloading the current one.
Use time budgets to shape the experiment, not to maximize activity.
- A budget is a cap on work, not a requirement to use all allotted time.
- Prefer a plan with one informative first slice and one optional next slice over a long speculative roadmap.
- Reserve some of the budget for setup, verification, logging, and summarizing.
- Include any proposed parallel experiments, child experiments, or downstream follow-up in the same budget reality check unless you state clearly that they are outside the current budget.
- When an experiment draws on multiple ideas or prior runs, list all of them as source entries at creation time.
- If the likely useful first slice already exceeds the available budget, say the plan is not feasible as stated.
- If the task is a metric comparison between two alternatives, where one side may be represented by prior run or runs, prefer a shortest credible comparison path that can produce the decision asynchronously without requiring the entire loop to finish first.
- If parallel follow-up experiments are delegated to subagents, count their compute time, wait time, and any other meaningful resource usage against the same budget unless you explicitly scope them out as later work.
- If the task is open-ended, propose a shortest credible iteration path and stop at the first decision point.
- When reporting the plan, distinguish:
- what fits now
- what becomes possible only if the first slice succeeds
- what is out of scope for the current budget
- If a running slice exceeds its loop or overall budget, mark it explicitly as
budget_exhausted, summarize what completed, and record the next safe resume point instead of silently treating it as a normal stop.
The central index exists to answer: what ideas and experiments exist, where are they, and what are they about?
When creating or updating the shared index:
- Acquire
locks/index.lockusing an atomic directory create. - Append exactly one row per new idea or experiment to
index/experiments.tsv. - Rebuild
index/index.mdfromexperiments.tsvwhile the lock is held. - Write the regenerated markdown to a temp file and rename it into place atomically.
- Release the lock even on failure.
- Keep status current in new rows or explicit follow-up events rather than silently mutating history.
If a lock appears stale, only clear it after confirming the owning process is gone. Prefer waiting over forcing.
- Every active experiment gets its own directory.
- Two agents may read the same project, but they must not share the same new experiment directory.
- If two agents will both edit the same codebase, each one must create a separate git worktree under its own
workspaces/<experiment-id>/path. If git worktrees are unavailable, use separate copied workspaces instead. - If multiple agents need related work, give each one a new experiment id and link them in notes instead of co-writing.
- Treat
index/experiments.tsvas append-only history. - If an experiment needs a follow-up, create a child experiment and record the parent id in
metadata.jsonorlog.md.
When resuming:
- Run the summary helper or read
index/index.mdfor the project slug. - Decide whether the best pickup point is a planned idea, an active experiment, or a completed experiment worth branching from.
- Open the target idea or experiment directory.
- Continue writing only inside that directory unless you are registering a new idea or experiment.
- Register a fresh experiment instead of mutating old metadata if the scope or hypothesis changed materially.
- Prefer the helper script over handwritten lock logic when the script is available.
- If you need a quick view of the notebook, run
scripts/summarize_index.pyor readindex/index.mdfirst and only inspect specific entry directories afterward. - Before starting a new experiment, summarize relevant prior ideas and experiments and say where you are picking up from.
- When a run stems from multiple ideas or prior experiments, register all of them as
source_idlinks instead of collapsing them into a single parent. - Review the parent constitution and local project guardrails before planning or writing.
- Use the experiment's dedicated workspace path for editable project state; do not point multiple active agents at the same worktree.
- Prefer creating a dedicated git worktree in the experiment workspace before editing whenever the source tree is a git repository. If it is not, copy the source instead.
- Ask whether the workspace should live somewhere else when a source worktree, datasets, or generated artifacts would be better outside the notebook root.
- Re-use the same experiment directory for iterative logging, but create a new child experiment when you need a new loop with a new hypothesis or project state.
- Record unimplemented but promising directions as ideas instead of forcing them into active experiments.
- Track labnb-managed changes in provenance files, but say clearly that external changes may exist outside that record.
- Use W3C PROV-O terms in provenance records rather than ad hoc event fields.
- Use provenance as the source of truth for monitored slice state and remaining budget.
- Require explicit confirmation before deleting entry files, artifacts, or workspaces through labnb-driven actions.
- If the user gives a budget like "two hours," do not stretch the plan to fill two hours by default; start with the smallest decision-making slice and say when the budget is insufficient.
- If you propose parallel branches or downstream experiments, count them against the same stated budget unless you explicitly mark them as later follow-up outside the current scope.
- Before leaving a background command unattended, decide whether to start a timer, watchdog, scheduler, or follow-up hook that will check the run before the budget expires.
- Before submitting a new wait job, check for an existing pending wait for the same experiment and either reuse it or replace it; do not stack overlapping waits by default.
- Re-read and actively check off the entry-local rules/checklist before each substantive action rather than assuming you already satisfied them.
- When the local operating rules change, update
idea.mdorplan.mdso later steps inherit the new constraints instead of rediscovering them. - When facts, waits, resume points, or durable constraints change, update
memory.mdso later steps inherit the new memory instead of reconstructing it. - If two alternatives are being compared by a metric, and one side may be one or more prior runs, prefer designing the smallest trustworthy asynchronous comparison path and an explicit checkpoint rather than keeping the whole experiment loop running until a full conclusion.
- If parallel follow-up experiments would help, you may use subagents to run them as separate notebook experiments, but count their resource usage against the same budget unless the user explicitly scopes them out.
- Unless absolutely necessary, do not run things blindly; prefer enough logging, checkpointing, and external health checks to inspect logs, progress, and resource consumption periodically.
- When a verify command or long-running job should be measured, wrap it with the
ductskill so the experiment captures wall-clock time, CPU, and memory usage as structured logs that a later agent review can inspect. - When a run is unattended, monitor it from the outside by probing logs, checkpoint files, and resource/progress signals instead of assuming the internal process is behaving.
- If you cannot supervise or schedule a background command safely, stop the slice deliberately, write a resume checkpoint, and say exactly how to resume.
- If the time budget is exceeded, treat that as
budget_exhaustedby default, summarize partial results, and record whether the next step is resume, branch, or stop. - Keep instructions concise in user-facing updates; the notebook should do the long-term memory work.