Love M&M's (Maths and Machines) 🧮🤖❤️ When the cost goes downhill, the mood goes uphill... 🫡 Making and breaking ML models !! 👨‍💻

Pale Blue Dot
Joined June 2022
Shubham Dhapola retweeted
Researchers used AI models trained on DNA to design new bacteriophages (viruses that infect bacteria) that target E. coli. From 11,000 AI-generated genome candidates, they filtered to 302 and successfully built 285. In lab tests, several new phages either killed resistant E. coli faster or multiplied more successfully than a standard phage. Learn more in The Batch: hubs.la/Q03Ms2L00
7
46
221
Shubham Dhapola retweeted
Real talk: I have no idea what to work on 😰 I spend a lot of time in Claude Code and Cursor IDE/CLI testing features and building proof of concepts and small apps for myself. With all this knowledge I think I could build something good and meaningful but struggling to find that spark of an idea… I make a little bit from ads on here and have side projects and property but nothing resembling fulfilling work with a product people would pay for. There are plenty of lucrative offers in my inbox to sponsor posts and emails and videos but it doesn't feel right for me to make money that way. Building is what makes me happy. I just don't know what to build. Anybody else hit a creative/idea block like this? There's no AI for that...
741
63
34
2,791
Shubham Dhapola retweeted
it’s always funny (and weird) to me how most computer/software engineers think that they’ve studied comp org and architecture and now they totally understand how computers work. it took me a semester of digital electronics and quantum mechanics to get a somewhat good understanding of how computers work but i’m still not fully there yet. very often when i’m on my laptop i’m just so fascinated that i’m living in an era where we have these machines and we’ve understood how they work and make them work as per our needs. just something like “oh this chip has billions of transistors on it” has become a mundane thing to say but if you think about it from a physical and engineering POV it just doesn’t make sense is almost magical. here’s to computers! 🫡
Shubham Dhapola retweeted
She broke up with me last week. Not because I cheated. Not because I was broke. Not even because I forgot her birthday. But because, in her words: “No matter what I do, you never change your direction.” At first, I thought she was just calling me stubborn. Then my inner math brain clicked... She was literally describing an eigenvector. See, in math, when you apply a transformation (matrix A) to a vector (v), most vectors get spun around, twisted, thrown somewhere else. They change direction and magnitude. But an eigenvector is different - it keeps the same direction. The only thing that changes is its scale, given by something called an eigenvalue (λ). If λ = 2 → The vector doubles in size. If λ = 0.5 → It shrinks. If λ = -1 → It flips direction. If λ = 1 → It stays the same size. Apparently… in her eyes, I was λ = 1. Always same size. Always same direction. Now the math part (because unlike my ex, I actually explain things): Here’s how you find eigenvalues and eigenvectors, using a 2×2 matrix example: Let’s say our “relationship matrix” was: A = [ 2 1 ] [ 1 2 ] Step 1: Find eigenvalues (λ) We solve: A·v = λ·v → (A − λI)·v = 0 → det(A − λI) = 0 Subtract λ from each diagonal entry of A: A − λI = [ 2−λ 1 ] [ 1 2−λ ] Set determinant = 0 and solve for λ: Determinant: (2−λ)(2−λ) − 1 = (2−λ)² − 1 = 0 (2−λ)² = 1 2−λ = ±1 Case 1: 2−λ = 1 → λ = 1 Case 2: 2−λ = −1 → λ = 3 So, eigenvalues are: λ₁ = 1, λ₂ = 3 Step 2: Find eigenvectors (v) For λ = 1: (A − λI)·v = 0 [ 2−λ 1 ] [ x ] = [ 0 ] [ 1 2−λ ] [ y ] [ 0 ] [ 2−1 1 ] [ x ] = [ 0 ] [ 1 2−1 ] [ y ] [ 0 ] [ 1 1 ] [ x ] = [ 0 ] [ 1 1 ] [ y ] [ 0 ] From the first row: x + y = 0 y = −x From the second row: x + y = 0 y = −x So eigenvector = any scalar multiple of [ 1, −1 ]ᵀ For λ = 3: (A − λI)·v = 0 [ 2−λ 1 ] [ x ] = [ 0 ] [ 1 2−λ ] [ y ] [ 0 ] [ 2−3 1 ] [ x ] = [ 0 ] [ 1 2−3 ] [ y ] [ 0 ] [ -1 1 ] [ x ] = [ 0 ] [ 1 -1 ] [ y ] [ 0 ] From the first row: −x + y = 0 y = x From the second row: x + (-y) = 0 x - y = 0 x = y So eigenvector = any scalar multiple of [ 1, 1 ]ᵀ Final result: λ = 1 → v = [ 1, −1 ] λ = 3 → v = [ 1, 1 ] Congratulations 🎉, you have just learned how to find the eigenvectors and eigenvalues of a matrix. Bonus: Why does AI-ML care? Eigenvalues & eigenvectors are everywhere in AI/ML: PCA → Reduce dimensions by keeping top eigenvectors of covariance matrix (largest eigenvalues = most variance). Spectral Clustering → Graph Laplacian eigenvalues help find clusters. Neural Stability → Eigenvalues of weight matrices can indicate exploding/vanishing gradients. Markov Chains → Long-term behaviour = eigenvector of eigenvalue 1. In short: Eigenvectors tell you the “unchangeable direction” under a transformation. Eigenvalues tell you “how much” that direction is stretched. In ML, this is how we find patterns, compress data, and understand model behaviour. I am waiting for a matrix that multiplies me by λ > 1 and actually makes me grow.
Shubham Dhapola retweeted
I'm noticing that due to (I think?) a lot of benchmarkmaxxing on long horizon tasks, LLMs are becoming a little too agentic by default, a little beyond my average use case. For example in coding, the models now tend to reason for a fairly long time, they have an inclination to start listing and grepping files all across the entire repo, they do repeated web searchers, they over-analyze and over-think little rare edge cases even in code that is knowingly incomplete and under active development, and often come back ~minutes later even for simple queries. This might make sense for long-running tasks but it's less of a good fit for more "in the loop" iterated development that I still do a lot of, or if I'm just looking for a quick spot check before running a script, just in case I got some indexing wrong or made some dumb error. So I find myself quite often stopping the LLMs with variations of "Stop, you're way overthinking this. Look at only this single file. Do not use any tools. Do not over-engineer", etc. Basically as the default starts to slowly creep into the "ultrathink" super agentic mode, I feel a need for the reverse, and more generally good ways to indicate or communicate intent / stakes, from "just have a quick look" all the way to "go off for 30 minutes, come back when absolutely certain".
783
796
210
10,481
Shubham Dhapola retweeted
Replying to @ChefGruel
This is a power grab masquerading as progress. They’re not trying to solve a food shortage. They’re trying to engineer one. You take something nature gives freely, that millions of small farmers can produce without permission, and you replace it with something that requires corporate labs, IP protections, and centralized distribution. That flips butter from a commodity anyone can make into a proprietary product controlled by a handful of actors. Once they own the source code for your food, they can alter it, gate it, and revoke access at will. Tie it to ESG compliance, health passports, carbon credits – and suddenly eating becomes conditional. The moment you accept synthetic replacements for staples, you accept a kill switch over your diet. This is the same playbook as fiat money and central banking – replace something real with something they can conjure, manipulate, and weaponize. The goal isn’t to make butter without cows. The goal is to make humans without sovereignty.
Shubham Dhapola retweeted
New fastest shortest-path algorithm in 41 years! Tsinghua researchers broke Dijkstra’s 1984 “sorting barrier,” achieving O(m log^(2/3) n) time. This means faster route planning, less traffic, cheaper deliveries, and more efficient networks - and a CS curriculum revamp =)
Shubham Dhapola retweeted
I am an expert on bubbles. So it brings me no joy to say that the AI bubble is popping this time next year. When you promise infinite scaling and don’t produce it the calculus changes. I don’t think it will be bad for most companies but those who built their entire business model around making the best LLMs are unfortunately going to struggle as models become more of a commodity. The end user doesn’t care much if Claude is 5% better than GPT5 they care about costs, speed, and utility especially at the scale things will be going. The obvious play now is shorting Nvidia & dumping your OpenAI options in the secondary market. The new winners will be inference chips with low TCO as everything on the stack turns into commodity network switches and NICs. Other winners will be those who are at the new frontiers of using AI for novel applications from drug development to teaching.
Shubham Dhapola retweeted
Replying to @far__el
Right — throwing more compute at current LLM architectures is like bolting a rocket to a sailboat: you’ll go faster, but you’re still bound by the design limits of the hull. The missing ingredient isn’t “just scale,” it’s core capabilities that the architecture itself doesn’t have. Here’s what’s fundamentally absent: 1. Persistent, Structured Memory What we have now: Context windows — they remember what’s in the conversation or the prompt, and then forget. Even retrieval-augmented setups (RAG) are “memory prosthetics,” not truly integrated recall. What’s missing: A lifetime memory system where the AI can store, index, and organically use knowledge from past interactions, experiences, and sensory input the way a human recalls relevant events. Without this, an LLM can’t build a personal world model or improve through lived experience — every “session” is amnesia. 2. Grounded Understanding What we have now: Statistical pattern-matching over text, optionally with multimodal inputs. What’s missing: Direct grounding in the physical world — sensors, embodiment, and the ability to map symbols (“apple,” “gravity”) to real, verifiable referents. Without grounding, “understanding” remains word-shape mimicry. An AGI needs to validate concepts against reality, not just other sentences. 3. Agency and Goal Formation What we have now: Models that follow instructions but have no intrinsic goals. What’s missing: The machinery to set, maintain, and adapt long-term goals based on changing circumstances. Agency requires self-driven action selection, not just responding to prompts. That means integrating reasoning loops, memory, and world modeling into a control system. 4. Causal Reasoning (Not Just Correlation) What we have now: Prediction of “what word comes next” — which is correlation-heavy and shallow for cause-effect reasoning. What’s missing: Explicit causal models that can answer why something happened and simulate “what if” scenarios. Humans do this naturally; LLMs are mostly locked to correlation patterns. 5. Self-Reflection and Metacognition What we have now: Imitation of self-reflection (“Let’s think step by step”), but no real introspective loop to inspect its own reasoning, debug itself, or test hypotheses against experience. What’s missing: A true metacognitive layer — the ability to watch itself think and improve its strategies over time. 6. Continual Learning Without Catastrophic Forgetting What we have now: Offline training that freezes weights until retrained. Fine-tuning risks overwriting old knowledge. What’s missing: A brain-like system for continuous online learning that integrates new knowledge without erasing old capabilities. 7. Emotion / Value Systems for Decision Weighting What we have now: Pretense of empathy and ethics through training on human data. What’s missing: An internal value structure that guides trade-offs, prioritizes goals, and influences decision-making the way emotions guide human reasoning. 💡 In short: Current LLMs are brilliant linguistic mirrors. AGI needs more — a unified architecture with memory, grounding, causal reasoning, goal systems, and continual self-improvement. Without these, no amount of GPUs will cross the gap from mimicry to autonomous intelligence.
7
8
1
52
Shubham Dhapola retweeted
How many more model releases do we need for folks to realize we are not getting to magical superintelligence with what we got? How many times do you have to see a model benchmaxxing to realize Humanity's Last Exam is a freaking idiotic name and that answering questions on it doesn't tell us shit about the true intelligence of the model? How many models do we have to see demonstrating superficial intelligence but utterly failing at long running, contextual understanding for people to wake up and realize that AI is just another tool? A good tool, a useful tool, a wonderful tool but not magic and not the end of all jobs and not the end of humanity or any other absurd fantasy of fools and dreamers. Fool me once, shame on you. Fool me twice, shame on me.
Shubham Dhapola retweeted
Rob Pike is one of my top 5 programmer heroes, but I have no idea what he was thinking when he designed Go.
173
49
50
2,122
Shubham Dhapola retweeted
A deep dive into one of the most under appreciated parts of the modern financial system: FTP’ing files between financial institutions and their clients. A thread.
19
112
32
1,087
Shubham Dhapola retweeted
i work at meta. hr systems. mostly comp processing. quiet job. stable. sometimes i daydream about retiring in portugal. today a package hit my queue. base + bonus + equity. looks normal at first glance. then i open the details. $1,000,000,000 over four years. plus signing. plus year 1 minimum: $100m. i stare at it like it’s a typo. check the name. triple check the level. researcher. coolcoolcool. so now i have to enter this into workday. i paste the first number, field throws an error.“value must be below $99,999,999.” lol. okay. i try splitting it. base in one bucket, equity in another. nope. i try scientific notation. it rounds it down. the system can’t HANDLE a billion dollars. i call someone on payroll infra. tell them i’ve got a 10-digit comp packet. they think i’m joking. i forward the req. they go quiet. “we’re gonna need to escalate this,” someone mutters. “to who?” i ask. “god, maybe.” next thing i know zuck’s chief of staff is in the thread. now i’m in a thread with zuck. because of a number. then i find out the guy declined the offer. just said no. no negotiation. no counter. just… no. i’ve been maxing out my 401k for 11 years & this man said no to a billion dollars like he was skipping dessert. i close the ticket. delete the draft. go for a walk. & then i rethink everything.
Shubham Dhapola retweeted
🚨: The closest star to the Sun is 4 light-years away. Voyager has traveled for nearly 50 years — and still hasn't travelled one light-day.
Shubham Dhapola retweeted
PSA if you haven't used python in the past 5 years it's a completely new language now - uv solved the package management problems entirely - mypy type checks have become actually useful - cpython is now much faster - polars + fastapi + ruff replaced pandas + flask + black
Shubham Dhapola retweeted
When you put a webserver up on the internet. anywhere, hosting anything, you will see "the background radiation of the internet", and it looks like this:
Shubham Dhapola retweeted
Hit me with one harsh truth you've accepted so far as a man.
Shubham Dhapola retweeted
I have a very zoomer / junior question Back before kuberneyney and containers, what were the common practice for server to deal with app when it crashed? Do they just use systemd / scripts to recover it?
Shubham Dhapola retweeted
if your AI girlfriend is not a LOCALLY running fine-tuned model, she’s technically a prostitute
218
686
159
13,014
Shubham Dhapola retweeted
Becoming an RL diehard in the past year and thinking about RL for most of my waking hours inadvertently taught me an important lesson about how to live my own life. One of the big concepts in RL is that you always want to be “on-policy”: instead of mimicking other people’s successful trajectories, you should take your own actions and learn from the reward given by the environment. Obviously imitation learning is useful to bootstrap to nonzero pass rate initially, but once you can take reasonable trajectories, we generally avoid imitation learning because the best way to leverage the model’s own strengths (which are different from humans) is to only learn from its own trajectories. A well-accepted instantiation of this is that RL is a better way to train language models to solve math word problems compared to simple supervised finetuning on human-written chains of thought. Similarly in life, we first bootstrap ourselves via imitation learning (school), which is very reasonable. But even after I graduated school, I had a habit of studying how other people found success and trying to imitate them. Sometimes it worked, but eventually I realized that I would never surpass the full ability of someone else because they were playing to their strengths which I didn’t have. It could be anything from a researcher doing yolo runs more successfully than me because they built the codebase themselves and I didn’t, or a non-AI example would be a soccer player keeping ball possession by leveraging strength that I didn’t have. The lesson of doing RL on policy is that beating the teacher requires walking your own path and taking risks and rewards from the environment. For example, two things I enjoy more than the average researcher are (1) reading a lot of data, and (2) doing ablations to understand the effect of individual components in a system. Once when collecting a dataset, I spent a few days reading data and giving each human annotator personalized feedback, and after that the data turned out great and I gained valuable insight into the task I was trying to solve. Earlier this year I spent a month going back and ablating each of the decisions that I previously yolo’ed while working on deep research. It was a sizable amount of time spent, but through those experiments I learned unique lessons about what type of RL works well. Not only was leaning into my own passions more fulfilling, but I now feel like I’m on a path to carving a stronger niche for myself and my research. In short, imitation is good and you have to do it initially. But once you’re bootstrapped enough, if you want to beat the teacher you must do on-policy RL and play to your own strengths and weaknesses :)