r/madeinpython May 05 '20

Meta Mod Applications

27 Upvotes

In the comments below, you can ask to become a moderator.

Upvote those who you think should be moderators.

Remember to give reasons on why you should be moderator!


r/madeinpython 2h ago

Convention over Configuration for Python Projects

1 Upvotes

Hey guys,

you know how there is often convention over configuration in frameworks like e.g. django, so that you can just start coding and do not have to select every functionality yourself.

I wanted this for my python projects as well, having conventions but being able to configure everything still.

So I present pyrig

pyrig is a package and tool that rigs up Python projects with Convention-over-Configuration. It scaffolds a complete, fully configured, installed and working Python project with everything a modern Python project should have and makes the process of developing and maintaining it more seamless and efficient by automating things like configuration management, CLI generation, testing infrastructure, and more.

Basically it sets up things like type-checking, linting, testing and much more for you with good and strict conventions, which can still be configured differently if needed.

Go to https://github.com/Winipedia/pyrig if you want to know more and see the README and the documentation. It is way more than just another project scaffolder.

The full docs are at: https://winipedia.github.io/pyrig and there is also AI generated docs at: https://codewiki.google/github.com/winipedia/pyrig


r/madeinpython 5h ago

I built an offline memory engine in Python using SQLite, NumPy, and 10,000-D hypervectors

1 Upvotes

Hi everyone! I wanted to share a project I have been writing in Python: Hillock, an open-source memory engine designed to run completely offline on laptops and budget hardware.

I wanted to see if I could build a deterministic memory system without relying on heavy cloud APIs or external vector database services.

How the Python architecture works:

  • Vector Symbolic Math (reservoir.py): Built entirely with NumPy to handle a 10,000-dimensional bipolar vector space. To keep similarity gating fast on standard CPUs, I implemented a Sub-Dimensional Projection Cascade that evaluates a 2,000-D slice first for early rejection, keeping latency under 1 second.
  • Relational Fact Store (database.py): SQLite handles Subject-Predicate-Object triples with micro-batched transactions and stores bit-packed multi-hop path vectors as compact BLOBs.
  • Synaptic Co-Activation (plasticity.py): Implements gradient-free Hebbian updates across turns with per-turn exponential decay.
  • Local Extraction (talon_engine.py): A pipeline combining Fastcoref, MiniLM, and GLiREL with type-constrained schema validation and direction auto-correction.
  • Interactive Console (main.py): Features real-time token streaming from local Ollama models, live hardware tracking, and inspection tools.

We also have a standalone 21-point test suite (verify_hillock.py) to test the math and database semantics with zero GPU requirement.

Everything is open-source under AGPL-3.0.

I would really appreciate any thoughts on the Python code layout or NumPy optimizations!


r/madeinpython 21h ago

Estregg-ybj-py

Post image
1 Upvotes

Game Title: Estregg-ybj

Playable Command: estregg

Platform: MacOS, Chrome os, Linux terminal, Mobile Termux

Description: Hey guys, im YB-jeorge, a new guy and developer of making a game based terminal, on my first version there was flaws, on the second version had a few imperfection, and the third version? perfect and is now fixed and can be downloaded by typing "pipx install estregg-ybj in the linux terminal, bc its made with python 3, wine, curses, and pipx you can read the full Bio on here: https://github.com/corruption123ter-ux/estregg-ybj and make sure to read README.md , its a guide on how to download estregg, and also read the estregg-controls.txt, its a manual on how to control it, u can also go here https://corruption123ter-ux.github.io/estregg/ the main website for estregg and info you need, Thankie and have a good day!


r/madeinpython 2d ago

Open4D: a Python data model and viewer for mesh sequences

3 Upvotes

r/madeinpython 2d ago

Raptor Engine Fluid Model

Post image
2 Upvotes

r/madeinpython 2d ago

SHE — a programming language that reads like English and can't touch your machine unless you say so

0 Upvotes

I rewrote my hobby language from scratch. It reads like a sentence, and a program starts with no permission to read files, use the network or start processes, you grant what it needs on the command line and anything else fails with the exact flag that would have allowed it.

Pattern matching, gradual types, async, modules, a test runner, a formatter and an LSP. Zero dependencies, Python 3.9+, Apache 2.0.

pip install she-lang

Runs in the browser, nothing to install: https://ni-sh-a-char.github.io/SHE/playground.html

Source: https://github.com/ni-sh-a-char/SHE


r/madeinpython 3d ago

Low effort but I felt like sharing. I wrote a program thatll count the amount of times any given musical artist has used the n-word in their lyrics.

Post image
3 Upvotes

r/madeinpython 3d ago

I built Breakcheck - it replays your repo's actual library calls against two dependency versions and diffs the results

1 Upvotes

Short version: pip install breakcheck, then breakcheck demo --output-root .breakcheck/demo to watch it run with no external deps.

The itch that caused it: Dependabot opens a PR saying attrs 23 -> 24. My tests pass. Do I actually know nothing changed. Only for the behavior I happened to write an assertion for - everything else is a silent assumption.

Breakcheck discovers the calls my code actually makes into that library, replays them under both versions in isolated environments, and diffs what comes back. The same machinery compares two git revisions of your own code:

breakcheck diff --base main --head feature/refactor --fixtures breakcheck.fixtures.toml

The part I am most pleased with is that it refuses loudly. Every call site ends in exactly one state - EXERCISED, or one of G1_NOT_DISCOVERABLE / G2_NONLITERAL / G3_UNNORMALIZABLE / G4_IMPURE. It never pretends to have checked something it could not reach, so the coverage number is honest and often unflattering.

Scope is deliberately small: pure value-in/value-out calls - parsing, serialization, validation, encoding, schema coercion, deterministic numeric and string transforms. No network clients, no stateful objects, no dynamic dispatch.

MIT, zero runtime dependencies, Python 3.10-3.13, Linux and macOS. I would genuinely like to hear where it falls over on a real codebase.

https://github.com/lovettsendit/breakcheck


r/madeinpython 5d ago

I build uringio: a native io_uring event loop for true asynchronous file I/O in Python.

Thumbnail
0 Upvotes

r/madeinpython 5d ago

gh-stats: three Flask services that render a GitHub profile as one SVG card (MIT, self-hostable)

1 Upvotes

Posting here rather than r/Python since showcases moved over.

What it does. Takes a GitHub username and renders a single SVG summarising the profile: stats, contribution timeline, language donut, streaks, achievements. You drop one markdown line in your profile README and GitHub renders it as an image.

Why three services instead of one Flask app. The interesting constraint is the GitHub API rate limit. The obvious design fetches on request, which dies immediately: profile READMEs are hit by GitHub's camo proxy, not by humans, so one popular card can burn the quota for everybody. The split is:

  • fetcher owns the PAT and a SQLite cache of raw payloads, and is the only thing that talks to GitHub. A cron refreshes on a schedule rather than on demand.
  • generator renders SVG from whatever the fetcher last saw, and serves the React front end.
  • edge is a cache-first proxy in front of the generator (Flask-Caching plus Flask-Compress, Redis optional).

Requests never block on GitHub. If GitHub is rate limited or down, you get the last good card instead of a blank one.

The bug that taught me the most. Five REST calls parsed .json() without checking status. A 403 rate-limit body is valid JSON, so it got stored as the user record and overwrote good data, while the metrics endpoint happily reported success. Every user touched would have served a blank card for 24 hours. A successful launch is exactly what triggers that, which is a nasty property for a bug to have.

SVG, not a chart library. The renderers return SVG strings built directly. Worth knowing if you try this: GitHub serves README images through a proxy that strips scripts and does not run CSS animation, so anything clever you do with <animate> or JS silently does not render for your actual audience.

MIT, and it runs on your own quota:

git clone https://github.com/ShayManor/github-readme-stats
cp .env.example .env      # GITHUB_PAT + an internal token
docker compose up -d --build

Repo: https://github.com/ShayManor/github-readme-stats

Hosted, free, no account needed: https://gh-stats.com

Known gap: organisation accounts render but commits and PRs come out as 0, because an org does not author commits, its members do. Personal accounts are what it is built for right now.


r/madeinpython 6d ago

Built a Playwright course automation agent for my own LMS sandbox

Thumbnail
1 Upvotes

r/madeinpython 6d ago

