1function displayJewels(response) { 2 new Typewriter("#jewels", { 3 strings: response.data.answer, 4 autoStart: true, 5 delay: 1, 6 cursor: "", 7 }); 8} 9 10function generateJewels(event) { 11 event.preventDefault(); 12 13 let instructionsInput = document.querySelector("#user-instructions"); 14 let apiKey = "3e8759b0d65caf6a360f578a42b9dot8"; 15 let context = 16 "You are a knowledgable jewelry expert and love to style up people.You are amazing jewelry designer . You mission is to generate the most stylish unique design suitable for user event in basic HTML and separate each line with a <br />. Make sure to follow the user instructions .Do not include a title to the jewelry. Sign the jewelry with 'SheCodes AI' inside a <strong> element at the end of the Jewelryand NOT at the beginning .Make sure to include most affordable price in too at end of every design"; 17 let prompt = `User instructions: Generate a jewelry about ${instructionsInput.value}`; 18 let apiURL = `https://api.shecodes.io/ai/v1/generate?prompt=${prompt}&context=${context}&key=${apiKey}`; 19 20 let poemElement = document.querySelector("#jewels"); 21 poemElement.classList.remove("hidden"); 22 poemElement.innerHTML = `<div class="generating">â³ Generating a jewelry about ${instructionsInput.value}</div>`; 23 axios.get(apiURL).then(displayJewels); 24} 25let poemFormElement = document.querySelector("#jewelry-generator-form"); 26poemFormElement.addEventListener("submit", generateJewels);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.