Holy crap! Programmers better start looking for a new line of work!

SeniorBen

Senior Member
I was wondering if ChatGPT could generate code based on a requirement. This is what I got...

Requirement: Write a PHP function to retrieve the text to audio from AWS based on the text passed as a parameter

Code:
<?php
require 'vendor/autoload.php';

use Aws\Polly\PollyClient;
use Aws\Exception\AwsException;

function retrieveAudioFromAws($text) {
  // AWS credentials
  $awsAccessKeyId = '<Your AWS Access Key Id>';
  $awsSecretAccessKey = '<Your AWS Secret Access Key>';

  // Polly Client
  $pollyClient = new PollyClient([
    'version' => 'latest',
    'region' => 'us-west-2',
    'credentials' => [
    'key' => $awsAccessKeyId,
    'secret' => $awsSecretAccessKey
    ]
  ]);

  try {
    // Create a SynthesizeSpeechPresignRequest

    $request = $pollyClient->getSynthesizeSpeechPresignUrl([
    'OutputFormat' => 'mp3',
    'Text' => $text,
    'VoiceId' => 'Joanna'
  ]);

    // Get the URL for the audio file
    $audioUrl = $request->get('Url');
    return $audioUrl;
  } catch (AwsException $e) {
    // An error occurred
    echo $e->getMessage();
  }
}

// Example usage
$text = "Hello, this is an example of how to retrieve audio from AWS based on the text passed as a parameter.";
$audioUrl = retrieveAudioFromAws($text);

// You can use the $audioUrl to play the audio or download the file.

I haven't tested it, but it looks right. Yikes!
 

Last edited:
Using AI generated code will greatly reduce the amount of time required to write software, which no doubt will result in layoffs. We're already seeing layoffs in the tech industry — partially because of over-hiring during the pandemic. I suspect we'll see more of that as AI gets incorporated into software shops. We'll still need engineers to design the software, and architects to design the systems, but a lot of the programmers won't be needed, nor will many of the test "engineers." AI will be used, not only to write code but to test the system. The result will be far better software.

That's the economic downside.

The upside of AI assisted software development is that if it takes fewer people to do the work, it opens the door to a return to the days when one or two developers could write a complex piece of software and compete with some of the bigger companies. That was the case back in the '90s. Of course, the small companies often got bought up by bigger ones, but that's how things work.
 
I would be more concerned if I was a writer, chatGPT replied to OP:

As an AI language model, I understand that this statement might be based on a fear of automation and job displacement in the field of programming. However, it's important to note that while automation may change the nature of some jobs, it has also created new opportunities in the past.

Programming is a dynamic field that is constantly evolving, and new technologies and tools are being developed all the time. The key for programmers is to continuously learn and upskill, so they can stay relevant and take advantage of new opportunities as they arise.

It's also worth noting that there is still a high demand for skilled programmers, and this is unlikely to change in the near future. So, rather than looking for a new line of work, it might be more productive for programmers to focus on developing their skills and staying up-to-date with the latest technologies.

I asked for a human reply:

Hey there, I hear what you're saying about programmers needing to find a new line of work, but I don't think it's quite that dire just yet. While automation has disrupted certain industries in the past, it's also led to the creation of new jobs and opportunities.

Programming is a field that's always changing and growing, and there's always going to be a need for people who are able to adapt and stay ahead of the curve. Instead of worrying about finding a new job, I'd say focus on sharpening your skills and keeping up with the latest and greatest in the programming world. That way, you'll be ready for whatever new opportunities come your way.
 
I asked chatGBT to write some guidelines and rules for a forum for senior citizens, it doesn't allow politics. What do you think about its work? ;)

Here are some guidelines and rules for a forum for senior citizens that does not allow politics:

1. Respect for all members: All members should be treated with respect and dignity. Personal attacks, harassment, or hate speech will not be tolerated.

2. No political discussions: This forum is a place for seniors to connect and discuss topics that are important to them, but political discussions are not allowed.

3. Staying on topic: Please make sure your posts are relevant to the topic at hand and stay on topic. Posts that are off-topic or spam will be removed.

