Skip to content

Instantly share code, notes, and snippets.

View savarin's full-sized avatar

Ezzeri Esa savarin

  • San Francisco Bay Area
View GitHub Profile

ALICE

Review: Broaden _requires_full_refresh to check entire query tree

Summary

This PR simplifies _requires_full_refresh by replacing a targeted SELECT-projection-only check with a whole-query parsed.find(expression) search. The motivation is that Snowflake dynamic tables don't support change tracking for CURRENT_TIMESTAMP()/CURRENT_DATE/CURRENT_TIME anywhere in the query, not just in SELECT projections. The old code incorrectly allowed INCREMENTAL mode when these functions appeared in WHERE clauses.

This is a correctness fix — the old behavior could produce dynamic tables that Snowflake silently downgrades or errors on.

@savarin
savarin / pr_418_review.md
Created February 7, 2026 22:33
Review of PR #418

Review: PR #418 - Training Pipeline Hardening

This is a substantial and high-quality piece of engineering. It makes several critical improvements to the training pipeline that address real-world operational concerns. My review is strongly positive.

Summary

This PR hardens the nbcore training pipeline by tackling two fundamental issues: the risk of OOM errors from loading large training windows into memory, and the temporal information leakage from using a random train/test split.

It introduces:

  1. A week-by-week streaming pattern (stream_training_weeks) to cap peak memory usage.
import sys
DETAILS = {
2: [7, 5, "Introduction to Operating Systems", "https://pages.cs.wisc.edu/~remzi/OSTEP/intro.pdf"],
4: [6, 5, "The Abstraction: The Process", "https://pages.cs.wisc.edu/~remzi/OSTEP/cpu-intro.pdf"],
5: [7, 6, "Interlude: Process API", "https://pages.cs.wisc.edu/~remzi/OSTEP/cpu-api.pdf"],
6: [5, 12 ,"Mechanism: Limited Direct Execution", "https://pages.cs.wisc.edu/~remzi/OSTEP/cpu-mechanisms.pdf"],
7: [10, 5, "Scheduling: Introduction", "https://pages.cs.wisc.edu/~remzi/OSTEP/cpu-sched.pdf"],
8: [6, 5, "Scheduling: The Multi-Level Feedback Queue", "https://pages.cs.wisc.edu/~remzi/OSTEP/cpu-sched-mlfq.pdf"],
Question:
Is there a reason you switched from "interpretable" when there were 4 groups to
mean "there is only one way to do things and thus interpretable to humans", but
when there were 8 groups you mean "interpretable by the machine"?
Answer:
I apologize for any confusion caused. The term "interpretable" can be used in
different contexts and with different meanings. In the first categorization with
four groups, I used "interpretable" to refer to languages that are human
-readable and allow for clear understanding of the code's behavior. In the
Highly expressive: Ruby, Perl, PHP, JavaScript, Lua
Expressive: Python, Swift, F#
Balanced: Go, OCaml, Haskell, Scala, Elixir, Erlang, Julia
Interpretable: COBOL, Visual Basic, Python (again), Rust, Kotlin
Highly interpretable: C, Fortran, C++, Zig
Highly expressive and dynamic: Ruby, Perl, PHP
Highly expressive and static: TypeScript, Kotlin
@savarin
savarin / digital-rights-ledger.md
Last active November 3, 2021 22:04
The Blockchain as a Digital Rights Ledger

Date: 2014-09-09

I recently became interested in startups that are building a layer on top of the bitcoin ecosystem as a means to record digital rights. For example, an artist would create digital artwork and, by encoding in a message on the blockchain, assign her rights to the work to another party.

The blockchain appears to be the ideal ledger for this purpose. It is widely distributed and publicly available. More importably [sic], the record made on the ledger is, like the transfer of bitcoins, irreversible. It is worth asking how this method of recording digital rights would be treated at law.

For the purposes of our discussion, we will review English law. The Copyright, Designs and Patents Act 1988 (from here onwards, CPDA 1988) covers much of this area. A lot of standardisation has occurred under the aegis of the World Intellectual Property Organization (an arm of the UN), the World Trade Organization, as well as under EU Directives and Regulations. As such, a similar treatment is expected in most ju

Can money set you free?

By John Lanchester

Published: January 29 2010 16:50 | Last updated: January 29 2010 16:50

In 1982, partway through my first year at Oxford university, my father asked me a question that took me by surprise. He said, “Do you have enough money?”

It took me by surprise partly because it is somehow, in and of itself, a surprising question - not one that people often ask. What’s enough? We don’t ask ourselves that very often. I thought about what he’d asked for a moment and then said, truthfully, “I never think about money.” He laughed and said, “Then you’re rich.”

Custodians of the custard

By David Atkinson

Published: February 16 2007

Every morning at 7, a lone figure pushes open the blue iron door and enters the secret room of a Lisbon bakery. The door is then locked from the inside while the man gets to work with the secret recipe. There's only one escape clause: if the burden of guarding the recipe ever becomes too much and the man's heart should give way under the strain, an alarm system will manually override the system and release the door. The lone figure? One of only four so-called "secret masters", the revered confectioners who make Portugal's most celebrated - and imitated - patisserie, the revered pasteis de Belém.

The café/bakery, Antiga Confeitaria de Belém, is just down the road from the 16th-century Mosteiro dos Jerónimos in the Lisbon suburb of Belém and opposite the Monument to the Discoveries, which celebrates Lisbon's maritime connections. This is the place from which Vasco de Gama set off to discover the new world and where, according to history

Crisis of confidence

By Caroline Moorehead

Published: June 17 2005 14:48 | Last updated: June 17 2005 14:48

The first that Beatrice Megevand-Roggo knew about the leak was a call from The Wall Street Journal, late on the night of May 7 2004, when she was asleep in Geneva. A few days earlier CBS television had broadcast photographs of Iraqi prisoners being tortured and mocked by their US guards in Abu Ghraib prison in Baghdad. Megevand-Roggo works for the International Committee of the Red Cross (ICRC) in Geneva, and she and her staff had been visiting Abu Ghraib and other Iraqi prisons run by the Americans since the beginning of the occupation. The Wall Street Journal told her it was planning to publish the ICRC’s confidential report about these visits, leaked to it by an unnamed source, corroborating the scenes portrayed in the photographs. Had the ICRC in fact known all along, The Wall Street Journal asked, what was going on in Abu Ghraib? And if so, why hadn’t it spoken out?

Realising the delicacy of th

The cordon bleu kid

By Michael Steinberger

Published: March 1 2008 01:07 | Last updated: March 1 2008 01:07

On a visit to Boston last summer, just before our son’s birthday, my wife and I gave him the gift he most desired: we allowed James to eat his first raw clam, thus ending three years of simmering frustration for him.

True, he was only turning six, but that meant he had spent half his life pining for a taste of uncooked bivalves. His reaction, when the moment finally arrived, was unsurprising: he loved the clam, so much so that he proceeded to help himself to the five others on my plate and declared that henceforth I would need to order double the number so that he and I could each get our fair share. Between slurps, he reiterated his determination to eat that other long-forbidden fruit of the sea, raw oysters.