Skip to content

docs(dspy): fix the optimizers overview link on the BetterTogether page - #10253

Merged
isaacbmiller merged 2 commits into
stanfordnlp:mainfrom
saime428:docs-fix-bettertogether-optimizers-link
Aug 21, 2026
Merged

isaacbmiller merged 2 commits into
stanfordnlp:mainfrom
saime428:docs-fix-bettertogether-optimizers-link

Conversation

@saime428

Copy link
Copy Markdown
Contributor

📝 Changes Description

The "Further Reading" list at the bottom of the BetterTogether page pointed at ../../../learn/programming/optimizers.md. That path is wrong twice over. The optimizers overview lives under learn/optimization/, not learn/programming/, and from docs/api/optimizers/ a three-level prefix climbs above the docs root.

mkdocs leaves a relative link alone when it cannot resolve it, so the bad href goes straight into the built page. Building current main reports it:

WARNING -  Doc file 'api/optimizers/BetterTogether.md' contains a link
'../../../learn/programming/optimizers.md', but the target
'../learn/programming/optimizers.md' is not found among documentation files.

and the generated HTML keeps it verbatim, so the link 404s for anyone who clicks it:

<li><a href="../../../learn/programming/optimizers.md">DSPy Optimizers Overview</a></li>

This changes the target to ../../learn/optimization/optimizers.md, the same two-level form already used by api/utils/configure.md and api/utils/context.md. The link text stays as it was.

It is the only occurrence. grep -rn "learn/programming/optimizers" docs/ finds nothing else.

Validation, running what docs-push.yml runs (pip install -r requirements.txt then mkdocs build), before and after the change:

  • before: 247 warnings, including the one quoted above
  • after: 245 warnings, that one gone, nothing new introduced

The total drops by two rather than one because a second warning, a Discord badge request coming back 403, showed up only in the first run and has nothing to do with this change.

✅ Contributor Checklist

  • Pre-Commit checks are passing (locally and remotely)
  • Title of your PR / MR corresponds to the required format
  • Commit message follows required format {label}(dspy): {message}

⚠️ Warnings

Two things worth flagging.

No pre-commit hook covers markdown. ruff is scoped to ^(dspy|tests)/.*\.py$ and the rest of the hooks handle yaml, toml, large files, and merge markers, so the checklist item above is true but close to vacuous for this diff. The real check here was the docs build.

docs-push.yml runs a bare mkdocs build without --strict, which is why a broken link never failed CI. I left that alone on purpose. With 245 warnings still on main, most of them griffe complaining about docstring indentation, turning on strict mode would block the build immediately, and that is a maintainer decision rather than something to fold into a one-line docs fix.

The "Further Reading" link pointed at ../../../learn/programming/optimizers.md,
which is wrong twice over: the optimizers overview lives under
learn/optimization/, not learn/programming/, and from docs/api/optimizers/ the
three-level prefix climbs above the docs root. mkdocs left the href untouched in
the rendered page, so the link 404s for readers.

Point it at ../../learn/optimization/optimizers.md, matching the two-level form
already used in api/utils/configure.md and api/utils/context.md.
@greptile-apps

greptile-apps Bot commented Aug 21, 2026 •

Copy link
Copy Markdown
Contributor

Greptile Summary

The BetterTogether Further Reading link now uses the matching “Optimizers: choosing one” label and opens the live optimizer-selection guide. Rendered-browser validation confirmed that it no longer lands on the GEPA getting-started tutorial.

Confidence Score: 5/5

No blocking failure remains.

The rendered link and its destination were exercised successfully, and no accepted blocking findings remain.

T-Rex T-Rex Logs

What T-Rex did

  • T-Rex ran the requested general contract validation checks, but its local artifact references were not uploaded.

T-Rex Ran code and verified through T-Rex

Reviews (2): Last reviewed commit: "docs(dspy): point the further-reading li..." | Re-trigger Greptile

Comment thread docs/docs/api/optimizers/BetterTogether.md Outdated
The first pass only fixed the path, so the link resolved but landed on a
redirect stub: mkdocs.yml maps learn/optimization/optimizers.md to
getting-started/gepa-optimization.md, and the whole learn/ tree redirects into
getting-started/. A reader clicking "DSPy Optimizers Overview" ended up in the
GEPA tutorial instead of an overview.

Link diving-deeper/choosing-an-optimizer.md instead, which is live in the nav,
carries no redirect, and covers what each optimizer tunes and how to pick one.
The label now repeats that page's own title so the two cannot drift apart again.
@isaacbmiller
isaacbmiller merged commit 1fbfadf into stanfordnlp:main Aug 21, 2026
23 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