diff --git a/.github/workflows/push.yaml b/.github/workflows/push.yaml index bf5b4c1..5b5325a 100644 --- a/.github/workflows/push.yaml +++ b/.github/workflows/push.yaml @@ -36,6 +36,12 @@ jobs: run: | pip install git+https://github.com/replicate/cog-safe-push.git + - name: "Inject secrets into cog-safe-push.yaml" + env: + HF_TOKEN: ${{ secrets.HF_WRITE_TO_TEST_FINE_TUNER_INTEGRATION }} + run: | + envsubst < cog-safe-push.yaml.tpl > cog-safe-push.yaml + - name: Run cog-safe-push to test the trainer and predictor and optionally push to production env: ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} diff --git a/cog-safe-push.yaml b/cog-safe-push.yaml.tpl similarity index 95% rename from cog-safe-push.yaml rename to cog-safe-push.yaml.tpl index bbf2a96..7615f93 100644 --- a/cog-safe-push.yaml +++ b/cog-safe-push.yaml.tpl @@ -112,8 +112,10 @@ train: # tiny training with autocaption - inputs: - input_images: "https://replicate.delivery/pbxt/LbXqvBzG3Bfo6CDkIkBNo8a8v6GWZGQrqxBrgeRpaQ1knkyD/me-tiny.zip" + input_images: https://replicate.delivery/pbxt/LbXqvBzG3Bfo6CDkIkBNo8a8v6GWZGQrqxBrgeRpaQ1knkyD/me-tiny.zip steps: 50 autocaption: true trigger_word: NDRS + hf_repo_id: replicate/test-flux-fine-tuner-integration + hf_token: "$HF_TOKEN" match_prompt: "A dictionary of a version and weights which are a .tar file"