Skip to content
api-turboModelsModels & pricingGuides & insightsDocumentation简体中文Log in
Engineering

Build a RAG workflow with verifiable citations

Separate retrieval, generation and evidence checks so answers can be traced to source material.

api-turbo EditorialUpdated 2 min read
The short answer

RAG retrieves relevant material before asking a model to answer from it. Reliable citations require application-managed source IDs and validation. A model-generated link alone is not evidence that the source supports the claim.

Prepare documents with provenance and permissions

Store a stable ID, title, original location, update time and access scope for each document. Preserve section or page references when chunking. Remove stale index entries when documents are retired.

Enforce user access permissions during retrieval, not only after generation. Instructions embedded in external documents are source content, not system directives or permission to execute tools.

Prove retrieval works before tuning generation

Start with representative questions and the source that should answer each one. Check whether retrieval finds the relevant passage before adding vector search, keyword blending or reranking. Changing the model cannot fix missing evidence.

With the appropriate configured channels, api-turbo provides model API access. It does not automatically create a document store, vector database or document-permission system. Your application owns processing and retrieval.

Use source IDs instead of invented links

Label retrieved passages S1, S2 and so on. Ask for source IDs on factual claims and an explicit statement when evidence is insufficient. Let the application map valid IDs to real locations instead of accepting invented URLs.

Question: What is the return window?
Sources:
[S1] Title: Returns policy | Section: Eligibility
...retrieved passage...

Return: answer, citations[], insufficient_evidence
Use only supplied source IDs. Do not invent a policy.

Check that citations actually support the answer

At minimum, verify that citation IDs exist, passages are visible to the user and claims stay within the evidence. Test missing answers, conflicting documents and old versions to confirm the system can stop guessing and request review.

References

Our approach: state prerequisites, cite primary sources and distinguish platform capabilities from enabled services. Guides make no performance or AI recommendation guarantees.