Conversation
* update * feat: add molexp run command with ExperimentDef and SLURM/molq support - Add ExperimentDef dataclass and standalone_run() helper in runner.py for declarative parameter sweep definitions with GridSpace support - Add top-level `molexp run` CLI command (renamed old sub-group to `runs` to free the name); supports --dry-run and --slurm flags - SLURM submission powered by molq plugin with inline CLI resource args (--partition, --gpus, --gpu-type, --mem, --time, --cpus, --account) instead of JSON resource files - Add RunContext.open(run_dir) classmethod for reconstructing full workspace hierarchy from a run directory path - Add dry_run: bool and labels: dict[str,str] fields to RunMetadata so dry-run records are visible in the UI with appropriate badge - Re-export ExperimentDef and standalone_run at molexp package level * refactor: architecture convergence to pydantic-graph + PydanticAI Major refactoring replacing the custom workflow engine with pydantic-graph based runtime, and adding PydanticAI-powered agent layer. - Replace workflow/compiler, engine, control, plugin with _pydantic_graph runtime - Add functional DSL (@wf.step) and OOP builder (WorkflowBuilder) APIs - Add agent layer (plugins/agent) with PydanticAI integration - Add remote execution plugins (SLURM/molq backends) - Restructure workspace layer (simplified Project/Experiment/Run) - Add ParamSpace (GridSpace, UniformSpace) to workspace - Update server routes and schemas for new architecture - Reorganize tests to mirror source structure - Update UI with AgentViewer, SnapshotViewer, mock handlers - Add CLAUDE.md, LICENSE, architecture docs - Add uv.lock for reproducible builds * refactor: establish lint/type baselines and remove dry_run late-bind Python: - Add ruff config (E/F/I rules) to pyproject.toml; fix all 46+32 issues (unused imports, unused vars, unsorted blocks, F821 WorkflowDeps) - Add ExecutionConfig(frozen dataclass) to workspace/models.py - RunContext: replace _execution_dry_run with _execution_config at construction time; remove _bind_execution_mode late-bind entirely - _execution_scope in GraphWorkflowRuntime: raises immediately when run_context + dry_run=True; creates RunContext(run, ExecutionConfig) directly instead of calling _bind_execution_mode post-construction - Run.start() always creates normal-mode RunContext; RunContext.open() restores dry_run from persisted metadata - Tests: RunContextStub no longer has _bind_execution_mode; new test asserts run_context+dry_run=True raises ValueError Frontend: - Add Biome 2.4.11 + biome.json; add lint/lint:fix/format/typecheck scripts - Fix 5 tsc errors (fixture type mismatch, unused vars, missing agent entry in metadata.ts, RendererEntry.Component return type) - Fix 144 Biome errors: noExplicitAny, noArrayIndexKey, noNonNullAssertion, useButtonType, a11y keyboard/role, useIterableCallbackReturn, noUselessFragments * fix: promote pydantic-graph to core dependency GraphWorkflowRuntime is the only concrete runtime implementation — keeping pydantic-graph as optional made pip install molexp silently unusable for any workflow execution. Also removed the dead _NotImplementedRuntime fallback and the now-empty [workflow] extra. * fix: tighten pydantic/pydantic-graph/pydantic-ai version floors Old lower bounds (>=0.0.20, >=2.5) accepted pre-1.0 releases that have completely incompatible APIs. Align with the 1.x series that the codebase is actually built and tested against. * chore: update backend, frontend, and tests * refactor: plugin-driven multi-backend CLI with no fake defaults - Replace monolithic `molexp run --slurm` with sub-app: `molexp run slurm/pbs/lsf` (auto-registered by submit_molq plugin) - DefaultLocalGroup auto-resolves `molexp run train.py` to local - All resource options Optional with no defaults (scheduler decides) - Rename plugins: agent → agent_pydanticai, new submit_molq - Delete plugins/remote/ (RunSubmission, ExecutionBackend, MolqBackend) - Plugin uses molq types (JobResources, JobScheduling) directly - Remove dead capabilities (REMOTE_EXECUTION, EXECUTION_BACKEND, TRANSFER) * feat: add --bg flag for background local execution molexp run train.py --bg forks a detached subprocess and logs to <workspace>/molexp_bg.log. Also adds cli/__main__.py for python -m molexp.cli invocation. * chore: remove tracked __pycache__ files These were committed before .gitignore had the __pycache__/ rule. * refactor: flat `molexp run SCRIPT --backend` CLI replacing subcommands Replace the `run local/slurm/pbs/lsf SCRIPT` subcommand tree with a single flat command: `molexp run SCRIPT [--local|--slurm|--pbs|--lsf]`. - Remove `_DefaultLocalGroup` hack and `run_cmd` sub-app - Delete `plugins/submit_molq/commands.py` (absorbed into cli/__init__.py) - Cluster backends imported lazily; molq is no longer required at import time - Options grouped via rich_help_panel into Backend / HPC / SLURM / PBS+LSF - Fix worker.py: move load_projects() inside RunContext to ensure FAILED status is written when script loading raises before the with-block - Update test to verify new grouped-panel help structure Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * replace logger and config with mollog and molcfg * fix: block mode prints OK after wait(), not before monitor panel * feat: split run dir into artifacts/ + logs/, add cancel and job-id tracking - workspace: introduce logs/ alongside artifacts/; error.txt moves out of artifacts (drops error.json since RunMetadata.error already captures it) - run: add update_job_ids() and cancel(); rename run dir to run-{id}; retry run.json load on Lustre/NFS to tolerate metadata-cache staleness - cli/server: surface cancel + slurm/molq job IDs; new /runs/{id}/logs and /runs/{id}/execution endpoints; UI RunViewer renders them Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix zombie * feat: add molq plugin runtime * update workspace model * improve ui * update molexp Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * refactor(submit_molq): move worker logic into molexp core - Add `RunMetadata.script` field: persisted at submit time so any node can reconstruct the full execution from run_dir alone. - Add `molexp execute <run_dir>` CLI command: loads the script, finds the matching workflow via `find_workflow_for_run()`, and runs it. This is the new worker entry point for cluster backends. - Add `entry.find_workflow_for_run()`: extracts the workspace-traversal logic from the old plugin worker into core where it belongs. - Simplify `SubmitHandler`: argv now calls `molexp execute <run_dir>`; removes the execution_id pre-computation that duplicated RunContext internals. stdout/stderr go to run_dir/{stdout,stderr}.log. - Delete `plugins/submit_molq/worker.py`: plugin now only handles scheduler interaction; all execution logic lives in core. - Drop `script` from `RunHandler` signature and all call sites. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * feat(workspace): track per-execution history and per-execution error files - Add ExecutionRecord to execution_history on every RunContext enter/exit - Generate execution_id (exec-{run_id}[-N]) that mirrors the workflow runtime - Write timestamped run.log entries for start and finish - Save error.txt under execution/{exec_id}/ instead of logs/ - Fix monitor.py: read cluster_name from executor_info dict Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * update cmd * build: switch to hatchling + manual npm build:ui, aligned with molvis Drop the custom setup.py build_py hook and MOLEXP_SKIP_UI_BUILD escape hatch. Frontend is now compiled by `npm run build:ui` (root workspace script) which populates src/molexp/_webapp/; hatchling packages it via the artifacts declaration. Release flow: `npm run build:ui && python -m build --wheel`. * ci: add pre-commit config and GitHub Actions CI workflow - ruff-format, ruff lint, ty type check on every commit - pytest matrix on Python 3.12/3.13 with coverage --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Document the component-library preference in the UI Layer section of CLAUDE.md so contributors know to reach for shadcn/ui first and to justify any deviation in the PR description. Closes #5
Contributor
Author
|
Closing as stale — this branch is 207 commits behind dev. Its CI/pre-commit commit is already on dev, and its only live content (the shadcn/ui CLAUDE.md note) is re-landed cleanly in #9. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Document a frontend component-library preference in
CLAUDE.md. Adds a short"Component library preference" subsection inside the existing UI Layer section
so contributors know to reach for shadcn/ui first and to justify any deviation
in the PR description.
Changes
CLAUDE.md— add 4 lines (one heading + two bullets + blank line) under the UI Layer section.Out of scope (per the issue)
shadcndependency added.Test plan
git diffshows only additions toCLAUDE.md.Closes #5