michael 📈 👨‍💻's Avatar

michael 📈 👨‍💻

@mikedecr.computer.bsky.social

Quant finance researcher/developer. Former political scientist, sometimes bike rider. Long form mikedecr.computer

221 Followers  |  234 Following  |  344 Posts  |  Joined: 12.07.2023
Posts Following

Posts by michael 📈 👨‍💻 (@mikedecr.computer.bsky.social)

TIL `[<-`, wish I hadn't

24.02.2026 02:52 — 👍 5    🔁 1    💬 1    📌 0

Why do I have to pretend that I'm going to print something in order to save it as a PDF. Why do I have to engage in a little ruse.

23.02.2026 21:43 — 👍 19129    🔁 2893    💬 344    📌 1

how broadly do they apply that title? I know a guy who used to be an "imagineer" and he was an actual robotics engineer. cool guy super smart

21.02.2026 02:14 — 👍 1    🔁 0    💬 0    📌 0

I simply love the striver / climber energy of tacking "engineering" onto any unsystematic concept. I will be having-3-beers engineering

20.02.2026 00:36 — 👍 8    🔁 0    💬 2    📌 0
AI changes *Nothing* — Dax Raad, OpenCode
YouTube video by AI Engineer AI changes *Nothing* — Dax Raad, OpenCode

forget about the clickbaity title, whatever, it's pragmatic reflection about what things LLM tools cannot just one-shot for you

www.youtube.com/watch?v=o3gm...

19.02.2026 01:50 — 👍 2    🔁 0    💬 0    📌 0

two priors, the easy mean is the risky mean + k and k has some positive value constraint

10.02.2026 03:27 — 👍 0    🔁 0    💬 0    📌 0

One relief about LLM tools for code is that programmers hold strong preferences as individuals but heterogeneous preferences as a population, and they are more temperamentally libertarian than other groups. So the marketplace for coding tools is usually pretty rich with high quality options

31.01.2026 17:15 — 👍 1    🔁 0    💬 0    📌 0
This is the only AI I want to use
YouTube video by The PrimeTime This is the only AI I want to use

Speaking of keeping the focus in the code, not the chat, I saw this clip of a new nvim pkg "99" that's more my style maybe. A prompt buffer appears only briefly, and you can still work while an LLM fulfills some request asynchronously.

youtu.be/ws9zR-UzwTE?...

31.01.2026 17:13 — 👍 0    🔁 0    💬 0    📌 1
Preview
GitHub - greggh/claude-code.nvim: Seamless integration between Claude Code AI assistant and Neovim Seamless integration between Claude Code AI assistant and Neovim - greggh/claude-code.nvim

And I guess it's easier with LLMs to create your own integrations.

For example this Claude \in Nvim pkg github.com/greggh/claud... lets you bind a fn to send a visual selection into the chat prompt. Stuff like that is good. I want to be in the code, not in the chat.

31.01.2026 17:13 — 👍 1    🔁 0    💬 1    📌 0

I wrote this 6 months ago and the pace at which CLI tools have been rolled out and publicized is making me feel a lot better about this. There's still a bit of friction when you want to pass context from your editor directly to the TUI that could benefit from more protocolization but not as bad

31.01.2026 16:51 — 👍 1    🔁 0    💬 1    📌 0

LLMs don't scare me, executives do

21.01.2026 01:44 — 👍 1    🔁 0    💬 0    📌 0

does any other marketing tactic threaten and bully me as much as LLM marketing? If software developers will really be irrelevant (any day now...) then it doesn't matter if I use your coding agent. If using your coding agents will make me more productive then software devs still matter. which is it

21.01.2026 01:28 — 👍 2    🔁 0    💬 1    📌 0

I need to be bombarded by unsolicited rage bait but in an ethical way

20.01.2026 00:22 — 👍 0    🔁 0    💬 0    📌 0
Screenshot of python code:

@dataclass
class CircuitNetwork:
    _circuits: list[Circuit]

    # idk if this is the best place for this method but oh well.
    def contains_link(self, a: Box, b: Box) -> bool:
        """True if a local circuit contains boxes A and B"""
        return any(a in circ and b in circ for circ in self._circuits)

    def attach(self, a: Circuit, b: Circuit) -> None:
        """Consolidates circuits A and B into a single circuit"""
        assert a != b, "Circuits must be distinct"
        assert a in self._circuits, f"Circuit {a=} is not in the network"
        assert b in self._circuits, f"Circuit {b=} is not in the network"
        self._circuits.remove(a)
        self._circuits.remove(b)
        self._circuits.append(a.union(b))

    def get_circuit(self, pt: Box) -> Circuit:
        """Returns the circuit containing provided Box"""
        for circ in self._circuits:
            if pt in circ:
                return circ