4. Confidentiality: Please respect the privacy of other members and do not share personal information or private conversations without their permission.

5. Constructive criticism: If you disagree with someone's post, please do so in a respectful and constructive manner.

6. No commercial promotions: This forum is not a platform for commercial promotions or advertisements. Any posts that appear to be promoting a product or service will be removed.

7. Reporting violations: If you come across a post that you feel violates these guidelines, please use the "Report" button to bring it to the attention of the moderators.

By following these guidelines, we can create a safe and inclusive community for senior citizens to connect and share their experiences.
 
I used this when I was doing custom coding. Code generation on steroids.

https://xlinesoft.com/phprunner/screenshots.htm
I tried a few of those code generation applications years ago. Some were decent, some created more work than they saved. And code maintenance was a nightmare.

ChatGPT writes code in the style of a good programmer. I think it's a game changer. We shall see, though.
 
I asked chatGBT to write some guidelines and rules for a forum for senior citizens, it doesn't allow politics. What do you think about its work? ;)

Here are some guidelines and rules for a forum for senior citizens that does not allow politics:

1. Respect for all members: All members should be treated with respect and dignity. Personal attacks, harassment, or hate speech will not be tolerated.

2. No political discussions: This forum is a place for seniors to connect and discuss topics that are important to them, but political discussions are not allowed.

3. Staying on topic: Please make sure your posts are relevant to the topic at hand and stay on topic. Posts that are off-topic or spam will be removed.

4. Confidentiality: Please respect the privacy of other members and do not share personal information or private conversations without their permission.

5. Constructive criticism: If you disagree with someone's post, please do so in a respectful and constructive manner.

6. No commercial promotions: This forum is not a platform for commercial promotions or advertisements. Any posts that appear to be promoting a product or service will be removed.

7. Reporting violations: If you come across a post that you feel violates these guidelines, please use the "Report" button to bring it to the attention of the moderators.

By following these guidelines, we can create a safe and inclusive community for senior citizens to connect and share their experiences.
That's pretty good!

I'm sure in the near future, you'll be able to use AI to help moderate the forums and detect political posts. There will probably be a plugin for XenForo and all the other popular web forum applications. With ChatGPT, it would take just a few minutes to write something like that.
 
I agree with all except this one:
3. Staying on topic: Please make sure your posts are relevant to the topic at hand and stay on topic. Posts that are off-topic or spam will be removed.
One of the most endearing (to me) aspects of Senior Forums is that conversations evolve and meander, just as they do in real life. Sometimes they go back to the original post, but oftentimes they do not. Most people here seem fine with that.

Spam should indeed be be removed.

For the record, I think political posts have been handled well here. Sometimes it's almost impossible to have a conversation about current events without slightly stepping into the political realm and those posts have been left intact. Quite sensibly.

Other conversations become politically charged and divisive, and those get shut down. Again, quite sensibly.

Thanks for doing what you do, @Matrix!
 
I agree with all except this one:

One of the most endearing (to me) aspects of Senior Forums is that conversations evolve and meander, just as they do in real life. Sometimes they go back to the original post, but oftentimes they do not. Most people here seem fine with that.

Spam should indeed be be removed.

For the record, I think political posts have been handled well here. Sometimes it's almost impossible to have a conversation about current events without slightly stepping into the political realm and those posts have been left intact. Quite sensibly.

Other conversations become politically charged and divisive, and those get shut down. Again, quite sensibly.

Thanks for doing what you do, @Matrix!
Yeah, I agree. The rule should be something like, "if the person who started the thread asks you to stay on-topic, do so."
 
It's just not programmers, but artists and writers as well.

Heck, AI will do a better job raising children than many parents.
 
This was inevitable.
My daddy always said when you build a ten foot wall, people start building eleven foot ladders.

Case in point: SF members quickly realized certain words in our postings will become a series of asterisks, Our taller ladder: s*x, s ex, and similar. It's not actually against forum policy because we're not discussing provocative matters. AI may be "intelligent" but it's not wise enough to know when it's throwing out the baby along with the bathwater.

