Homepage: eli.thegreenplace.net/
Amazing systems programming tutorials. Whenever you Google a hard topic, his blog comes up.
Also has many great contributions on Stack Overflow: stackoverflow.com/users/8206/eli-bendersky
As of 2016, Eli worked at Google (reference). TODO before that, I had found his earlier info previously but lost it.
Eli focuses mostly on compiler toolchains.
He also has some mathematics stuff, so cute: eli.thegreenplace.net/2015/change-of-basis-in-linear-algebra/
Possibly not made not possible from userland due to privacy issues. Apparently not even kernelland can see it, only
Bibliography:
- Stack Overflow:
- stackoverflow.com/questions/35934729/capture-fingerprint-from-smartphone-and-save-to-a-file
- stackoverflow.com/questions/63257762/how-to-save-and-compare-2-fingerprints-on-android
- stackoverflow.com/questions/67104186/can-we-use-android-fingerprint-scanner-to-get-finger-pattern-and-store-that-patt
- stackoverflow.com/questions/41632225/android-where-and-how-securely-is-fingerprint-information-stored-in-a-device
- android.stackexchange.com/questions/161780/where-does-android-store-fingerprint-data
- Reddit:
Author of gwern.net.
Accounts:He posts insanely much on these websites. It's a bit like Ciro Santilli on Stack Overflow.
- news.ycombinator.com/user?id=gwern
- www.lesswrong.com/users/gwern LessWrong
- twitter.com/gwern locked 2021: www.reddit.com/r/slatestarcodex/comments/kp2fek/does_anybody_know_what_happened_to_gwern/
- www.reddit.com/user/gwern/
- en.wikipedia.org/wiki/User:Gwern on Wikipedia. Self summary: gwern.net/wikipedia-resume. Also he is a critic of deletionism on Wikipedia like Ciro Santilli
Ciro Santilli envies this guy a bit. He dumps his brain more or less full time on his highly customized static website partly due to early Bitcoin investments gwern.net/me says:
Also unsurprisingly he likes Haskell:
I mostly contribute to projects in Haskell, my favorite language
Ciro Santilli considers Gwern Ciro Santilli's e-soulmates due to his interest in "dark web things" like Bitcoin and Silk Road, his immense writing output in encyclopedic book-sized articles on a static website, and his desire to live frugally and just research and write all day. Ah, if only Ciro had some old coins!!!
This is likely a pseudonym, his real name not being publicly unknown, e.g. at news.ycombinator.com/item?id=5659278:
Why do you choose relative anonymity?For the reasons I've said in the past. To which I can add personal safety: my Silk Road page is a bit questionable legally, and we all know that there are ways to exploit knowledge of one's True Name and address (even if, as far as I know, I have no enemies willing to resort to, say, 'swatting' me) - one group of stalkers called up a college they thought I worked at to see if they could get me fired or otherwise ruin my day.
Not everything is perfect.
One big problem of many big open source projects is that they are contributed to by separate selfish organizations, that have private information. Then what happens is that:
- people implement the same thing twice, or one change makes the other completely unmergeable
- you get bugs but can't share your closed source test cases, and then you can't automate tests for them, or clearly demonstrate the problem
- other contributors don't see your full semi secret important motivation, and may either nitpick too much or take too long to review your stuff
Another common difficulty is that open source maintainers may simply not care enough about their own project (maybe they did in the past but lost interest) to review external patches by people they don't know.
This is understandable: a new patch, is a new risk of things breaking.
Therefore, if you ever submit patches and they get ignore, don't be too sad. It just comes down to a question of maintenance cost, and means that you will waste some extra time on the next rebase. You just have to decide your goals and be cold about it:
- are you doing the right thing and going for a specific goal backward design? Then just fork, run as fast as possible towards a minimum viable product, and if you start to feel that rebase is costing you a lot, or feel you could get some open source fame for cheap, open reviews and see what upstream says. If they ignore you, politely tell yourself in your mind silently "fuck them", and carry on with the MVP
- otherwise, e.g. you just want to randomly help out, you have to ask them before doing anything big "how can I be of help". If I propose a patch for this issue, do you promise to review it?
Writing documentation in an open source project in which you don't have immediate push rights is another major pain due to code reviews. Code code reviews tend to be much less subjective, because if you do something wrong, stuff crashes, runs slower, or you need more lines of code to reach the same goal. There are tradeoffs, but in a limited number. Documentation code reviews on the other hand, are an open invitation to infinite bike-shedding, since you can't "run" documentation through a standardized brain model. Much better is for one good documenter person to just make one cohesive Stack Overflow post, and ping others with more knowledge to review details or add any missing pieces :-)
MOOCs are a bad idea. We don't want to simply map the pre-computer classroom to the Internet. The Internet allows, and requires, fundamentally new ways to do things. More like Stack Overflow/Wikipedia. More like OurBigBook.com.
Some possible/not possible sources that could be used to manually bootstrap content:
- LibreTexts. Good project. "Teacher-only-content" unfortunately as usual. But besides that fundamental flaw, they do exactly what we want to do in a sense.
- OpenStax: CC BY. This could be a great entry point, as they already have some university integration going on, and might be interested in this project.
- physics.stackexchange.com/questions/6157/list-of-freely-available-physics-books "List of freely available physics books" explicitly asks for:but the thread was locked, and basically none of the sources in the answers have free licenses, nor do they note it. It just seems that the physicists don't know what a free license is.
a list of physics books with open-source licenses, like Creative Commons, GPL
- MIT OpenCourseWare: CC BY-NC-SA, so not really usable
- github.com/certik/theoretical-physics: MIT License. Workable but wonky.
- subwiki.org/: wiki with some upper graduate math subjects presumably by this Indian dude: www.linkedin.com/in/vipul-naik-0ab1898/. Description on his homepage: vipulnaik.com/subwiki/. He's also got other interesting but not so relevant projects:He's also into Stack Overflow, Quora and Wikipedia editing. That's a cool dude. He's into in LessWrong it seems.
- pro freer immigration laws: vipulnaik.com/openborders/
- vipulnaik.com/cognito-mentoring/ free mentoring project for interested students
- massive mathematics books
- Infinite Napkin.CC BY-SA mathematics infinite book: github.com/vEnhance/napkin/issues/77. Very similar type of content to what we want in this project!
- Stacks Project
Existing lecture notes by students:
- github.com/mb2g17/NotesNetworkArchive Google Docs-based: docs.google.com/document/d/1OIcQ8dJ_FAhdkirU94M29-ZbNZ4oQs1LbWF3Nz-mq_U/edit#heading=h.vehxib58w1iw. An actual student uploading tons of lecture notes in one coherent system. CC BY-NC-SA unfortunately.
- academia.stackexchange.com/questions/148261/do-you-keep-your-study-notes-publicly-available mentions:Related: academia.stackexchange.com/questions/40381/how-common-is-it-that-professors-have-their-students-write-textbooks
- Cambridge Mathematics Lecture Notes by Dexter Chua (2014-2018)Comments:
Lecture note upload website:
- nexusnotes.com likely illegal reuploads of PDFs from teachers
- www.studocu.com/en-gb Paywall. PDF uploads. Unclear if simple teacher reuploads or actual novel notes.
- www.studydrive.net/
- Chinese GitHub repos. Some of these are very advanced in terms of content quantity and organizational quality! The Chinese are miles ahead in this area:
- github.com/PKUanonym/REKCARC-TSC-UHT Guidance for courses in Department of Computer Science and Technology, Tsinghua University. Chinese. Appears to try and store all past exams.
- github.com/lib-pku/libpku
- github.com/openwhu/OpenWHU: Wuhan University
- github.com/USTC-Resource/USTC-Course: USTC
- github.com/Zeal-L/UNSW: UNSW from Australia, but by a Chinese dude
- github.com/apachecn/mit-18.06-linalg-notes: translation of MIT course to Chinese
- github.com/chenyang1999/MyComputerCollegeCourses: TODO which univeresity
- github.com/elder-frog/OpenCourseCatalog: nothing to do with this project, but since I'm making a list, this dude is copying YouTube videos to Bilibili. And he's edgy anti-CCP on Twitter, what a legend.
- github.com/TheBloodthirster/BUAA_Course_Sharing: en.wikipedia.org/wiki/Beihang_University
- github.com/1051727403/SHU-CS-Source-Share: ShangHai University CS course source code
- github.com/Willie169/tw-gifted-k12-notes: Taiwanese high school notes
Exams uploads:
- questions.tripos.org/part-ib/all/ University of Cambridge Mathematics past examinations
A major difficulty of getting such this to work is that may university teachers want to retain closed copyright of their work because they:
- want to publish a book later and get paid. Yes, the root problem is that teachers get paid way too little and have way too little job security for the incredibly important and difficult extremely difficult job they are doing, and we have to vote to change that
- are afraid that if amazing material is made freely available, then they would not be needed and lose their jobs. Once again, job security issue.
- believe that if anyone were allowed to touch their precious content, those people would just "screw it up" and make it worse
- don't even want to publish their notes online because "someone will copy it and take their credit". What a mentality! In order to prevent a theft, you are basically guaranteeing that your work will be completely forgotten!
- don't want students to read the notes and skip class, because spoken word has magic properties and imparts knowledge that cannot otherwise conveyed by a book
- are afraid that mistakes will be found in their material. Reputation is of course everything in academia, since there is no money.So it's less risky to have closed, more buggy notes, than open, more correct ones.This can be seen clearly for example on Physics Stack Exchange, and most notably in particle physics (well, which is basically the only subject that really gets asked, since anything more experimental is going to be blocked off by patents/interlab competition), where a large proportion incredibly amazing users have anonymous profiles.They prefer to get no reputation gains from their amazing contributions, due to the fear that a single mistake will ruin their career.This is in stark contrast for example to Stack Overflow, where almost all top users are not anonymous:List of top users: physics.stackexchange.com/users?tab=Reputation&filter=all and some notable anonymous ones:
- physics.stackexchange.com/users/2451/qmechanic
- physics.stackexchange.com/users/50583/acuriousmind
- physics.stackexchange.com/users/43351/profrob
- physics.stackexchange.com/users/84967/accidentalfouriertransform
- physics.stackexchange.com/users/56997/curiousone
- physics.stackexchange.com/users/139781/probably-someone
- physics.stackexchange.com/users/206691/chiral-anomaly
Therefore the only way is to find teachers who are:The forced option therefore seems like a more bulk efficient starting point for searches.
- enlightened to use such licenses
- forced by their organizations to use such licenses
No matter how much effort a single person puts into writing perfect tutorials, they will never beat 1000x people + an algorithm.
It is not simply a matter of how much time you have. The fundamental reason is that each person has a different background and different skills. Notably the young students have radically different understanding than that of the experienced teacher.
Therefore, those that refuse to contribute to such platforms, or at least license their content with open licenses, will inevitably have their work forgotten in favor of those that have contributed to the more open platform, which will eventually dominate everything.
Perhaps OurBigBook.com is not he killer platform that will make this happen. Perhaps the world is not yet ready for it. But Ciro believes that this will happen, sooner or later, inevitable, and he wants to give it a shot.
Also worth checking:
- jornal.usp.br/universidade/usp-de-sao-carlos-oferece-aulas-de-graduacao-em-matematica-e-estatistica-abertas-ao-publico/ "Open Classroom" program from the University of São Paulo. We should Google for "Open Classroom" a bit more actually.
- open.ed.ac.uk/about/: talk only
Peter Mortensen is by far the largest serial editor on Stack Overflow, making predominantly style and grammar edits.
He is the prototypical WikiGnome.
His edit count is insane, ~127k as of November 2024 and increasing.
As per Users with most posts edited and stackoverflow.com/users?tab=Editors&filter=all he was the second most prolific editor of all time as of 2024, surpassed only by
marc_s
.Ron Maimon is a male human theoretical physicist with an all but dissertation started in 1995 at Cornell University[ref][ref].
Ron is mostly known for simultaneously:
- the amazing free online content he has published in online forums such as Stack Overflow and Quora, notably about particle physics, until around 2014 when Ron disappeared from the Internet entirely. Ciro Santilli figures he's hanging out with Ettore Majorana somewhere in the metaverse.
- having either been blocked from or quit every single website he participates in, partly due to his highly combative nature, e.g.:He explicitly defends this combative approach at youtu.be/ObXbKbpkSjQ?t=944 from Video 1. "Ron Maimon interview with Jeff Meverson (2014)":
- Physics Stack Exchange: physics.meta.stackexchange.com/users/4864/ron-maimon
physics.meta.stackexchange.com/questions/976/physics-ses-inability-to-deal-with-users-who-are-highly-persistent-have-kook-b user Marty Green makes one of the best characterizations of Ron's approach to science/collaboration:The thing about Ron Maimon is he definitely comes here to talk about physics. I personally can't get into discussions with him for two reasons: first, he's so single-minded in his own point of view that you can't really communicate with him back and forth; secondly, the structure of this forum is simply not conducive to extended discussions. But he sometimes posts things that are so coherently argued and with such intricate detail that even if I can't understand them myself, I just can't believe he's simply pulling this stuff out of his ass.
- physics.meta.stackexchange.com/questions/1376/what-violation-caused-this-suspension user Jerry Schirmer makes another good comment:
The thing that makes me pretty angry about Ron's behaviour is that he does not distinguish between common consensus belief and his own private research - this makes evaluating his claims hard for a third party not familiar with physics.
- Quora: www.quora.com/profile/Ron-Maimon. Ron was very active on Quora, until he was blocked for his views on the Boston Marathon bombing as mentioned at Video 1. "Ron Maimon interview with Jeff Meverson (2014)"
And notably, relevant to cirosantilli.com/china-dictatorship/stack-overflow-mods-refuse-to-clarify-if-anti-ccp-imagery-is-allowed-or-not-2021In order to have this process work [finding of truth] it is extremely important that the tone is hostile, that it is like a court of law, where you have an adversarial relationship with your opponent. Because if you have a friendly relationship with your opponent, then political consensus is preserved.
and he then also mentions that Wolfgang Pauli was a major proponent of this in physics, and so was Galileo.Unfortunately, when you're in a minority, the only way to correct the consensus view is to just shout it, and repeat it, until people go and look and check for themselves. The reason is that it creates an adversarial atmosphere where the people have to pick sides, and they don't like to pick sides, they would rather have everyone be happy. So when you have to pick sides, what do you do? You either butt out, you just leave it alone, you run away. Or you sit and review the evidence until you know which side to pick.
- Physics Stack Exchange: physics.meta.stackexchange.com/users/4864/ron-maimon
Ron seems to share a few philosophies which Ciro greatly agrees with as part of Cirism, which together with his knowledge of physics, make Ciro greatly respect Ron. Such philosophies include:
- he gives great importance to the history of physics and learning from original papers. He appears to know this insanely well, notably emphasizing that there is value in tutorials written by early pioneers of the field, see also Section "How to teach and learn physics". TODO find quote. Ciro Santilli distinctly remembers one specifically taking about this, but can't find it anymore.
- education views, notably emphasising autodidacticism
- www.quora.com/Why-should-high-school-students-learn-physics/answer/Ron-Maimon, highlighted at gmachine1729.livejournal.com/161418.html: "Why should high school students learn physics?" Answer:Yes, please, give it to me baby:
But they should learn it, preferably on their own, because the school doesn't know how to teach physics. Physics is extremely interesting, even the elementary kind. It takes the mathematics you learn in high school and uses it to describe certain natural phenomenon completely, beyond what was imagined possible in the wildest dreams of people like Pythagoras or Archimedes. If you have a computer, Newton's laws plus a tiny code can produce the motion of the planets around the sun, the motion of a free-twirling baton, the motion of colliding billiards, it's very simple.
- www.quora.com/Why-should-high-school-students-learn-physics/answer/Ron-Maimon, highlighted at gmachine1729.livejournal.com/161418.html: "Why should high school students learn physics?" Answer:
- enthusiasm for molecular biology technologies, seen e.g. at: www.quora.com/Why-are-an-abundance-of-physicists-moving-to-theoretical-biology/answer/Ron-Maimon on Quora:Ciro is actually specifically curious about whole cell simulation which he makes reference to.
[biology] is also clearly going to be the major technology of the 21st century, you should have a sugar outlet next to the electrical outlet, and plug in artificial biological technology made out of artificial cells. To plan these requires a complete method of describing biological cells, a precise model of all the processes, so that you can make artificial ones, and it produces a type of precise control on single-molecule chemistry that makes chemists drool.
- effortless effort and the to explain everything he knows online. These can be seen at www.quora.com/How-do-you-control-your-urge-to-access-the-internet-so-you-can-complete-your-assignments "How do you control your urge to access the Internet so you can complete your assignments?":
I don't. I consider the internet the first priority, as it will be viewed by thousands of people, and will have a real impact, while other assignments are lower priority, as they will only have an impact locally.
- his cheapness as in Ciro Santilli's cheapness as mentioned at youtu.be/ObXbKbpkSjQ?t=2454 from Video 1. "Ron Maimon interview with Jeff Meverson (2014)":Interviewer: there's a question on Quora where you say that you took a vow of poverty when you were very young.Ron: I was ten, I mean, most people would give it up, but I mean I figured I didn't have any need to give it up, so I just kept with it, I mean, I was never was really offered that much more. When we started the startup, I think I was offered 50k, but I said "no, I'll keep it 40k, I took a vow", and then they gave me 40k. And that of sort of set an example, the CEO also took 40k. It was a very good thing because we had very little money, we were a startup, and we were going by seed money.
However he also subscribes to some theories which Ciro Santilli considers conspiracy theories, e.g. his ideas about the Boston Marathon bombing that got him banned from Quora (a ban which Ciro strongly opposes due to freedom of speech concerns!), but the physics might be sound, Ciro Santilli does not know enough physics to judge, but it often feels that what he says makes sense.
chat.stackexchange.com/transcript/message/7104585#7104585 mentions that he was at Cornell University and did all but dissertation, but he mentions that he was still self-taught:This is corroborated e.g. at: web.archive.org/web/20201226171231/http://pages.physics.cornell.edu/~gtoombes/Student_Index.html (original pages.physics.cornell.edu/~gtoombes/Student_Index.html down as of 2023).
Eugene Seidel: On your personal info page you write that you are not a physics Ph.D. but does that mean you were a physics undergrad in college then went to grad school and finished ABD... or are you entirely self taught?Ron Maimon: ABD. I am self- taught though, I only went to school for accreditation. I had a thesis worth of work at the time I left grad-school,Eugene Seidel: ok thanksRon Maimon: I was just kind of sickened by academic stuff that was going on--- large extra dimensions were popular then.Eric Walker: Anyway, thanks Ron -- I'll get back to you with more questions soon, I'm sure.Ron Maimon: Also I was at Cornell, my advisor left for Cincinnatti, and I was not in very good standing there (I was kind of a jerk, as I still am). Some friends wanted to start a biotech company called "Gene Network Sciences", and I joined them.
At youtu.be/ObXbKbpkSjQ?t=2454 from Video 1. "Ron Maimon interview with Jeff Meverson (2014)" he mentions his brother is a professor. At physics.stackexchange.com/questions/32382/could-we-build-a-supercomputer-out-of-wires-and-switches-instead-of-a-microchip confirms that his brother's name is "Gaby Maimon", so this neuroscience professor at the Rockerfeller University is likely him: www.rockefeller.edu/our-scientists/heads-of-laboratories/985-gaby-maimon/. Looks, age, location and research interest match.
Some notable technical posts:
Some notable history posts:
- physics.stackexchange.com/questions/18632/good-book-on-the-history-of-quantum-mechanics/18643#18643 about the history of quantum mechanics give the quadratic explanation
- and closely related for the factor 2: physics.stackexchange.com/questions/27847/why-is-there-a-frac-1-2-in-frac-1-2-mv2/27916#27916
Bibliography:
- gmachine1729.livejournal.com/161418.html Ron Maimon answers about physics and math on Quora (part 1) by Sheng Li (2020) contains a selection of some amazing Ron Maimon posts
- www.reddit.com/r/RonMaimon/ someone made a Reddit for him. Less than 100 users as of 2022, but has potential.
- some Quora threads about him, oh the irony:
- www.quora.com/Is-Ron-Maimon-actually-a-pioneer-or-a-jest
- www.quora.com/Are-Ron-Maimons-answers-on-mathematics-physics-and-computer-science-factually-correct
- www.quora.com/What-do-people-think-of-Ron-Maimons-paper-Computational-Theory-of-Biological-Function-I
- www.quora.com/Who-is-Ron-Maimon/answer/Ron-MaimonAlso in a comment he explains something to a now deleted comment, presumably asking why he dropped out of grad school, and gives a lot more insight:
I'm a physics grad school drop-out working in theoretical biology but I still do physics when I get a chance, but not right now because I am in a middle of a project to understand the properties of a certain virus as completely as possible.
It's a complicated boring story.I dropped out mainly to do biology with friends at a startup, because I figured out how you're supposed to do theory in biology, but also I truly believe it was next to impossible for me to get a degree without selling out, and I would rather be shot than write a paper with an idea I don't believe.My grad school phase was a disaster. I first worked for Eric Siggia, but I got away because he had me do something boring and safe, I figured I have only a limited number of years before I turn 30 and my brain rots, and I wasn't going to sell out and do second-rate stuff. I found a young guy at the department doing interesting things (Siggia was also doing interesting things, like RNA interactions, he just wouldn't assign any of them to ME), this was Philip Argyres, and got him to take me. Argyres wanted me to work on large-extra dimensions (this was 1998), but I made it clear to him that I would rather be boiled in oil. I worked a little bit on a crappy experimental setup that didn't work at all, because I didn't know enough about electromagnetic screening nor about how to set up experiment. But EVERYONE LOVED IT! This is also how I knew it was shit. Good work is when everyone hates it. But I learned Lifschitz's ideas for quantum electrodynamics in media from this project.Me and every competent young person in high-energy physics knew large extra dimensions was a fraud on the day it came out, and I had no intention of doing anything except killing the theory. Once Wikipedia appeared, I did my best to kill it by exposing it's charlatanry on the page for large extra dimension. That was in 2005 (after getting fired from the company), and from this point onward large-extra-dimensions lost steam. But I can't tell how much of this was my doing.Argyres liked N=2 theory, and we did something minor in N=2 SUSY models around 2000, but I was bogged down here, because I was trying to do Nicolai map for these, and it ALMOST worked for years, but it never quite worked. But I knew from the moduli interpretation and Seiberg-Witten solution that it must work. If I live long enough, I'll figure it out, I am still sure it isn't hard. But this was the link to statistical stochastic models, the work I was doing with Jennifer Schwarz, and I wanted to link up the two bodies of work (they naturally do through Nicolai map).But I had my own discovery, the first real discovery I made, in 1999, this thing that I called the mass-charge inequality, what Vafa and Motl called "the weakest-force principle" when they discovered it in 2006. It was swampland, and Vafa hadn't yet begun swampland. My advisor didn't believe my result was correct, because he saw me say many stupid things before this. So he wouldn't write it or develop it with me (but I had read about Veltman telling 'tHooft he couldn't publish the beta-function, I knew Argyres was wrong about this)Anyway, Argyres left for Cincinnatti in 2000, and I joined the company then. I was in the company until january 2005. Then they fired me, which was ok, by then it was a miserable hell-hole full of business types.I discovered Wikipedia, and started killing large extra dimensions. I wanted to finish my thesis, and some people agreed to help me do this, but I had told myself "no thesis until you get the Nicolai map sorted out" and I never did. I worked with Chris Henley a little bit, who wanted me to do some stuff for him, and I discovered an interesting model for high-Tc, but Henley said it was out of fasion, and nobody would care, even though I knew it was the key to the phenomenon (still unpublished, but soon).This was 2008-2009, and I became obsessed with cold fusion, so Henley dropped me, as I had clearly gone crazy. I developed the theory of cold fusion during the last weeks of working for Henley. Then I dropped out for good.Honestly, by the time I was gone, I realized that the internet would make a degree counterproductive, because I knew I had better internet writing skills than any of the old people, I was a Usenet person. Online, the degrees and accreditation were actually a hinderance. So by this point, I secretly preferred not to have a PhD, because I knew I was good at physics, and I could attack from the outside and win. It's not too hard if you know the technical material.The only problem is that I was unemployed and isolated in Ithaca for about 7 years after having gone through my first productive phase. But I developed the cold-fusion ideas in this period, I learned a lot of mathematics, and I developed a ton of biology ideas that are mostly unpublished, but will be published soon. It astonished people that I could have no degree and be unemployed and have such a sky-high ego. The reason is that I could evaluate my own stuff, and I liked it!
Backlinks:
- 2022: twitter.com/johncarlosbaez/status/1556085484937310209 by John Baez. This page was one of the top Google hits for "Ron Maimon" at the time.
To run examples on a specific database:All examples can be tested on all databases with:
./index.js
or./index.js l
: SQLite./index.js p
: PostgreSQL. You must manually create a database calledtmp
and ensure that peer authentication works for it
cd sequelize
./test
Overview of the examples:
- nodejs/sequelize/index.js: a bunch of basic examples
- nodejs/sequelize/update.js: This file is also where we are storing our expression-foo for now, e.g. how to do stuff like
col1 + col2
. Such knowledge can however be used basically anywhere else however, e.g. inAS
orWHERE
clauses, not just inUPDATE
. - nodejs/sequelize/count.js: a simplified single-table count example. In practice, this will be usually done together with JOIN queries across multiple tables. Answers: stackoverflow.com/questions/22627258/how-does-group-by-works-in-sequelize/69896449#69896449
- nodejs/sequelize/date.js: automatic date typecasts
- nodejs/sequelize/like.js: LIKE
- nodejs/sequelize/camel_case.js: trying to get everything in the database camel cased, columns starting with lowercase, and tables starting with uppercase. The defaults documented on getting started documentation do uppercase foreign keys, and lowercase non-foreign keys. It's a mess.
- nodejs/sequelize/ignore_duplicates.js: ignore query on unique violation with
ignoreDuplicates: true
which does SQLiteINSERT OR IGNORE INTO
or PostgreSQLON CONFLICT DO NOTHING
. Closely related Upsert versions:- Upsert
- nodejs/sequelize/upsert.js:
.upsert
selects the conflict column automatically by unique columns. Both SQLite and PostgreSQL doINSERT INTO ON CONFLICT
. PostgreSQL usesRETURNING
, which was added too recently to SQLite: www.sqlite.org/lang_returning.htmlAt nodejs/sequelize/composite_index.js we have a.upsert
test with a composite index. Works just fine as you'd expect with a compositeON CONFLICT
. Well done. - nodejs/sequelize/update_on_duplicate.js:
.bulkCreate({}, { updateOnDuplicate: ['col1', col2'] }
. Produces queries analogous to.upsert
. This method is cool because it can upsert multiple columns at once. But it is annoying that you have to specify all fields to be updated one by one manually. - stackoverflow.com/questions/29063232/how-to-get-the-id-of-an-inserted-or-updated-record-in-sequelize-upsert/72092277#72092277
- stackoverflow.com/questions/55531860/sequelize-bulkcreate-updateonduplicate-for-postgresql
- Upsert
- nodejs/sequelize/inc.js: demonstrate the
increment
method. In SQLite, it produces a statement of type:UPDATE `IntegerNames` SET `value`=`value`+ 1,`updatedAt`='2021-11-03 10:23:45.409 +00:00' WHERE `id` = 3
- nodejs/sequelize/sync_alter.js: illustrates
Model.sync({alter: true})
to modify a table definition, answers: stackoverflow.com/questions/54898994/bulkupdate-in-sequelize-orm/69044138#69044138 - nodejs/sequelize/truncate_key.js
- nodejs/sequelize/validation.js: is handled by a third-party library: github.com/validatorjs/validator.js. They then add a few extra validators on top of that.The
args: true
thing is explained at: stackoverflow.com/questions/58522387/unhandled-rejection-sequelizevalidationerror-validation-error-cannot-create-pr/70263032#70263032 - nodejs/sequelize/composite_index.js: stackoverflow.com/questions/34664853/sequelize-composite-unique-constraint
- nodejs/sequelize/indent_log.js: stackoverflow.com/questions/34664853/sequelize-composite-unique-constraint
- association examples:
- nodejs/sequelize/one_to_many.js: basic one-to-many examples.
- nodejs/sequelize/many_to_many.js: basic many-to-many examples, each user can like multiple posts. Answers: stackoverflow.com/questions/22958683/how-to-implement-many-to-many-association-in-sequelize/67973948#67973948
- ORDER BY include:
- nodejs/sequelize/many_to_many_custom_table.js: many-to-many example, but where we craft our own table which can hold extra data. In our case, users can like posts, but likes have a integer weight associated with them. Related threads:
- nodejs/sequelize/many_to_many_same_model.js: association between a model and itself: users can follow other users. Related:
- nodejs/sequelize/many_to_many_same_model_super.js
- nodejs/sequelize/many_to_many_super.js: "Super many to many": sequelize.org/master/manual/advanced-many-to-many.html This should not exist and shows how bad this library is for associations, you need all that boilerplate in order to expose certain relationships that aren't otherwise exposed by a direct
hasMany
with implicit join table.
- nested includes to produce queries with multiple JOIN:
- nodejs/sequelize/nested_include.js: find all posts by users that a given user follows. Answers: stackoverflow.com/questions/42632943/sequelize-multiple-where-clause/68018083#68018083
- nodejs/sequelize/nested_include_super.js: like nodejs/sequelize/nested_include.js but with a super many to many. We should move this to nodejs/sequelize/many_to_many_super.js.
- two relationships between two specific tables: we need to use
as:
to disambiguate them- nodejs/sequelize/many_to_many_double.js: users can both follow and like posts
- nodejs/sequelize/one_to_many_double.js: posts have the author and a mandatory reviewer
- hooks
- internals:
- nodejs/sequelize/common.js: common utilities used across examples, most notably:
- to easily setup different DBRM
- nodejs/sequelize/min_nocommon.js: to copy paste to Stack Overflow
- nodejs/sequelize/min.js: template for new exapmles in the folder
- nodejs/sequelize/common.js: common utilities used across examples, most notably:
This is a really good project. So fun to play around with. Low level IO part only like drawing to screen and handling keyboard inputs.
Ciro Santilli has:
- a few answers on Stack Overflow: stackoverflow.com/search?tab=votes&q=user%3a895245%20%5bsdl%5d
- a small cheatsheet on: github.com/cirosantilli/cpp-cheat/tree/09cb7c9fc1ee4a8bee421f12d0596b81cfd836bd/sdl
So that he can work full time on OurBigBook.com and revolutionize advanced university-level science, technology, engineering, and mathematics eduction for all ages.
Donating to Ciro is the most effective donation per dollar that you can make to:
- improve hardcore university-level STEM education for all ages
- help make every child into the next Nobel Prize/Fields Medal/deep tech unicorn co-founder
Ciro's goal in life is to help kids as young as possible to reach, and the push, the frontiers of natural sciences human knowledge, linking it to applications that might be the the next big thing as early as possible. Because nothing is more motivating to students than that feeling of:rather than repeating the same crap that everyone is already learning.
Hey, I can actually do something in this area that has never been done before!
To do this, Ciro wants to work in parallel both on:
- the multi-user website e-learning platform of OurBigBook.com
- creating amazing teaching content that motivates that platform, and that deeply interests Ciro, notably quantum mechanics and its related applications:
- quantum computing
- molecular biology
- condensed matter physics and chemistry
- slightly more theoretical stuff in somewhat related fields of:
- continue to dump his brain/research in areas Ciro has expertise in: software engineering and open source software
Ciro believes that this rare combination of both:produces a virtuous circle, because Ciro:
- proven passion and capability to learn and teach science, technology, engineering, and mathematics subjects
- proven programming skills, including web development
- wants to learn and teach, so he starts to create content
- then he notices the teaching tools are crap
- and since he has the ability to actually improve them, he does
As explained at OurBigBook.com and high flying bird scientist, Ciro is most excited to make contributions at the "missing middle level of specialization" that lies around later undergrad and lower grad education:But on that middle sweet spot, Ciro believes that something can be done, in such as way that delivers:in a way that is:
- at lower undergrad level, there is already a lot of free material out there to learn stuff
- at upper graduate level and beyond, too few people know about each specific subject, that it becomes hard to factor things out
- beauty
- power
- in your face, without requiring you to study for a year
- but also giving enough precision to allow you to truly appreciate the beauty of the subjectCiro's programming skills can also be used to create educational, or actually more production-like, simulations and illustrations.
Ciro believes that today's society just keep saying over and over: "STEM is good", "STEM is good", "STEM is good" as a religious mantra, but fails miserably at providing free learning material and interaction opportunities for people to actually learn it at a deep enough level to truly appreciate why "STEM is good". This is what he wants to fix.
The following quote is ripped from Gwern Branwen's Patreon page, and it perfectly synthesizes how Ciro feels as well:
Omar Khayyam also came to the Vizier... but not to ask for title or office. 'The greatest boon you can confer on me,' he said, 'is to let me live in a corner under the shadow of your fortune, to spread wide the advantages of Science, and pray for your long life and prosperity.'
In addition to all of this, financial support also helps Ciro continue his general community support activities:
- writing and updating his amazing Stack Overflow answers: Section "Ciro Santilli's Stack Overflow contributions"
- saving the world from the CCP: Section "Ciro Santilli's campaign for freedom of speech in China"
Waste of time sub-sites that should instead be merged into Stack Overflow as different tags.
Nowhere is this waste more visible than at: cs50.stackexchange.com/. A website just for some specific course that is completely covered by other sites of the network? What a humongous waste!!!
The best place to get answers to programming questions as of 2019. Google into Stack Overflow is always the best bet.
An overview of Ciro Santilli's Stack Overflow contribution can be found at: Ciro Santilli's Stack Overflow contributions.
Stack Overflow does have an super naive reputation and moderation system and overly restrictive subject matter, which Ciro Santilli wants to improve upon with OurBigBook.com.
However, it is the best that we have now, and if you use it like Ciro, you won't get tired:What else would you expect from a naive algorithm system that has 10 million newbies asking stuff?
- monitor only rare tags that you know a lot about, let others answer duplicates on big tags for you
- only answer on bigger tags when you find a better answer than can be found on the page
- accept that sometimes things are bound to go wrong, that reputation is meaningless, and move on
The key problem of Stack Overflow is closurism. The answer close feature is just not made for purpose. The sole purpose of "closing" should be to prevent easy reputation farming. What it should do instead, is remove points gained from duplicates and off topic questions. But it should not prevent new answers. The disk space costs nothing, and Google doesn't care about the closed status of a question.
As of 2024, the only competitor of Stack Overflow is Reddit (besides LLMs, which do nothing but extract data from those two and other sites). Reddit removed the mandatory thread locking after 6 months, but still lacks the Q&A focus required for greatness. Its community however is much more chill and doesn't close and downvote the fuck out of everything.
Related posts:
The link will break, and the answer will lose. Or the person who summarizes inline will get more upvotes because people are lazy to click the link. Also, web archiving exists.
This is especially idiotic when it is a link to another post in Stack Overflow itself.
How do you think Ciro got his rep? Just kidding.
Stack Overflow later forbade Ciro from advertising this project as described at: Section "Ciro Santilli's Stack Overflow suspension for vote fraud script 2019". Those newbs know nothing about security through obscurity.
They sent one of the rare spams Ciro actually was interested in!!! Likely going down lists of top Stack Overflow users.
They have some kind of cryptocurrency, TCHME token, as a reward. Ciro wonders if the value of TCHME will ever be high enough to serve as a valid incentive.
Also, what is the total TCHME supply? Can the website devs issue as much as they want? They do giveaways e.g. as shown at: twitter.com/TeachMeAsap/status/1621353671840899072
And a centralized system with a certralized marketplace would work just as well for the initial phases. But fair play, the idea is interesting.
There are unlisted articles, also show them or only show them.