Screenshot of python code: @dataclass class CircuitNetwork: _circuits: list[Circuit] # idk if this is the best place for this method but oh well. def contains_link(self, a: Box, b: Box) -> bool: """True if a local circuit contains boxes A and B""" return any(a in circ and b in circ for circ in self._circuits) def attach(self, a: Circuit, b: Circuit) -> None: """Consolidates circuits A and B into a single circuit""" assert a != b, "Circuits must be distinct" assert a in self._circuits, f"Circuit {a=} is not in the network" assert b in self._circuits, f"Circuit {b=} is not in the network" self._circuits.remove(a) self._circuits.remove(b) self._circuits.append(a.union(b)) def get_circuit(self, pt: Box) -> Circuit: """Returns the circuit containing provided Box""" for circ in self._circuits: if pt in circ: return circ

I don't normally do really oop-y solutions to advent of code problems but it helped clean up the main fns a lot here

github.com/mikedecr/aoc...

19.01.2026 19:57 — 👍 1    🔁 0    💬 0    📌 0

I want politicians to care about today's kitchen-table issues like cable management. I didn't create the world where everything is powered by 3ft usb-c cables. Why should I bear the cost of its negative externalities entirely out of my own pocket?

16.01.2026 14:14 — 👍 0    🔁 0    💬 0    📌 0

permit me this one windmill: I have some obstinate anti-corporate, pro-flesh thing inside me that refuses to call it "AI". They are LLMs. Yes, I use LLM tools, but I don't do their marketing for them

16.01.2026 14:11 — 👍 0    🔁 0    💬 0    📌 0

im confident that i would thrive in a groundhog day type situation

09.01.2026 22:54 — 👍 138    🔁 17    💬 3    📌 0
def attach_interval(lst: list[Interval], new: Interval) -> list[Interval]:
    """Collapse interval `new` to the last element of `lst` if possible, otherwise append."""
    if len(lst) == 0:
        lst.append(new)
        return lst
    if (collapsed := maybe_collapse_intervals(lst[-1], new)):
        lst[-1] = collapsed
    else:
        lst.append(new)
    return lst

def attach_interval(lst: list[Interval], new: Interval) -> list[Interval]: """Collapse interval `new` to the last element of `lst` if possible, otherwise append.""" if len(lst) == 0: lst.append(new) return lst if (collapsed := maybe_collapse_intervals(lst[-1], new)): lst[-1] = collapsed else: lst.append(new) return lst

I suppose this is also less clunky then popping an element only to maybe re-append it

10.01.2026 03:24 — 👍 0    🔁 0    💬 0    📌 0
python code:

def maybe_collapse_intervals(left: Interval, right: Interval) -> tuple[Interval, ...] | None:
    """Return collapsed interval if possible, or None"""
    a, b = left
    x, y = right
    if a <= x <= y <= b:    # left contains right
        return (a, b)
    elif x <= a <= b <= y:  # right contains left
        return (x, y)
    elif a <= x <= b <= y:  # left straddles right lower bound
        return (a, y)
    elif x <= a <= y <= b:  # left straddles right upper bound
        return (x, b)
    else:
        return

python code: def maybe_collapse_intervals(left: Interval, right: Interval) -> tuple[Interval, ...] | None: """Return collapsed interval if possible, or None""" a, b = left x, y = right if a <= x <= y <= b: # left contains right return (a, b) elif x <= a <= b <= y: # right contains left return (x, y) elif a <= x <= b <= y: # left straddles right lower bound return (a, y) elif x <= a <= y <= b: # left straddles right upper bound return (x, b) else: return

de-structuring the tuples here creates a more pleasant reading experience

10.01.2026 03:21 — 👍 0    🔁 0    💬 1    📌 0
Python code:

@app.command()
def day_5_2(test: Flag("--test") = False):
    data_path: Path = Data(5, test=test)
    intervals_lst: list[Interval] = []
    with open(data_path, "r") as f:
        for line in f:
            if line == "\n":
                break
            interval: Interval = tuple(eval(chr) for chr in line.strip().split("-"))
            intervals_lst.append(interval)
    # with the intervals sorted, we can do this w/ reduce
    # fn: combine RIGHT w/ tail of LEFT or append RIGHT to LEFT
    intervals_lst.sort()
    collapsed_intervals: list[Interval] = reduce(attach_interval, intervals_lst, [])
    result: int = sum(1 + (right - left) for left, right in collapsed_intervals)
    print("solution:", result)

