~Don't~ Repeat Yourself

📰 Hugging Face Blog

The DRY principle in software development emphasizes avoiding repetition in code

intermediate Published 5 Apr 2022
Action Steps
  1. Understand the DRY principle and its importance in software development
  2. Identify areas in code where repetition can be avoided
  3. Apply the DRY principle by extracting common logic into reusable functions or modules
  4. Continuously review and refactor code to ensure adherence to the DRY principle
Who Needs to Know This

Software engineers and developers on a team benefit from following the DRY principle to write more efficient and maintainable code

Key Insight

💡 The DRY principle helps reduce code duplication and improves maintainability

Share This
💡 Don't repeat yourself! Follow the DRY principle for more efficient code #softwaredevelopment #DRYprinciple

Key Takeaways

The DRY principle in software development emphasizes avoiding repetition in code

Full Article

Published Time: 2022-04-05T00:00:00.064Z

# ~Don't~ Repeat Yourself

[![Image 1: Hugging Face's logo](https://huggingface.co/front/assets/huggingface_logo-noborder.svg)Hugging Face](https://huggingface.co/)

* [Models](https://huggingface.co/models)
* [Datasets](https://huggingface.co/datasets)
* [Spaces](https://huggingface.co/spaces)
* [Buckets new](https://huggingface.co/storage)
* [Docs](https://huggingface.co/docs)
* [Enterprise](https://huggingface.co/enterprise)
* [Pricing](https://huggingface.co/pricing)
*
*
* * *

* [Log In](https://huggingface.co/login)
* [Sign Up](https://huggingface.co/join)

[Back to Articles](https://huggingface.co/blog)

# [](https://huggingface.co/blog/transformers-design-philosophy#dont-repeat-yourself)~~Don't~~ Repeat Yourself*

Published April 5, 2022

[Update on GitHub](https://github.com/huggingface/blog/blob/main/transformers-design-philosophy.md)

[- [x] Upvote 55](https://huggingface.co/login?next=%2Fblog%2Ftransformers-design-philosophy)
* [![Image 2](https://cdn-avatars.huggingface.co/v1/production/uploads/5e3aec01f55e2b62848a5217/PMKS0NNB4MJQlTSFzh918.jpeg)](https://huggingface.co/lysandre "lysandre")
* [![Image 3](https://cdn-avatars.huggingface.co/v1/production/uploads/1649681653581-5f7fbd813e94f16a85448745.jpeg)](https://huggingface.co/sayakpaul "sayakpaul")
* [![Image 4](https://cdn-avatars.huggingface.co/v1/production/uploads/608aabf24955d2bfc3cd99c6/-YxmtpzEmf3NKOTktODRP.jpeg)](https://huggingface.co/ariG23498 "ariG23498")
* [![Image 5](https://cdn-avatars.huggingface.co/v1/production/uploads/61324ea4e24f4931e104df67/-9VVBX72zxiB2yTDeyJnn.jpeg)](https://huggingface.co/lilkm "lilkm")
* [![Image 6](https://cdn-avatars.huggingface.co/v1/production/uploads/623769abeddd7763adca040c/hkbFhpAPeWMPm_VxeQNhp.jpeg)](https://huggingface.co/TornikeO "TornikeO")
* [![Image 7](https://cdn-avatars.huggingface.co/v1/production/uploads/1674683851722-62441cb7456803e95009a08f.jpeg)](https://huggingface.co/ArthurZ "ArthurZ")
* +49

[![Image 8: Patrick von Platen's avatar](https://cdn-avatars.huggingface.co/v1/production/uploads/1584435275418-5dfcb1aada6d0311fd3d5448.jpeg)](https://huggingface.co/patrickvonplaten)

[Patrick von Platen patrickvonplaten Follow](https://huggingface.co/patrickvonplaten)

##### [](https://huggingface.co/blog/transformers-design-philosophy#designing-open-source-libraries-for-modern-machine-learning)_Designing open-source libraries for modern machine learning_

## * [🤗 Transformers Design Philosophy](https://huggingface.co/blog/transformers-design-philosophy#%F0%9F%A4%97-transformers-design-philosophy "🤗 Transformers Design Philosophy")
* [1. Built by and for the open-source community](https://huggingface.co/blog/transformers-design-philosophy#1-built-by-and-for-the-open-source-community "1. Built by and for the open-source community")

* [2. Modeling code is our product](https://huggingface.co/blog/transformers-design-philosophy#2-modeling-code-is-our-product "2. Modeling code is our product")

* [3. Machine Learning is evolving at a neck-breaking speed](https://huggingface.co/blog/transformers-design-philosophy#3-machine-learning-is-evolving-at-a-neck-breaking-speed "3. Machine Learning is evolving at a neck-breaking speed")

* [4. Machine Learning models are static](https://huggingface.co/blog/transformers-design-philosophy#4-machine-learning-models-are-static "4. Machine Learning models are static")

* [Drawbacks](https://huggingface.co/blog/transformers-design-philosophy#drawbacks "Drawbacks")

* [Conclusion](https://huggingface.co/blog/transformers-design-philosophy#conclusion "Conclusion")

[](https://huggingface.co/blog/transformers-design-philosophy#%F0%9F%A4%97-transformers-design-philosophy) 🤗 Transformers Design Philosophy

_"Don't repeat yourself"_, or **DRY**, is a well-known principle of software development. The principle originates from "The pragmatic programmer", one of the mo
Read full article → ← Back to Reads