feat(argo): plumb --instrument-id flag through alpha-perception script + template
Adds new workflow parameter instrument-id (default empty string = no filter). Script forwards via --instrument-id CLI flag to alpha_train when non-empty. EXTRA_FLAGS template logic appends --instrument-id only when set. kubectl apply must run first (per feedback_argo_template_must_apply) so the cluster CRD reflects the new parameter before argo submit.
This commit is contained in:
@@ -66,6 +66,8 @@ spec:
|
||||
value: "1"
|
||||
- name: auto-horizon-weights
|
||||
value: "false"
|
||||
- name: instrument-id
|
||||
value: ""
|
||||
- name: early-stop-metric
|
||||
value: "mean_auc"
|
||||
- name: early-stop-patience
|
||||
@@ -445,6 +447,9 @@ spec:
|
||||
if [ "{{workflow.parameters.auto-horizon-weights}}" = "true" ]; then
|
||||
EXTRA_FLAGS="$EXTRA_FLAGS --auto-horizon-weights"
|
||||
fi
|
||||
if [ -n "{{workflow.parameters.instrument-id}}" ]; then
|
||||
EXTRA_FLAGS="$EXTRA_FLAGS --instrument-id {{workflow.parameters.instrument-id}}"
|
||||
fi
|
||||
|
||||
TRACE_FLAG=""
|
||||
if [ -n "{{workflow.parameters.kernel-step-trace-path}}" ]; then
|
||||
|
||||
@@ -35,6 +35,7 @@ CV_FOLD=0
|
||||
CV_N_FOLDS=1
|
||||
CV_TRAIN_WINDOW=0
|
||||
DECISION_STRIDE=1
|
||||
INSTRUMENT_ID=""
|
||||
WATCH=false
|
||||
|
||||
usage() {
|
||||
@@ -80,6 +81,7 @@ while [[ $# -gt 0 ]]; do
|
||||
--cv-n-folds) CV_N_FOLDS="$2"; shift 2 ;;
|
||||
--cv-train-window) CV_TRAIN_WINDOW="$2"; shift 2 ;;
|
||||
--decision-stride) DECISION_STRIDE="$2"; shift 2 ;;
|
||||
--instrument-id) INSTRUMENT_ID="$2"; shift 2 ;;
|
||||
--watch) WATCH=true; shift ;;
|
||||
-h|--help) usage; exit 0 ;;
|
||||
*) echo "Unknown option: $1"; usage; exit 1 ;;
|
||||
@@ -151,4 +153,5 @@ argo submit -n foxhunt --from=wftmpl/alpha-perception \
|
||||
-p cv-n-folds="$CV_N_FOLDS" \
|
||||
-p cv-train-window="$CV_TRAIN_WINDOW" \
|
||||
-p decision-stride="$DECISION_STRIDE" \
|
||||
-p instrument-id="$INSTRUMENT_ID" \
|
||||
$WATCH_FLAG
|
||||
|
||||
Reference in New Issue
Block a user