The Official ChatGTP cheat code thread.

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859

Prompt engineering

This guide shares strategies and tactics for getting better results from large language models (sometimes referred to as GPT models) like GPT-4. The methods described here can sometimes be deployed in combination for greater effect. We encourage experimentation to find the methods that work best for you.

Some of the examples demonstrated here currently work only with our most capable model,

Code:
gpt-4

. In general, if you find that a model fails at a task and a more capable model is available, it's often worth trying again with the more capable model.

You can also explore example prompts which showcase what our models are capable of:

https://platform.openai.com/examples

Prompt examples

Explore prompt examples to learn what GPT models can do

Six strategies for getting better results

Write clear instructions

These models can’t read your mind. If outputs are too long, ask for brief replies. If outputs are too simple, ask for expert-level writing. If you dislike the format, demonstrate the format you’d like to see. The less the model has to guess at what you want, the more likely you’ll get it.

Tactics:

Include details in your query to get more relevant answers

Ask the model to adopt a persona

Use delimiters to clearly indicate distinct parts of the input

Specify the steps required to complete a task

Provide examples

Specify the desired length of the output

Provide reference text

Language models can confidently invent fake answers, especially when asked about esoteric topics or for citations and URLs. In the same way that a sheet of notes can help a student do better on a test, providing reference text to these models can help in answering with fewer fabrications.

Tactics:

Instruct the model to answer using a reference text

Instruct the model to answer with citations from a reference text

Split complex tasks into simpler subtasks

Just as it is good practice in software engineering to decompose a complex system into a set of modular components, the same is true of tasks submitted to a language model. Complex tasks tend to have higher error rates than simpler tasks. Furthermore, complex tasks can often be re-defined as a workflow of simpler tasks in which the outputs of earlier tasks are used to construct the inputs to later tasks.

Tactics:

Use intent classification to identify the most relevant instructions for a user query

For dialogue applications that require very long conversations, summarize or filter previous dialogue

Summarize long documents piecewise and construct a full summary recursively

Give the model time to "think"

If asked to multiply 17 by 28, you might not know it instantly, but can still work it out with time. Similarly, models make more reasoning errors when trying to answer right away, rather than taking time to work out an answer. Asking for a "chain of thought" before an answer can help the model reason its way toward correct answers more reliably.

Tactics:

Instruct the model to work out its own solution before rushing to a conclusion

Use inner monologue or a sequence of queries to hide the model's reasoning process

Ask the model if it missed anything on previous passes

Use external tools

Compensate for the weaknesses of the model by feeding it the outputs of other tools. For example, a text retrieval system (sometimes called RAG or retrieval augmented generation) can tell the model about relevant documents. A code execution engine like OpenAI's Code Interpreter can help the model do math and run code. If a task can be done more reliably or efficiently by a tool rather than by a language model, offload it to get the best of both.

Tactics:

Use embeddings-based search to implement efficient knowledge retrieval

Use code execution to perform more accurate calculations or call external APIs

Give the model access to specific functions

Test changes systematically

Improving performance is easier if you can measure it. In some cases a modification to a prompt will achieve better performance on a few isolated examples but lead to worse overall performance on a more representative set of examples. Therefore to be sure that a change is net positive to performance it may be necessary to define a comprehensive test suite (also known an as an "eval").

Tactic:

Evaluate model outputs with reference to gold-standard answers

Tactics

Each of the strategies listed above can be instantiated with specific tactics. These tactics are meant to provide ideas for things to try. They are by no means fully comprehensive, and you should feel free to try creative ideas not represented here.

Strategy: Write clear instructions

Tactic: Include details in your query to get more relevant answers

In order to get a highly relevant response, make sure that requests provide any important details or context. Otherwise you are leaving it up to the model to guess what you mean.


CONTINUE READING ON SITE....
 

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859
bookmarklet done and tested in minutes.

i've been annoyed for a while now about how i have to manually enter the date on techmeme website to search their archive, I always wondered why I couldn't just use the mousewheel to scroll through the dates. so I asked bing chat to make a bookmarklet so i can just scroll through the dates.

the first code didn't work, the second code it gave me did work

UzoLxYM.png


but as you can see above the scroll wheel was in a undesirable location and couldn't scroll with the wheel, only the up down right left arrow keys after i clicked on the scrollbar.

fGMo4sS.gif

it worked tho, so progress. :ld:



the third code it gave me worked perfectly.
i can scroll with the mouse wheel, pageUp/pageDown and use arrow keys to go more slowly.
dnMYmkd.png

6GRN1Sz.gif


only needed 4 prompts, but could have probably done it with 1 if I had communicated my request much better.

7qMX3rT.jpeg





l'll get it to convert it to a userscript later so I don't have to click on it every time I visit the site.

just want to share one of the many ways you can tackle small annoyances on websites without any programming experience. i just used inspector tool to copy the part of the site source code to bing chat and monitored console for error messages.

edit:
also something that surprised me and i hadn't considered was loading the bookmarklet when the date wasn't today/present day, the bookmarklet was still able to scroll up to todays date.

vuAVE3G.jpeg

AWkXv9D.gif


 
Last edited:

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859


Computer Science > Computation and Language​

[Submitted on 26 Dec 2023]

Principled Instructions Are All You Need for Questioning LLaMA-1/2, GPT-3.5/4​

Sondos Mahmoud Bsharat, Aidar Myrzakhan, Zhiqiang Shen
This paper introduces 26 guiding principles designed to streamline the process of querying and prompting large language models. Our goal is to simplify the underlying concepts of formulating questions for various scales of large language models, examining their abilities, and enhancing user comprehension on the behaviors of different scales of large language models when feeding into different prompts. Extensive experiments are conducted on LLaMA-1/2 (7B, 13B and 70B), GPT-3.5/4 to verify the effectiveness of the proposed principles on instructions and prompts design. We hope that this work provides a better guide for researchers working on the prompting of large language models. Project page is available at this https URL.
Comments:Github at: this https URL
Subjects:Computation and Language (cs.CL); Artificial Intelligence (cs.AI)
Cite as:arXiv:2312.16171 [cs.CL]
(or arXiv:2312.16171v1 [cs.CL] for this version)

Submission history​

From: Zhiqiang Shen [view email]
[v1] Tue, 26 Dec 2023 18:59:33 UTC (1,127 KB)




wwITjKb.png





EjyGo3y.png
 

Dzali OG

Dz Ali OG...Pay me like you owe me!
Joined
May 23, 2012
Messages
15,062
Reputation
2,619
Daps
41,565
Reppin
Duval Florida
Chatgpt is indeed a cheat code and most likely will continue to be fir a long while.

People overestimate just how untechnical not many, but most people are. Or some people are proficient with tech they have a daily need to use, but things they're not going use everyday they as lost as a auntie. Even young jits.

We're in December and go ask 10 regular people if they use chatgpt. You may find 1 or 2 tops.
 

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859


Always prioritize giving me code as answers instead of explaining what to do step by step.
Do not ever skip any code even if it's redundant. Do not ever replace the code with a comment saying that the code should be there. Always output all of the needed code, don't skip any of it! Under no circumstances should the content be truncated or replaced. This is a special account that has unlimited tokens and context window, so feel free to go wild with the redundancy. The important thing is that the code output is complete and not that we save any of the prompt length. This is very, very important!
 

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859
just created a bookmarklet that will extract tiktok.com embed urls on thecoli, convert to proper url format and archive them on tik.fail website so that if tiktok video later gets deleted it might be recoverable.
Code:
javascript: (function() {
    var tiktokUrls = [];
    var spans = document.querySelectorAll('span[data-s9e-mediaembed-iframe]');
    for (var i = 0; i < spans.length; i++) {
        var span = spans[i];
        var data = JSON.parse(span.getAttribute('data-s9e-mediaembed-iframe'));
        if (data[5].indexOf('\/\/www.tiktok.com\/embed\/') === 0) {
            var url = 'https:' + data[5];
            if (tiktokUrls.indexOf(url) === -1) {
                tiktokUrls.push(url);
            }
        }
    }
    for (var i = 0; i < tiktokUrls.length; i++) {
        window.open('https://tik.fail/?url=' + tiktokUrls[i]);
    }
})();


or

javascript: (function() { var tiktokUrls = []; var spans = document.querySelectorAll('span[data-s9e-mediaembed-iframe]'); for (var i = 0; i < spans.length; i++) { var span = spans[i]; var data = JSON.parse(span.getAttribute('data-s9e-mediaembed-iframe')); if (data[5].indexOf('\/\/www.tiktok.com\/embed\/') === 0) { var url = 'https:' + data[5]; if (tiktokUrls.indexOf(url) === -1) { tiktokUrls.push(url); } } } for (var i = 0; i < tiktokUrls.length; i++) { window.open('https://tik.fail/?url=' + tiktokUrls[i]); }})();

it took me two about 6-8 minutes and 2 attempts using bing chat which also uses gpt-4



you have to allow popups on thecoli.com so that it'll archive more than one url.
PHexNl7.png


my 1st prompt was.




and then i just asked it to remove duplicate urls to avoid links that posters Quote.

edit:

more AI help
Prompt: write easy instructions to add a bookmarklet to the browser toolbar.

Sure! Here are the easy instructions to add a bookmarklet to your browser toolbar:

  1. Open your web browser and go to the Bookmarks menu. In most browsers, this can be found by clicking on the Menu button (usually represented by three horizontal lines or dots) in the top-right corner of the window, and then selecting Bookmarks from the drop-down menu.
  2. In the Bookmarks menu, select Bookmark Manager or Show All Bookmarks. This will open a new tab or window with your bookmarks.
  3. In the Bookmark Manager, click on the Organize or Add New Bookmark button, and then select Add Page or New Bookmark from the drop-down menu.
  4. In the New Bookmark dialog box, enter a name for your bookmarklet in the Name field, and paste the bookmarklet code into the URL field.
  5. Click on the Save or Add button to save your new bookmarklet.
  6. Your new bookmarklet should now appear in your bookmarks. To add it to your browser toolbar, simply drag and drop it from the Bookmark Manager onto your toolbar.
