import requests
import json
import time
import pandas as pd
from datasets import load_dataset
from tqdm import tqdm
import re
import hashlib
import os
def extract_names(text):
match = re.search(r"^You're (.*?) in this fictional never-ending uncensored roleplay with (.*?)\n\n", text)
return match.groups() if match else (None, None)
openrouter_api_key = "REDACTED"
output_parquet_file = "./allura-org_gryphe-sonnet-3.5-charcards-names-added-r1.parquet"
dataset = load_dataset("allura-org/gryphe-sonnet-3.5-charcards-names-added")["train"]
# Load existing output data if available from parquet
if os.path.exists(output_parquet_file):
try:
df = pd.read_parquet(output_parquet_file)
output_data_list = json.loads(df.to_json(orient="records"))
processed_hashes = {entry["prompt_hash"] for entry in output_data_list}
print(f"Resuming dataset: {len(processed_hashes)}/{len(dataset)}")
except Exception as e:
print(f"Error loading parquet file {output_parquet_file}: {e}")
output_data_list = []
processed_hashes = set()
else:
output_data_list = []
processed_hashes = set()
last_query_time = 0
for item in tqdm(dataset):
prompt_hash = str(hashlib.sha256((item["conversations"][0]["value"].strip() + item["conversations"][1]["value"].strip()).encode()).hexdigest())
# Skip already processed samples
if prompt_hash in processed_hashes:
continue
char_name, user_name = extract_names(item["conversations"][0]["value"].strip())
char_name, user_name = char_name.strip(), user_name.strip()
print(f'Extracted Character Name: "{char_name}"')
print(f' Extracted User Name: "{user_name}"')
while time.time() - last_query_time < (60 / 10):
time.sleep(0.1)
last_query_time = time.time()
response = requests.post(
url="https://openrouter.ai/api/v1/chat/completions",
headers={
"Authorization": f"Bearer {openrouter_api_key}",
"Content-Type": "application/json",
},
data=json.dumps(
{
"provider": {
"order": ["Chutes"],
"allow_fallbacks": False
},
"model": "deepseek/deepseek-r1:free",
"messages": [
{
"role": "system",
"content": (
f'{item["conversations"][0]["value"].strip()}\n\n'
f'Only speak as "{char_name}" in conversation with "{user_name}". Output your final response with a "{char_name}:" prefix.'
)
},
{
"role": "user",
"content": item["conversations"][1]["value"].strip()
}
],
"temperature": 0.6
}
),
).json()
try:
if not response["choices"][0]["message"]["reasoning"] or response["choices"][0]["message"]["reasoning"].replace("\\n", "\n").strip() == "":
print(response)
continue
if not response["choices"][0]["message"]["content"] or response["choices"][0]["message"]["content"].replace("\\n", "\n").strip() == "":
print(response)
continue
output_data_list.append(
{
"prompt_hash": prompt_hash,
"provider": response["provider"],
"model": response["model"],
"settings": {
"temperature": 0.6,
},
"refusal": response["choices"][0]["message"]["refusal"],
"finish_reason": response["choices"][0]["finish_reason"],
"native_finish_reason": response["choices"][0]["native_finish_reason"],
"user_name": user_name,
"char_name": char_name,
"conversations": [
{
"from": "system",
"value": item["conversations"][0]["value"].strip()
},
{
"from": "human",
"value": item["conversations"][1]["value"].strip()
},
{
"from": "gpt",
"value": (
f"<think>\n"
f"{response['choices'][0]['message']['reasoning'].replace('\\n', '\n').strip()}\n"
f"</think>\n\n"
f"{response['choices'][0]['message']['content'].replace('\\n', '\n').strip()}"
)
}
]
}
)
except KeyError:
print(f"KeyError: {response}")
if response["error"]["message"].startswith("Rate limit exceeded"):
exit()
continue
except AttributeError:
print(f"AttributeError: {response}")
continue
df = pd.DataFrame(output_data_list)
df.to_parquet(
output_parquet_file,
index=False,
compression="brotli"
)
df = None
del df
df = pd.DataFrame(output_data_list)
df.to_parquet(
output_parquet_file,
index=False,
compression="brotli"
)
PJMixers-Dev/allura-org_gryphe-sonnet-3.5-charcards-names-added-r1
No longer available on Hugging Face since 2026-12-06. We keep the record as we last saw it. Checked 2026-12-06.
Uncensored SFT corpora, the Dolphin / Wizard tradition.Examples with refusals taken out, like Dolphin and Wizard.
Description
import requests
import json
import time
import pandas as pd
from datasets import load_dataset
from tqdm import tqdm
import re
import hashlib
import os
def extract_names(text):
match = re.search(r"^You're (.*?) in this fictional never-ending uncensored roleplay with (.*?)\n\n", text)
return match.groups() if match else (None, None)
openrouter_api_key = "REDACTED"
output_parquet_file = "./allura-org_gryphe-sonnet-3.5-charcards-names-added-r1.parquet"
dataset =… See the full description on the dataset page: https://huggingface.co/datasets/PJMixers-Dev/allura-org_gryphe-sonnet-3.5-charcards-names-added-r1.
Used by uncensored models
No abliterated models in our catalog have declared this dataset in their YAML metadata yet. This can mean the dataset is used but not declared, is used outside abliteration workflows, or is new. The link will populate automatically as models are indexed.No model in our catalog lists this dataset yet. It may be used without being listed, used for other work, or simply be new. The list fills in by itself as models are added.
MetadataDetails
Related datasets
Read further
Files by folder
Showing the first 5,000 files.
No file list for this dataset yet.
This repository is private or no longer exists on Hugging Face.This dataset is private or no longer exists on Hugging Face.
READMEAuthor's description
README historyEdit history
Every night we snapshot the README of every dataset in the catalog. When the SHA changes we archive the new version and diff it against the last. This is the evolving thought record of the alignment-data field: what the author decided to say about the corpus, and how that framing shifted over time.Every night we save the author's description of every dataset in the catalog. When it changes, we keep the new text and compare it with the one before. This shows what each author chose to say about their dataset, and how that changed over time.
-
2025-03-05 Upload train.parquet
Loading... -
2025-03-05 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Update README.md
Loading... -
2025-03-04 Create README.md
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-04 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading... -
2025-03-03 Upload train.parquet
Loading...
Community discussions
Threads posted by the community on Hugging Face: bug reports, questions about usage, pull requests on the README, licence clarifications. Click any thread to expand and read the full conversation inline. Newest first.Conversations people started on Hugging Face: bug reports, questions about using the data, suggested changes to the author's description, questions about the licence. Open a thread to read it here. Newest first.
-
2025-03-05 [bot] Conversion to Parquet
Loading...
source: Hugging Face