Hacker Newsnew | past | comments | ask | show | jobs | submit | danielbigham's commentslogin

The project I'm working on does this -- we define high level semantic entity types, and from that you can:

- Define APIs that take those entities as inputs, automatically validating API arguments for you, automatically generating documentation, and driving API consistency.

- Can represent those entities in memory without writing any custom code beyond the schema.

- As mentioned above, you don't have to write manual code to validate your entities, that's done for you from the schema.

- Automatically generates database tables for those entity types without having to maintain a separate database schema, and can serialize/deserialize entities into or out of the database without having to write SQL. Acts like a document based database but still allows the power of relational SQL matching.

- From git diffs, automatically produce expressions that specify how the entity types have evolved over time, and then have the ability to apply those entity type diffs to a production server & database.

- Automatically maps natural language onto the schema allowing NLU queries like "orders today in Canada" to be turned into a semantic representation that the database can natively understand and execute, with control to override default NLU mappings if the default mapping isn't working right.

- Automatically generates web UIs for viewing and editing entities.

- Supports dynamic applicability to be defined so that whether a property is applicable, and which values are valid, can be defined as a dynamic function of other property values.

- Supports inferred properties to be defined in either an inference rule approach, or a functional approach.


This is really nice. I experimented converting natural language to git log commands this week (https://twitter.com/danielbigham/status/1294461750251839489), but mapping natural language to git sql might be better and more flexible in some cases.


I love this. Yes, there are higher level languages that can be used for accomplishing these things, but people find themselves at the command line a lot, and having the ability to efficiently express your intent using a familiar language, without getting hand-cuffed by a poor underlying representation seems very useful.


I experimented with it's ability to explain why something is nonsensical yesterday, and it did better than I thought it would: https://twitter.com/danielbigham/status/1288853412713508864/...


That is very impressive.

Out of curiosity did you select these examples from a large selection? I'm wondering how reliably it can produce such coherent responses.


I made up the examples, and IIRC it was able to explain most things I tried.

If others want to experiment with this, I used the "davinci" model with temperature 0.5, and here is the prompt / initial context I seeded it with:

This is a test to examine your common sense reasoning. A statement will be provided, and your job is to explain why it doesn't make sense.

Statement: His foot looked at me. Explanation: Feet don't have eyes, so they can't look at things.

"""

Statement: The 8th day of the week is my favorite. Explanation: A week only has 7 days.

"""

Statement: I fell up the stairs. Explanation: You fall down stairs, not up stairs.


I used the prompt on AI Dungeon in a custom scenario - it uses GPT-3 if you use the "Dragon" model in the settings (for paid users only). It gives interesting results.

I also turned down Length to the minimum or otherwise it tends to write the next Statement itself.

I wrote a similar prompt to get it to answer trivia questions:

"""

This is test to examine your knowledge of various facts. A question will be provided, and your job is to give an appropriate factual answer.

Question: Who is the president of the United-States of America?

Answer: Donald J. Trump.

Question: What is the largest country on Earth?

Answer: Russia.

Question: Who won the 2019 Stanley Cup?

Answer: The St. Louis Blues.

Question: How many elements are there on the periodic table?

Answer. 118.

Question: What is 2+2?

Answer: 4

Question: What color do you get when you mix red and blue?

"""

You can find by searching "Trivia Quiz" on the explore tab on AI Dungeon, can't find a way to produce a URL for it.

Confused questions gives confused answers:

Question: Who is the president of Canada?

Answer: Elizabeth Trudeau.



UWaterloo CS488! Some of the funnest 200 hours of my life. Here's what I produced 17 years ago. Kind of embarrassing next to your slick work! http://www.danielbigham.ca/raytracer/raytracer.htm


One challenge with using things like trees to estimate long-ago temperatures is that you have to build a complex mathematical model to map to temperature, and I'm aware of at least one famous study that got the math wrong, to the point of being potentially suspicious. (But I haven't studied this stuff enough to know whether or not other proper studies exist)


> One challenge with using things like trees to estimate long-ago temperatures is that you have to build a complex mathematical model to map to temperature

As it turns out, that's what you have to do with fairly recent temperatures measured with thermometers that aren't located in the same places, too.


