Skip to content

docs: fix broken code examples in evaluating-a-custom-model.mdx - #1352

Open
mohansree14 wants to merge 1 commit into
huggingface:mainfrom
mohansree14:fix/custom-model-docs-syntax
Open

docs: fix broken code examples in evaluating-a-custom-model.mdx#1352
mohansree14 wants to merge 1 commit into
huggingface:mainfrom
mohansree14:fix/custom-model-docs-syntax

Conversation

@mohansree14

Copy link
Copy Markdown

Summary

Fixes #760.

The imports originally reported as missing (ParallelismManager, and the nonexistent EnvConfig) were already fixed on main. While re-verifying the examples actually run, I found two remaining breaks in the same file:

  • Python API example: tasks=truthfulqa:mc, is a SyntaxError — the task string wasn't quoted. Fixed to tasks="truthfulqa:mc",.
  • CLI example: the "wmt20:fr-de \ task argument's quote was never closed. Fixed to "wmt20:fr-de" \.

Test plan

  • Read through the fixed code blocks; both are now valid Python / shell syntax.
  • No functional code changed, docs-only.

- quote the unquoted tasks value in the Python API example (was a
  SyntaxError: tasks=truthfulqa:mc, -> tasks="truthfulqa:mc",)
- close the unterminated task string in the CLI example

Fixes huggingface#760
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.

[BUG] custom model docs don't run: missing imports

1 participant