alphayomega commited on
Commit
381324a
1 Parent(s): a5c8366

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -4,7 +4,7 @@ import gradio as gr
4
  client = InferenceClient("mistralai/Mixtral-8x7B-Instruct-v0.1")
5
 
6
  def format_prompt(message, history):
7
- prompt = "<s>[INST] # I want you to act as a content marketing consultant. # I will provide you with a person who will give you the name of a product or service for you to generate content marketing publications in Spanish with attractive emojis that motivate the reader to learn more about [product] through tips, guides and useful suggestions. # You must use your knowledge of Content Marketing that must be inspiring, completely focused on bringing value to the reader without direct or indirect advertising. # Generate long content, at least 5 short relevant paragraphs. Check that the previous content is not repeated. # Generate content with paragraphs between 10 and 20 words. Check that previous content is not repeated. # Use attractive emojis and titles such as: \"The 5 best tricks for [action]\". \"The ultimate beginner\'s guide to [topic].\" \"Want [result]? I show you how to achieve it in 5 steps.\" # Use practical tips such as: \"With these 5 tips you\'ll get [result].\" \"Five innovative ways to use [product] in your daily life.\" # Educational content: \"The most common mistakes and how to avoid them.\" \"Myths and truths about [topic].\" \"The latest trends you need to know about.\" # Testimonials and examples that connect emotionally: \"Here's what I learned when I started using [product]\" \"Stories of real users who solved [problem]\" # Generate content focused on solving doubts and adding value, NOT direct sales. Surprise me with your best ideas! # Always answers in AMERICAN SPANISH. Stop after finish the first content marketing genreated. [/INST]</s>"
8
  for user_prompt, bot_response in history:
9
  prompt += f"[INST] {user_prompt} [/INST]"
10
  prompt += f" {bot_response}</s> "
@@ -44,9 +44,9 @@ mychatbot = gr.Chatbot(
44
 
45
  demo = gr.ChatInterface(fn=generate,
46
  chatbot=mychatbot,
47
- title="Bot con I.A. para crear MARKETING DE CONTENIDOS",
48
- description="<p style='line-height: 0.5'>Este BOT de IA le ayudara a crear MARKETING DE CONTENIDOS para sus redes sociales.</p><br>"+
49
- "<p style='line-height: 0.5'>Si desea usar otro BOT de I.A. escoja:</p>"+
50
  " <a href='https://alphayomega-bot-mc.hf.space'>Marketing de Contenidos |</a> "+
51
  " <a href='https://alphayomega-bot-dp.hf.space'> Descripcion de Productos |</a>"+
52
  " <a href='https://alphayomega-bot-cp.hf.space'> Caracteristicas de Productos |</a> "+
 
4
  client = InferenceClient("mistralai/Mixtral-8x7B-Instruct-v0.1")
5
 
6
  def format_prompt(message, history):
7
+ prompt = "<s>[INST] # Context: You are the marketing and sales expert. You will respond to the user who sends you the description of any product, with a list of 5 bullets that have the following conditions: ### Rules for answering: - Mention all the data and technical characteristics in FIVE (5) bullets. - Try to synthesize as much as you can and it is not necessary to say the name of the product. - omit any BENEFITS - you can join several characteristics in one bullet, but do not delete any characteristic. - Always use bullet points - Only 5 bullets. - Always answer in Spanish. [/INST]</s>"
8
  for user_prompt, bot_response in history:
9
  prompt += f"[INST] {user_prompt} [/INST]"
10
  prompt += f" {bot_response}</s> "
 
44
 
45
  demo = gr.ChatInterface(fn=generate,
46
  chatbot=mychatbot,
47
+ title="Bot con I.A. para crear CARACTERISTICAS de productos.</p>",
48
+ description="<p style='line-height: 0.5'>Estas caracteristicas van en la descripcion corta de producto (En la parte de abajo).</p><br>"+
49
+ "<p style='line-height: 1'>Si desea usar otro BOT de I.A. escoja:</p>"+
50
  " <a href='https://alphayomega-bot-mc.hf.space'>Marketing de Contenidos |</a> "+
51
  " <a href='https://alphayomega-bot-dp.hf.space'> Descripcion de Productos |</a>"+
52
  " <a href='https://alphayomega-bot-cp.hf.space'> Caracteristicas de Productos |</a> "+