def attach_interval(lst: list[Interval], new: Interval) -> list[Interval]:
    """Collapse interval `new` to the last element of `lst` if possible, otherwise append."""
    if len(lst) == 0:
        lst.append(new)
        return lst
    end = lst.pop(-1)
    if (collapsed := maybe_collapse_intervals(end, new)):
        lst.append(collapsed)
    else:
        lst.append(end)
        lst.append(new)
    return lst

def maybe_collapse_intervals(left: Interval, right: Interval) -> tuple[Interval, ...] | None:
    """Return collapsed interval if possible, or None"""
    if left[0] <= right[0] <= right[1] <= left[1]:  # left contains right
        return left
    elif right[0] <= left[0] <= left[1] <= right[1]:  # right contains left
        return right
    elif left[0] <= right[0] <= left[1] <= right[1]:  # left straddles right lower bound
        return (left[0], right[1])
    elif right[0] <= left[0] <= right[1] <= left[1]:  # left straddles right upper bound
        return (right[0], left[1])
    else:
        return

Python code: @app.command() def day_5_2(test: Flag("--test") = False): data_path: Path = Data(5, test=test) intervals_lst: list[Interval] = [] with open(data_path, "r") as f: for line in f: if line == "\n": break interval: Interval = tuple(eval(chr) for chr in line.strip().split("-")) intervals_lst.append(interval) # with the intervals sorted, we can do this w/ reduce # fn: combine RIGHT w/ tail of LEFT or append RIGHT to LEFT intervals_lst.sort() collapsed_intervals: list[Interval] = reduce(attach_interval, intervals_lst, []) result: int = sum(1 + (right - left) for left, right in collapsed_intervals) print("solution:", result) def attach_interval(lst: list[Interval], new: Interval) -> list[Interval]: """Collapse interval `new` to the last element of `lst` if possible, otherwise append.""" if len(lst) == 0: lst.append(new) return lst end = lst.pop(-1) if (collapsed := maybe_collapse_intervals(end, new)): lst.append(collapsed) else: lst.append(end) lst.append(new) return lst def maybe_collapse_intervals(left: Interval, right: Interval) -> tuple[Interval, ...] | None: """Return collapsed interval if possible, or None""" if left[0] <= right[0] <= right[1] <= left[1]: # left contains right return left elif right[0] <= left[0] <= left[1] <= right[1]: # right contains left return right elif left[0] <= right[0] <= left[1] <= right[1]: # left straddles right lower bound return (left[0], right[1]) elif right[0] <= left[0] <= right[1] <= left[1]: # left straddles right upper bound return (right[0], left[1]) else: return

terminal input and output:

$ time uv run aoc day-5-2 
solution: 357907198933892
uv run aoc day-5-2  0.08s user 0.02s system 94% cpu 0.110 total

terminal input and output: $ time uv run aoc day-5-2 solution: 357907198933892 uv run aoc day-5-2 0.08s user 0.02s system 94% cpu 0.110 total

did I overly functionalize Day 5.2 or is this just the thing to do

10.01.2026 03:16 — 👍 0    🔁 0    💬 1    📌 0

I repudiate totally the name of the product "Liquid IV". You know what an IV is, right? It's already liquid. The core conceit of Liquid IV meanwhile is that it's a powder. It's Solid IV

02.01.2026 14:16 — 👍 2    🔁 0    💬 0    📌 0

i shall spare you from my blegh

01.01.2026 18:32 — 👍 1    🔁 0    💬 0    📌 0

any time a website is like "made with ❤ by <name>" I am like blegh

31.12.2025 22:17 — 👍 3    🔁 0    💬 1    📌 0

elderly math profs be like "ok let's say we have a matrix. and now we're going to bully this matrix"

20.12.2025 03:58 — 👍 4    🔁 0    💬 0    📌 0

join the vim gang and control everything

13.12.2025 17:44 — 👍 0    🔁 0    💬 1    📌 0

editing the clip: "hard rule: no statistics... it isn't worth it"

30.11.2025 17:53 — 👍 2    🔁 0    💬 0    📌 0

my worry is that this is good armor against slop only to the extent that people have collective energy to join hands and hate it together, which is a shaky foundation

09.11.2025 17:52 — 👍 0    🔁 0    💬 1    📌 0

the work is never done, matt

09.11.2025 16:58 — 👍 1    🔁 0    💬 0    📌 0
Post image Post image

One bewildering piece of condescending Apple UI is that, while you *can* attach files to iMessage, you can't do it with the obvious UI element that should do it.

If you're audacious enough to realize that your computer has these things called "files" there's drag-and-drop or the menu bar?

28.10.2025 23:40 — 👍 1    🔁 0    💬 0    📌 0

really excited for my gf's new iphone to arrive so I can finally rid our lives of lightning cables forever

28.10.2025 23:25 — 👍 2    🔁 0    💬 0    📌 0