GitHub - omeraydin00/PolicyGPT: AI assistant that turns Turkish government-procedure documents into interactive step-by-step guides with a local RAG pipeline. · GitHub
Skip to content
omeraydin00Public

About

AI assistant that turns Turkish government-procedure documents into interactive step-by-step guides with a local RAG pipeline.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

28 Commits

Folders and files

Repository files navigation

PolicyGPT

Turns long government documents into short, step-by-step answers.

Python · LangChain · FAISS · Ollama (Mistral) · Flask

Residence certificate Tax debt inquiry

Official procedures in Turkey, such as registering a residence, getting a social security record, applying for citizenship or checking tax debt, are explained in long PDFs written in legal language. PolicyGPT reads those documents and answers a question with a numbered list of what to do, based on the documents rather than on the model's own guesses.

The PDFs in data/ are split into overlapping chunks, embedded with all-MiniLM-L6-v2 and stored in a FAISS index. For each question the closest passages are passed to Mistral, which runs locally through Ollama, so no document or question leaves the computer.

Social security record Citizenship application

Running it

You need Python 3.10 or newer and Ollama.

ollama pull mistral

git clone https://github.com/omeraydin00/PolicyGPT.git
cd PolicyGPT/PolicyGPT
python -m venv venv && source venv/bin/activate
pip install -r requirements.txt
python app.py

Then open http://127.0.0.1:5000 and ask something like "İkametgah belgesi nasıl alınır?". To add a topic, put its PDF in data/ and add the path to pdf_files in rag_engine.py.

Notes

  • The index is rebuilt for every question; saving it to disk would make answers much faster.
  • Answers are only as current as the PDFs. Check anything important on the official portal.

Made for the Deep Learning course at Sakarya University.

About

AI assistant that turns Turkish government-procedure documents into interactive step-by-step guides with a local RAG pipeline.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages