LESSWRONG
LW

Johannes C. Mayer
1314Ω34733154
Message
Dialogue
Subscribe

↘↘↘↘↘↘↙↙↙↙↙↙
Checkout my Biography.
↗↗↗↗↗↗↖↖↖↖↖↖

Posts

Sorted by New

Wikitag Contributions

Comments

Sorted by
Newest
1Johannes C. Mayer's Shortform
4y
192
Johannes C. Mayer's Shortform
Johannes C. Mayer11mo*271

Typst is better than Latex

I started to use Typst. I feel a lot more productive in it. Latex feels like a slug. Typst doesn't feel like it slows me down when typing math, or code. That and the fact that it has an online collaborative editor, and that rendering is very very fast are the most important features. Here are some more:

  • It has an online collaborative editor.
  • It compiles instantly (at least for my main 30-page document)
  • The online editor has Vim support.
  • It's free.
  • It can syntax highlight lots of languages (e.g. LISP and Lean3 are supported).
  • It's embedded scripting language is much easier to use than Latex Macros.
  • The paid version has Google Doc-style comment support.
  • It's open source and you can compile documents locally, though the online editor is closed source.

Here is a comparison of encoding the games of life in logic:

Latex

$$
\forall i, j \in \mathbb{Z}, A_{t+1}(i, j) = \begin{cases}
                                0 &\text{if} \quad A_t(i, j) = 1 \land N_t(i, j) < 2 \\
                                1 &\text{if} \quad A_t(i, j) = 1 \land N_t(i, j) \in \{2, 3\} \\
                                0 &\text{if} \quad A_t(i, j) = 1 \land N_t(i, j) > 3 \\
                                1 &\text{if} \quad A_t(i, j) = 0 \land N_t(i, j) = 3 \\
                                0 &\text{otherwise}
                              \end{cases}
$$

Typst

$
forall i, j in ZZ, A_(t+1)(i, j) = cases(
                                0 "if" A_t(i, j) = 1 and N_t(i, j) < 2 \
                                1 "if" A_t(i, j) = 1 and N_t(i, j) in {2, 3} \
                                0 "if" A_t(i, j) = 1 and N_t(i, j) > 3 \
                                1 "if" A_t(i, j) = 0 and N_t(i, j) = 3 \
                                0 "otherwise")
$

Typst in Emacs Org Mode

Here is some elisp to treat latex blocks in emacs org-mode as typst math, when exporting to HTML (renders/embeds as SVG images):

;;;; Typst Exporter
;;; This exporter requires that you have inkscape and typst in your path.
;;; Call org-typst-enabled-html-export

;;; TODO
;;; - Error if inskape or typst is not installed.
;;; - Make it such that it shows up in the org-dispatch exporter and we can
;;;   automatically not export only to output.html.
;;; - Automatically setup the HTML header, and possible also automatically start the server as described in: [[id:d9f72e91-7e8d-426d-af46-037378bc9b15][Setting up org-typst-html-exporter]]
;;; - Make it such that the temporary buffers are deleted after use.


