Skip to main content

OpenAI::ChatGPT - ChatGPT scraper

img

Overview of the scraper

Overview: customization

The ChatGPT scraper. It is based on the official API and uses an API key.

A-Parser functionality allows you to save scraper settings for Google for future use (presets), set a scraping schedule, and much more. You can use automatic query multiplication, substitute subqueries from files, iterate through alphanumeric combinations and lists to get the maximum possible number of results.

Saving results is possible in the form and structure you need, thanks to the built-in powerful template engine Template Toolkit which allows you to apply additional logic to the results and output data in various formats, including JSON, SQL, and CSV.

Collected data

  • Response from ChatGPT
  • Number of tokens used

Capabilities

  • Scrape response from ChatGPT
  • Ability to set System prompt content

Use cases

  • Generating responses from ChatGPT to any questions

Queries

As queries, you need to specify text in one line, for example:

int main() { std::cout << "Hello, user!"; return 0; }
What are 5 key points I should know when studying Ancient Rome?

Query substitutions

You can use built-in macros for query multiplication.

In the query format, we will specify the iteration of characters from a to zzzz, this method allows you to maximally rotate the search output and get many new unique results:

$query {az:a:zzzz}

This macro will create 475254 additional queries for each original search query, which in total will give 4 x 475254 = 1901016 search queries, an impressive figure, but it's not a problem for A-Parser at all. At a speed of 2000 queries per minute, such a task will be processed in just 16 hours.

Output results examples

A-Parser supports flexible formatting of results thanks to the built-in template engine Template Toolkit, which allows it to output results in any form, as well as in structured formats, for example CSV or JSON

Default output

Result format:

Used tokens: $total_tokens, Answer:\n$answer\n

Example of result:

Used tokens: 54, Answer:
print("Hello, user!")
exit(0)
Used tokens: 290, Answer:
1. Founding and Early History: Ancient Rome was founded in 753 BCE by twin brothers Romulus and Remus. The city grew to become one of the most powerful and influential empires in world history.
2. Roman Republic: The Roman Republic was established in 509 BCE and lasted until 27 BCE. During this time, Rome developed a complex system of government, with two consuls elected annually, a senate, and assemblies of citizens.
3. Roman Empire: The Roman Empire began in 27 BCE when Augustus became the first Roman emperor. The empire grew to include much of Europe, the Middle East, and North Africa and lasted until the fall of the Western Roman Empire in 476 CE.
4. Achievements and Contributions: Ancient Rome made significant contributions to architecture, engineering, law, philosophy, art, literature, and language. Roman innovations include the arch, concrete, aqueducts, roads, and the Latin alphabet.
5. Decline and Fall: The Roman Empire faced numerous challenges, including economic instability, political corruption, military defeats, and invasions by barbarian tribes. The Western Roman Empire fell in 476 CE, while the Eastern Roman Empire (Byzantine Empire) survived until 1453 CE.

Possible settings

ParameterDefault valueDescription
API-keyAPI key. You can specify several (one per line), for each attempt the key will be randomly chosen from the available and not used within the current request.
Model namegpt-3.5-turboModel type (gpt-4 / gpt-4-0314 / gpt-4-32k / gpt-4-32k-0314 / gpt-3.5-turbo / gpt-3.5-turbo-0301)
System prompt contentSystem prompt content
Temperature0.7Temperature
Top P1Top P
Maximum length256Maximum number of tokens used
Presence penalty0Presence penalty
Frequency penalty0Frequency penalty