This repository contains a small utility for collecting information from shared ChatGPT conversations. It parses a share link and outputs structured data about the chat.
- Python 3.8+
requests
beautifulsoup4
Install dependencies with:
pip install -r requirements.txt
Run the main script with a ChatGPT share link:
python main.py <share_link>
Example:
python main.py https://chat.openai.com/share/1234abcd
The command prints JSON with two keys:
analysis
– meta data, user info and experiment layer details.chat_messages
– a list of all messages, including author, content and timestamp.
The scraping logic resides in service.py
and exposes two functions:
scrape_chatgpt_conversation(share_link)
– returns meta information about the conversation.extract_chat_messages(share_link)
– extracts the messages in order.
Each function returns None
if the relevant data cannot be obtained.