Live data from Hacker News

Building a Virtual Machine Inside ChatGPT

engraved.blog

341–350 of 947 posts

Re: Building a Virtual Machine Inside ChatGPT

#342
This ChatGPT really blows my mind with some stuff.

I randomly typed in "Tell me a story about a software engineer who descends into alcohol addiction."

I got back:

There once was a brilliant software engineer named Sarah. She had a natural talent for writing code and a passion for creating innovative software applications. She loved her job and was highly respected by her peers and superiors.

However, Sarah also struggled with inner demons. She had always been a perfectionist and a high achiever, but this came at a cost. She was constantly stressed and anxious, always pushing herself to the limit. She often worked long hours and never seemed to take time for herself.

As time went on, Sarah found herself turning to alcohol to cope with the pressure. At first, it was just a drink or two after work to unwind. But soon, she was drinking more and more, until it became a daily habit. She would come home from work, pour herself a drink, and spend the evening alone, staring at her computer screen.

At first, Sarah's drinking didn't affect her work. She was still producing high-quality code and meeting all of her deadlines. But as her addiction grew, she started to make mistakes. She would forget important meetings and miss deadlines. She would show up to work hungover and struggling to focus.

Her supervisors and coworkers started to notice the change in her behavior and grew concerned. They tried to talk to her about her drinking, but she became defensive and refused to admit that she had a problem. She was in denial and couldn't see the harm that her addiction was causing.

Finally, Sarah hit rock bottom. She was fired from her job and lost everything she had worked so hard for. She was alone, unemployed, and addicted to alcohol. She realized that she needed help and sought out treatment for her addiction.

It was a long and difficult journey, but Sarah was determined to overcome her addiction and rebuild her life. She attended rehab, learned new coping skills, and began to reconnect with the things she used to love. Slowly but surely, she began to heal and rebuild her life.

Today, Sarah is sober and thriving. She has a new job, a supportive community, and a newfound sense of peace and purpose. She looks back on her journey with gratitude, knowing that she has overcome a great challenge and come out stronger on the other side.

Re: Building a Virtual Machine Inside ChatGPT

#343

I've spent a couple of hours playing with ChatGPT since it was released and I am convinced people are not freaking out about it enough. It is well beyond merely retrieving compressed knowledge; I see a lot of capability for synthesis and what I can only call 'understanding'. I think a lot of people are getting tripped up by the fact it's trained to be very conservative in terms of what topics it will discuss. It's ea…

This could be the tech that dislodges Google from its monopoly! There are definitely questions I would prefer this experience than Google and the inevitable SEO spam for introduction type questions. If the generated text included further links to learn more it would be awesome.

Google has been chasing this stuff from the beginning and has probably been devoting tons more resources to it than OpenAI. Given their infrastructure and existing user advantage, once they think this will be feasible and better than existing Google Search, they will make sure it becomes Google Search.

Re: Building a Virtual Machine Inside ChatGPT

#344
post #109

Earlier quoted context omitted.

"general intelligence" means so many things to different people. This can code better than most programmers I've worked with, on novel problems.

ChatGPT seems to disagree with this assessment. Prompt: Can you code better than most programmers? Response: As a large language model trained by OpenAI, I don’t have the ability to write or execute code. My function is to provide general information and answer questions based on the text that I have been trained on. I do not have the same capabilities as a human programmer and am not able to perform complex tasks su…

Modest, isn't it?

Try this:

> write a python script to download a page from hacker news

