logic-engine / examples /openclaw /ace-learn.sh
ghostdrive1's picture
Upload folder using huggingface_hub
116524e verified
Raw
History Blame Contribute Delete
717 Bytes
#!/bin/bash
# ace-learn — wrapper for learn_from_traces.py
#
# Writes skillbook output to the persistent workspace volume so it
# survives container restarts. The agent calls this as: ace-learn [args]
set -euo pipefail
# Resolve OPENCLAW_HOME once — the Python script also reads this env var
# to find the sessions directory. Without it, the script falls back to a
# path relative to its own location which is wrong inside Docker.
export OPENCLAW_HOME="${OPENCLAW_HOME:-$HOME/.openclaw}"
OUTPUT_DIR="$OPENCLAW_HOME/workspace/skills/kayba-ace"
mkdir -p "$OUTPUT_DIR"
cd /opt/ace
exec .venv/bin/python examples/openclaw/kayba-ace/learn_from_traces.py \
--output "$OUTPUT_DIR" \
"$@"