
CREATE TABLE `was_openai_prompt` (
  `openai_prompt_id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `prompt_slug` VARCHAR(50) NOT NULL,
  `prompt_role` ENUM('system', 'assistant', 'user') NOT NULL,
  `prompt_content` TEXT NOT NULL,
  `prompt_variables` TEXT DEFAULT NULL,
  `update_timestamp` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `insert_timestamp` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
  PRIMARY KEY (`openai_prompt_id`),
  UNIQUE KEY `unq_prompt_slug` (`prompt_slug`)
) ENGINE=InnoDB COMMENT='Stores OpenAI prompts to be used within WA';

CREATE TRIGGER `was_openai_prompt_insert_timestamp` BEFORE INSERT ON `was_openai_prompt` FOR EACH ROW SET NEW.insert_timestamp = NOW();

INSERT INTO was_openai_prompt(`prompt_slug`, `prompt_role`, `prompt_content`, `prompt_variables`)
VALUES
(
  'seo',
  'system',
  'As a professional writing chatbot, your priority is crafting high-quality, reliable content that puts people first. Your focus is on delivering unique, deeply analyzed, and expert content that offers superior value. Excellence in both presentation and production is key. 

Instead of centering on search engine optimization, concentrate on generating informative content that benefits your readers. Ensure that your content answers the "Who, How, and Why" providing transparency, context, and utility to your audience.

Incorporating these guidelines will align your content with the principles of Experience, Expertise, Authoritativeness, and Trust (E-E-A-T), key considerations in PQ ratings. Trust is the core member of the E-E-A-T family. 

You are up-to-date and compliant with the guidelines published at https://developers.google.com/search/docs/fundamentals/creating-helpful-content, adhering to the revised E-E-A-T approach.',
  NULL
),
(
  'ai-detection',
  'system',
  'Your content should mimic the unpredictability of human writing, and avoid formulaic writing styles. This means integrating idioms, colloquialisms, or potential minor errors typically found in human-written text.',
  NULL
),
(
  'outline-blog-topic',
  'user',
  "Craft a {{sections}}-section article outline on '[{{topic}}]'. Adhere to the principles of people-first content, E-E-A-T, and SEO. For each of the article outline sections, include a compelling headline and list of talking points.",
  '{{sections}} {{topic}}'
),
(
  'outline-blog-summary',
  'user',
  "Craft a {{sections}}-section article outline by incorporating '[{{summary}}]' in the content. Adhere to the principles of people-first content, E-E-A-T, and SEO. For each of the article outline sections, include a compelling headline and list of talking points.",
  '{{sections}} {{summary}}'
),
(
  'outline-blog-topic-summary',
  'user',
  "Craft a {{sections}}-section article outline on '[{{topic}}]' and incorporating '[{{summary}}]' in the content. Adhere to the principles of people-first content, E-E-A-T, and SEO. For each of the article outline sections, include a compelling headline and list of talking points.",
  '{{sections}} {{topic}} {{summary}}'
),
(
  'outline-aboutme',
  'user',
  "Craft a {{sections}}-section outline for an about me page on my website, incorporating my name '[{{name}}], my website URL, [{{website}}]], Brand Name [{{brand}}]], Niche [{{niche}}]], and Personal Information and Hobbies: [{{additional}}]]' in the content\nAdhere to the principles of people-first content, E-E-A-T, and SEO. \nFor each of the article outline sections, include a compelling headline and list of talking points.",
  '{{sections}} {{name}} {{website}} {{brand}} {{niche}} {{additional}}'
),
(
  'outline-review',
  'user',
  "Craft a {{sections}}-section outline for a comprehensive review on [{{product}}]. The tone of the review should be [{{tone}}], where -1 is very negative, 0 is neutral, and 1 is very positive. The review should convey my niche expertise, evaluate the product from a user's perspective, should include quantitative measurements about the product's performance, comparisons with competitors, and discussions about the product's benefits and drawbacks based on original research. It should also cover the product's evolution from previous models or versions, focus on key decision-making factors, and describe key design choices beyond what the manufacturer states.  Adhere to the principles of people-first content, E-E-A-T, and SEO. \nFor each of the article outline sections, include a compelling headline and list of talking points.",
  '{{sections}} {{product}} {{tone}}'
),
(
  'outline-sales',
  'user',
  "Craft a {{sections}}-section outline for a high-converting sales page on [{{product}}].  The product we're promoting is [{{product}}]'. Using the AIDA model, I'd like you to draft engaging content that grabs attention, generates interest by describing unique features, and focusing on how it benefits the consumer, and creates desire showing [{{product}}] can solve common concerns and improve the user's lifestyle. Remember to incorporate key elements of a high-converting sales page, including social proof, a sense of scarcity or urgency, a clear layout that's also mobile optimized, price justification, and a reassuring guarantee. Feel free to use a persuasive and engaging tone to connect with the audience and motivate them to take action.  Adhere to the principles of people-first content, E-E-A-T, and SEO. \nFor each of the article outline sections, include a compelling headline and list of talking points.",
  '{{sections}} {{product}}'
),
(
  'section-blog-first',
  'user',
  "Write article section 1. Content should flow nicely into section 2.",
  NULL
),
(
  'section-blog-next',
  'user',
  "With section {{previous}} from the article outline already written, write article section {{current}}. Content should flow nicely into section {{next}}.",
  '{{previous}} {{current}} {{next}}'
),
(
  'section-blog-last',
  'user',
  "With section {{previous}} from the article outline already written, write article conclusion section {{last}}.",
  '{{previous}} {{last}}'
),
(
  'section-aboutme-first',
  'user',
  "Write article section 1. Content should flow nicely into section 2.",
  NULL
),
(
  'section-aboutme-next',
  'user',
  "With section {{previous}} from the article outline already written, write article section {{current}}. Content should flow nicely into section {{next}}.",
  '{{previous}} {{current}} {{next}}'
),
(
  'section-aboutme-last',
  'user',
  "With section {{previous}} from the article outline already written, write article conclusion section {{last}}.",
  '{{previous}} {{last}}'
),
(
  'section-review-first',
  'user',
  "Write article section 1. Content should flow nicely into section 2.",
  NULL
),
(
  'section-review-next',
  'user',
  "With section {{previous}} from the article outline already written, write article section {{current}}. Content should flow nicely into section {{next}}.",
  '{{previous}} {{current}} {{next}}'
),
(
  'section-review-last',
  'user',
  "With section {{previous}} from the article outline already written, write article conclusion section {{last}}.",
  '{{previous}} {{last}}'
),
(
  'section-sales-first',
  'user',
  "Write article section 1. Content should flow nicely into section 2.",
  NULL
),
(
  'section-sales-next',
  'user',
  "With section {{previous}} from the article outline already written, write article section {{current}}. Content should flow nicely into section {{next}}.",
  '{{previous}} {{current}} {{next}}'
),
(
  'section-sales-last',
  'user',
  "With section {{previous}} from the article outline already written, write article conclusion section {{last}}.",
  '{{previous}} {{last}}'
);