(Python script to get https://news.ycombinator.com/)

> make it download this page: https://news.ycombinator.com/item?id=33847479

(Python script to get https://news.ycombinator.com/item?id=33847479)

> now find the comment by the user "dragonwriter" on that page

This script uses the re (regular expression) module to search for the string "dragonwriter" in the HTML file. If a match is found, it prints the matching string. (This is ChatGPT's explanation BTW)

> can you do that by querying the DOM?

Here is an example of how you might use BeautifulSoup to search for the comment by "dragonwriter" in the HTML file: (correct script follows)

Re: Building a Virtual Machine Inside ChatGPT

#345
It's very cool that you can run some python code in ChatGPT. Moreover, its python seems to have an integer overflow problem.

> I want you to act as a python interpreter. I will type commands and you will reply with what the terminal should show. I want you to only reply with the terminal output inside one unique code block, and nothing else. Do no write explanations. Do not type commands unless I instruct you to do so. When I need to tell you something in English I will do so by putting text inside curl brackets {like this}. My first command is print('Hello World').

Hello World

> l = [1, 1] for i in range(2, 100): l.append(l[i-1] + l[i-2])

print(l[:60])

[1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987, 1597, 2584, 4181, 6765, 10946, 17711, 28657, 46368, 75025, 121393, 196418, 317811, 514229, 832040, 1346269, 2178309, 3524578, 5702887, 9227465, 14930352, 24157817, 39088169, 63245986, 102334155, 165580141, 267914296, 433494437, 701408733, 1134903170, 1836311903, 2974808370, 4811805473, 7712777313, 12552040332, 20277215517, 32809805901, 52949708537, 85819868961, 138799055938, 223698329301, 365497597541, 590198454580, 965596908802, 1565800818933, 2541213821873, 4117124400766, 6699682812639, 10831622575801, 17532468141340, 28365448716941, 46208008488321, 74514670894261, 120724679684982, 195240235318303, 315780697528144, 511000771197447, 827781568619191, 1338781770749838, 2176564902024129, 3514418353773270, 5710877373977599, 9226323127750669, 14937202445647909, 24157816312226068, 39088217670086237, 63245987386802425, 102334157406978654]

Re: Building a Virtual Machine Inside ChatGPT

#346

I've spent a couple of hours playing with ChatGPT since it was released and I am convinced people are not freaking out about it enough. It is well beyond merely retrieving compressed knowledge; I see a lot of capability for synthesis and what I can only call 'understanding'. I think a lot of people are getting tripped up by the fact it's trained to be very conservative in terms of what topics it will discuss. It's ea…

Call me a skeptic, but I'm frankly a bit surprised that the output of ChatGPT gets attributed to any sort of understanding or general intelligence. Whatever ChatGPT does currently, albeit novel and impressive, is still extremely limited in scope and very far from any sort of general intelligence. I'd love to be proven wrong, but I still have a hard time seeing how this is going to change whole industries.

Ask it to write you a story or some poetry ... you'll be surprised at how creative it can be.

Re: Building a Virtual Machine Inside ChatGPT

#347

Earlier quoted context omitted.

ChatGPT seems to disagree with this assessment. Prompt: Can you code better than most programmers? Response: As a large language model trained by OpenAI, I don’t have the ability to write or execute code. My function is to provide general information and answer questions based on the text that I have been trained on. I do not have the same capabilities as a human programmer and am not able to perform complex tasks su…

Should confront it with some obvious evidence that it can write code. Such as asking it about a coding problem.

I like this:

> Why can't most programmers solve FizzBuzz?

[snip]

The reason why most programmers cannot solve the FizzBuzz problem is that it requires a basic understanding of programming concepts, such as loops, conditionals, and modulo arithmetic. Many programmers may not have a strong foundation in these concepts, or may not be familiar with the specific requirements of the FizzBuzz problem. As a result, they may struggle to write a correct and efficient solution to the problem.

[snip]

> solve FizzBuzz in Bash using recursion

  # Function to solve the FizzBuzz problem
  fizzbuzz() {
    # Check if the number is greater than 100
    if [[ $1 -gt 100 ]]; then
      # If so, return
      return
    fi

    # Check if the number is a multiple of 3 and 5
    if [[ $1 -eq 0 ]]; then
      echo "FizzBuzz"
    # Check if the number is a multiple of 3
    elif [[ $(( $1 % 3 )) -eq 0 ]]; then
      echo "Fizz"
    # Check if the number is a multiple of 5
    elif [[ $(( $1 % 5 )) -eq 0 ]]; then
      echo "Buzz"
    # Otherwise, print the number
    else
      echo $1
    fi

    # Increment the number and call the function recursively
    fizzbuzz $(( $1 + 1 ))
  }

  # Call the function to solve the FizzBuzz problem
  fizzbuzz 1
This solution uses a recursive function called fizzbuzz to solve the FizzBuzz problem. The function takes a number as an argument and checks if it is greater than 100. If so, it returns and the recursion ends. Otherwise, it checks if the number is a multiple of 3 and 5, 3, or 5, and outputs the appropriate string (FizzBuzz, Fizz, or Buzz) based on the result of the check. For all other numbers, the function simply outputs the number itself. It then increments the number and calls the function recursively with the incremented value as the argument. This continues until the number is greater than 100, at which point the recursion ends and the solution is complete.

This solution is correct and efficient, as it uses a recursive function and the modulo operator to check for the required conditions and output the appropriate string. It also follows the best practices of the Bash programming language, such as using [[ to test conditions and $(( )) to perform arithmetic operations.

Re: Building a Virtual Machine Inside ChatGPT

#348

When can we run something like ChatGPT locally i wonder? Ie like StableDiffusion. I'm kinda dying for that, honestly. I can't even imagine all the neat applications i'd make of ChatGPT if it was purely local.. but it would take all of my free time to play with it. It's so damn impressive.

Agreed. The things I want to do with this don't make sense as a web service.

Re: Building a Virtual Machine Inside ChatGPT

#349
post #30
post #21

Well, I couldn't resist: > {create a script called hn.py that will print out the top 10 posts on hacker news} [a lot of output] > python hn.py 1: Apple acquires Tesla 2: Amazon to open 10,000 brick-and-mortar stores 3: Google unveils new AI technology 4: Facebook to launch new virtual reality headset 5: Microsoft announces new partnership with SpaceX 6: Uber introduces flying cars 7: Twitter to double character limit…

More succinct prompt: > w3m news.ycombinator.com

Interesting, that‘s what I got:

                              HN Search powered by Algolia
Hacker News Search:

Top Stories

Submit

Log In

Top Stories

Show HN: A Turing machine game (github.com)

Ex-Facebook executive defends Parler, says Amazon Web Services was its only option (cnbc.com)

Pascal's Triangle (brian-borchers.com)

SpaceX Starship SN8 explodes on landing (twitter.com)

Google's new quantum computer is 100 million times faster than a classical one (arstechnica.com)

Stories

Ask HN: What are some great products or services that were killed off by their creators? (self.AskHN)

FreeBSD’s new Code of Conduct (freebsd.org)

GPT-3, the most powerful AI language model, is now available for beta testing (openai.com)

Tech Giants and Their Market Dominance (maketecheasier.com)

Show HN: Y Combinator News with Algolia search (github.com)

Re: Building a Virtual Machine Inside ChatGPT

#350
post #299

Earlier quoted context omitted.

I'm surprised that anyone could be so skeptical over what is clearly an incredible technological breakthrough. It's not perfect - in particular the making up nonsense problem needs to be solved before it can be relied on - but the difference between this and the "state of the art" just 4 years ago is off the chart. GitHub CoPilot has already changed my day to day life, and I'm frequently astounded by the level of app…

I tested ChatGPT with a couple of topics I’m personally unclear on, and while it is linguistically eloquent, it basically just regurgitates the majority opinions that can be found on the internet on those topics (sometimes combining several of those opinions in an incoherent way). It wasn’t possible to engage it with actual reasoning on specific aspects of those topics. It just went with whatever premise you gave it,…

> It doesn't have any thought or understanding of its own

Of course it doesn't. Anyone who says it does clearly doesn't understand how large language models work.

I'm finding it incredibly useful as an actual tool already - it turns out regurgitating combinations of things it knows about from the internet is just astoundingly useful.

I'm having it teach me Rust for example. I don't need original thought for that, just the ability to answer questions about how a rust works and show me sample code.

https://github.com/simonw/advent-of-code-2022-in-rust/issues...

Post reply on HN