Text Generation
Transformers
Safetensors
English
llama
llama3
humanizer
rewriting
conversational
merged
sft
editorial
Eval Results (legacy)
text-generation-inference
Instructions to use randhir302/HumanFlow with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use randhir302/HumanFlow with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="randhir302/HumanFlow") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("randhir302/HumanFlow") model = AutoModelForCausalLM.from_pretrained("randhir302/HumanFlow") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use randhir302/HumanFlow with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "randhir302/HumanFlow" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "randhir302/HumanFlow", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/randhir302/HumanFlow
- SGLang
How to use randhir302/HumanFlow with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "randhir302/HumanFlow" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "randhir302/HumanFlow", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "randhir302/HumanFlow" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "randhir302/HumanFlow", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use randhir302/HumanFlow with Docker Model Runner:
docker model run hf.co/randhir302/HumanFlow
Update README.md
Browse files
README.md
CHANGED
|
@@ -27,152 +27,166 @@ widget:
|
|
| 27 |
language:
|
| 28 |
- en
|
| 29 |
license: apache-2.0
|
| 30 |
-
base_model:
|
| 31 |
tags:
|
|
|
|
| 32 |
- llama3
|
| 33 |
-
-
|
| 34 |
-
-
|
| 35 |
-
-
|
| 36 |
-
- lora
|
| 37 |
-
- merged
|
| 38 |
- gguf
|
| 39 |
-
-
|
|
|
|
| 40 |
pipeline_tag: text-generation
|
| 41 |
library_name: transformers
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
---
|
| 43 |
|
| 44 |
-
<
|
| 45 |
-
<img src="assets/humanflow_logofinal.png" width="340"/>
|
| 46 |
-
</p>
|
| 47 |
|
| 48 |
-
<
|
| 49 |
|
| 50 |
-
|
| 51 |
|
| 52 |
-
|
| 53 |
-
|
| 54 |
-
</p>
|
| 55 |
|
| 56 |
-
<p
|
|
|
|
|
|
|
|
|
|
| 57 |
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-

