contribution.md
June 13, 2025 ยท View on GitHub
<file name=1 path=/Users/khuyentran/Data-science/contribution.md># Contribution Guidelines
Table of Contents
CodeCut Mission
CodeCut exists to help data scientists stay productive and up-to-date by delivering short, focused, and practical code examples that showcase modern tools in action.
We strive to:
- Help readers quickly understand what a tool does
- Show how it fits into real-world data science workflows
- Provide just enough to empower readers to try it on their own
Your Responsibility as a Writer
As a writer for CodeCut, your role is to:
- Break down complex tools and workflows into clear, digestible pieces
- Focus on practical value over theoretical depth
- Maintain a tone that is approachable, confident, and helpful
- Show rather than tell - use code snippets, visuals, or graphs to demonstrate your points
How to Write a Good Article
Good technical articles are:
- Easy to skim
- Broadly helpful
- Clear and concise
Follow the tips highlighted in How to Write Good Technical Articles to write a good article.
Write Article Draft
- Create your blog post in HackMD
- Follow these instructions to share your draft with khuyentran@codecut.ai for review
Write Code
Environment Setup
Install uv
uv is a fast Python package installer and resolver.
# Install uv
curl -LsSf https://astral.sh/uv/install.sh | sh
# Verify installation
uv --version
Install Dependencies
# Install dependencies from pyproject.toml
uv sync
Install Pre-commit Hooks
We use pre-commit to ensure code quality and consistency.
# Install pre-commit hooks
uv run pre-commit install
Working with Marimo Notebooks
Creating a New Notebook
Create a new notebook using marimo:
uv run marimo edit notebook.py --sandbox
Publishing Notebooks
To export your marimo notebooks to HTML locally:
-
Make sure the
export_notebook.shscript is executable:chmod +x export_notebook.sh -
Run the script with your notebook name:
# For notebooks in the root directory ./export_notebook.sh notebook_name # For notebooks in subdirectories ./export_notebook.sh path/to/notebook_nameFor example:
./export_notebook.sh data_science_tools/polars_vs_pandas ./export_notebook.sh llm/pydantic_ai_examples
The exported HTML files will be automatically deployed to GitHub Pages through the GitHub Actions workflow.
Pull Request Process
-
Fork the repository
# Click the "Fork" button on the repository's GitHub page # Then clone your forked repository git clone https://github.com/YOUR-USERNAME/REPOSITORY-NAME.git cd REPOSITORY-NAME -
Create a new branch for your feature
git checkout -b feature/your-feature-name -
Make your changes
# Make your code changes # Add your changes to staging git add . # Commit your changes git commit -m "Description of your changes" -
Pull the latest changes
# Pull the latest changes git pull origin main -
Submit a pull request
# Push your changes to your fork git push origin feature/your-feature-name # Then go to GitHub and click "Create Pull Request"