Data & RAG

Your data as a source of knowledge for AI

A language model can know nothing about your business that is not in the request. RAG picks out exactly those passages from your own material that answer a given question and puts them in front of the model. With a source reference, and without pushing your entire archive through the context window.

Your material

Customer database
Documents
Wiki & file stores
Mail & tickets

Preparation & index

ExtractSplitEmbedIndex

The source stays with the passage

Clients

Claude
ChatGPT
Copilot
Custom AI assistants
References

Knowledge we have made accessible to AI

A group whose specialist knowledge sat in stores nobody could search. Today the assistant answers questions from it, with evidence attached to every statement.

Primeo Energie

Primeo Energie

In production

The knowledge assistant answers questions from the group's business material and backs every answer with the original source. The pipeline runs from ingest through extraction and splitting into the index. Retrieval works by similarity, after which the hits are re-scored so that the most fitting passages come out on top rather than the longest ones.

In use

pgvectorAzure AI SearchDocument AIDoclingReranking
Preparation

A scanned manual is not text

The effort rarely sits with the model. It sits in turning what you have into something that can be searched.

Step 1 of 4

Extract

PDFs, scans and office files become text with structure. Headings, tables and page numbers survive, because the answer will point back at them.

Choosing the technology

The volume decides, not the fashion

There is no setup that is right for every archive. We choose by size, spread of formats and rate of change, and we are not tied to any vendor. That choice lands directly on your token bill.

Archive

Up to a few thousand documents, uniform formats

An index inside the database you already run

No extra infrastructure. Common databases handle similarity search themselves these days. As long as volume and formats stay manageable, that is the whole answer.

Archive

Clearly bounded topics, small archives

Separate knowledge bases per topic

A search across everything always finds something. Separate archives find the right thing, because the wrong neighbours never join in.

Archive

Large, mixed archives

A managed search service

As format variety and volume grow, a service that has solved scaling and operations pays off. We then build the feed, not the search engine.

Archive

Several hundred gigabytes, constantly moving

Your own vector index plus delta sync

At this size, rebuilding daily costs more than the project. Only what changed gets updated, and the initial load stays a one-off item.

Why this decides the bill

It is not the archive that travels into the context window but a handful of passages. Whether that is five or fifty is decided by the setup: an index that hits roughly compensates with volume. And every extra page is on the bill, on every request, for every user, every day.

Transparency

Every answer shows where it came from

An answer without a source is an assertion. Transparency here is not a badge but a property you can check: every sentence has the document it came from attached to it.

How is the drain pump replaced for error code E24?

Searching manuals and service sheets

E24 reports a blocked drain. Before replacing the pump, check the filter and the hose.

Removal is described step by step in the service manual, torque figures included.

Service manual, ch. 4.2Service sheet, E codes

Evidence per passage

Below the answer sit the passages it was built from. Anyone who wants to read on clicks and reads on.

Better no answer than an invented one

If the search finds nothing suitable, the system says so instead of guessing. A setting, not a hope for good behaviour.

Permissions apply inside the index

The search only covers what the person asking may see. What they may not never turns up as a hit.

The date stays visible

Every passage carries its revision. An answer taken from a 2019 version is recognisable as such.

Where the EU AI Act comes in

The regulation has applied in full since 2 August 2026. For high-risk applications it requires that output can be interpreted, that events are logged and that people keep oversight. Source references and logs are exactly that evidence, and we build it. Whether your application counts as high-risk is a legal question for your legal department, not for us.

How the per-user sign-in works technically and how systems get connected is described on the Integration page.

Quality

How you know the answers are right

RAG without measurement is a feeling. We build the measurement in from the start, not as an afterthought before go-live.

Gold standard questions

Real questions from the business, each with the correct answer and the source behind it. Work for your people, and the basis for everything else.

RetrievalAnswer

Score the two halves separately

Did the search find the right passages? And did the model build the right answer from them? Merge the two and you look for the fault in the wrong place.

On every change

Different model, different split, new documents: scoring runs automatically alongside. Without it, every adjustment is flying blind.

Limits

What RAG does not solve

So that it is clear from the start what you get and what you do not. These points come up in every project.

Outdated stays outdated

The search finds what is there. If the old instruction is still in the archive, it can end up in the answer. People have to do the tidying.

Contradictions become visible, not resolved

Where two documents contradict each other, the system shows both. Which one applies is a question for the business, and often the most useful side effect.

Counting is not searching

“How many orders last quarter” is not answered by a document index. That needs the system holding the number.

What is written nowhere is found by nobody

Knowledge in people's heads does not become text through an index. The gap becomes visible; closing it is up to the organisation.

Common questions

What we get asked first

What is RAG, exactly?

Retrieval-augmented generation. For every question the fitting passages from your own material are retrieved first, then the model receives those passages together with the question. So it answers out of your material rather than out of what it saw during training.

Do we have to train our own model for this?

No, and as a rule it would be the wrong route. Training binds the knowledge into the weights, where nobody can check or update it any more. An index can be changed the moment a document changes.

How long until the first answers?

For a bounded archive in workable formats, a few weeks to answers you can rely on. The effort grows with the spread of formats and with the question of who may see what. That is the same question as with any connection, it simply comes up earlier here.

Do our documents leave the house?

Only as far as you decide. Embedding can run at a provider or on your own servers, and running in Switzerland or in the EU is possible. What goes where is settled beforehand and stays traceable.

What does running it cost?

Three items: storing the index, embedding the changes and the requests themselves. The last one dominates by a wide margin and depends on how much text goes to the model per request. That is precisely why the choice in the section above is not a matter of taste.

Do we have to tidy up our data first?

Not first, and not completely. It helps to begin with a well-kept archive. The result then shows what tidying up is worth. A project that starts with a data cleanup delivers nothing for six months.

Contact

Get in touch directly & without obligation

  • ✓Non-binding initial consultation
  • ✓Personal advice from our expert team
  • ✓Response within 24 hours
Timo Weiser

Timo Weiser

Co-Founder Codify AG, Cloud Engineer

contact@codify.ch

Your message

What are you interested in?
0/2000

By submitting I agree to the privacy policy.