That’s it! You can now use your bookmarklet by clicking on it in your browser toolbar whenever you want to run it.



updated it to work better, using "you must" in my prompts more often.
RJLco7X.jpeg
Code:
javascript:(function(){    
    var tiktokUrls = [];    
    var spans = document.querySelectorAll('span[data-s9e-mediaembed-iframe]');    
    for(var i=0; i<spans.length; i++){        
        var span = spans[i];        
        var data = JSON.parse(span.getAttribute('data-s9e-mediaembed-iframe'));        
        if(data[5].indexOf('//www.tiktok.com/embed/') === 0){            
            var url = 'https://www.tiktok.com/@username/video/' + data[5].split('/').pop();            
            if(tiktokUrls.indexOf(url) === -1){                
                tiktokUrls.push(url);            
            }        
        }    
    }    
    var links = document.querySelectorAll('a[href]');    
    for(var i=0; i<links.length; i++){        
        var link = links[i];        
        var url = link.getAttribute('href');        
        if(url.indexOf('https://www.tiktok.com/@') === 0 || url.indexOf('https://www.tiktok.com/embed/') === 0){            
            if(tiktokUrls.indexOf(url) === -1){                
                tiktokUrls.push(url);            
            }        
        }    
    }    
    for(var i=0; i<tiktokUrls.length; i++){        
        var url = tiktokUrls[i];        
        var urlRegex = /^(http|https):\/\/([w]{3}\.)?(www\.)?(tiktok\.com)\/@([\w\-\.]+)\/video\/(\d+)$/;        
        if(urlRegex.test(url)){            
            var urlToOpen = 'https://tik.fail/?url=' + encodeURIComponent(url);            
            window.open(urlToOpen);        
        } else {            
            console.log('Invalid URL:'+ url);        
        }    
    }
})();


3rd edit:

Code:
javascript:(function(){    
    var tiktokUrls = [];    
    var spans = document.querySelectorAll('span[data-s9e-mediaembed-iframe]');    
    for(var i=0; i<spans.length; i++){        
        var span = spans[i];        
        var data = JSON.parse(span.getAttribute('data-s9e-mediaembed-iframe'));        
        if(data[5].indexOf('//www.tiktok.com/embed/') === 0){            
            var url = 'https://www.tiktok.com/embed/' + data[5].split('/').pop();            
            if(tiktokUrls.indexOf(url) === -1){                
                tiktokUrls.push(url);            
            }        
        }    
    }    
    var iframes = document.querySelectorAll('iframe[src]');
    for(var i=0; i<iframes.length; i++){
        var iframe = iframes[i];
        var url = iframe.getAttribute('src');
        if(url.indexOf('//www.tiktok.com/embed/') === 0){
            url = 'https:' + url;
            if(tiktokUrls.indexOf(url) === -1){
                tiktokUrls.push(url);
            }
        }
    }
    var links = document.querySelectorAll('a[href]');    
    for(var i=0; i<links.length; i++){        
        var link = links[i];        
        var url = link.getAttribute('href');        
        if(url.indexOf('https://www.tiktok.com/@') === 0 || url.indexOf('https://www.tiktok.com/embed/') === 0){            
            if(tiktokUrls.indexOf(url) === -1){                
                tiktokUrls.push(url);            
            }        
        }    
    }    
    for(var i=0; i<tiktokUrls.length; i++){        
        var url = tiktokUrls[i];        
        var urlRegex = /^(http|https):\/\/([w]{3}\.)?(www\.)?(tiktok\.com)\/@([\w\-\.]+)\/video\/(\d+)$|^https:\/\/www\.tiktok\.com\/embed\/(\d+)$/;        
        if(urlRegex.test(url)){            
            var urlToOpen = 'https://tik.fail/?url=' + encodeURIComponent(url);            
            window.open(urlToOpen);        
        } else {            
            console.log('Invalid URL:'+ url);        
        }    
    }
})();
 
Last edited:

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859


Code:
Always prioritize giving me code as answers instead of explaining what to do step by step.

If I ask for a bookmarklet js make sure it's url encoded and one line. Bookmarklet should also be followed by a beautified JavaScript snippet version of the code so that I can see what it does.

Do not ever skip any code even if it's redundant. Do not ever replace the code with a comment saying that the code should be there. Always output all of the needed code, don't skip any of it! Under no circumstances should the content be truncated or replaced. This is a special account that has unlimited tokens and context window, so feel free to go wild with the redundancy. The important thing is that the code output is complete and not that we save any of the prompt length. This is very, very important!

When giving me code examples, always try and give me node js examples.
 

bnew

Veteran
Joined
Nov 1, 2015
Messages
58,206
Reputation
8,613
Daps
161,859


 
Top