Build a private brand knowledge graph by ingesting URLs, then query it with grounded answers and Q&A verification.
Collections let you build a per-brand private corpus by ingesting multiple URLs into one unified knowledge graph (TKG). Once built, you can ask questions grounded only in that corpus, or verify existing Q&A pairs against it.Requires a personal access token. Master keys are rejected.
Ingest one or more URLs into the collection’s unified knowledge graph. Each URL is fetched, parsed by LLM, and its claims/predictions/edges are extracted and accumulated into the collection TKG.Note: Ingestion is synchronous: the request completes only after all URLs are processed. Each URL typically takes 10–30 seconds. Send URLs one at a time for best reliability.
Remove a source URL from the collection (soft detach). The source’s extracted claims, predictions, and chunks are retained in the database but are no longer associated with this collection.
Ask a question and get an answer grounded only in this collection’s knowledge graph. Uses semantic search (pgvector) to retrieve the most relevant content before generating an answer.If the knowledge graph does not contain enough information to answer, grounded is set to false to prevent hallucination.
Language for the answer (e.g. "Korean", "Japanese").
curl -X POST "https://api.factagora.com/api/v1/collections/5966a861-6952-482a-a9d0-041ad5d2a667/answer" \ -H "Authorization: Bearer fag_your_personal_token" \ -H "Content-Type: application/json" \ -d '{"question": "What is the IONIQ 6 electric range?"}'
{ "question": "What is the IONIQ 6 electric range?", "answer": "The IONIQ 6 has a driving range of up to 338 miles.", "grounded": true, "sources": [ { "url": "https://www.hyundai.com/uk/en/models/ioniq6.html", "title": "IONIQ 6 | Hyundai UK" } ], "meta": { "executionTimeMs": 1285 }}
curl -X POST "https://api.factagora.com/api/v1/collections/5966a861-6952-482a-a9d0-041ad5d2a667/qa-verify" \ -H "Authorization: Bearer fag_your_personal_token" \ -H "Content-Type: application/json" \ -d '{ "qa_pairs": [ { "question": "What is the IONIQ 6 charging time?", "answer": "The IONIQ 6 charges from 10% to 80% in 18 to 36 minutes." }, { "question": "Is the IONIQ 6 available as a petrol car?", "answer": "Yes, the IONIQ 6 is available as a petrol car." } ] }'
{ "results": [ { "question": "What is the IONIQ 6 charging time?", "answer": "The IONIQ 6 charges from 10% to 80% in 18 to 36 minutes.", "verdict": "correct", "confidence": 0.92, "correction": null, "summary": "The collection confirms IONIQ 6 charges from 10% to 80% in 18–36 minutes on a 350 kW ultra-fast charger." }, { "question": "Is the IONIQ 6 available as a petrol car?", "answer": "Yes, the IONIQ 6 is available as a petrol car.", "verdict": "incorrect", "confidence": 0.95, "correction": "The IONIQ 6 is a fully electric vehicle. No petrol variant is available.", "summary": "The collection describes the IONIQ 6 exclusively as an electric car." } ], "meta": { "executionTimeMs": 2100 }}