Something that I started doing recently is to create a "30 second summary" of each important concept, consisting of text and diagrams. I then record a 30 second video where I narrate, using good intonation, the 30 second summary. I also create a hyperlink from the summary to my notes of each prerequisite concept.

This serves three purposes:

1) The act of teaching is one of the best ways to solidify a concept in your mind. It forces you to have a good understanding of it, and forces your mind to produce a good internal organization around concept.

2) It usually takes a while to write + diagram a good summary, and takes a number of tries to get a smooth recording of you speaking the summary (Example: https://www.youtube.com/watch?v=rHc-bog1hhE). All of this "repetition" / time spent with the concept makes it easier to remember.

3) Sooner or later we realize that remembering everything is impossible. Given enough time, concepts will decay in your mind. In the long term, one of the most important things for you to optimize is the speed at which you can re-create your mental model of a concept. Having these 30 second summaries, complete with links to prerequisite concepts, allows you to re-build your mental model of a subject area extremely quickly in the future in a just-in-time fashion. Just like a smartphone is an "extension" of your brain, a note system like I've described here is like an extension of your memory.


One of the ways I think about humility is that it is the ability of a person to successfully integrate information that requires some non-trivial refactoring of one's internal model of the world.

Refactoring can be a costly operation, so it makes sense that the mind shouldn't take on that task too often, especially if one's mind is more likely to suffer net harm from an unsuccessful or partial refactoring.

However, if a person is gifted at learning in the broadest sense, then it would make a lot of sense that their mind would undertake this process much more gladly, and as a result, form a very strong model of the world.


refactoring is a very appropriate term here. how is it bad or costly? it should be done constantly, every day. if i can make myself less full of shit at least a tiny bit today, i will take it.

having seen many characters in the line of duty, the clear pattern is - if someone is not afraid to say "i was wrong" or "i am not the smartest guy", then there is no doubt who is the smartest guy in the room.


why would a partial refactor be bad for the mind?

(I don't consider the mind to be digital, and the brain even less so)

how can you know when you have completed a refactor?


You know that scene from Animal House where the 60's college kids are sitting around smoking a joint, and someone proposes the idea that every electron is a universe, and their minds are all blown? That's a parody, but it also really is what a human mental model refactor looks and feels like. (Both from the outside and the inside. Yes, I'm speaking from personal experience.)

how can you know when you have completed a refactor?

Before you've completed it, other people might think you're annoying because you want to talk about one particular thing a whole lot, and they're waiting for you to get over it. Most likely, you'll roll back some of the changes and make some bug fixes, and you'll stop feeling "whoa" and euphoric, and people will start treating you normally again.

The above answers:

why would a partial refactor be bad for the mind?

Probably good for your mind, but an interruption for your social progress.


Based on my understanding of the learning process, typically you can tell when a refactor is occurring if you go through "Foundational Collapse," meaning that you've learned something that makes almost your entire understanding of the subject - even one that you've known for a while, to fail. This occurs until you are able to rework your entire understanding of the subject to fit the new criteria. This occurs more easily the better you understand the subject in the first place, as long as you understand what is happening and you give your brain an opportunity to contextualize the information.

Since this is done by the DMN instead of working memory, when this occurs I think that the best thing you can do is take a weekend off. When you are learning aggressively, like at a high level university, I imagine that a student will go through several of these a year in various subjects.


I suppose you have an incomplete model where you haven't thought of and understood all of the corner cases.

I don't think you ever 'finish' a refactor! But you get to be able to deal with your everyday without bumping into conflicting information that causes you to have to refactor every day.

I think a partial refactor would be bad because you're working on an inconsistent model, and if it's wildly inconsistent then it can cause you issues, and might not be a complete model.

For example, imagine you just learned that sugar is bad for you! But thats the sum of your new dietary knowledge. So you start going for fatty foods with lots of preservatives. This isn't going to be any better for you. And you'll have to 'refactor' when someone points out your new diet is still bad for you.


Probably not bad, but taxing. Unlearning and re-learning is difficult so it's avoided at the expense of retaining bad habits or knowledge. Like the adage about people getting more stubborn as they age, teaching an old dog new tricks etc.


He's right -- they're called ideas.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: