Hugging Face Text avatar
Hugging Face Text

Pricing

from $0.01 / 1,000 results

Go to Apify Store
Hugging Face Text

Hugging Face Text

Comprehensive text processing w/Hugging Face models generation, NLP & embeddings. Text Generations Chat Completion Summarization Condense documents Translation Sentiment Analysis Classify sentiment NER Named entity recognition Q&A Answer context Embeddings Semantic search Zero-Shot without training

Pricing

from $0.01 / 1,000 results

Rating

0.0

(0)

Developer

John Rippy

John Rippy

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

7 days ago

Last modified

Share

Hugging Face Text - AI Text Processing with 100K+ NLP Models

Process text with the world's largest collection of NLP models. Text generation, summarization, translation, sentiment analysis, NER, Q&A, embeddings, paraphrase, and zero-shot classification. Lightweight actor focused on text-only tasks. BYOK with your Hugging Face API token.

Features

  • Text Generation - Generate content with Llama 2, Mistral, Falcon
  • Chat Completion - Conversational AI with system prompts
  • Summarization - Condense documents with BART, T5
  • Translation - 100+ language pairs with Helsinki-NLP
  • Sentiment Analysis - Classify emotions and sentiment
  • Named Entity Recognition - Extract people, places, organizations
  • Question Answering - Extract answers from context
  • Fill-Mask - Complete sentences with BERT
  • Embeddings - Generate semantic vectors
  • Zero-Shot Classification - Classify without training data
  • Text Similarity - Compare text semantically
  • Paraphrase - Rewrite text in different ways
  • Demo Mode - Test with sample data before going live

Who Should Use This Actor?

Content Marketers

Generate blog posts, social content, and copy. Summarize research. Repurpose content across formats.

SEO Specialists

Generate meta descriptions. Expand keyword content. Translate for international SEO.

Customer Support Teams

Analyze ticket sentiment. Extract key entities. Generate response templates.

Data Analysts

Extract entities from text data. Classify documents. Generate embeddings for ML pipelines.

Researchers

Summarize papers. Translate sources. Analyze sentiment in datasets.

E-commerce Teams

Generate product descriptions. Translate listings. Analyze reviews.

Quick Start

Demo Mode (Free Test)

{
"task": "text_generation",
"prompt": "Write a product description for wireless earbuds",
"demoMode": true
}

Text Generation

{
"task": "text_generation",
"apiToken": "hf_your_token_here",
"prompt": "Write a compelling meta description for a page about local SEO services",
"maxTokens": 160,
"temperature": 0.7,
"demoMode": false
}

Chat Completion

{
"task": "chat_completion",
"apiToken": "hf_your_token_here",
"model": "mistralai/Mistral-7B-Instruct-v0.1",
"systemPrompt": "You are a helpful SEO expert. Provide concise, actionable advice.",
"prompt": "How do I improve my local search rankings?",
"maxTokens": 300,
"demoMode": false
}

Summarization

{
"task": "summarization",
"apiToken": "hf_your_token_here",
"text": "Your long article or document text goes here...",
"maxTokens": 150,
"minTokens": 50,
"demoMode": false
}

Sentiment Analysis

{
"task": "sentiment_analysis",
"apiToken": "hf_your_token_here",
"text": "This product exceeded my expectations! Amazing quality and fast shipping.",
"demoMode": false
}

Named Entity Recognition

{
"task": "ner",
"apiToken": "hf_your_token_here",
"text": "Tim Cook announced that Apple will open a new store in San Francisco next month.",
"demoMode": false
}

Translation

{
"task": "translation",
"apiToken": "hf_your_token_here",
"text": "Our services are available in all major cities.",
"sourceLanguage": "en",
"targetLanguage": "fr",
"demoMode": false
}

Embeddings

{
"task": "embeddings",
"apiToken": "hf_your_token_here",
"text": "Local SEO services for small businesses",
"demoMode": false
}

Batch Embeddings

{
"task": "embeddings",
"apiToken": "hf_your_token_here",
"texts": "[\"SEO services\", \"Digital marketing\", \"Local business optimization\"]",
"demoMode": false
}

Zero-Shot Classification

{
"task": "zero_shot_classification",
"apiToken": "hf_your_token_here",
"text": "The new iPhone features a revolutionary camera system",
"candidateLabels": "technology,business,sports,entertainment",
"demoMode": false
}

Text Similarity

{
"task": "text_similarity",
"apiToken": "hf_your_token_here",
"text": "SEO optimization services",
"compareText": "Search engine marketing",
"demoMode": false
}

Paraphrase

{
"task": "paraphrase",
"apiToken": "hf_your_token_here",
"text": "Local SEO helps small businesses get found online",
"maxTokens": 100,
"demoMode": false
}

Input Parameters

ParameterTypeDefaultDescription
taskstringrequiredTask to perform (see task list)
apiTokenstring-Your Hugging Face API token
modelstringtask defaultSpecific model to use
textstring-Input text for processing
textsstring-JSON array of texts (for batch embeddings)
promptstring-Input prompt for generation
systemPromptstring-System prompt for chat completion
contextstring-Context for Q&A
questionstring-Question for Q&A
compareTextstring-Second text for similarity
sourceLanguagestring"en"Source language code
targetLanguagestring"es"Target language code
candidateLabelsstring-Comma-separated classification labels
maxTokensnumber256Max tokens to generate
minTokensnumber30Min tokens for summarization
temperaturenumber0.7Randomness (0.0-1.0)
topPnumber0.9Nucleus sampling
topKnumber50Top-k sampling
repetitionPenaltynumber1.0Reduce repetition
doSamplebooleantrueEnable sampling
waitForModelbooleantrueWait for model to load
webhookUrlstring-Webhook URL for results
demoModebooleantrueReturn sample data

