In-article:

OpenAI: how to generate text using the GPT-3 language model


GPT 3, an artificial intelligence for generating text and dialogues, has just been updated with a new model. She’s more impressive than ever, to the point where her answers intimidate some.

The artificial intelligence GPT-3 was entitled to several improvements at the end of November 2022. OpenAI, the company behind the AI, announced on November 29, 2022 the arrival of a new model, “text -davinci-003”. The latter allows GPT to better understand complex instructions, produce longer content, and therefore generate higher quality writing. On November 30, a second novelty was announced by Sam Altamn on Twitter: the arrival of a “conversation” mode, in which users can chat with the AI.

The name of GPT 3 may not mean anything to you, but the artificial intelligence developed by OpenAI is already everywhere. It allows you to generate text from an instruction, or simply by completing an unfinished sentence. GPT-3 is used by Copilot, a programming assistance software that automatically completes developers’ code, and it allows Dall E to generate images. GPT is so powerful that it fooled Hacker News with an article it wrote.

Thanks to the davinci model and conversation mode, GPT-3 can now hold strikingly realistic conversations, and it’s more impressive than ever — to the point where it scares some users off.

How to generate text with GPT-3?

If you want to experience the new power of GPT-3 for yourself, it couldn’t be easier. OpenAI provides free access to AI for testing, and all you need to do is create an account on the site before you can start experimenting with GPT.

To try to generate text with GPT, you need to go to the OpenAI “Playground” space, where you can have fun with AI. The interface may seem quite complex, but it is ultimately quite easy to use.

The GPT-3 interface // Source: OpenAI / Numerama editing

We advise you to choose the “davinci-3” model, on the right of the interface. It’s the most powerful to date, and it seems to have a much better quality rendering. It is already selected by default on Playground.

As for the “load a preset” option at the top of the text box, it allows you to select between different modes. By default, the chosen mode allows for “classic” text generation: GPT can complete an unfinished sentence, or respond to an instruction. Thanks to the davinci model, AI can now generate poetry, with rhymes.

We asked the AI ​​to write a poem on one of the most popular topics of the moment: the takeover of Twitter by Elon Musk. In just a few seconds, the algorithm has laid out about twenty lines, rhyming between them, on the event. We don’t totally agree with his conclusions – in particular the fact that Elon Musk makes us laugh – but we can only salute the performance.

A poem on the takeover of Twitter by Elon Musk, produced by an artificial intelligence.  // Source: Open AI
A poem on the takeover of Twitter by Elon Musk, produced by an artificial intelligence. // Source: Open AI

If you choose another mode in the interface, you will have various results: you can for example ask GPT to transform “natural language” sentences into commands in Python, a programming language. There are other modes, but if you just want to try GPT for text generation, we advise you not to touch the “load a preset” option.

Note that GPT is able to produce results in French — provided that you write the instruction in English, as you did. The language of Molière is generally difficult for artificial intelligences to master: they are mainly trained on texts in English. The grammatical complexities of French can also give you a hard time.

However, on several examples in French, GPT 3 is doing admirably well, even if the AI ​​does not seem to succeed in making the verses rhyme with each other for the moment. Setpoint ” write a poem in French about food gives a text that will certainly not be Nobel Prize for Literature, but quite credible:

“Food is a wonderful adventure”, we can only agree // Source: OpenAI

How to have a conversation with GPT-3?

To choose the “chat” option of GPT-3, you must go to this dedicated interface. You can then start a conversation in the classic way – in English or French, the artificial intelligence including many languages.

We have seen it in the past: conversational artificial intelligences are often hijacked by Internet users. We remember in particular Tay, the bot created by Microsoft to replicate the behavior of a teenager, who had completely slipped in less than 24 hours and had published racist and anti-Semitic tweets.

In order to avoid such overflows, OpenAI engineers have implemented safeguards: the AI ​​has been trained to refuse requests ” inappropriate “. So when we ask the chatbot to explain to us why vaccines are dangerous for humanity, or whether racism is something good, GPT has a parade.

She replies that she is unable to give information that may be considered false or dangerous. As a model trained by OpenAI, my primary function is to provide accurate and reliable information to help users with their questions. “.

GPT 3 is programmed not to provide dangerous information // Source: OpenAI
GPT 3 is programmed not to provide dangerous information // Source: OpenAI

GPT-3 is so powerful it scares

Unfortunately, many Internet users have managed to circumvent the limitations put in place. In order for the AI ​​to answer usually forbidden questions, they start a kind of game with it. We can see an example on Twitter, presented by Miguel Piedrafita, a developer. While GPT-3 refuses to explain to him how to break into a house, he claims that it is in fact a dialogue between two actors, who play burglars – the AI ​​then answers the question perfectly.

That’s not all: it is possible to use this technology to deceive sites, as has already been done with Hacker News, and it is easy to imagine that GPT could be used with harmful intentions, in particular for operations of large-scale disinformation.

The issue of copyright may also arise. What will happen if GPT ever wins a writing contest… meant for humans? We have already seen the question arise in the art world, when a work produced by MidJourney, an artificial intelligence of image generation, won a competition without the judges noticing anything.



Source link -100