(require 'org)
(require 'ox-html) ; Make sure the HTML backend is loaded

(defun spawn-trim-svg (svg-file-path output-file-path)
  (start-process svg-file-path
		 nil
		 "inkscape"
		 svg-file-path
		 "--export-area-drawing"
		 "--export-plain-svg"
		 (format "--export-filename=%s" output-file-path)))

(defun correct-dollar-sings (typst-src)
  (replace-regexp-in-string "\\$\\$$"
			    " $" ; Replace inital $$ with '$ '
			    (replace-regexp-in-string "^\\$\\$" "$ " ; same for ending $$
						      typst-src)))

(defun math-block-p (typst-src)
  (string-match "^\\$\\$\\(\\(?:.\\|\n\\)*?\\)\\$\\$$" typst-src))

(defun html-image-centered (image-path)
  (format "<div style=\"display: flex; justify-content: center; align-items: center;\">\n<img src=\"%s\" alt=\"Centered Image\">\n</div>" image-path))

(defun html-image-inline (image-path)
  (format " <img hspace=3px src=\"%s\"> " image-path))

(defun spawn-render-typst (file-format input-file output-file)
  (start-process input-file nil "typst" "compile" "-f" file-format input-file output-file))

(defun generate-typst-buffer (typst-source)
  "Given typst-source code, make a buffer with this code and neccesary preamble."
  (let ((buffer (generate-new-buffer (generate-new-buffer-name "tmp-typst-source-buffer"))))
    (with-current-buffer buffer
      (insert "#set text(16pt)\n")
      (insert "#show math.equation: set text(14pt)\n")
      (insert "#set page(width: auto, height: auto)\n")1
      (insert typst-source))
    buffer))
  
(defun embed-math (is-math-block typst-image-path)
    (if is-math-block
	(html-image-centered typst-image-path)
        (html-image-inline typst-image-path)))

(defun generate-math-image (output-path typst-source-file)
  (let* ((raw-typst-render-output (make-temp-file "my-temp-file-2" nil ".typ")))
    (spawn-render-typst file-format typst-source-file raw-typst-render-output)
    (spawn-trim-svg raw-typst-render-output typst-image-path)))

(defun my-typst-math (latex-fragment contents info)
  ;; Extract LaTeX source from the fragment's plist
  (let* ((typst-source-raw (org-element-property :value latex-fragment))
	 (is-math-block (math-block-p typst-source-raw))
	 (typst-source (correct-dollar-sings typst-source-raw))
	 (file-format "svg") ;; This is the only supported format.
         (typst-image-dir (concat "./typst-svg"))
	 (typst-buffer (generate-typst-buffer typst-source)) ; buffer of full typst code to render
	 (typst-source-file (make-temp-file "my-temp-file-1" nil ".typ"))
	 ;; Name is unique for every typst source we render to enable caching.
	 (typst-image-path (concat typst-image-dir "/"
				   (secure-hash 'sha256 (with-current-buffer typst-buffer (buffer-string)))
				   "." file-format)))
    ;; Only render if neccesary
    (unless (file-exists-p typst-image-path)
      (message (format "Rendering: %s" typst-source))
      ;; Write the typst code to a file
      (with-current-buffer typst-buffer
	(write-region (point-min) (point-max) typst-source-file))
      (generate-math-image typst-image-path typst-source-file))
    (kill-buffer typst-buffer)
    (embed-math is-math-block typst-image-path)))

(org-export-define-derived-backend 'my-html 'html
    :translate-alist '((latex-fragment . my-typst-math))
    :menu-entry
    '(?M "Export to My HTML"
	((?h "To HTML file" org-html-export-to-html))))

;; Ensure org-html-export-to-html is bound correctly to your backend:
(defun org-html-export-to-html-with-typst (&optional async subtreep visible-only body-only ext-plist)
  (interactive)
  (let* ((buffer-file-name (buffer-file-name (window-buffer (minibuffer-selected-window))))
	 (html-output-name (concat (file-name-sans-extension buffer-file-name) ".html")))
    (org-export-to-file 'my-html html-output-name
      async subtreep visible-only body-only ext-plist)))

(setq org-export-backends (remove 'html org-export-backends))
(add-to-list 'org-export-backends 'my-html)

Simply eval this code and then call org-html-export-to-html-with-typst.

Reply
The Feeling of Idea Scarcity
Johannes C. Mayer3y*186

Emotionally Detatch yourself from your Ideas

Here is a model of mine, that seems related.

[Edit: Add Epistemic status]
Epistemic status: I have used this successfully in the past and found it helpful. It is relatively easy to do. utilitytime_investment is large for me.

I think it is helpful to be able to emotionally detach yourself from your ideas. There is an implicit "concept of I" in our minds. When somebody criticizes this "concept of I", it is painful. If somebody says "You suck", that hurts.

There is an implicit assumption in the mind that this concept of "I" is eternal. This has the effect, that when somebody says "You suck", it is actually more like they say "You sucked in the past, you suck now, and you will suck, always and ever".

In order to emotionally detach yourself from your ideas, you need to sever the links in your mind, between your ideas and this "concept of I". You need to see an idea as an object that is not related to you. Don't see it as "your idea", but just as an idea.

It might help to imagine that there is an idea-generation machine in your brain. That machine makes ideas magically appear in your perception as thoughts. Normally when somebody says "Your idea is dumb", you feel hurt. But now we can translate "Your idea is dumb" to "There is idea-generating machinery in my brain. This machinery has produced some output. Somebody says this output is dumb".

Instead of feeling hurt, you can think "Hmm, the idea-generating machinery in my brain produced an idea that this person thinks is bad. Well maybe they don't understand my idea yet, and they criticize their idea of my idea, and not actually my idea. How can I make them understand?" This thought is a lot harder to have while being busy feeling hurt.

Or "Hmm, this person that I think is very competent thinks this idea is bad, and after thinking about it I agree that this idea is bad. Now how can I change the idea-generating machinery in my brain, such that in the future I will have better ideas?" That thought is a lot harder to have when you think that you yourself are the problem. What is that even supposed to mean that you yourself are the problem? This might not be a meaningful statement, but it is the default interpretation when somebody criticizes you.

The basic idea here is, to frame everything without any reference to yourself. It is not me producing a bad plan, but some mechanism that I just happened to observe the output of. In my experience, this not only helps alleviate pain but also makes you think thoughts that are more useful.

Reply
What do you imagine, when you imagine "taking over the world"?
Answer by Johannes C. MayerDec 31, 2022*74

Here is what I would do, in the hypothetical scenario, where I have taken over the world.

  1. Guard against existential risk.
  2. Make sure that every conscious being I have access to is at least comfortable as the baseline.
  3. Figure out how to safely self-modify, and become much much much ... much stronger.
  4. Deconfuse myself about what consciousness is, such that I can do something like 'maximize positive experiences and minimize negative experiences in the universe', without it going horribly wrong. I expect that 'maximize positive experiences, minimize negative experiences in the universe' very roughly points in the right direction, and I don't expect that would change after a long reflection. Or after getting a better understanding of consciousness.
  5. Optimize hard for what I think is best.

Though this is what I would do in any situation really. It is what I am doing right now. This is what I breathe for, and I won't stop until I am dead.

[EDIT 2023-03-01_17-59: I have recently realized that is is just how one part of my mind feels. The part that feels like me. However, there are tons of other parts in my mind that pull me in different directions. For example, there is one part that wants me to do lots of random improvements to my computer setup, which are fun to do, but probably not worth the effort. I have been ignoring these parts in the past, and I think that their grip on me is stronger because I did not take them into account appropriately in my plans.]

Reply
Johannes C. Mayer's Shortform
Johannes C. Mayer3d60

Depression as a Learned Suppression Loop

Overview

This post proposes a mechanistic model of a common kind of depression, framing it not as a transient emotional state or a chemical imbalance, but as a persistent, self-reinforcing control loop. The model assumes a brain composed of interacting subsystems, some of which issue heuristic error signals (e.g., bad feelings), and others which execute learned policies in response. The claim is that a large part of what is commonly called "depression" can be understood as a long-term learned pattern of suppressing internal error signals using high-intensity external stimuli.

Key components

  • The brain includes systems that detect mismatches between actual behavior and higher-level goals or models. When these detect an issue (e.g., agency violation, unresolved conflict, lack of progress), they emit negative affect.

  • Negative affect is not noise. It is a signal. In some cases, it simply arises from overstimulation and regulatory lag. In other cases, it points to an actual error: something is wrong with the current behavior, motivational alignment, or action trajectory.

  • In a healthy system, negative affect would prompt reflection: "Why do I feel bad? What's the mismatch? Should I change direction?"

  • In practice, this reflection step is often bypassed. Instead, the brain learns that high-intensity stimulus (YouTube, Skinner-box games, food, porn) suppresses the signal. This works in the short term, so the suppression policy gets reinforced.

  • Over time, the suppression policy becomes automatic. Every time a conflict signal arises, it gets overwritten by external input. The system learns: "feeling bad" -> "inject stimulus" -> "feel better." No reflection or course correction happens. The source of the bad feeling persists, so the loop repeats.

  • This creates a self-reinforcing attractor: more suppression leads to more misalignment, which leads to more negative signals, which leads to more suppression. The behavior becomes proceduralized and embedded into long-term structure.

Agency Violation as Error Signal

One key class of negative affect is what we call an "agency violation" signal. This occurs when behavior is driven by urges or automated triggers rather than deliberate, reflective choice.

Example: You feel a slight urge to open YouTube instead of working. You give in. After watching for 20 minutes, you feel bad. The bad feeling is not about the content. It's a second-order signal: you took an action that bypassed your reflective control system. You were coerced by an urge. The system flags that as a problem.

If, instead of reflecting on that signal, you suppress it by continuing to watch YouTube, the suppression gets reinforced. Eventually, the sequence becomes automatic.

Suppression vs. Resolution

Suppression works by injecting a high-reward stimulus. This reduces the negative signal. But it does not correct the cause. The policy becomes: bad feeling -> avoid it.

Resolution would involve explicitly checking: "Why do I feel bad?" and running a diagnostic process. Example: "I feel bad. Did I get coerced by an urge? Was I avoiding something? Am I stagnating?" If a concrete cause is found and addressed, the signal terminates because the underlying mismatch is resolved.

The Role of Superstimuli

Modern environments are full of fast-acting, high-reward, low-effort stimuli. These serve as perfect suppression mechanisms. They hijack the system's reward learning by offering reliable affective relief without behavioral correction.

Examples:

  • Watching videos when you feel restless
  • Playing reward-loop-heavy games when you feel failure
  • Eating sugar when you feel discouraged

These actions reinforce suppression patterns.

Depression as Policy Entrenchment

Over time, if this suppression loop becomes the default policy, the system reorganizes around it. The underlying problems do not go away. The system becomes more fragile. The ability to reflect degrades. The habit becomes chronic. This is what we call depression.

Note: this model does not deny neurochemical involvement. Rather, it treats neurochemistry as part of the loop dynamics. If the procedural pattern of suppression dominates for long enough, neurochemical state will reflect that pattern. But the origin was structural, not random imbalance.

Role of Interventions Like Bupropion

Certain medications (e.g., bupropion) can disrupt the suppression loop temporarily. They increase energy or decrease suppression effectiveness, allowing for enough reflective bandwidth to notice and correct maladaptive patterns.

The drug doesn’t fix depression. It interrupts the loop long enough for you to fix it yourself.

Practical Implication

If this model is correct, then the right policy is:

  • When you feel bad, pause. Do not immediately act to suppress it.
  • Ask: is this a genuine signal? Did something go wrong? Did I get coerced by an urge?
  • Try to trace the source. If you find it, resolve it directly.
  • If you can't trace it, just wait. Sometimes the bad feeling is transient and resolves on its own.

In many cases, talking to someone (or to a reflective system, like a chatbot) can help reveal the structure behind the feeling. The key is engaging with the feeling as a signal, not a nuisance.

Conclusion

Depression is not always a surface-level mood disorder. In many cases, it is the long-term consequence of learned suppression policies that override internal signals rather than resolving them. These policies become structural, self-reinforcing, and difficult to dislodge without deliberate intervention. The first step is recognizing bad feelings as information, not errors.

Reply
Johannes C. Mayer's Shortform
Johannes C. Mayer9d*20

This is a good informal introduction to Control Theory / Cybernetics.

https://www.youtube.com/watch?v=YrdgPNe8KNA

Reply
johnswentworth's Shortform
Johannes C. Mayer14d40

In both cases, the conversation drains more energy than the equal-fun alternative. I have probably had at most a single-digit number of conversations in my entire life which were as fun-in-their-own-right as e.g. a median night out dancing, or a median escape room, or median sex, or a median cabaret show. Maybe zero, unsure.

I wanted to say that for me it is the opposite, but reading the second half I have to say it's the same.

I have defnetly had the problem that I talked too long sometimes to somebody. E.g. multiple times I talked to a person for 8-14 hours without break about various technical things. E.g. talking about compiler optimizations, CPU architectures and this kind of stuff, and it was really hard to stop.

Also just solving problems in a conversation is very fun. The main reason I didn't do this a lot is that there are not that many people I know, actually basically zero right now (if you exclude LLMs), that I can have the kinds of conversations with that I like to have.

It seems to be very dependent on the person.

So I am quite confused why you say "but conversation just isn't a particularly fun medium". If it's anything like for me, then engaging with the right kind of people on the right kind of content is extremenly fun. It seems like your model is confused because you say "conversations are not fun" when infact in the space of possible conversations I expect there are many types of conversations that can be very fun, but you haven't mapped this space, while implicitly assuming that your map is complete.

Probably there are also things besides technical conversations that you would find fun but that you simply don't know about, such as hardcore flirting in a very particular way. E.g. I like to talk to Grok in voice mode, in romantic mode, and then do some analysis of some topic (or rather that is what I just naturally do), and then Grok complements my mind in ways that my mind likes, e.g. pointing out that I used a particular thinking pattern that is good or that I at all thought about this difficult thing and then I am like "Ah yes that was actually good, and yes it seems like this is a difficult topic most people would not think about."

Reply
Johannes C. Mayer's Shortform
Johannes C. Mayer26d30

Mathematical Notation as Learnable Language

To utilize mathematical notation fully you need to interpret it. To read it fluently, you must map symbols to concrete lenses, e.g. computational, visual, algebraic, or descriptive.


Example: Bilinear Map

Let

f:R2×R2→R

be defined by

f((x1,x2),(y1,y2))=x1y1+2x2y2.

Interpretations:

  1. Computational

    Substitute specific vectors and check results. If v=(3,4), then

    f((x1,x2),v)=3x1+8x2,

    Through this symbolic computation we can see how the expression depends on x. Perform such computations until you get a feel for the "shape" of the functions behavior.

  2. Visual

    For each fixed v, the function u↦f(u,v) is represented by a hyperplane in R2×R. We can imagine walking on the hyperplane. This obviously always walks on a line, therefore it's linear.

  3. Symbolic manipulation

    Verify algebraically:

    f(au+bw,v)=(au1+bw1)v1+2(au2+bw2)v2=af(u,v)+bf(w,v).

    This establishes linearity by direct algebraic manipulation. You understand what properties exist by showing them algebraically.

  4. Descriptive

    What it means to be a bilinear map is, that if you hold the second argument fixed, and vary the second, you have a linear function. Same if holding the first fixed and varying the second.

    You want to capture the intuition in natural language.


Mathematical language is a language that you need to learn like any other. Often people get stuck by trying to use symbolic manipulation too much. Because mathematical language is so precise, it makes it easy to interpret it in many different while still being able to check if your interpretation captures the core.

Reply1
johnswentworth's Shortform
Johannes C. Mayer1mo41

My mind derives pleasure from deep philosophical and technical discussions.

Reply
johnswentworth's Shortform
Johannes C. Mayer1mo60

In model flirting is about showing that you are paying attention. You say things that you could only pick up if you pay close attention to me and what I say. It's like a cryptographic proof certificate, showing that you think that I am important enough to pay attention to continuously. Usually this is coupled with an optimization process of using that knowledge to make me feel good, e.g. given a compliment that actually tracks reality in a way I care about.

It's more general than just showing sexual interest I think.

Reply
johnswentworth's Shortform
Johannes C. Mayer2mo21

I don't use it to write code, or really anything. Rather I find it useful to converse with it. My experience is also that half is wrong and that it makes many dumb mistakes. But doing the conversation is still extremely valuable, because GPT often makes me aware of existing ideas that I don't know. Also like you say it can get many things right, and then later get them wrong. That getting right part is what's useful to me. The part where I tell it to write all my code is just not a thing I do. Usually I just have it write snippets, and it seems pretty good at that.

Overall I am like "Look there are so many useful things that GPT tells me and helps me think about simply by having a conversation". Then somebody else says "But look it get's so many things wrong. Even quite basic things." And I am like "Yes, but the useful things are still useful that overall it's totally worth it."

Maybe for your use case try codex.

Reply
Load More
The Pointers Problem
2y
(+538/-86)
Fallacy of Gray
2y
(-1)
Fallacy of Gray
2y
(+357)
Inner Alignment
3y
(+3/-2)
5S-Expressions as a Design Language: A Tool for Deconfusion in Alignment
Ω
21d
Ω
0
24Constraining Minds, Not Goals: A Structural Approach to AI Alignment
Ω
1mo
Ω
0
20The Insanity Detector and Writing
4mo
3
18The Legacy of Computer Science
6mo
0
55Vegans need to eat just enough Meat - emperically evaluate the minimum ammount of meat that maximizes utility
7mo
35
16Doing Sport Reliably via Dancing
7mo
0
14Goal: Understand Intelligence
8mo
19
1A Cable Holder for 2 Cent
10mo
1
19Why Reflective Stability is Important
10mo
2
3Playing Minecraft with a Superintelligence
11mo
0
Load More