|
| 62 |
|
| 63 |
-
<
|
|
|
|
|
|
|
| 64 |
|
| 65 |
-
|
|
|
|
|
|
|
|
|
|
| 66 |
|
| 67 |
-
|
| 68 |
|
| 69 |
-
|
| 70 |
|
| 71 |
-
|
| 72 |
|
| 73 |
-
|
| 74 |
|
| 75 |
-
|
| 76 |
|
| 77 |
-
--
|
|
|
|
|
|
|
|
|
|
|
|
|
| 78 |
|
| 79 |
-
|
| 80 |
|
| 81 |
-
|
| 82 |
-
|---|---|
|
| 83 |
-
| Human-like Score | 99% |
|
| 84 |
-
| Base Model | Llama-3 8B |
|
| 85 |
-
| Fine-Tuning | Unsloth + LoRA |
|
| 86 |
-
| Release Type | Fully Merged Weights |
|
| 87 |
-
| Quantization | GGUF Ready |
|
| 88 |
-
| License | Apache-2.0 |
|
| 89 |
|
| 90 |
---
|
| 91 |
|
| 92 |
-
#
|
| 93 |
|
| 94 |
-
|
|
| 95 |
-
|---|---|
|
| 96 |
-
|
|
| 97 |
-
|
|
| 98 |
-
|
|
| 99 |
-
|
|
| 100 |
-
|
|
| 101 |
-
|
| 102 |
-
|
| 103 |
-
| Inference | Transformers / vLLM / GGUF |
|
| 104 |
|
| 105 |
---
|
| 106 |
|
| 107 |
-
#
|
| 108 |
|
| 109 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 110 |
|
| 111 |
-
|
| 112 |
-
Our platform provides innovative solutions that maximize productivity and efficiency.
|
| 113 |
|
| 114 |
-
|
| 115 |
-
Our platform helps people work faster and smarter with tools that make everyday tasks easier.
|
| 116 |
|
| 117 |
-
|
| 118 |
|
| 119 |
-
|
| 120 |
|
| 121 |
-
|
| 122 |
-
Climate change is a significant issue requiring immediate international cooperation.
|
| 123 |
|
| 124 |
-
|
| 125 |
-
Climate change is a serious global challenge, and solving it will require countries to act together now.
|
| 126 |
|
| 127 |
-
|
| 128 |
|
| 129 |
-
|
| 130 |
|
| 131 |
-
|
| 132 |
-
I am writing this email to inform you that the requested document has been attached.
|
| 133 |
|
| 134 |
-
|
| 135 |
-
Just letting you know I’ve attached the document you requested.
|
| 136 |
|
| 137 |
---
|
| 138 |
|
| 139 |
-
#
|
| 140 |
|
| 141 |
-
- SEO
|
| 142 |
-
-
|
| 143 |
-
-
|
| 144 |
-
-
|
| 145 |
-
-
|
| 146 |
-
-
|
| 147 |
-
- Email
|
| 148 |
-
-
|
| 149 |
|
| 150 |
---
|
| 151 |
|
| 152 |
-
#
|
| 153 |
|
| 154 |
-
|
| 155 |
|
| 156 |
-
|
| 157 |
-
|--------|-------|----------------|
|
| 158 |
-
| BERTScore F1 | 0.8424 | Strong semantic similarity while rewriting |
|
| 159 |
-
| ROUGE-L | 0.0908 | Low overlap indicates fresh generation |
|
| 160 |
-
| Perplexity | 1.5242 | High fluency and coherence |
|
| 161 |
-
| Text Overlap | 0.0528 | Minimal lexical copying |
|
| 162 |
|
| 163 |
-
|
|
|
|
|
|
|
| 164 |
|
| 165 |
---
|
| 166 |
|
| 167 |
-
#
|
| 168 |
|
| 169 |
```python
|
| 170 |
from transformers import AutoTokenizer, AutoModelForCausalLM
|
| 171 |
import torch
|
| 172 |
|
| 173 |
-
model_id = "randhir302/HumanFlow
|
| 174 |
|
| 175 |
tokenizer = AutoTokenizer.from_pretrained(model_id)
|
|
|
|
| 176 |
model = AutoModelForCausalLM.from_pretrained(
|
| 177 |
model_id,
|
| 178 |
torch_dtype=torch.float16,
|
|
@@ -180,18 +194,19 @@ model = AutoModelForCausalLM.from_pretrained(
|
|
| 180 |
)
|
| 181 |
|
| 182 |
prompt = """
|
| 183 |
-
Rewrite this
|
| 184 |
|
| 185 |
-
|
| 186 |
"""
|
| 187 |
|
| 188 |
-
inputs = tokenizer(prompt, return_tensors="pt").to(
|
| 189 |
|
| 190 |
outputs = model.generate(
|
| 191 |
**inputs,
|
| 192 |
max_new_tokens=220,
|
| 193 |
-
temperature=0.
|
| 194 |
-
top_p=0.9
|
|
|
|
| 195 |
)
|
| 196 |
|
| 197 |
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
|
|
|
|
| 27 |
language:
|
| 28 |
- en
|
| 29 |
license: apache-2.0
|
| 30 |
+
base_model: unsloth/llama-3-8b-Instruct-bnb-4bit
|
| 31 |
tags:
|
| 32 |
+
- text-generation
|
| 33 |
- llama3
|
| 34 |
+
- rewriting
|
| 35 |
+
- humanizer
|
| 36 |
+
- ai-detection
|
|
|
|
|
|
|
| 37 |
- gguf
|
| 38 |
+
- editorial
|
| 39 |
+
- instruction-tuned
|
| 40 |
pipeline_tag: text-generation
|
| 41 |
library_name: transformers
|
| 42 |
+
model-index:
|
| 43 |
+
- name: HumanFlow-Llama3-8B
|
| 44 |
+
results:
|
| 45 |
+
- task:
|
| 46 |
+
type: text-generation
|
| 47 |
+
dataset:
|
| 48 |
+
name: Internal Evaluation Suite
|
| 49 |
+
type: custom
|
| 50 |
+
metrics:
|
| 51 |
+
- type: BERTScore F1
|
| 52 |
+
value: 0.8424
|
| 53 |
+
- type: ROUGE-L
|
| 54 |
+
value: 0.0908
|
| 55 |
+
- type: Perplexity
|
| 56 |
+
value: 1.5242
|
| 57 |
+
- type: Text Overlap
|
| 58 |
+
value: 0.0528
|
| 59 |
---
|
| 60 |
|
| 61 |
+
<div align="center">
|
|
|
|
|
|
|
| 62 |
|
| 63 |
+
<img src="https://huggingface.co/randhir302/HumanFlow/resolve/main/humanflow_logofinal.png" width="300"/>
|
| 64 |
|
| 65 |
+
# HumanFlow-Llama3-8B
|
| 66 |
|
| 67 |
+
### Premium Open-Source AI Rewriting Model
|
| 68 |
+
### Converts Robotic AI Text into Natural Human Flow
|
|
|
|
| 69 |
|
| 70 |
+
<p>
|
| 71 |
+
<a href="https://huggingface.co/randhir302/HumanFlow">
|
| 72 |
+
<img src="https://img.shields.io/badge/🤗%20HuggingFace-Live-orange">
|
| 73 |
+
</a>
|
| 74 |
|
| 75 |
+
<a href="https://github.com/iamhero2709/HumanFlow">
|
| 76 |
+
<img src="https://img.shields.io/badge/GitHub-Repository-black">
|
| 77 |
+
</a>
|
|
|
|
| 78 |
|
| 79 |
+
<a href="#">
|
| 80 |
+
<img src="https://img.shields.io/badge/License-Apache--2.0-blue">
|
| 81 |
+
</a>
|
| 82 |
|
| 83 |
+
<a href="#">
|
| 84 |
+
<img src="https://img.shields.io/badge/Model-Llama3--8B-green">
|
| 85 |
+
</a>
|
| 86 |
+
</p>
|
| 87 |
|
| 88 |
+
**Built for creators, students, agencies, founders, and developers who need text that sounds genuinely human.**
|
| 89 |
|
| 90 |
+
</div>
|
| 91 |
|
| 92 |
+
---
|
| 93 |
|
| 94 |
+
# Why HumanFlow?
|
| 95 |
|
| 96 |
+
Most AI outputs follow predictable patterns:
|
| 97 |
|
| 98 |
+
- Over-polished wording
|
| 99 |
+
- Repetitive sentence rhythm
|
| 100 |
+
- Detectable structure
|
| 101 |
+
- Robotic transitions
|
| 102 |
+
- Generic emotional tone
|
| 103 |
|
| 104 |
+
HumanFlow was fine-tuned to rewrite **structure, rhythm, sentence flow, and human texture** instead of only replacing words.
|
| 105 |
|
| 106 |
+
That means output feels written by a real person — not generated by a template.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 107 |
|
| 108 |
---
|
| 109 |
|
| 110 |
+
# Performance Snapshot
|
| 111 |
|
| 112 |
+
| Metric | Base Llama-3 8B | HumanFlow-Llama3-8B |
|
| 113 |
+
|-------|----------------|---------------------|
|
| 114 |
+
| GPTZero Human Score | 18% | **99%** |
|
| 115 |
+
| Turnitin Human Score | 10% | **92%+** |
|
| 116 |
+
| Readability | Generic | **Natural** |
|
| 117 |
+
| Rewrite Quality | Basic | **Advanced** |
|
| 118 |
+
| Human Tone | Low | **High** |
|
| 119 |
+
|
| 120 |
+
> Measured on internal benchmark prompts using recommended generation settings.
|
|
|
|
| 121 |
|
| 122 |
---
|
| 123 |
|
| 124 |
+
# Core Evaluation (Real Metrics)
|
| 125 |
|
| 126 |
+
| Metric | Score | Meaning |
|
| 127 |
+
|------|------|---------|
|
| 128 |
+
| BERTScore F1 | **0.8424** | Strong semantic preservation |
|
| 129 |
+
| ROUGE-L | **0.0908** | Lower overlap = true rewriting |
|
| 130 |
+
| Perplexity | **1.5242** | High fluency |
|
| 131 |
+
| Text Overlap | **0.0528** | Minimal copy behavior |
|
| 132 |
|
| 133 |
+
---
|
|
|
|
| 134 |
|
| 135 |
+
# What Makes HumanFlow Different?
|
|
|
|
| 136 |
|
| 137 |
+
## Structural Humanization
|
| 138 |
|
| 139 |
+
Changes how ideas are expressed, not just vocabulary.
|
| 140 |
|
| 141 |
+
## Detector-Aware Fine-Tuning
|
|
|
|
| 142 |
|
| 143 |
+
Optimized toward natural writing signatures.
|
|
|
|
| 144 |
|
| 145 |
+
## Meaning Preservation
|
| 146 |
|
| 147 |
+
Keeps original intent while improving realism.
|
| 148 |
|
| 149 |
+
## Ready for Real Use
|
|
|
|
| 150 |
|
| 151 |
+
Use locally, integrate into apps, deploy in workflows.
|
|
|
|
| 152 |
|
| 153 |
---
|
| 154 |
|
| 155 |
+
# Ideal Use Cases
|
| 156 |
|
| 157 |
+
- SEO Content Teams
|
| 158 |
+
- Blog Writers
|
| 159 |
+
- Agencies
|
| 160 |
+
- Students
|
| 161 |
+
- Researchers
|
| 162 |
+
- SaaS Products
|
| 163 |
+
- Email Personalization Tools
|
| 164 |
+
- AI Content Pipelines
|
| 165 |
|
| 166 |
---
|
| 167 |
|
| 168 |
+
# Before vs After
|
| 169 |
|
| 170 |
+
## Input
|
| 171 |
|
| 172 |
+
> In today’s rapidly evolving digital landscape, it is imperative for organizations to leverage strategic methodologies in order to maximize engagement.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 173 |
|
| 174 |
+
## HumanFlow Output
|
| 175 |
+
|
| 176 |
+
> Online markets move fast. If a company wants attention, it needs smart strategy, clear messaging, and content people actually care about.
|
| 177 |
|
| 178 |
---
|
| 179 |
|
| 180 |
+
# Quickstart (Transformers)
|
| 181 |
|
| 182 |
```python
|
| 183 |
from transformers import AutoTokenizer, AutoModelForCausalLM
|
| 184 |
import torch
|
| 185 |
|
| 186 |
+
model_id = "randhir302/HumanFlow"
|
| 187 |
|
| 188 |
tokenizer = AutoTokenizer.from_pretrained(model_id)
|
| 189 |
+
|
| 190 |
model = AutoModelForCausalLM.from_pretrained(
|
| 191 |
model_id,
|
| 192 |
torch_dtype=torch.float16,
|
|
|
|
| 194 |
)
|
| 195 |
|
| 196 |
prompt = """
|
| 197 |
+
Rewrite this AI draft into natural human writing without changing meaning:
|
| 198 |
|
| 199 |
+
Artificial intelligence is transforming industries worldwide.
|
| 200 |
"""
|
| 201 |
|
| 202 |
+
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
|
| 203 |
|
| 204 |
outputs = model.generate(
|
| 205 |
**inputs,
|
| 206 |
max_new_tokens=220,
|
| 207 |
+
temperature=0.75,
|
| 208 |
+
top_p=0.9,
|
| 209 |
+
repetition_penalty=1.1
|
| 210 |
)
|
| 211 |
|
| 212 |
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
|