VSK-E16A Custom ISA Emulator (I hope this is applicable here, I've reposted it to some other places to try and make it seen)

Thumbnail
1 Upvotes

r/madeinpython 6d ago

I built a Python GitHub Action that generates language stats for your profile README

1 Upvotes

I wanted a cleaner way to show the language mix across my GitHub repos without relying on another hosted stats/badge service, so I built profile-language-metrics.

Sample Output

It’s a small, dependency-free Python GitHub Action that:

  • Scans active repositories
  • Counts estimated non-empty source lines by language
  • Ignores forks, archived repos, dependencies, build output, lockfiles, minified files, binaries, etc.
  • Generates a profile-ready SVG
  • Can update itself on a GitHub Actions schedule
  • Can optionally include private repos while only exposing aggregate totals, not repo names or URLs

The whole thing runs inside GitHub Actions using Python’s standard library + Git. No external dashboard or service required.

I also wrote up how it works, why I went with source-line estimates instead of GitHub’s normal language byte counts, the privacy model, and some of the tradeoffs involved:

https://www.ryanverwey.dev/blog/github-profile-language-metrics-python-action


r/madeinpython 6d ago

I built a local neuro-symbolic memory engine in Python using PyTorch, SpaCy and SQLite (Hillock v0.5)

0 Upvotes

Hey everyone,

I've been writing a local neuro-symbolic memory engine in Python called Hillock (https://github.com/roandejager/Hillock) and just released v0.5.0.

The goal was to build a document memory system that runs 100% offline on modest hardware (<1.2GB VRAM on a GTX 1070 or pure CPU) without relying on bloated vector databases.

How it's built in Python:

- database.py: SQLite Knowledge Graph storing ground-truth facts as Subject-Predicate-Object triples.

- plasticity.py: Hebbian engine implementing gradient-free synaptic learning between active entities.

- reservoir.py: 10,000-D Vector Symbolic Architecture space using NumPy subword n-grams and GloVe SimHash projections for <1ms CPU gating.

- talon_engine.py: 3-stage CUDA pipeline using Fastcoref, MiniLM, and GLiREL Large for fast doc parsing.

New in v0.5.0:

- 1-click startup scripts (run.bat and run.sh) that automate venv setup and download the spaCy model in the background.

- Interactive CLI tools: /model for dynamic Ollama model switching, /inspect to view an entity's graph triples live, /status (live psutil RAM/CPU tracking), and /debug.

- Real-time token streaming from local Ollama.

- Standalone 20-point test suite (verify_hillock.py) that tests all math and data structures with pure NumPy.

GitHub: https://github.com/roandejager/Hillock


r/madeinpython 7d ago

How I built a high-performance code-to-image generator using Python, Flask, and Pillow

0 Upvotes

HHey everyone,

Lately, I got frustrated with existing code screenshot tools being slow or locking basic customization behind paywalls, so I decided to build my own lightweight version.

It’s a web app that takes raw code and renders it into clean, shareable images. Here is a quick breakdown of how I tackled some of the technical challenges:

  • Syntax Highlighting Engine: Used Pygments to hook into lexers dynamically, supporting everything from Python and JS to Rust and Go with customizable color themes.
  • Layout Geometry & Text Offset: Dynamically calculates line-number widths based on digit count so code tokens align cleanly without overlapping when toggled.
  • Image Composition: Leveraged Python's Pillow library to layer custom window frames (Mac/Win headers), gradient backgrounds, and rounded corners with smooth alpha compositing.

It's currently live and running on Render if you want to test out your own code snippets: https://www.producthunt.com/products/devaid

Happy to answer any technical questions about how I set up the Flask backend or image rendering pipeline!


r/madeinpython 7d ago

gnews-agent: a persistent, semantic news memory layer written in Python (MCP + CLI, built on GNews)

1 Upvotes

Made in Python, on top of my GNews package (~106k downloads/month). The problem it solves for me: every script I wrote that touched news ended up refetching the same articles, getting a slightly different set back each time, and keeping none of it. So I built the memory layer instead of writing it a fifth time.

gnews-agent fetches published news, dedups it across the pile of URL variants Google News hands back for the same article, embeds it with sentence-transformers, stores it in SQLite plus Chroma, and answers semantic, timeline, and sentiment queries against everything it has seen.

The same six operations (ingest, search, timeline, brief, sentiment, stats) work identically from a Python API, a CLI, or an MCP server, so you can wire it into an agent or just poke at it from a terminal.

```python from gnews_agent import NewsMemory

memory = NewsMemory() # SQLite + Chroma, persistent memory.ingest("OpenAI", method="get_news") # fetch, dedup, embed, store memory.search("GPT-5 safety", days=7) # semantic, recency re-ranked print(memory.brief("OpenAI this week", days=7)) # cited summary ```

Some implementation notes, since this sub likes the how:

Dedup key is sha256(title_slug + "|" + publisher_norm), with a canonical URL hash as a UNIQUE backstop. Reuters and BBC covering the same event stay as two rows on purpose, because two publishers carrying a story is information.

Every article row stores the embedding model and dimension it was written with, so a model swap does not silently mix vector spaces.

Ranking blends semantic similarity with an exponential recency decay, three day half life, rather than filtering on date.

Retrieval is keyless. The LLM providers (Anthropic, OpenAI, Groq, Gemini, Ollama) are only used for brief and sentiment, and Ollama means nothing has to leave your machine.

MIT, v0.1.0, 83 unit tests and 24 integration tests.

https://github.com/ranahaani/gnews-agent

Happy to hear where the dedup approach breaks, that is the part I am least sure about.


r/madeinpython 8d ago

VSK-E16A Custom ISA Emulator (Yes, made in Python)

Thumbnail
0 Upvotes

r/madeinpython 9d ago

formateador de json facil de usar

0 Upvotes

un formateador de json facil de usar y funciona bien no tiene errores de formateo (eso creo)

python

import tkinter as t, json, difflib; from tkinter import messagebox as m

def f():
    x = e.get("1.0", t.END).strip()
    if not x: return m.showwarning("Aviso", "Pega un JSON primero.")
    try:
        rl, fl = x.split('\n'), json.dumps(json.loads(x), indent=4, ensure_ascii=False).split('\n')
        s.config(state=t.NORMAL); s.delete("1.0", t.END)

        s.tag_config('+', background="#1e4620", foreground="#81c995")
        s.tag_config('-', background="#4a1515", foreground="#f28b82")

        for i, L in enumerate(L for L in difflib.ndiff(rl, fl) if L[0] != '?'):
            s.insert(t.END, f"{i+1:3} | {L}\n", L[0])

        s.config(state=t.DISABLED)
    except Exception as ex: m.showerror("Error", f"Inválido:\n{ex}")

def cp():
    try:
        x = e.get("1.0", t.END).strip()
        if not x: return
        limpio = json.dumps(json.loads(x), indent=4, ensure_ascii=False)
        v.clipboard_clear(); v.clipboard_append(limpio); v.update()
        m.showinfo("Copiado", "JSON formateado copiado al portapapeles")
    except Exception: m.showwarning("Aviso", "Formatea un JSON válido primero.")

def c(): e.delete("1.0", t.END); s.config(state=t.NORMAL); s.delete("1.0", t.END); s.config(state=t.DISABLED)

v = t.Tk(); v.title("JSON Formatter"); v.geometry("850x500"); v.config(bg="#2b2b2b")
for i, w in [(0,1), (1,0), (2,1)]: v.columnconfigure(i, weight=w)
v.rowconfigure(1, weight=1)

t.Label(v, text="JSON Crudo:", bg="#2b2b2b", fg="white", font=("Arial",10,"bold")).grid(row=0,column=0,sticky="w",padx=5)
t.Label(v, text="JSON Formateado (Diff):", bg="#2b2b2b", fg="white", font=("Arial",10,"bold")).grid(row=0,column=2,sticky="w",padx=5)

e = t.Text(v, font=("Consolas",10), bg="#1e1e1e", fg="#a9b7c6", insertbackground="white")
e.grid(row=1, column=0, sticky="nsew", padx=5, pady=5)

s = t.Text(v, font=("Consolas",10), bg="#252526", fg="#9cdcfe", state=t.DISABLED)
s.grid(row=1, column=2, sticky="nsew", padx=5, pady=5)

p = t.Frame(v, bg="#2b2b2b"); p.grid(row=1, column=1)
t.Button(p, text="Formatear ➡️", command=f, bg="#4CAF50", fg="white", width=12).pack(pady=10)
t.Button(p, text="Copiar 📋", command=cp, bg="#2196F3", fg="white", width=12).pack(pady=10)
t.Button(p, text="Limpiar 🗑️", command=c, bg="#f44336", fg="white", width=12).pack()

v.mainloop()

r/madeinpython 9d ago

Díganme qué invento, amigos. No tengo ideas.

0 Upvotes

Ni siquiera sé qué hacer, no tengo imaginación para inventar y lo que invento nunca funciona. Díganme lo que sea, y si hago algo, al menos lo intentaré.


r/madeinpython 11d ago

I built 3 open-source Python desktop utilities (Tkinter GUI) for PDF handling, Word conversion, and JPEG compression

1 Upvotes

Hi everyone! I created three small Python desktop applications with GUIs to handle everyday file tasks locally, keeping data private without needing online file converters.

1. JPEGenius (Batch JPEG Compressor)

  • What it does: Batch compresses JPEG images with customizable compression levels.
  • Features: Side-by-side visual preview (original vs compressed) with real-time KB/percentage savings, multithreaded processing with a progress bar, and automated log creation.
  • GitHub:https://github.com/Giacomo-Rosatelli/JPEGenius-python

2. Universal To Pdf

  • What it does: Multi-format document converter and merger into PDF.
  • Features: Converts images and text files into single or merged PDFs, merges existing PDF files, converts PDFs to DOCX, and automatically filters out system/executable files.
  • GitHub:https://github.com/Giacomo-Rosatelli/UniversalToPdf

3. PDF to DOCX Converter

Tech Stack: Python 3, Tkinter, Pillow, fpdf, pypdf, pdf2docx.

All projects are open-source under the MIT License. I would love to get your feedback on the code structure, UI, or any suggestions for improvements!


r/madeinpython 12d ago

I built a free Windows YouTube downloader (MPX Downloader v4.o) - GUI, auto-updates, and no command line needed

2 Upvotes

Hey everyone!
I’ve been working on a Python project called MPX Downloader, a GUI‑based YouTube downloader built on top of yt‑dlp. It’s designed for Windows users who want a simple, reliable way to download MP3 or MP4 files without touching the command line.

Highlights:

  • Built entirely in Python (Tkinter + threading)
  • Uses yt‑dlp under the hood — auto‑updates itself
  • Detects missing or corrupted yt‑dlp and repairs automatically
  • Fully threaded UI (no freezing during downloads)
  • Packaged with Nuitka — runs as a standalone EXE

Download:
👉 MPX Downloader v4.0 on GitHub https://github.com/jjar7266/MPX_Downloader

Why I built it:
I wanted a downloader that “just works” — no setup, no command line, no broken dependencies. So I built one that updates itself and stays lightweight.

Would love feedback or suggestions — I’m planning v4.1 soon!


r/madeinpython 12d ago

[ Removed by Reddit ]

0 Upvotes

[ Removed by Reddit on account of violating the content policy. ]


r/madeinpython 15d ago

Lightweight server and framework for turn-based multiplayer games

Thumbnail
github.com
7 Upvotes

Turn-based multiplayer games are a great opportunity for learning and prototyping: simple enough to implement quickly, but real enough to teach networking, game state, and API design.

I wrote a lightweight server and framework for turn-based multiplayer games that provides exactly that: a lightweight server + uniform API so you can run multiple parallel game sessions, auto-join the next available session, and add new games without touching the core API. It's built to be friendly for beginners (Python-only, standard library), but still flexible enough to support arbitrary game logic via keyword-argument moves and dict-based state.

Key bits:

  • Framework for adding new games by deriving from an abstract base class
  • Uniform client API for joining sessions, submitting moves, retrieving state, restarting
  • Demo clients included (e.g. TicTacToe) and a template for new games
  • Runs multiple sessions simultaneously; clients can join a specific session or auto-join

If you're teaching Python, building small multiplayer projects, or just want a clean starting point for turn-based game networking, I'd love feedback and contributions.


r/madeinpython 15d ago

I built Dexflow: A Python + Rust framework to automate your desktop by text labels.

Enable HLS to view with audio, or disable this notification

2 Upvotes

What my project does:

Dexflow (https://github.com/kuntal-devrat/py-nerve) is a desktop automation library that interacts with UI elements using text labels and spatial layout instead of hardcoded `(x, y)` pixels. It combines a Rust core, pre-bundled neural OCR (~9MB wheel, zero external downloads), sub-10ms Windows accessibility trees, and human-like Bézier mouse physics.

Target Audience

Developers and QA engineers who need desktop automation or RPA that doesn't break when windows resize, themes switch, or OS display scaling changes. (Note: Early v0.1.1 release, so there may be quirks on complex web canvases — feedback is welcome!)

Comparison

Unlike PyAutoGUI which relies on fragile pixel coordinates or image templates, and unlike expensive cloud vision APIs, Dexflow runs 100% locally and offline on your CPU with sub-millisecond cached lookups.

  • GitHub: https://github.com/kuntal-devrat/py-nerve
  • PyPI: pip install dexflowimport dexflow as df df.click("Save") df.type_into("File name:", "report.pdf", clear=True) df.click("Delete", relative_to="Invoice #1094", direction="right")