Shortcuts

torchtune.data.GrammarErrorCorrectionTemplate

torchtune.data.GrammarErrorCorrectionTemplate = functools.partial(<class 'torchtune.data._prompt_templates.PromptTemplate'>, template={'user': ('Correct this to standard English: ', '\n---\nCorrected: ')})

A prompt template for grammar error correction tasks:

Correct this to standard English: {user_message}
---
Corrected: {assistant_message}

Please see PromptTemplate for full API arguments.

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources