Skip to content

Instantly share code, notes, and snippets.

View krishjainx's full-sized avatar

Krish Jain krishjainx

View GitHub Profile

Workflow Orchestration

1. Plan Node Default

  • Enter plan mode for ANY non-trivial task (3+ steps or architectural decisions)
  • If something goes sideways, STOP and re-plan immediately - don't keep pushing
  • Use plan mode for verification steps, not just building
  • Write detailed specs upfront to reduce ambiguity

2. Subagent Strategy

  • Use subagents liberally to keep main context window clean
@krishjainx
krishjainx / git-filter-repo
Created May 29, 2024 09:13
If you accidentally commit a sensitive file (like secret API key)
git filter-repo --invert-paths --path /path/to/file

To remove a specific file from every commit in your Git history:

  1. Execute the following command, replacing path_to_file with the actual path to the file you wish to remove:

    git filter-branch --index-filter "git rm -rf --cached --ignore-unmatch path_to_file" HEAD
  2. Once the file is successfully removed from your repository history, forcefully update your remote repository with:

@krishjainx
krishjainx / caffeine_absorbance_curve_fitting_and_visualization.py
Created February 1, 2024 18:41
Relationship between the concentration of caffeine and its absorbance measurement
from cProfile import label
import os
import sys
import matplotlib
import numpy as np
import matplotlib.pyplot as plt
from numpy import ones, vstack
from numpy.linalg import lstsq
import scipy
from scipy.optimize import curve_fit