Skip to content

MCP write tools in the background; legume-mcp 0.3; version 0.10.1 - #40

Merged
YPARK merged 4 commits into
mainfrom
mcp-jobs
Oct 20, 2026
Merged

YPARK merged 4 commits into
mainfrom
mcp-jobs

Conversation

@YPARK

@YPARK YPARK commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

What

  • background on every MCP tool that writes a backend (qc with out, import, subset, subsample, split, convert, merge). The step runs as a legume-mcp 0.3 job and the call returns {job, written, note} at once. Merge also returns batches and qc returns report. legume-mcp's job_status / job_wait / job_cancel follow the job, which is recorded in runall.sh and INDEX.tsv when it ends.
  • Outputs being written are claimed while the call runs, or, for a job, for as long as the server runs. Two unnamed jobs take two names, and a named output a job is writing is refused.
  • Background edge cases:
    • a subset's names file is kept for its job;
    • import checks its input exists before noting provenance;
    • qc refuses background on a dry run.
  • data-beans mcp watch: o opens a job's output once it exists.
  • legume-mcp 0.3 (it skips 0.2). Version 0.10.1: background is an MCP tool argument, not a CLI flag, subcommand or library API, so a patch.
  • README: the instructions block, the job tools, and how background writes behave.

Checks

  • tests/mcp_server.rs, a_write_in_the_background_returns_a_job_that_writes_it, covers:

    • subset by pattern and by names;
    • split;
    • two unnamed jobs at once;
    • a named output a job holds;
    • the steps in runall.sh;
    • the refused dry run and missing import.

    It fails with the names-file fix reverted, and with the claim's check removed.

  • cargo test --features sim, cargo fmt, and cargo clippy --all-targets --features sim: all clean.

YPARK added 2 commits October 20, 2026 14:52
…sion 0.11.0

qc (with out), import, subset, subsample, split, convert and merge take
`background`: the step runs as a legume-mcp job, and the call answers at
once with the job and the paths it will write; job_status, job_wait and
job_cancel (from legume-mcp) follow it. A job is recorded in runall.sh
and INDEX.tsv when it ends, like any other step.

Outputs being written, by a running call or a job, are claimed until the
call ends (for a job, while the server runs): an unnamed output takes the
next free name and a named one is refused, so no two writers share a
file. A subset's names file outlives the call for its job; an import's
input must exist before its provenance is noted; qc refuses `background`
on a dry run. The watch pane opens a job's output once it exists.
@YPARK YPARK changed the title MCP write tools in the background; legume-mcp 0.3; version 0.11.0 MCP write tools in the background; legume-mcp 0.3; version 0.10.1 Oct 20, 2026
@YPARK
YPARK merged commit 7521f9f into main Oct 20, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant