Skip to content

Add a figure to the descent direction example - #669

Merged
d-morrison merged 3 commits into
mainfrom
claude/mds646-descent-direction-fig
Nov 6, 2026
Merged

d-morrison merged 3 commits into
mainfrom
claude/mds646-descent-direction-fig

Conversation

@d-morrison

Copy link
Copy Markdown
Contributor

Requested by Ezra · project thread

Adds a figure to exm-descent-direction: the ratio f(x − 2sx)/f(x) = (1 − 2s)² against the step length s, with the line at ratio 1 and the too-long step s = 1.5 marked. R (ggplot2) and Python (matplotlib) tabs, nested in and cited from the example.

Part of #646.

Files:

  • _subfiles/vector-calc/_fig-descent-direction.qmd (new)
  • _subfiles/vector-calc/_exm-descent-direction.qmd

Rendered optimization-gradient-descent.qmd locally and checked the R figure.


Generated by Claude Code

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019xfc9pBmXswEX8Uu9Kt7f7
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019xfc9pBmXswEX8Uu9Kt7f7
@d-morrison d-morrison self-assigned this Nov 6, 2026
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019xfc9pBmXswEX8Uu9Kt7f7
@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

Claude finished review — View run


Review of PR #669 (commit 97aec0e0fc0027a44f26b2a1c50a8f4a5e457729)

The only change since the last round is commit 97aec0e, "Break the descent direction caption at clause boundaries". It touches _subfiles/vector-calc/_fig-descent-direction.qmd and re-wraps the two caption sentences. The wording and math are unchanged. I did not render the page or run the code chunks.

Prior blocking findings (from the 2026-11-06T03:10:52Z review):

  • Former :63 ("too long, since its ratio is 4"): fixed. The line now breaks after "long,", so the "since" clause has its own line.
  • Former :62 (several clauses on one line): fixed. The text now breaks after "(blue)", "below 1," and "so the step decreases $f$,". Each line holds at most one clause.

No new violations of the clause-level rule appear in the changed lines. The "since" clause and the "so" clause each start a line, and the sentence boundary starts a new line.

The prior round also left suggestions. They are non-blocking and still apply if the author wants to take them:

  • Rename the R chunk's odd scratch names (dd_s_dd and similar) to plain names.
  • Use semantic math macros for f, x and s where latex-macros/ defines them.
  • Note that the caption identifies the marked point by colour alone. The circle marker partly covers this.

Verdict

Ready for merge. Both prior blocking line-break findings are resolved in the current diff, and nothing new blocks.

Structured Review Data (JSON)
{
  "schema_version": "1.1",
  "reviewer": "claude",
  "commit_sha": "97aec0e0fc0027a44f26b2a1c50a8f4a5e457729",
  "verdict": "CLEAN",
  "findings": [],
  "detailed_assessment": "Commit 97aec0e re-wraps the two caption sentences in _fig-descent-direction.qmd at clause boundaries, resolving both prior line-break findings with no wording or math change.",
  "holistic_assessment": "The change is scoped to caption line breaks only; remaining prior suggestions on scratch names and semantic macros are non-blocking, and rendering was not validated."
}

Reviewed commit: 97aec0e

@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

💰 Cost: $0.1759 (review) — run

@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.2
🚀 Preview available at: https://Morrison-Lab.github.io/mds/pr-preview/pr-669/

Built to branch gh-pages at 2026-11-06 04:05 UTC.

Copy link
Copy Markdown
Contributor Author

Annotations reviewed: 97aec0e

All are platform notices (the ubuntu-latest migration, an empty SUBMODULES_TOKEN, a diff-highlight cap); none concern this change.


Posted by Claude Code (AI agent) --- not written by a human.
Generated by Claude Code


Generated by Claude Code

@d-morrison
d-morrison merged commit 63b009c into main Nov 6, 2026
45 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants