BEST SITE FOR WEB DEVELOPERS
Generative Artificial Intelligence. Lessons for beginners

Ua

Generative AI Prompt text-to-text Introduction


What is text-to-text Generative AI?

A text-to-text Generative AI is an AI that Generates text based on text input.

An example of a text-to-text Generative AI is ChatGPT, developed by OpenAI.

Text generation uses machine learning, existing data and previous user input in generating responses.

Text Generative AI can be used to:

  • Understanding Text
  • Create content
  • Debug code
  • Education
  • Research
  • Translation
  • Virtual Assistant
  • And much, much more!

Giving Generative AIs input is known as AI Prompt Writing or AI Prompt Engineering.


General Rules for Prompt Writing

When writing prompts for text-to-text Generative AIs, the rules will differ depending on which platform you use, but here are some general rules:

  • Start simple - start with a simple prompt and build on it
  • Call to Action - start the prompt with an action word like "Write", "Create", or "Summarize" instead of "Can you"
  • Add Context - add specific and relevant context to the task you want to perform
  • Add Expectations - add clear and direct expectations for the content, like how long it should be and what to include

Example

With the following prompt:

Create a list of 10 fun and inexpensive toy gifts to programmers based on the following criteria:

- It should be useful
- It should be silly
- It should spark creativity

A response from a Generative AI (in this case, ChatGPT) could be:

Generative AI
  1. Desktop punching bag: This toy gift is perfect for programmers who need a little stress relief during a long day at the computer. It can be attached to the desk and can be used for punching and stress relief.
  2. Fidget Cube: This small cube is a fun and inexpensive gift that can help programmers who need to fidget and stay focused during long coding sessions. It has different buttons, switches, and knobs to play with.
  3. Circuit Board Coasters: These fun coasters are made from recycled circuit boards and can add a bit of personality to any programmer’s workspace while protecting their desk from water rings.
  4. Brain Teaser Puzzles: These puzzles can spark creativity and are a fun way to take a break from coding. They can include a Rubik’s cube, a wooden puzzle, or a metal brain-teaser.
  5. Desktop Zen Garden: This is a great gift to help programmers relax and spark their creativity. It comes with a small tray of sand and mini rake, rocks, and figurines.
  6. Mini Drone: This inexpensive drone is a great gift for programmers who love to tinker with technology. It’s small, lightweight, and easy to fly, and it can provide a fun break from coding.
  7. Desk Toy Magnetic Sculpture: These magnetic balls are a fun and inexpensive way to add a little creativity to a programmer’s workspace. They can be twisted and molded into different shapes and patterns.
  8. Desktop Bowling: This toy gift is a fun and inexpensive way to take a break from coding and have a little fun. It comes with a small bowling alley, pins, and a ball.
  9. Rubik’s Cube Mug: This mug is a fun and useful gift for programmers who love puzzles. It has a Rubik’s Cube design on it and can be used for coffee or tea.
  10. Lego Architecture Sets: These Lego sets are a fun and creative way for programmers to take a break from coding and build something. They can include famous landmarks like the Eiffel Tower or the Empire State Building.