Artificial intelligence is constantly thwarted by humans determined to do so. Taller walls, taller ladders.
 
I asked chatGBT to write some guidelines and rules for a forum for senior citizens, it doesn't allow politics. What do you think about its work? ;)

Here are some guidelines and rules for a forum for senior citizens that does not allow politics:

1. Respect for all members: All members should be treated with respect and dignity. Personal attacks, harassment, or hate speech will not be tolerated.

2. No political discussions: This forum is a place for seniors to connect and discuss topics that are important to them, but political discussions are not allowed.

3. Staying on topic: Please make sure your posts are relevant to the topic at hand and stay on topic. Posts that are off-topic or spam will be removed.

4. Confidentiality: Please respect the privacy of other members and do not share personal information or private conversations without their permission.

5. Constructive criticism: If you disagree with someone's post, please do so in a respectful and constructive manner.

6. No commercial promotions: This forum is not a platform for commercial promotions or advertisements. Any posts that appear to be promoting a product or service will be removed.

7. Reporting violations: If you come across a post that you feel violates these guidelines, please use the "Report" button to bring it to the attention of the moderators.

By following these guidelines, we can create a safe and inclusive community for senior citizens to connect and share their experiences.
ChatGBT did a good job. I wouldn’t be concerned about a topic drifting to other thoughts; it’s just not that important. The OP can say something if the discussion is too far off topic. They should consider that doing that might make them seem grumpy or domineering.
 
My daddy always said when you build a ten foot wall, people start building eleven foot ladders.

Case in point: SF members quickly realized certain words in our postings will become a series of asterisks, Our taller ladder: s*x, s ex, and similar. It's not actually against forum policy because we're not discussing provocative matters. AI may be "intelligent" but it's not wise enough to know when it's throwing out the baby along with the bathwater.

Artificial intelligence is constantly thwarted by humans determined to do so. Taller walls, taller ladders.
And that's not a bad thing, imo. Challenges are a necessity. People can't advance and evolve without them.
 
ChatGBT did a good job. I wouldn’t be concerned about a topic drifting to other thoughts; it’s just not that important. The OP can say something if the discussion is too far off topic. They should consider that doing that might make them seem grumpy or domineering.
Agreed. I've started topics that went off in a whole other direction and it wasn't bothersome at all... it's how conversations go "in real life" so it just always seems natural to me. @Jules
 
And that's not a bad thing, imo. Challenges are a necessity. People can't advance and evolve without them.
Very true. I watch my 14 month old grandson working out obstacles. He comes here 3 days a week. Every single time he checks the cabinets to see if we forgot to put them on. Every. Single. Time. When he finds an unlocked cabinet, he giggles with glee for the five seconds it takes for us to close and lock the cabinet. Undaunted, he moves to the next one in hopes of more success.
 
Agreed. I've started topics that went off in a whole other direction and it wasn't bothersome at all... it's how conversations go "in real life" so it just always seems natural to me. @Jules
I agree with that, conversations straying off topic is just human nature. Something an AI wouldn't understand. LOL I love starting a conversation with someone about something like apples and ending up talking about outerspace and an hour later it's like wait, how did we end up talking about aliens? LOL 🤣🤣 It's funny how a conversation takes on a life of it's own. But I do love the no politics rule though. People get way too heated and passionate about politics. It's like their religion. LOL Best to avoid that discussion since we all have different opinions. :) (y)
 
Very true. I watch my 14 month old grandson working out obstacles. He comes here 3 days a week. Every single time he checks the cabinets to see if we forgot to put them on. Every. Single. Time. When he finds an unlocked cabinet, he giggles with glee for the five seconds it takes for us to close and lock the cabinet. Undaunted, he moves to the next one in hopes of more success.
Babies are so smart! Much smarter than we think they are! It's fun to watch them as they learn about how the world works. :love:
 
Is this part of the reason why so many people are suffering from dementia....we are letting machines do our thinking for us? We already watch too much television, which is bad for our brains. Brain cells atrophy if not used. If this carries on we will be a nation of zombies.
 


Back
Top