I built an offline Q&A Chatbot for my University using FastAPI and BM25 (No heavy LLMs required!)
▲ 8 r/madeinpython+3 crossposts

I built an offline Q&A Chatbot for my University using FastAPI and BM25 (No heavy LLMs required!)

Hey everyone,

I wanted to share an open-source project I've been working on: Fırat University Assistant.

It’s a Turkish question-answering system that searches through local PDF documents (like student regulations, course contents) to find answers instantly. Instead of using expensive or slow APIs, I implemented a lightweight BM25 search index with Turkish-aware normalization.

Key Features:

  • Offline First: Does not require an internet connection or external API keys.
  • Tech Stack: Python 3.10+, FastAPI, pdfplumber, and Jinja2.
  • Speed: fast indexing and retrieval without heavy GPU usage.

I built this to help students find information like "passing grades" or "absenteeism rules" quickly without reading through 50-page PDFs.

I’d love to hear your feedback or suggestions on the code structure!

Repo Link: https://github.com/Yigtwxx/FiratUniversityChatbot

u/Yigtwx6 — 8 days ago
▲ 4 r/madeinpython+2 crossposts

I built "Neural-Archives" – An open-source knowledge base for AI, ML, and RAG. I am a 3rd-year SE student and would value your constructive feedback.

Hi everyone,

I am a third-year Software Engineering student focusing primarily on Artificial Intelligence, Machine Learning, and Retrieval-Augmented Generation (RAG). As my research and project complexity grew, I found myself needing a structured, central repository to document architectures, resources, and implementation notes.

To solve this, I created Neural-Archives:https://github.com/Yigtwxx/Neural-Archives

What is inside the repository?

  • Core ML & DL Concepts: Curated notes and resources covering foundational theories and practical applications.
  • RAG Architectures: Documentation and implementation strategies for building robust Retrieval-Augmented Generation systems.
  • AI Agents: Structural logic and workflow documentation for autonomous agents.
  • Production Focus: Code snippets and architectural guidelines aimed at transitioning models from experimental phases to production-ready states.

Why I am sharing this here: I originally built this to organize my own learning journey, but I have cleaned it up and made it open-source in the hopes that it might help other students or junior developers.

More importantly, I am here to learn from the experienced engineers in this community. I know I still have a lot to learn, and there are likely areas where my architecture or understanding can be optimized.

If you have the time to take a look, I would highly appreciate any constructive criticism regarding:

  1. Missing foundational papers or concepts I should include.
  2. Bad practices in my documentation or code structuring.
  3. Recommendations for better production-grade RAG implementations.

Pull requests and issues are highly welcomed. Thank you for your time and any feedback you can provide.

u/Yigtwx6 — 12 days ago
▲ 1 r/madeinpython+2 crossposts

I built "Star Cipher" — A custom 128-bit SPN Block Cipher from scratch using only the Python standard library.

Hey everyone,

I've always been fascinated by how modern cryptography architectures like the Advanced Encryption Standard (AES) actually work under the hood. To truly understand the mechanics of block ciphers and diffusion, I decided to build one from scratch without relying on external cryptography libraries.

I'm excited to share Yıldız Cipher (bsglab) — a custom-built, block-based Substitution-Permutation Network (SPN) encryption algorithm and interactive console application written entirely in Python.

What is it? It's an educational cryptography project designed to demonstrate the inner workings of symmetric-key encryption. Instead of being a black box, it breaks down complex concepts into an accessible, heavily documented Python codebase.

Key Features:

  • Custom SPN Architecture: Implements a 128-bit block encryption utilizing a custom S-Box (Substitution) and P-Box (Permutation).
  • Cipher Modes: Supports both ECB (Electronic Codebook) and CBC (Cipher Block Chaining) modes of operation.
  • Avalanche Effect Testing Suite: Includes a built-in testing feature to visually and mathematically demonstrate how a single flipped bit in the plaintext (or key) ripples through the entire ciphertext.
  • Zero Dependencies: Written purely in Python 3.6+ using standard libraries. No pip install required.
  • Interactive CLI: A user-friendly command-line interface to easily encrypt, decrypt, and run avalanche tests on the fly.

