Mickey Petersen

1.9K posts

Mickey Petersen banner
Mickey Petersen

Mickey Petersen

@mickeynp

"Mastering Emacs" author; AI agent coding; 30 years of experience building software.

London Katılım Şubat 2011
411 Takip Edilen3.8K Takipçiler
Mickey Petersen
Mickey Petersen@mickeynp·
@wesbos who knows where it actually is. an nginx location directive is all it takes to put it anywhere in their interior infrastructure..
English
0
0
0
1.2K
Wes Bos
Wes Bos@wesbos·
Anyone else impressed nvidia got the install script on the main domain, root path? Imagine the meeting of lawyers, security and infra
Wes Bos tweet media
English
77
49
2.5K
289.2K
Mickey Petersen
Mickey Petersen@mickeynp·
@paradite_ and they will. openrouter's many open weight inference providers are nothing more than garbage amateur hour: broken tool calling templates; secret quantisation; wrong setup; and no caching (or they're not giving you the benefit of a kv hit.) it's a cosmic joke
English
0
0
1
114
Zhu Liang
Zhu Liang@paradite_·
token economics: chat sessions have different token patterns from agentic sessions. chat sessions are primarily output or cache write, as most tokens are generated by the model. agentic sessions are primarily cache read and output, as tool calls results are external and fed into model as input. inference provider needs to offer cheap input and cache read to optimize the cost of running agents.
English
1
0
1
289
Zhu Liang
Zhu Liang@paradite_·
quick tips on building agents: - rewrite your agent every 3 months or less - read system prompts every day and fix contradictions - write custom evals for your specific tasks - automate the improvement loop (logs to prompt) - less tools is better than more tools - different models need different tools - bash cli is better than tools - aggressively remove features that are not useful
English
1
3
17
4.9K
Zhu Liang
Zhu Liang@paradite_·
you want to build an agent? it’s easy, just learn: models, tools, prompts, harness, providers, api formats, multimodal, streaming, reasoning, sessions, compaction, handoff, token accounting, cli, mcp, embedding, skills, memory, abort controller, sse, process isolation, sandboxing.
English
52
25
250
20.5K
Mickey Petersen
Mickey Petersen@mickeynp·
@c4_cauliflower @LinkofSunshine This is the only correct answer in this thread. All those algo/DS books are not... useless... but they speak of a hypothetical world where you do not have to care about luxuries like L1-L3 cache coherency, RAM, bandwidth, NUMA, etc. Shame, really.
English
0
0
1
9
Coooooooolin
Coooooooolin@c4_cauliflower·
@LinkofSunshine They’re pretty rare in modern systems, not because self-balancing trees aren’t important, but because cache locality concerns have become the dominant practical performance bottleneck in most data structures, and simple trees have poor cache line properties.
English
2
0
1
437
Basil🧡
Basil🧡@LinkofSunshine·
So does anyone here actually use Red-Black Trees or did everyone just need to spend a month learning those
English
52
3
434
28.3K
Mickey Petersen
Mickey Petersen@mickeynp·
been trying to get claude to give me computer game suggestions and after a long back and forth it told me to go outside.
English
1
1
6
483
Mickey Petersen
Mickey Petersen@mickeynp·
@PeterB585337060 @JustDeezGuy @dcolascione glad you like it, Peter! oh i get the theory behind it. that bit's fine, but its importance is shadowed by incompetent user design and a "kernel workflow" that was never good to begin with, imho.
English
0
0
1
14
Peter B
Peter B@PeterB585337060·
Love your book. As for Git I found that I hated it much less when I sat down with the git-scm book and worked through it. It’s certainly got its warts, but most of the problems people have with it is that their mental model of it is somewhere around not even wrong. A DAG of (mostly) immutable filesystem states isn’t an inherently bad way to store a project history, even if there are perhaps better ones. It might have been better if it didn’t have an interface trying to trick people into thinking it’s distributed CVS.
English
1
0
2
25
Mickey Petersen
Mickey Petersen@mickeynp·
@dcolascione @JustDeezGuy I worked on MLOC code bases with idiots. Literal idiots; these people should've been wearing helmets. We somehow managed to merge work just fine. Regular merges + reintegration when that was added was adequate. But again: the merging mechanic could've been fixed also.
English
0
0
0
25
Mickey Petersen
Mickey Petersen@mickeynp·
@dcolascione @JustDeezGuy i don't like git. i'm not sure i ever have. and i'm still upset that the chattering macbook classes somehow convinced everyone that we must use it, even though it's a poorly-architected, user-hostile piece of software.
English
2
1
3
402
Filip Jerzy Pizło
Filip Jerzy Pizło@filpizlo·
This programming style: - Read code in Emacs - Write a `plan.txt` file in Emacs describing what to do (basically like a bug description for jira or bugzilla or whatever) - Open agent and say `execute plan.txt` - Review code in Emacs - Maybe tell the agent to do it differently, maybe not - git commit -m "more shit" - git push
English
17
3
131
19.5K
Mickey Petersen
Mickey Petersen@mickeynp·
@willmcgugan Conceptually a fast-moving stream of text may result in GC never triggering then? Should probably have an exit hatch for that scenario.
English
1
0
1
228
Will McGugan
Will McGugan@willmcgugan·
I had reports of brief freezes (sub 100ms) when scrolling very large documents in Textual (the type that agents produce). This was due to Python's Garbage Collection. To remedy this, I broke (good kind) reference cycles with weakrefs, which helped a lot. I've also added a switch to disable garbage collection while scrolling. Now scrolling remains smooth with large Markdown documents. The freezes were only evident when not running in Python 3.14, which improved GC performance a lot. Check out the video.
English
5
3
62
9.2K
Mustafa
Mustafa@oprydai·
I had this roommate in college who once coded a complete semester compiler project in C. he did it with the complete lexer and parser both, in a non-stop 14 hour session, and got an A on it. no college in the world can produce such talent now. this was pre-gpt era, in my 2nd semester.
English
21
31
1.2K
74.6K
Mickey Petersen
Mickey Petersen@mickeynp·
@_m27e @sertherk surprised there's that much perf bottlenecking this tbh. i am really surprised with p index on it. table stats ok/db tuned ok? anyway. nerd sniping. clickhouse for analytics is sane, not arguing that. thanks for humouring me, zeke.
English
0
0
2
172
Zeke Gabrielse
Zeke Gabrielse@_m27e·
@mickeynp @sertherk It doesn't matter if it's indexed or not, pg is terrible at this type of workload. I'm more praising Clickhouse than attacking pg, anyways. (And I did say "probably.")
Zeke Gabrielse tweet media
English
2
0
7
1.4K
Zeke Gabrielse
Zeke Gabrielse@_m27e·
Clickhouse is insane. Wrote this terrible query to sketch an idea and it completed in 2ms across 26M events. This query (probably) would've crashed pg.
Zeke Gabrielse tweet media
English
32
3
390
46.9K
Mickey Petersen
Mickey Petersen@mickeynp·
@_m27e going back to this: your choice of tech is not wrong for analytics. olap in pg is a bit of a minefield, even with small sub-billion tables. and clickhouse is great. but pg can do it, too, even with its shitty ~128MiB default working mem or whatever it is.
English
0
0
0
42
Zeke Gabrielse
Zeke Gabrielse@_m27e·
@mickeynp I was being hyperbolic. But I can guarantee you pg could not do this aggregation in any usable way. It can't even count in any usable way, which is why I'm pushing so much data into Clickhouse so that I can pull out analytics.
English
2
0
4
1.3K
Mickey Petersen
Mickey Petersen@mickeynp·
@_m27e @sertherk is that a full table scan? because it sure seems it. an index should speed that up assuming table stats are up to date. nobody's arguing that a columnar store is better at columnar stuff; my argument is that your claim that 'it'll crash pg' is as you said hyperbolic.
English
2
0
5
998
Mickey Petersen
Mickey Petersen@mickeynp·
@_m27e i very much doubt a small table of 26m rows will 'crash pg' because you aggregate on an unindexed json column. i'm not even sure the index would help here - it's not a scalar. does pg even inline json on the index itself if you had one? not even sure.
English
1
0
15
1.4K
Zeke Gabrielse
Zeke Gabrielse@_m27e·
@mickeynp Aggregating on an unindexed JSON column, for one. And counting -- pg sucks at counting.
English
2
0
10
3.1K
Mickey Petersen
Mickey Petersen@mickeynp·
@doodlestein ah great. sqlite's tests are private, so i figured you used sqlite to build a facsimile suite using it. but still, concurrent writes sorted? i'm impressed!
English
0
0
1
61
Jeffrey Emanuel
Jeffrey Emanuel@doodlestein·
@mickeynp Check the repo, there’s an ungodly amount of test code and crazy conformance harness and so forth.
English
1
0
3
217
Jeffrey Emanuel
Jeffrey Emanuel@doodlestein·
My FrankenSQLite project is rapidly approaching completion. In honor of that milestone, I created a nice website for the project that tries to explain in the most intuitive and visual way possible all of its cool technical innovations and advantages: frankensqlite.com
Jeffrey Emanuel tweet mediaJeffrey Emanuel tweet mediaJeffrey Emanuel tweet mediaJeffrey Emanuel tweet media
English
33
11
180
10.8K