41 karma · joined Jan 1, 2024 (2y ago) · 41 submissions
1.
A Tour of Barkdown(pratik.deoghare.com ↗)
1 points · by pratikdeoghare · 5d ago · discuss
2.
Roman Numerals and the Symptom of Bad Design(pratik.deoghare.com ↗)
1 points · by pratikdeoghare · 1w ago · discuss
3.
Missing Tools of Literate Programming(pratik.deoghare.com ↗)
4 points · by pratikdeoghare · 1w ago · discuss
comment 2w ago · link · parent
You have a list of sets and their subsets below them shown on screen. Now you take one element from one of the sets and add it to another set want things updated, this will trigger exponential computation. Since we (human) can't really visually look at all the exponential subsets anyway it will be not a very useful visulalization.
So exponential state space will be a problem only in the cases we don't care about it. Even then we could choose only few of the states by some criteria.
comment 2w ago · link · parent
comment 1mo ago · link · parent
- I wanted it to implement 5 buttons for some actions. I told Claude only about 4 of them. Then I implemented frontend/backend for the fifth one myself pretending that I just joined the project.
- I made Claude implement backend only and frontend only and then connected them myself.
I will never ship without looking. I might not look right away and ship when I am pushed. But then I will go into the code later and look anyway.
I don’t care which way the industry goes. I like looking under the hood and understanding stuff. Understanding makes you much faster because you can think inside of your head. Because I understood the code I knew just what to do when something was off. I love it when that happens.
I do feel bad when I think I don’t understand. I still go back and read high school book even though my grades were good.
comment 1mo ago · link · parent
Even before complex numbers, I was confused by negative numbers. Why negative times negative suddenly positive?
I spent time figuring that out. When complex numbers came I was ready. I knew they were not really numbers that would count something. And that they are just called numbers.
comment 1mo ago · link · parent
> Starting with a given convex quadrilateral, construct a square, external to the quadrilateral, on each side. Van Aubel's theorem states that the two line segments between the centers of opposite squares are of equal lengths and are at right angles to one another.
comment 1mo ago · link · parent
#foo`fmt.Println("Hello world!")`
instead of current
#foo{`fmt.Println("Hello world!")`} .
This would mean code can have tags too just like bags. Right now only bags can have tags and children. If you want to tag something, you have to put it in a bag. This works for tagging blogs, code, other bags.
I think the extra braces are worth suffering for uniformity like the trailing commas.
comment 1mo ago · link · parent
Because it stops after making you a tree. Markdown takes your document all the way to html. Making it do anything else requires much work.
file.md -> markdown -> file.html
file.bt -> brashtag -> tree -> to-html -> file.html
file.bt -> brashtag -> tree -> todo-list-maker -> todo list
...
file.bt -> brashtag -> tree -> ... -> ...
Brashtag is not about code at all. Most text is already a valid brashtag. It is optimized for human writing. For example, this comment is a valid brashtag document if you surround it with #{} which can be done by a program easily.
comment 1mo ago · link · parent
As you have noticed it is poor substitute for json. It would be cumbersome to write config file in brashtag.
> This isn't a competitor to markdown.
You can write blog post in markdown. You can write it just as elegantly in brashtag. Only brashtag does not convert the doc to html for you. It just gives you tree. You write a program that processes the tree and produces html.
Example,
Markdown: # Lorem ipsum dolor sit amet
Consectetur _adipiscing_ elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam.
---
Brashtag:
#h1{Lorem ipsum dolor sit amet}
Consectetur #u{adipiscing} elit, sed do eiusmod tempor incididunt #b{ut labore et dolore} magna aliqua. Ut enim ad minim veniam.
OR you could write
#really big title{Lorem ipsum dolor sit amet}
Consectetur #super duper underline{adipiscing} elit, sed do eiusmod tempor incididunt #emphsize{ut labore et dolore} magna aliqua. Ut enim ad minim veniam.
comment 1mo ago · link · parent
> 'this is a bag named code with a blob, therefore it is code."
This would make #code{} a special bag. Right now no bag is special. Also it would be hard to find the closing } if somebody wrote unbalanced paren code in the bag like #code{ func main() { }.
comment 1mo ago · link · parent
See how easy it is to write programs to process brashtag [1].
I can chat with llm, interact with jupyter kernel and do literate programming from any text editor all in the same document [3].
It took me like 10 minutes to build this mermaid like thing [2].
List of frustrations:
- One day Anki crashed. --- You can just write #card{....} in a text file. Some program would read it and show flashcards in browser.
- Another day JabRef crashed. --- You can just write #bib{....} put link to a paper and its citation info there and have a program download the paper and copy the citation to bib file.
- Markdown parser processed mathjax wrong. Why keep trying different markdown parsers? Just write #h1{}, #b{} #i{} and just convert them to html tags.
- Literate programming tool I was using failed at some corner case.
- My notes were scattered across files and tools. I couldn't find anything. I tried to have a text file where sections were separated by four dashes. But that didn't allow nesting. Also, the parser I wrote for that hit corner cases. Why not just put #note{} #JIRA-334{} etc. in text file.
[1] https://github.com/PratikDeoghare/brashtag#some-programs [2] https://github.com/PratikDeoghare/brashtag/tree/master/cmd/m... [3] https://www.youtube.com/watch?v=IMXgIE0Vljg
comment 1mo ago · link · parent
Here I am using it as frontend to Jupyter and ollama [2].
comment 3mo ago · link · parent
There are many such lines (think convex hull) and they are easy to find. This makes it hard to appreciate the theorem. You keep thinking oh whats the big deal.
[1] https://en.wikipedia.org/wiki/Sylvester%E2%80%93Gallai_theor...
comment 4mo ago · link · parent
This would be my advice. Why? My own road was haphazard. Other books broaden your mind and teach you really cool tricks. This book gets you using lisp like you would say golang. But it still teaches you the lisp things and broadens your mind. Time spent choosing will be better spent reading this book. After that PAIP, On Lisp, SICP etc.
comment 4mo ago · link · parent
I find such tasks easier to just do in the programming language directly than describe them in English.
comment 4mo ago · link · parent
These frontends are necessary however because researchers in non-computer related fields are not trained/proficient at command line tools. Many of them need help installing software. Many of them don’t use raw text files much either. They use MS word files instead etc.
comment 5mo ago · link · parent
When this article was posted here earlier I got an idea that maybe wearing a mechanical watch for a while might help.
I bought a cheap mechanical watch. It needs manual winding daily. If you take it off your wrist it gets out of sync with the other clocks or just stops.
Few weeks with that clock convinced me.
comment 6mo ago · link · parent
or you could come up with a notation that works in any editor. I have [1].
> That way you can easily try different ways without deleting any text.
Sorry I haven't yet read your story. Here is how I would explore alternatives with my notation. I do this when designing software/algorithms etc.
``` Elias performed at this level for about a year. He was up for a well-deserved promotion to staff engineer. I sent him a meeting invite to go through the updated leveling framework to make sure we didn't miss anything.
#{ #{ Elias declined the meeting. } #{ Elias went to the meeting but he went late.} ... }
```
comment 6mo ago · link · parent
BUT
Some people memorize these things. Take them too seriously. You are thought stupid if you don't know them. Somewhere someone then makes a story on Jira to verify that your product does all of these things and you have to convince them that we are fine without them or we don't need all of them etc.