apheris-foundry-cli 2.0.0__tar.gz → 2.1.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {apheris_foundry_cli-2.0.0/src/apheris_foundry_cli.egg-info → apheris_foundry_cli-2.1.1}/PKG-INFO +15 -1
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/README.md +14 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/pyproject.toml +1 -1
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1/src/apheris_foundry_cli.egg-info}/PKG-INFO +15 -1
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/foundry.py +16 -3
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/main.py +16 -11
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/skills/apheris-foundry-hub/SKILL.md +18 -0
- apheris_foundry_cli-2.1.1/src/apherisfold_cli/version.py +1 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_benchmark_examples.py +1 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_cli.py +103 -10
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_input_archive.py +5 -2
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_msa.py +4 -0
- apheris_foundry_cli-2.0.0/src/apherisfold_cli/version.py +0 -1
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/LICENSE +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/setup.cfg +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apheris_foundry_cli.egg-info/SOURCES.txt +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apheris_foundry_cli.egg-info/dependency_links.txt +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apheris_foundry_cli.egg-info/entry_points.txt +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apheris_foundry_cli.egg-info/requires.txt +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apheris_foundry_cli.egg-info/top_level.txt +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/__init__.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/__init__.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/compounds.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/login.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/settings.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/skills.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/weights.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/__init__.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/auth.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/config.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/context.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/documents.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/errors.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/hub_requests.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/input_archive.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/io.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/limits.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/login_profiles.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/msa.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/pubchem.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/render.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/result_artifacts.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/transient.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/handlers.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_auth.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_auth_lifecycle.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_config.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_documents.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_dry_run_guard.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_foundry_helpers.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_foundry_warnings.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_handlers.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_hub_requests.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_io.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_jobs_metadata.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_jobs_update.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_login_callback.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_main.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_model_discovery.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_pubchem.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_render.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_result_artifacts.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_skills.py +0 -0
- {apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/tests/test_weights.py +0 -0
{apheris_foundry_cli-2.0.0/src/apheris_foundry_cli.egg-info → apheris_foundry_cli-2.1.1}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: apheris-foundry-cli
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.1.1
|
|
4
4
|
Summary: Command-line interface for Apheris Foundry workflows.
|
|
5
5
|
Author: Apheris
|
|
6
6
|
License-Expression: LicenseRef-Apheris-Foundry-Software-License
|
|
@@ -532,3 +532,17 @@ that fewer rows were returned.
|
|
|
532
532
|
|
|
533
533
|
See [the usage guide](docs/usage.md#find-jobs)
|
|
534
534
|
for model, date, duration, and sorting options, which are hidden from default help.
|
|
535
|
+
|
|
536
|
+
### Research previews
|
|
537
|
+
|
|
538
|
+
Workflow and model listings mark early releases as **Research preview**. Workflow
|
|
539
|
+
and model details use this explanation:
|
|
540
|
+
|
|
541
|
+
> An early-access workflow, released so you can try it before it has been fully tested. You may run into issues. Your feedback helps us improve it.
|
|
542
|
+
|
|
543
|
+
Running a preview prints the same notice to stderr, including with
|
|
544
|
+
`--json`, so stdout remains machine-readable. The Hub's `researchPreview` boolean
|
|
545
|
+
is preserved in workflow/model JSON output; missing or false shows no label.
|
|
546
|
+
CLI-only access and preview status are independent.
|
|
547
|
+
Workflow discovery shows Hub's categories, tags, and UI mode. Local dry-runs do
|
|
548
|
+
not fetch preview metadata or print a preview notice.
|
|
@@ -506,3 +506,17 @@ that fewer rows were returned.
|
|
|
506
506
|
|
|
507
507
|
See [the usage guide](docs/usage.md#find-jobs)
|
|
508
508
|
for model, date, duration, and sorting options, which are hidden from default help.
|
|
509
|
+
|
|
510
|
+
### Research previews
|
|
511
|
+
|
|
512
|
+
Workflow and model listings mark early releases as **Research preview**. Workflow
|
|
513
|
+
and model details use this explanation:
|
|
514
|
+
|
|
515
|
+
> An early-access workflow, released so you can try it before it has been fully tested. You may run into issues. Your feedback helps us improve it.
|
|
516
|
+
|
|
517
|
+
Running a preview prints the same notice to stderr, including with
|
|
518
|
+
`--json`, so stdout remains machine-readable. The Hub's `researchPreview` boolean
|
|
519
|
+
is preserved in workflow/model JSON output; missing or false shows no label.
|
|
520
|
+
CLI-only access and preview status are independent.
|
|
521
|
+
Workflow discovery shows Hub's categories, tags, and UI mode. Local dry-runs do
|
|
522
|
+
not fetch preview metadata or print a preview notice.
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1/src/apheris_foundry_cli.egg-info}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: apheris-foundry-cli
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.1.1
|
|
4
4
|
Summary: Command-line interface for Apheris Foundry workflows.
|
|
5
5
|
Author: Apheris
|
|
6
6
|
License-Expression: LicenseRef-Apheris-Foundry-Software-License
|
|
@@ -532,3 +532,17 @@ that fewer rows were returned.
|
|
|
532
532
|
|
|
533
533
|
See [the usage guide](docs/usage.md#find-jobs)
|
|
534
534
|
for model, date, duration, and sorting options, which are hidden from default help.
|
|
535
|
+
|
|
536
|
+
### Research previews
|
|
537
|
+
|
|
538
|
+
Workflow and model listings mark early releases as **Research preview**. Workflow
|
|
539
|
+
and model details use this explanation:
|
|
540
|
+
|
|
541
|
+
> An early-access workflow, released so you can try it before it has been fully tested. You may run into issues. Your feedback helps us improve it.
|
|
542
|
+
|
|
543
|
+
Running a preview prints the same notice to stderr, including with
|
|
544
|
+
`--json`, so stdout remains machine-readable. The Hub's `researchPreview` boolean
|
|
545
|
+
is preserved in workflow/model JSON output; missing or false shows no label.
|
|
546
|
+
CLI-only access and preview status are independent.
|
|
547
|
+
Workflow discovery shows Hub's categories, tags, and UI mode. Local dry-runs do
|
|
548
|
+
not fetch preview metadata or print a preview notice.
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/foundry.py
RENAMED
|
@@ -40,6 +40,11 @@ from apherisfold_cli.core.render import command_examples
|
|
|
40
40
|
from apherisfold_cli.core.result_artifacts import extract_results_archive, validate_result_view
|
|
41
41
|
from apherisfold_cli.handlers import get_ctx, run_simple_listing
|
|
42
42
|
|
|
43
|
+
RESEARCH_PREVIEW_NOTICE = (
|
|
44
|
+
"Research preview: An early-access workflow, released so you can try it before it has been fully tested. "
|
|
45
|
+
"You may run into issues. Your feedback helps us improve it."
|
|
46
|
+
)
|
|
47
|
+
|
|
43
48
|
_CONSOLE = Console()
|
|
44
49
|
_TERMINAL_STATUSES = {"succeeded", "failed", "cancelled"}
|
|
45
50
|
_POLL_INTERVAL = 3.0
|
|
@@ -660,6 +665,9 @@ def foundry_run(
|
|
|
660
665
|
extra = {"upload": [str(path) for path in upload_sources]} if upload is not None else {}
|
|
661
666
|
_render_dry_run(body, title="Foundry Job Preview", json_output=json_output, **extra)
|
|
662
667
|
return
|
|
668
|
+
metadata = get_foundry_workflow(workflow)
|
|
669
|
+
if metadata.get("researchPreview") is True:
|
|
670
|
+
typer.echo(RESEARCH_PREVIEW_NOTICE, err=True)
|
|
663
671
|
resp = upload_foundry_run(body, upload) if upload is not None else create_foundry_run(body)
|
|
664
672
|
except CLIError as exc:
|
|
665
673
|
hint = msa_failure_hint(exc.message)
|
|
@@ -842,7 +850,7 @@ def _weight_label(weight: dict[str, Any]) -> str:
|
|
|
842
850
|
|
|
843
851
|
def _models_table(models: list[dict[str, Any]]) -> Table:
|
|
844
852
|
table = Table(box=box.SIMPLE_HEAD, show_header=True, padding=(0, 1), expand=True)
|
|
845
|
-
table.add_column("MODEL",
|
|
853
|
+
table.add_column("MODEL", overflow="fold", style="cyan")
|
|
846
854
|
table.add_column("WEIGHT", no_wrap=True, style="cyan")
|
|
847
855
|
table.add_column("SOURCE", no_wrap=True)
|
|
848
856
|
table.add_column("CAPABILITIES", overflow="fold")
|
|
@@ -852,7 +860,9 @@ def _models_table(models: list[dict[str, Any]]) -> Table:
|
|
|
852
860
|
if not weights:
|
|
853
861
|
note = model.get("metadataError") or "No selectable weights advertised."
|
|
854
862
|
table.add_row(
|
|
855
|
-
|
|
863
|
+
Text(
|
|
864
|
+
str(model.get("id", "")) + (" (Research preview)" if model.get("researchPreview") is True else "")
|
|
865
|
+
),
|
|
856
866
|
"",
|
|
857
867
|
"",
|
|
858
868
|
", ".join(_weight_capabilities(model, None)),
|
|
@@ -862,7 +872,9 @@ def _models_table(models: list[dict[str, Any]]) -> Table:
|
|
|
862
872
|
default_weight = default_model_weight(model)
|
|
863
873
|
for weight in weights:
|
|
864
874
|
table.add_row(
|
|
865
|
-
|
|
875
|
+
Text(
|
|
876
|
+
str(model.get("id", "")) + (" (Research preview)" if model.get("researchPreview") is True else "")
|
|
877
|
+
),
|
|
866
878
|
Text(f"{weight.get('version', '')}{' *' if weight is default_weight else ''}"),
|
|
867
879
|
_weight_source(weight),
|
|
868
880
|
", ".join(_weight_capabilities(model, weight)),
|
|
@@ -879,6 +891,7 @@ def _weight_detail(model: dict[str, Any], weight: dict[str, Any]) -> Table:
|
|
|
879
891
|
details.add_column("VALUE", overflow="fold")
|
|
880
892
|
for label, value in (
|
|
881
893
|
("MODEL", model.get("id")),
|
|
894
|
+
("STATUS", RESEARCH_PREVIEW_NOTICE if model.get("researchPreview") is True else None),
|
|
882
895
|
("WEIGHT", weight.get("version")),
|
|
883
896
|
("DEFAULT", "yes" if weight is default_weight else "no"),
|
|
884
897
|
("NAME", weight.get("name")),
|
|
@@ -21,6 +21,7 @@ from apherisfold_cli.commands import login
|
|
|
21
21
|
from apherisfold_cli.commands.compounds import app as compounds_app
|
|
22
22
|
from apherisfold_cli.commands.foundry import (
|
|
23
23
|
_DEFAULT_LIST_LIMIT,
|
|
24
|
+
RESEARCH_PREVIEW_NOTICE,
|
|
24
25
|
default_model_weight,
|
|
25
26
|
foundry_cancel,
|
|
26
27
|
foundry_delete,
|
|
@@ -366,18 +367,21 @@ def workflows_list_cmd(
|
|
|
366
367
|
table = Table(box=box.SIMPLE_HEAD, show_header=True, padding=(0, 1), expand=True)
|
|
367
368
|
table.add_column("WORKFLOW", style="cyan", no_wrap=True)
|
|
368
369
|
table.add_column("TITLE", overflow="fold")
|
|
369
|
-
table.add_column("
|
|
370
|
-
table.add_column("
|
|
371
|
-
table.add_column("
|
|
370
|
+
table.add_column("CATEGORIES", overflow="fold")
|
|
371
|
+
table.add_column("TAGS", overflow="fold")
|
|
372
|
+
table.add_column("UI MODE", no_wrap=True)
|
|
372
373
|
for workflow in workflows:
|
|
373
374
|
if not isinstance(workflow, dict):
|
|
374
375
|
continue
|
|
375
376
|
table.add_row(
|
|
376
377
|
str(workflow.get("id", "")),
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
378
|
+
Text(
|
|
379
|
+
str(workflow.get("title") or workflow.get("description") or "")
|
|
380
|
+
+ (" (Research preview)" if workflow.get("researchPreview") is True else "")
|
|
381
|
+
),
|
|
382
|
+
", ".join(workflow.get("categories") or []),
|
|
383
|
+
", ".join(workflow.get("tags") or []),
|
|
384
|
+
str(workflow.get("uiMode") or ""),
|
|
381
385
|
)
|
|
382
386
|
|
|
383
387
|
examples = Table(box=box.SIMPLE_HEAD, show_header=False, padding=(0, 1), expand=False)
|
|
@@ -410,10 +414,11 @@ def workflows_get_cmd(
|
|
|
410
414
|
info.add_row("ID", str(payload.get("id", "")))
|
|
411
415
|
info.add_row("Title", str(payload.get("title") or ""))
|
|
412
416
|
info.add_row("Description", str(payload.get("description") or ""))
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
info.add_row("
|
|
416
|
-
info.add_row("
|
|
417
|
+
if payload.get("researchPreview") is True:
|
|
418
|
+
info.add_row("Status", RESEARCH_PREVIEW_NOTICE)
|
|
419
|
+
info.add_row("Categories", ", ".join(payload.get("categories") or []))
|
|
420
|
+
info.add_row("Tags", ", ".join(payload.get("tags") or []))
|
|
421
|
+
info.add_row("UI mode", str(payload.get("uiMode") or ""))
|
|
417
422
|
|
|
418
423
|
models_value = payload.get("models")
|
|
419
424
|
models = models_value if isinstance(models_value, list) else []
|
|
@@ -69,6 +69,24 @@ Hub package deployment, not choosing one arbitrarily.
|
|
|
69
69
|
actual settings, artifact locations, and limitations; execution success alone
|
|
70
70
|
does not demonstrate a scientific improvement.
|
|
71
71
|
|
|
72
|
+
### Research previews
|
|
73
|
+
|
|
74
|
+
Workflow and model JSON may include `researchPreview: true`. When the selected
|
|
75
|
+
workflow or model has this flag, explain research preview using the same wording
|
|
76
|
+
as the Hub tooltip and CLI notice:
|
|
77
|
+
|
|
78
|
+
> An early-access workflow, released so you can try it before it has been fully tested. You may run into issues. Your feedback helps us improve it.
|
|
79
|
+
|
|
80
|
+
Carry that context into result summaries.
|
|
81
|
+
Missing or false means no preview label; it does not establish scientific validity.
|
|
82
|
+
Preview status is independent of `uiMode: "cli-only"` and is not a submission gate.
|
|
83
|
+
Continue within the user's authorized request without an extra confirmation.
|
|
84
|
+
|
|
85
|
+
The CLI labels previews in human-readable discovery output and prints a notice to
|
|
86
|
+
stderr when submitting a preview workflow, including with `--json`; stdout remains
|
|
87
|
+
machine-readable. Use the workflow/model JSON flag when interpreting structured
|
|
88
|
+
output. Local dry-runs skip the preview lookup and notice.
|
|
89
|
+
|
|
72
90
|
### MSA settings
|
|
73
91
|
|
|
74
92
|
Use `apheris-foundry settings msa list --json` to discover the current Hub's
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "2.1.1"
|
|
@@ -34,6 +34,7 @@ def submissions(monkeypatch):
|
|
|
34
34
|
"models": [{"id": "openfold3", "weights": [{"version": "0.3.0", "default": True}]}],
|
|
35
35
|
},
|
|
36
36
|
)
|
|
37
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
37
38
|
return calls
|
|
38
39
|
|
|
39
40
|
|
|
@@ -324,9 +324,9 @@ def hub_api_fixture(monkeypatch):
|
|
|
324
324
|
"id": "predict",
|
|
325
325
|
"description": "Predict structures",
|
|
326
326
|
"title": "Predict",
|
|
327
|
-
"
|
|
328
|
-
"
|
|
329
|
-
"
|
|
327
|
+
"categories": ["prediction"],
|
|
328
|
+
"tags": ["OpenFold3"],
|
|
329
|
+
"uiMode": "full",
|
|
330
330
|
"graph": {
|
|
331
331
|
"nodes": [
|
|
332
332
|
{"id": "v1", "label": "PREDICT_PREPROCESS"},
|
|
@@ -343,9 +343,9 @@ def hub_api_fixture(monkeypatch):
|
|
|
343
343
|
"id": "fragment-analysis",
|
|
344
344
|
"description": "Fragment analysis",
|
|
345
345
|
"title": "Fragment Analysis",
|
|
346
|
-
"
|
|
347
|
-
"
|
|
348
|
-
"
|
|
346
|
+
"categories": ["analysis"],
|
|
347
|
+
"tags": ["Fragment Model"],
|
|
348
|
+
"uiMode": "cli-only",
|
|
349
349
|
"graph": {
|
|
350
350
|
"nodes": [
|
|
351
351
|
{"id": "v1", "label": "FRAGMENT_PREPROCESS"},
|
|
@@ -494,8 +494,8 @@ def test_foundry_workflows_list_shows_mounted_workflows(hub_api_fixture) -> None
|
|
|
494
494
|
assert "Foundry Workflows" in result.stdout
|
|
495
495
|
assert "predict" in result.stdout
|
|
496
496
|
assert "fragment-analysis" in result.stdout
|
|
497
|
-
assert "
|
|
498
|
-
assert "
|
|
497
|
+
assert "Fragment Model" in result.stdout
|
|
498
|
+
assert "cli-only" in result.stdout
|
|
499
499
|
assert hub_api_fixture["list_foundry_workflows"] == [True]
|
|
500
500
|
|
|
501
501
|
|
|
@@ -505,8 +505,8 @@ def test_foundry_workflows_get_shows_workflow_contract(hub_api_fixture) -> None:
|
|
|
505
505
|
assert result.exit_code == 0
|
|
506
506
|
assert "Foundry Workflow" in result.stdout
|
|
507
507
|
assert "fragment-analysis" in result.stdout
|
|
508
|
-
assert "
|
|
509
|
-
assert "
|
|
508
|
+
assert "Fragment Model" in result.stdout
|
|
509
|
+
assert "cli-only" in result.stdout
|
|
510
510
|
assert "--param key=value" in result.stdout
|
|
511
511
|
assert "--model-params" not in result.stdout
|
|
512
512
|
assert hub_api_fixture["get_foundry_workflow"] == ["fragment-analysis"]
|
|
@@ -3058,3 +3058,96 @@ def test_foundry_workflows_run_points_to_possibly_created_job_after_5xx(
|
|
|
3058
3058
|
assert result.exception.code == 75
|
|
3059
3059
|
assert "The job may already exist" in result.exception.message
|
|
3060
3060
|
assert expected in result.exception.message
|
|
3061
|
+
|
|
3062
|
+
|
|
3063
|
+
@pytest.mark.parametrize("preview", [True, False, None])
|
|
3064
|
+
@pytest.mark.parametrize("with_weights", [True, False])
|
|
3065
|
+
def test_research_preview_in_workflow_and_model_discovery(hub_api_fixture, preview, with_weights) -> None:
|
|
3066
|
+
model = {"id": "example", "weights": [{"version": "base", "default": True}] if with_weights else []}
|
|
3067
|
+
workflow = {
|
|
3068
|
+
"id": "example",
|
|
3069
|
+
"title": "Example",
|
|
3070
|
+
"description": "Example workflow from the Hub catalog.",
|
|
3071
|
+
"categories": ["design"],
|
|
3072
|
+
"tags": ["RFD4-Proteina"],
|
|
3073
|
+
"models": [model],
|
|
3074
|
+
"uiMode": "cli-only",
|
|
3075
|
+
}
|
|
3076
|
+
if preview is not None:
|
|
3077
|
+
workflow["researchPreview"] = preview
|
|
3078
|
+
model["researchPreview"] = preview
|
|
3079
|
+
with (
|
|
3080
|
+
patch("apherisfold_cli.main.list_foundry_workflows", return_value={"workflows": [workflow]}),
|
|
3081
|
+
patch("apherisfold_cli.main.get_foundry_workflow", return_value=workflow),
|
|
3082
|
+
patch("apherisfold_cli.commands.foundry.get_foundry_workflow", return_value=workflow),
|
|
3083
|
+
):
|
|
3084
|
+
for args in (
|
|
3085
|
+
["list"],
|
|
3086
|
+
["get", "--workflow", "example"],
|
|
3087
|
+
["models", "--workflow", "example"],
|
|
3088
|
+
["models", "--workflow", "example", "--weight", "base"],
|
|
3089
|
+
):
|
|
3090
|
+
if "--weight" in args and not with_weights:
|
|
3091
|
+
continue
|
|
3092
|
+
result = runner.invoke(app, ["workflows", *args], env={"COLUMNS": "200"})
|
|
3093
|
+
assert result.exit_code == 0, result.output
|
|
3094
|
+
assert ("Research preview" in result.stdout) is (preview is True)
|
|
3095
|
+
if args[0] in {"list", "get"}:
|
|
3096
|
+
assert "design" in result.stdout
|
|
3097
|
+
assert "RFD4-Proteina" in result.stdout
|
|
3098
|
+
assert "cli-only" in result.stdout
|
|
3099
|
+
assert "PROFILES" not in result.stdout and "Profiles" not in result.stdout
|
|
3100
|
+
structured = runner.invoke(app, ["workflows", *args, "--json"])
|
|
3101
|
+
assert structured.exit_code == 0, structured.output
|
|
3102
|
+
payload = json.loads(structured.stdout)
|
|
3103
|
+
entry = payload["workflows"][0] if args[0] == "list" else payload
|
|
3104
|
+
if args[0] == "models":
|
|
3105
|
+
entry = entry["model"] if "--weight" in args else entry["models"][0]
|
|
3106
|
+
expected = model if args[0] == "models" else workflow
|
|
3107
|
+
if "--weight" in args:
|
|
3108
|
+
expected = {key: value for key, value in model.items() if key != "weights"}
|
|
3109
|
+
assert payload["weight"] == model["weights"][0]
|
|
3110
|
+
assert entry == expected
|
|
3111
|
+
assert entry.get("researchPreview") is preview
|
|
3112
|
+
|
|
3113
|
+
|
|
3114
|
+
@pytest.mark.parametrize("preview", [True, False, None])
|
|
3115
|
+
def test_research_preview_run_notice_keeps_json_stdout_clean(hub_api_fixture, preview) -> None:
|
|
3116
|
+
workflow = {"id": "example"}
|
|
3117
|
+
if preview is not None:
|
|
3118
|
+
workflow["researchPreview"] = preview
|
|
3119
|
+
with (
|
|
3120
|
+
patch("apherisfold_cli.commands.foundry.get_foundry_workflow", return_value=workflow),
|
|
3121
|
+
patch("apherisfold_cli.main.get_foundry_workflow", return_value=workflow),
|
|
3122
|
+
):
|
|
3123
|
+
result = runner.invoke(app, ["workflows", "run", "--workflow", "example", "--json"])
|
|
3124
|
+
assert result.exit_code == 0, result.output
|
|
3125
|
+
assert json.loads(result.stdout)["runId"]
|
|
3126
|
+
assert ("Research preview" in result.stderr) is (preview is True)
|
|
3127
|
+
assert len(hub_api_fixture["create_foundry_run"]) == 1
|
|
3128
|
+
|
|
3129
|
+
|
|
3130
|
+
@pytest.mark.parametrize("folder", [False, True])
|
|
3131
|
+
def test_local_dry_run_does_not_fetch_preview_metadata(hub_api_fixture, tmp_path, folder) -> None:
|
|
3132
|
+
request = tmp_path / "request.json"
|
|
3133
|
+
request.write_text("{}")
|
|
3134
|
+
with patch("apherisfold_cli.commands.foundry.get_foundry_workflow") as metadata:
|
|
3135
|
+
result = runner.invoke(
|
|
3136
|
+
app,
|
|
3137
|
+
[
|
|
3138
|
+
"--dry-run",
|
|
3139
|
+
"true",
|
|
3140
|
+
"workflows",
|
|
3141
|
+
"run",
|
|
3142
|
+
"--workflow",
|
|
3143
|
+
"example",
|
|
3144
|
+
"--input",
|
|
3145
|
+
str(tmp_path if folder else request),
|
|
3146
|
+
"--json",
|
|
3147
|
+
],
|
|
3148
|
+
)
|
|
3149
|
+
assert result.exit_code == 0, result.output
|
|
3150
|
+
json.loads(result.stdout)
|
|
3151
|
+
metadata.assert_not_called()
|
|
3152
|
+
assert hub_api_fixture["create_foundry_run"] == []
|
|
3153
|
+
assert hub_api_fixture["upload_foundry_run"] == []
|
|
@@ -59,7 +59,8 @@ def test_rejects_symlink_in_folder(tmp_path):
|
|
|
59
59
|
assert "links" in captured.value.message
|
|
60
60
|
|
|
61
61
|
|
|
62
|
-
def test_workflows_run_packages_folder(tmp_path):
|
|
62
|
+
def test_workflows_run_packages_folder(tmp_path, monkeypatch):
|
|
63
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
63
64
|
(tmp_path / "data.parquet").write_bytes(b"\xff\x00")
|
|
64
65
|
|
|
65
66
|
def upload(body, path):
|
|
@@ -101,7 +102,8 @@ def test_upload_body_can_be_replayed_after_auth_refresh(tmp_path, monkeypatch):
|
|
|
101
102
|
assert len(bodies) == 2
|
|
102
103
|
|
|
103
104
|
|
|
104
|
-
def test_zip_root_stripping_is_explicit(tmp_path):
|
|
105
|
+
def test_zip_root_stripping_is_explicit(tmp_path, monkeypatch):
|
|
106
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
105
107
|
path = tmp_path / "input.zip"
|
|
106
108
|
with zipfile.ZipFile(path, "w") as archive:
|
|
107
109
|
archive.writestr("expression/sample:treated.parquet", b"PAR1")
|
|
@@ -166,6 +168,7 @@ def test_old_timestamps_are_clamped(tmp_path):
|
|
|
166
168
|
|
|
167
169
|
|
|
168
170
|
def test_wait_removes_temporary_archive_before_polling(tmp_path, monkeypatch):
|
|
171
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
169
172
|
from apherisfold_cli.commands import foundry
|
|
170
173
|
|
|
171
174
|
(tmp_path / "data.bin").write_bytes(b"data")
|
|
@@ -184,6 +184,7 @@ def test_list_accepts_empty_catalog(monkeypatch, transport, raw):
|
|
|
184
184
|
|
|
185
185
|
@pytest.mark.parametrize("select_first", [False, True])
|
|
186
186
|
def test_run_leaves_msa_resolution_to_hub(monkeypatch, servers, tmp_path, select_first):
|
|
187
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
187
188
|
selections = []
|
|
188
189
|
submissions = []
|
|
189
190
|
monkeypatch.setattr(settings, "select_msa_server", selections.append)
|
|
@@ -253,6 +254,7 @@ def test_submission_preserves_hub_error_and_adds_msa_recovery(
|
|
|
253
254
|
calls.append(args)
|
|
254
255
|
raise error
|
|
255
256
|
|
|
257
|
+
monkeypatch.setattr(foundry, "get_foundry_workflow", lambda *_: {"id": "predict"})
|
|
256
258
|
monkeypatch.setattr(foundry, "upload_foundry_run" if upload else "create_foundry_run", reject)
|
|
257
259
|
monkeypatch.setattr(settings, "select_msa_server", lambda *_: pytest.fail("must not change settings"))
|
|
258
260
|
monkeypatch.setattr(msa, "list_msa_servers", lambda: pytest.fail("must not add a preflight request"))
|
|
@@ -273,6 +275,7 @@ def test_submission_preserves_hub_error_and_adds_msa_recovery(
|
|
|
273
275
|
|
|
274
276
|
|
|
275
277
|
def test_unrelated_submission_error_is_unchanged(monkeypatch, tmp_path):
|
|
278
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
276
279
|
error = CLIError(code=2, category="usage", message="Invalid request JSON.", task="foundry.runs.create")
|
|
277
280
|
|
|
278
281
|
def reject(*_):
|
|
@@ -332,6 +335,7 @@ def test_failed_job_diagnostics_offer_msa_recovery_only_when_relevant(monkeypatc
|
|
|
332
335
|
|
|
333
336
|
@pytest.mark.parametrize("json_output", [False, True])
|
|
334
337
|
def test_wait_for_missing_msa_failure_preserves_exit_and_json(monkeypatch, tmp_path, json_output):
|
|
338
|
+
monkeypatch.setattr("apherisfold_cli.commands.foundry.get_foundry_workflow", lambda workflow: {"id": workflow})
|
|
335
339
|
final = {"id": "failed-run", "status": "failed", "exitCode": 3, "error": "Missing required MSA files"}
|
|
336
340
|
monkeypatch.setattr(
|
|
337
341
|
"apherisfold_cli.commands.foundry.create_foundry_run", lambda _: {"runId": "failed-run", "status": "pending"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "2.0.0"
|
|
File without changes
|
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apheris_foundry_cli.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/__init__.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/compounds.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/login.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/settings.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/skills.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/commands/weights.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/documents.py
RENAMED
|
File without changes
|
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/hub_requests.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/input_archive.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/login_profiles.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/result_artifacts.py
RENAMED
|
File without changes
|
{apheris_foundry_cli-2.0.0 → apheris_foundry_cli-2.1.1}/src/apherisfold_cli/core/transient.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|