How it works (The Math & Structure):

  • Key Schedule: Normalizes the key via MD5 to exactly 16 bytes, and uses deterministic SHA-256 chaining to generate distinctly different subkeys for its 4 computational rounds.
  • Substitution (S-Box): Unlike AES which uses a fixed look-up table, this cipher uses a mathematically contiguous S-box: $S(x) = (x \times 3 + 7) \pmod{256}$.
  • Permutation (P-Box): Mimics the AES ShiftRows operation by treating the 16-byte block as a 4x4 matrix and applying row-based bit shifting to scatter the data.
  • Diffusion Layer: Employs modulo 256 addition to bind neighboring bytes, ensuring a high diffusion rate across the block.

Who is this for? If you are a student learning about cybersecurity, a Python developer, or a cryptography enthusiast looking to see how block ciphers are constructed layer by layer, this repository serves as a great starting point.

I would love for you to check it out, review the codebase, or play around with the CLI. Any feedback on the architecture, the Python implementation, or suggestions for structural improvements would be highly appreciated!

GitHub Repository:https://github.com/Yigtwxx/bsglab

Thanks for reading!

u/Yigtwx6 — 16 days ago
▲ 45 r/u_Yigtwx6+4 crossposts

I built an open-source Random Number Generator (BSG)

I’m currently a third-year Software Engineering student, and I recently decided to combine my interest in algorithms and chaos theory into a fun experimental side project.

I built BSG Random Number Generator, a pseudo-random number generator (PRNG) entirely powered by the chaotic orbits of the famous Collatz Conjecture (3n+1 problem).

If you are familiar with the Collatz Conjecture, you know how unpredictable and wildly varying the sequence paths can be before they inevitably crash down to the 4-2-1 loop. I wanted to see if I could harvest that mathematical chaos and extract entropy from those orbital lengths to generate usable random numbers.

How it works & Features:

  • Pure Python: Built entirely in Python with no heavy external dependencies.
  • Chaos-Driven: Uses the step counts, sequence parity, and peak values of Collatz orbits as seed parameters.
  • Experimental Nature: It produces surprisingly uniform distributions for general non-critical usage (like simulations, games, or procedural generation).
  • Disclaimer: As a responsible dev, I must note that this is strictly experimental. It has not been heavily audited for cryptographic security, so please don't use it to generate SSH keys or passwords!

Why I made it: Most of us just use import random or secrets without thinking twice. I wanted to build an RNG from scratch just to understand how entropy and uniform distribution logic work under the hood, and injecting a notorious unsolved math problem into the mix made it 10x more fun to code.

Check out the source code: You can find the repo, implementation details, and the Makefile on my GitHub:https://github.com/Yigtwxx/bsg-random-number-generator

I would genuinely appreciate any feedback on the code architecture, how I might extract even more entropy from the orbits, or any thoughts from the math/crypto nerds out there on improving the uniformity!

Thanks for checking it out!

u/Yigtwx6 — 17 days ago
▲ 6 r/u_Yigtwx6+3 crossposts

Built a Lightweight Language Model for Next-Word Prediction (PredictaLM) – Seeking Architectural Feedback

Hello everyone,

I am a software engineering student focusing on artificial intelligence and deep learning. I recently developed PredictaLM, a lightweight language model designed to demonstrate next-word prediction capabilities and fundamental NLP mechanics.

Rather than relying on external APIs, my goal was to build and train a neural network from scratch to better understand linguistic pattern recognition and model training pipelines under the hood.

I am currently looking for professional feedback on the codebase. I would greatly appreciate any technical insights regarding:

  • Model architecture optimizations
  • Training pipeline efficiency
  • Best practices for handling text datasets in this specific context

You can review the repository here:https://github.com/Yigtwxx/PredictaLM

Thank you for your time and feedback.

u/Yigtwx6 — 24 days ago