diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d931cba..f2a2af0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,9 @@ on: schedule: - cron: "0 3 * * 1" # Run every Monday 3 am +permissions: + pull-requests: write + jobs: ci: runs-on: ubuntu-latest @@ -62,10 +65,15 @@ jobs: publish_branch: gh-pages keep_files: true # Retain other content on gh-pages - - name: Add PR comment with preview link + - name: Add PR note if: github.event_name == 'pull_request' - run: | - echo "Deployed [https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }}/pr-${{ github.event.pull_request.number }}/](temporary docs)." + uses: marocchino/sticky-pull-request-comment@v2 + with: + message: | + ### :books: Docs + + Created [https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }}/pr-${{ github.event.pull_request.number }}/](temporary docs). + diff --git a/mkdocs.yml b/mkdocs.yml index 7a77ab3..f3a73c8 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -45,6 +45,7 @@ nav: - Decision Making: - Value Iteration: notebooks/mdp_value_iteration.ipynb - Q-Learning: notebooks/mdp_q_learning.ipynb + - Policy Gradient: notebooks/mdp_policy_gradient.ipynb - API Documentation (partial): reference/ plugins: diff --git a/notebooks/mdp_policy_gradient.ipynb b/notebooks/mdp_policy_gradient.ipynb index 004fe14..66ac7f8 100644 --- a/notebooks/mdp_policy_gradient.ipynb +++ b/notebooks/mdp_policy_gradient.ipynb @@ -62,7 +62,7 @@ "model_checkpoints = policy_gradient(\n", " mdp=grid_mdp,\n", " policy=policy,\n", - " iterations=100,\n", + " iterations=10,\n", " return_history=True,\n", ")" ] @@ -107,7 +107,7 @@ " w = ipywidgets.interactive(plot_policy_step_grid_map, iteration=iteration_slider)\n", " display(w)\n", "else:\n", - " plot_policy_step_grid_map(100)" + " plot_policy_step_grid_map(10)" ] }, { @@ -161,7 +161,7 @@ "model_checkpoints = policy_gradient(\n", " mdp=highway_mdp,\n", " policy=policy,\n", - " iterations=200,\n", + " iterations=20,\n", " return_history=True,\n", ")" ] @@ -205,7 +205,7 @@ " w = ipywidgets.interactive(plot_policy_step_grid_map, iteration=iteration_slider)\n", " display(w)\n", "else:\n", - " plot_policy_step_grid_map(200)" + " plot_policy_step_grid_map(20)" ] } ],