After the first useful result
Keep a model you can use again.
Start by answering your own passage with a saved program. If the computation needs to change, train a new profile and retain its parameters and supported continuation state. A task workflow then connects preparation, saved outputs and delivery.
PyTorch task workflows · arti-fit 3.3.0
Initialize an application task.
Create a project and prepare a stable snapshot of your inputs.
TRAINING & RECOVERYTrain with retained state.
Train toward your objective and keep supported checkpoints for the work that remains.
EVALUATION & DELIVERYDeliver the recorded output.
Save predictions, evaluate the outputs and export the files you need.
Your application owns the task.
Your model, data and objective. Your application defines the metrics and result format.
ARTI connects the retained state.
Preparation, checkpoints, committed predictions and selected exports retain the files needed by each stage.
Use a result that already exists.
The starter reloads two saved nonlinear reading programs. Paste a passage and ask questions on CPU. It includes an inference asset; it does not retrain or resume an optimizer.
Reading starter →Train when the component needs to change.
The complete reading cases declare the data split, native loss, saved program and GPU environment. Their independent reload and three-update continuation records show exactly what was checked.
Next: connect a full application task.
The chapters below use the installed package’s file-based tutorial to trace preparation, recovery, prediction and result delivery. Its small vector inputs keep every file easy to inspect. To train the reading model, follow the reading cases above; this generated file tutorial is a separate workflow example.
Before you begin
Initialize an application task.
Start in a fresh directory. The generated project includes application code, configuration and TUTORIAL.md, with the commands for each step below.
Read the official installed tutorial ↗my-task/ ├── project.json ├── code/task_app.py ├── configs/ ├── workflow.py ├── TUTORIAL.md ├── data/ │ ├── source/ │ ├── snapshot/ │ └── cache/ ├── runs/ └── artifacts/
python -m arti task init my-task --name "my task" --template files
cd my-task
python -m arti task check project.json
python -m arti task status project.json
python -m arti task explain project.jsontask check validates project declarations without running the task factory. status and explain inspect stage evidence. By contrast, recipe plan/check can construct a model through the explicit training factory.
01 / PREPARE
Prepare once. Reuse matching assets.
Keep logical records and physical files in an immutable snapshot. Your transform supplies decoding and preparation; its revision and options determine which committed cache entries can be reused.
The generated file tutorial has 12 records referring to 6 unique vectors. Its second preparation reuses the 6 matching entries. This is the official tutorial’s expected behavior, not a performance measurement from this website.
Detailed guidepython workflow.py prepare
python workflow.py prepareRETAINED IN THIS STAGE
data/source/Original records and declared binary files
data/snapshot/Portable, content-verified input identity
data/cache/Committed transform outputs for matching inputs
Execution boundaryThe application owns codecs, batching and transform semantics. Cache reuse requires matching content, revision and options.
02 / TRAIN
Keep your loss. Recover the original target.
Your task supplies the model, data and differentiable scalar objective. The shared training session owns backward, accumulation and optimizer steps. Recover from a completed checkpoint toward the original absolute update target.
A target of 200 updates with a checkpoint at 80 has 120 updates remaining. The coherent last training state is distinct from the validation-selected model used for prediction and export.
Detailed guidepython workflow.py train --stop-after 2
python -m arti task status project.json
python -m arti task explain project.json
python workflow.py recoverRETAINED IN THIS STAGE
runs/training/Original run, task contract and completed checkpoints
runs/recovered/A new attempt retaining the original target and lineage
Execution boundaryQualified recovery is local Torch or single-process Accelerate with supported tensor, optimizer, scheduler, RNG, data and validation state. Stop the earlier process before recovery.
03 / PREDICT
Commit outputs before reporting progress.
Package the selected model with the task’s declared reconstruction code and resources. Prediction pins the request IDs and publishes structured outputs, named files and a receipt as a committed part.
Resuming skips committed parts and runs the unfinished inputs. In the file tutorial, a part contains two records. An unpublished callback may execute again; result recovery does not imply physical exactly-once inference.
Detailed guidepython workflow.py package
python workflow.py predict --stop-after 1
python workflow.py predict --resume
python workflow.py predict --resumeRETAINED IN THIS STAGE
artifacts/deployment/Selected tensor state, task contract, code and resources
plan.json · predictions.jsonl · receiptPinned inputs and the committed output journal
Execution boundaryUse one local writer per journal. The predictor owns output meaning and file formats; declared batches preserve supported model state.
04 / EVALUATE
Measure saved results against independent references.
A suite reads committed outputs and runs application-owned views for task quality, file validity or declared external evidence. References are explicit inputs; the evaluator does not generate labels from model answers.
The tutorial evaluates all four requested IDs across the initial and recovered attempts. Coverage, measured metrics and threshold acceptance remain separate. Missing references are unavailable rather than invented zeros.
Detailed guidepython workflow.py evaluate
python -m arti task explain project.jsonRETAINED IN THIS STAGE
EvaluationSuiteConfigNamed views, scorer revisions and explicit criteria
.reports/<sha>.jsonContent-addressed history of evaluation reports
Execution boundaryScoring committed results does not reload the model or repeat prediction. A measured metric alone does not establish accepted task quality.
05 / RUNTIME
Reconstruct the task in a fresh local process.
The runtime uses the selected packaged entrypoint, code and resources in a compatible environment. The generated tutorial starts a fresh trusted local worker and writes a separate cold-prediction journal.
The consumer needs the declared dependencies installed. A runtime receipt records what that process actually ran; it does not make the operating system, network or hardware conditions universal.
Detailed guidepython workflow.py runtime
python workflow.py runtime --resumeRETAINED IN THIS STAGE
artifacts/cold-prediction/Independent packaged-runtime output journal
TaskRuntimeProfile · runtime receiptDeclared environment and observed worker execution
Execution boundaryOffline loading hints do not isolate sockets. A worker deadline applies to the direct worker; unsupported required enforcement is reported as not_run.
06 / EXPORT
Deliver the exact population, files and evidence.
Your writer chooses the result layout. Export verifies the original ID population and file closure, then carries the native outputs, selected deployment, evaluation and runtime receipts into a portable archive.
Inspection verifies the archive inventory, digests and declared results without importing model or writer code. Instructions and unresolved checks travel with the results so the consumer can see what still needs verification.
Detailed guidepython workflow.py export
python -m arti task status project.json
python -c "import arti; print(arti.inspect_result_export('artifacts/results.zip'))"RETAINED IN THIS STAGE
artifacts/results.zipFormatted results, native outputs and selected evidence
.arti-export/Provenance and checksummed file inventory
Execution boundaryExport does not train, predict, install dependencies or submit the archive. A portable task still requires its declared compatible environment.
CONTINUE BUILDING