Quickstart

Get your first result in under 60 seconds. No credit card. No OAuth flow.

Step 1 — Get a free API key

bash
curl -X POST "https://vlsiddarth-knowledge-universe.hf.space/v1/signup?email=you@company.com"
response
{
  "status": "created",
  "api_key": "ku_test_abc123...",
  "tier": "free",
  "calls_limit": 500,
  "message": "Save your API key — it won't be shown again."
}
⚠ Save your key immediately

Your API key is shown exactly once. It is not stored in plain text. If lost, sign up again with a different email.

Step 2 — Discover sources

bash
curl -X POST https://vlsiddarth-knowledge-universe.hf.space/v1/discover \
  -H "X-API-Key: ku_test_abc123..." \
  -H "Content-Type: application/json" \
  -d '{"topic":"transformer architecture","difficulty":3,"formats":["pdf","github"]}'

Step 3 — Read the decay scores

response (excerpt)
{
  "decay_scores": {
    "arxiv:2302.14017v1": {
      "decay_score": 0.504,
      "freshness": 0.496,
      "label": "stale",
      "age_days": 1107
    }
  },
  "coverage_intelligence": {
    "confidence": 0.71,
    "confidence_label": "high",
    "coverage_warning": false,
    "suggested_queries": []
  }
}

Authentication

Pass your API key in the X-API-Key header on every authenticated call.

bash
curl https://vlsiddarth-knowledge-universe.hf.space/v1/usage \
  -H "X-API-Key: ku_test_abc123..."
python
import requests

resp = requests.post(
    "https://vlsiddarth-knowledge-universe.hf.space/v1/discover",
    headers={"X-API-Key": "ku_test_abc123..."},
    json={"topic": "RAG retrieval", "difficulty": 3},
)
data = resp.json()

Key Formats

PrefixTierMonthly limit
ku_test_Free500 calls
ku_live_Starter / Growth / Pro5k – unlimited
ℹ Key rotation

Keys do not expire on a time basis. Usage resets on the 1st of every month UTC.

Error Codes

HTTPError codeMeaningFix
401MISSING_API_KEYNo key in headerAdd X-API-Key header
401INVALID_API_KEYKey not foundCheck for typos; re-signup if lost
409EMAIL_EXISTSAlready registeredUse a different email
422Validation errorBad request bodyCheck required fields
429QUOTA_EXCEEDEDMonthly limit hitUpgrade or wait for reset
500INTERNAL_ERRORServer faultRetry; open a GitHub issue if persists

POST /v1/signup

Create a free account and receive your API key. No authentication required.

POST https://vlsiddarth-knowledge-universe.hf.space/v1/signup

Query parameters

ParamTypeRequiredDescription
emailstringrequiredYour email address. Used as unique account identifier.
tierstringoptionalDefault: free.
bash
curl -X POST "https://vlsiddarth-knowledge-universe.hf.space/v1/signup?email=you@company.com"

POST /v1/discover

The core endpoint. Queries 13 platforms in parallel, scores quality and pedagogical fit, attaches a decay score and coverage confidence to every response.

POST https://vlsiddarth-knowledge-universe.hf.space/v1/discover

Request body

FieldTypeDescription
topicstringrequiredSearch query. 2–200 characters.
difficultyint 1–5required1 = beginner, 5 = research-level.
formatsstring[]optionalFilter by format. Default: ["pdf","video","github","jupyter"]
max_resultsint 1–50optionalDefault: 10
outputstringoptionaljson | embeddings | html
bash
curl -X POST https://vlsiddarth-knowledge-universe.hf.space/v1/discover\
  -H "X-API-Key: ku_test_..." \
  -H "Content-Type: application/json" \
  -d '{
    "topic": "transformer architecture",
    "difficulty": 3,
    "formats": ["pdf","github","stackoverflow"],
    "max_results": 10
  }'
python
import requests

resp = requests.post(
    "https://vlsiddarth-knowledge-universe.hf.space/v1/discover",
    headers={"X-API-Key": "ku_test_..."},
    json={
        "topic": "transformer architecture",
        "difficulty": 3,
        "formats": ["pdf", "github"],
    },
).json()

# Decay scores
for sid, d in resp["decay_scores"].items():
    print(f"{d['label']:8} score={d['decay_score']} {sid}")

# Coverage confidence
cov = resp["coverage_intelligence"]
if cov["coverage_warning"]:
    print("Low confidence. Try:", cov["suggested_queries"])
⚡ Caching

Cold queries: ~4 seconds (13 crawlers in parallel). Cache hits: ~14ms. TTL: 4 hours. Same query from any user hits cache immediately.

POST /v1/knowledge

Enterprise endpoint. Returns KnowledgeObjects with freshness scores pre-attached — designed for direct RAG pipeline ingestion.

POST https://vlsiddarth-knowledge-universe.hf.space/v1/knowledge

Same request body as /v1/discover. Set "output": "embeddings" for 384-dim vectors ready for Qdrant, Weaviate, ChromaDB, Pinecone.

bash
curl -X POST https://vlsiddarth-knowledge-universe.hf.space/v1/knowledge \
  -H "X-API-Key: ku_test_..." \
  -H "Content-Type: application/json" \
  -d '{"topic":"RAG retrieval","difficulty":3,"output":"embeddings"}'

GET /v1/usage

Check your current month usage and remaining quota.