Available Tasks

TaskDescriptionDefault Model
text_generationGenerate textMistral-7B-Instruct
chat_completionConversational AIMistral-7B-Instruct
summarizationSummarize textBART-large-CNN
translationTranslate textHelsinki-NLP OPUS
sentiment_analysisAnalyze sentimentDistilBERT-SST2
nerNamed entity recognitionBERT-NER
question_answeringAnswer from contextRoBERTa-SQuAD2
fill_maskComplete sentencesBERT-base
embeddingsVector embeddingsall-MiniLM-L6-v2
zero_shot_classificationClassify without trainingBART-large-MNLI
text_similarityCompare textsall-MiniLM-L6-v2
paraphraseRewrite textPegasus-paraphrase

Output Format

Text Generation

{
"success": true,
"model": "mistralai/Mistral-7B-Instruct-v0.1",
"generatedText": "Boost your local visibility with our proven SEO strategies..."
}

Sentiment Analysis

{
"success": true,
"model": "distilbert-base-uncased-finetuned-sst-2-english",
"sentiment": [
{"label": "POSITIVE", "score": 0.89},
{"label": "NEGATIVE", "score": 0.11}
]
}

Named Entity Recognition

{
"success": true,
"model": "dslim/bert-base-NER",
"entities": [
{"entity": "B-PER", "word": "Tim", "score": 0.99, "start": 0, "end": 3},
{"entity": "I-PER", "word": "Cook", "score": 0.98, "start": 4, "end": 8},
{"entity": "B-ORG", "word": "Apple", "score": 0.97, "start": 24, "end": 29},
{"entity": "B-LOC", "word": "San", "score": 0.95, "start": 56, "end": 59},
{"entity": "I-LOC", "word": "Francisco", "score": 0.96, "start": 60, "end": 69}
]
}

Zero-Shot Classification

{
"success": true,
"model": "facebook/bart-large-mnli",
"labels": [
{"label": "technology", "score": 0.85},
{"label": "business", "score": 0.12},
{"label": "entertainment", "score": 0.02},
{"label": "sports", "score": 0.01}
]
}

Embeddings

{
"success": true,
"model": "sentence-transformers/all-MiniLM-L6-v2",
"embedding": [0.023, -0.156, 0.089, ...],
"dimensions": 384
}

Text Similarity

{
"success": true,
"model": "sentence-transformers/all-MiniLM-L6-v2",
"similarity": 0.85,
"text1": "SEO optimization services",
"text2": "Search engine marketing"
}

Paraphrase

{
"success": true,
"model": "tuner007/pegasus_paraphrase",
"paraphrases": [
"Small businesses can improve their online presence with local SEO",
"Getting found online is easier for small businesses with local SEO",
"Local search optimization benefits small business visibility"
]
}

Pricing (Pay-Per-Event)

EventDescriptionPrice
text_processedPer text processing task$0.01

Example costs:

  • 100 sentiment analyses: 100 × $0.01 = $1.00
  • 50 translations: 50 × $0.01 = $0.50
  • 200 embeddings: 200 × $0.01 = $2.00
  • Demo mode: $0.00

Common Scenarios

Scenario 1: SEO Content Generation

{
"task": "text_generation",
"apiToken": "hf_your_token",
"prompt": "Write 5 unique meta descriptions for a local plumbing company in Miami",
"maxTokens": 500,
"temperature": 0.8,
"demoMode": false
}

Scenario 2: Review Sentiment Analysis

{
"task": "sentiment_analysis",
"apiToken": "hf_your_token",
"text": "The service was okay but took longer than expected. Staff were friendly though.",
"demoMode": false
}

Scenario 3: Multilingual SEO

{
"task": "translation",
"apiToken": "hf_your_token",
"text": "Professional plumbing services available 24/7. Call now for a free quote.",
"sourceLanguage": "en",
"targetLanguage": "es",
"demoMode": false
}

Scenario 4: Content Categorization

{
"task": "zero_shot_classification",
"apiToken": "hf_your_token",
"text": "New research shows that regular exercise improves mental health",
"candidateLabels": "health,fitness,science,lifestyle,news",
"demoMode": false
}

Webhook & Automation Integration

Zapier / Make.com / n8n

  1. Create a webhook trigger
  2. Copy the URL to webhookUrl
  3. Process text results in your workflow

Popular automations:

  • Generated content -> WordPress/CMS
  • Sentiment scores -> CRM tagging
  • Translations -> Multilingual site updates
  • NER extraction -> Contact enrichment

Hugging Face AI Suite

ActorBest For
Hugging Face MasterAll-in-one (text + image + audio)
Hugging Face TextText-only processing (lightweight)
Hugging Face ImageImage processing
Hugging Face AudioAudio processing
Hugging Face HubModel discovery

FAQ

Q: What's the max text length?

A: Most models support 512-4096 tokens. For longer texts, chunk and process separately.

Q: How do I choose a model?

A: Start with defaults - optimized for quality/speed. Check Hugging Face for task-specific leaderboards.

Q: Can I use multilingual models?

A: Yes! Many models support 100+ languages. Check model cards for language support.

Q: Are batch requests supported?

A: Yes for embeddings - pass a JSON array in texts. Other tasks process one at a time.

Common Problems & Solutions

"Model is loading"

  • Large models need warm-up time
  • Set waitForModel: true (default)
  • Use smaller models for faster responses

"Text too long"

  • Split into smaller chunks
  • Use summarization first, then process

"Demo data showing"

  • Set demoMode: false
  • Provide your Hugging Face API token

Built by John Rippy | Actor Arsenal