GET https://vlsiddarth-knowledge-universe.hf.space/v1/usage
bash
curl https://vlsiddarth-knowledge-universe.hf.space/v1/usage \
  -H "X-API-Key: ku_test_..."
200 response
{
  "tier": "free",
  "calls_used": 4,
  "calls_limit": 500,
  "calls_remaining": 496,
  "reset": "1st of next month"
}

GET /v1/formats

Returns all 54 supported format values. No auth required.

GET https://vlsiddarth-knowledge-universe.hf.space/v1/formats
bash
curl https://vlsiddarth-knowledge-universe.hf.space/v1/formats

GET /v1/crawlers

Lists all registered crawlers and their status. No auth required.

GET https://vlsiddarth-knowledge-universe.hf.space/v1/crawlers
bash
curl https://vlsiddarth-knowledge-universe.hf.space/v1/crawlers

GET /health

Liveness check. Returns Redis status. No auth. Use for uptime monitoring.

GET https://vlsiddarth-knowledge-universe.hf.space/health
200 response
{ "status": "healthy", "version": "1.0.0", "redis": "connected" }

Decay Engine

Every source gets a knowledge decay score — how much its relevance has drifted since publication. This is the core IP of Knowledge Universe.

formula
decay = 1 - 0.5 ^ (age_days / half_life_days)
freshness = 1 - decay

Half-life by platform

PlatformHalf-lifeReasoning
HuggingFace120 daysML moves extremely fast
GitHub180 daysCode goes stale as dependencies update
YouTube270 daysTutorials date quickly
Stack Overflow365 daysAnswers age with library versions
Kaggle365 daysNotebooks tied to competition contexts
arXiv1,095 daysResearch papers age slowly
MIT OCW1,095 daysCourse material revised on academic cycles
Wikipedia1,460 daysActively maintained
Open Library1,825 daysBooks revised infrequently

Decay labels

fresh
0.00 – 0.25
aging
0.25 – 0.50
stale
0.50 – 0.75
decayed
0.75 – 1.00
unknown
no date
ℹ Why this matters for RAG

LLMs and vector stores have no concept of source age. A 2019 Stack Overflow answer and a 2025 answer rank identically in cosine similarity. The decay score lets your pipeline filter or warn before stale knowledge reaches a response.

Coverage Confidence Score

KU is the only retrieval API that tells you when it didn't find exactly what you were looking for. Every /v1/discover response includes a coverage_intelligence field.

response field
"coverage_intelligence": {
  "confidence": 0.36,              // cosine similarity: query vs top results
  "confidence_label": "low",        // "high" | "medium" | "low" | "none"
  "coverage_warning": true,
  "warning_message": "Low confidence (0.36) — results may not fully match intent.",
  "suggested_queries": [
    "attention mechanism self-attention explained",
    "transformer encoder decoder tutorial",
    "attention is all you need paper explained"
  ],
  "top_result_similarities": [
    { "title": "A Survey of Graph Transformers...", "similarity": 0.377 }
  ]
}
LabelConfidence rangeMeaning
high≥ 0.65Results well match your query intent
medium0.45 – 0.65Partial match — consider refining
low< 0.45Significant mismatch — try suggested queries
none0.0No results returned

Source Formats

Pass any combination in the formats array.

GroupFormat values
Textualpdf markdown html epub latex
Videovideo video_playlist transcript
Audioaudio podcast
Interactivejupyter colab sandbox
Code / Platformgithub kaggle stackoverflow dataset
Assessmentflashcards problem_set lab exam

Platforms

Free = no key needed. Keyed = bring your own API key.

arXiv
Research papers
✓ Free
Wikipedia
Encyclopedia
✓ Free
Open Library
Books / EPUB
✓ Free
Stack Exchange
Q&A
✓ Free
HuggingFace
Models / Datasets
✓ Free
MIT OCW
University courses
✓ Free
Podcast Index
Podcasts
✓ Free
GitHub
Repos / Notebooks
⚙ Your key
YouTube
Video lectures
⚙ Your key
Kaggle
Notebooks / Datasets
⚙ Your key

Output Formats

ValueReturnsUse case
jsonDefault JSON responseGeneral use, dashboards
embeddingsJSON + 384-dim vectors per sourceDirect vector store ingestion
htmlFormatted HTML cardsBrowser rendering, reports

All Endpoints

POST /v1/signup Create account, receive API key no auth
POST /v1/discover Multi-platform discovery + decay scores + confidence auth
POST /v1/knowledge Enterprise KnowledgeObjects + embeddings auth
GET /v1/usage Monthly credit usage and remaining calls auth
GET /v1/formats All 54 supported source formats no auth
GET /v1/crawlers Active crawlers and status no auth
GET /v1/cache/stats Redis cache hit rate and memory auth
GET /health Liveness check, Redis status no auth

Rate Limits

Limits are per calendar month, not per minute.

PlanPriceMonthly calls
Free$0500
Starter$29/mo5,000
Growth$79/mo20,000
Pro$199/mo75,000
EnterpriseCustomUnlimited

Changelog

VersionDateChanges
v1.1.0Mar 2026Coverage Confidence Score. Per-crawler timeouts. Cold latency 25s → 4s. 5/5 gap analysis passing.
v1.0.0Mar 2026Initial release. Auth, decay engine, 13 crawlers, /v1/discover, /v1/knowledge, difficulty ceiling.