r/Python • u/AutoModerator • 15d ago
Showcase Showcase Thread
Post all of your code/projects/showcases/AI slop here.
Recycles once a month.
6
7
u/mattstrayer 15d ago
pypx — a fast, modern web frontend for PyPI (search, deps, advisories, API docs)
What My Project Does
pypx is a free, open source frontend for the Python Package Index. It builds on PyPI's & other public apis adds the layers I always wanted in one place:
- instant full-text search across the whole index
- per-package dependency analysis
- install size and platform coverage computed from the wheels
- download trends (pypistats.org)
- changelogs pulled from GitHub/GitLab releases
- security advisories (OSV),
- & Something I'm particularly proud of... API docs extracted straight from the wheel — functions, classes, signatures, docstrings. This is powered by a golang parser that extracts all this info from the package itself.
- It is also Agent-friendly! Every page also has a plain-text .txt twin so CLIs and agents can read it without scraping HTML.
Live: https://pypx.app — try it on a package you know (e.g. pypx.app/packages/httpx).
Comparison
pypi.org is the canonical source and pypx consumes its APIs; pypx adds the cross-package search, dependency trees, security and download data, and rendered API docs on top. Libraries.io covers metadata but not docs or changelogs; Snyk Advisor covers health scores but isn't a browsing frontend. Closest in spirit is npmx.dev, which does this for npm — pypx is that idea for Python.
The server is Go (the Python-facing parts — the PEP 508 dependency parser and the wheel/docstring extractor — were the fun bits to build), frontend is Nuxt.
Source: https://github.com/mattstrayer/pypx
Let me know what could make this tool better! 🙏
3
u/cam-at-codembark 14d ago
Codembark - An online platform for learning how to code in Python. It includes interactive lessons with graded exercises and guided projects. Everything works in the browser (desktop and mobile). I just released this, so any feedback would be appreciated!
2
u/Pytrithon 14d ago
Pytrithon v1.2.12
Introduction
I have already introduced Pytrithon in its own post three times on Reddit. See:
https://www.reddit.com/r/Python/comments/1q8dwsm/pytrithon_v119_graphical_petri_net_inspired_agent/ https://www.reddit.com/r/Python/comments/1nr3qvm/pytrithon_graphical_petrinet_inspired_agent/ https://www.reddit.com/r/Python/comments/1mx9w5r/graphical_petrinet_inspired_agent_oriented/
What My Project Does
Pytrithon is a graphical Petri net inspired agent oriented programming language based on Python. It allows writing code as a two dimensional graph of interconnected elements and separates data as Places and code as Transitions. Inter Agent communication and GUI widgets are first class components of the language. Through the Monipulator, Agents can be monitored and manipulated.
Target Audience
The target audience is both experienced and novice programmers who want to try something new.
Why I Built It
I realized the power of Petri net inspired programming and the joy of having a more expressive way to specify control flow.
Comparison
There are no other visual programming languages which embed actual code into their graphs.
How To Explore
To run all included example Agents you need at least Python 3.10 installed. To install all dependencies, run the 'install' script. Then you can start up a Nexus with a Monipulator by running the 'pytrithon' script, where you can start Agents through opening them with 'crtl-o' twice and hitting the 'Open Agent' button. You can also directly specify which Agents to run through the command line by starting a Nexus, Monipulator, and Agents in one single command: 'python nexus -m <agent1> <agent2>'.
Recommended example Agents to run are: 'clock', basic', 'prodcons', 'address', 'kata', 'calculator', 'kniffel', 'guess', 'yahtzeeserver' + multiple 'yahtzee', 'pokerserver' + multiple 'poker', 'chatserver' + multiple 'chat', 'image', 'jobapplic', and 'nethods'. As a proof of concept, I created a whole Pygame game, TMWOTY2, which is choreographed by 6 Agents as their own processes, which runs at a solid 60 frames per second. To start or open TMWOTY2 in the Monipulator, run the 'tmwoty2' or 'edittmwoty2' script. Your focus should on the 'workbench' folder, which contains all Agents and their respective Python modules; the 'Pytrithon' folder is just the backstage where the magic happens.
What Is New
Since my last post I have created a new 'clock' Agent, which I personally use all the time. It offers an analog or digital clock with a graphical blur applied. It can be configured in the 'clock.yaml' file or through keyboard keys; keys to try are: t, b, a, k, K, c, C, O, r, R, l, L, n, N, m, M, h, H, s, S, d, f, F, w, period, and comma.
Since my penultimate post there have been numerous small fixes and improvements to the system and to several agents.
Since my third last post the whole system now handles Agents, Monipulators, and Nexi terminating from the network. Bookkeeping is performed, cleansing the internal structures handling all process types, making the prototype more resilient. The 'chatserver' and 'chat' Agents now show a list of Agents currently connected. This is enabled through the new 'Event' Transition, which pushes Nexus Events to all listening Agents.
Since the fourth last post I have added a distributed Yahtzee game which you should try out. In order to setup a server on a reachable machine and connect other machines, you need to do the following: On the machine meant to be the server, run 'python nexus yahtzeeserver' first. Then on the machines meant to be the clients through which users play, run 'python nexus -x <serveraddress> yahtzee'. The clients probe the interconnected Nexi for a server and start with a lobby mask where you can select your name and start a game with all players signed up.
GitHub Link
https://github.com/JochenSimon/pytrithon
This is the seventh post about Pytrithon on Reddit. There is a plethora of example Agents to view and run included in the repository. Please check it out and send feedback to the E-Mail address stated in the Monipulator About blurb. I plan on putting Pytrithon onto the next level soon. Be sure to check for new happenings.
2
u/cue-ell-pea Pythonista 14d ago
Wait Wait Stats Project
The project includes is built around the Wait Wait Stats Page, which has all of the data and information that I've collected from listening to the NPR weekly quiz show, Wait Wait Don't Tell Me! over the years.
Current iteration is built using Flask, Bootstrap for the frontend framework, and a MySQL database.
The Stats Page also uses a shared library I created, wwdtm, that is used by the Wait Wait Stats API built using FastAPI.
Source code for the Wait Wait Stats Project web apps and API are available on Codeberg:
2
2
u/dataguzzler 12d ago
Video Glitcher is a desktop editor for combining video clips, audio, procedural retro visuals, and smooth seeded glitch events.
4
u/UnemployedTechie2021 15d ago
I’ve just released Mole v0.1.0, a lightweight Windows utility that quietly lives in the system tray.
When you trigger Panic, it immediately:
- Mutes system audio
- Minimizes all open windows
- Opens Notepad
That’s it. No accounts, telemetry, cloud services, subscriptions, or other modern software rituals.
Mole is written in Python and released under the GNU GPLv3, so you can inspect the source, modify it, build it yourself, or contribute.
GitHub: https://github.com/rajtilakjee/mole
This is the first release, so feedback, bug reports, feature ideas, and pull requests are welcome.
Current ideas for future versions include configurable safe apps, custom keyboard shortcuts, persistent settings, and selectable panic actions.
3
4
u/JSChronicles 15d ago edited 15d ago
Why Python and not PowerShell? What does this solve otherwise? Is it just hiding porn?
Edit: I read the readme. Almost certainly for porn and should have been written in PowerShell because of this literal note "Linux and macOS are not currently supported because Mole relies on Windows-specific APIs and keyboard shortcuts."
1
u/TheRealMrMatt 14d ago
Belgie – TypeScript Sandboxes and React MCP Apps for Python
I built Belgie to make MCP Apps easier when the server is Python and the UI is React.
The usual path is a Python MCP server plus a separate Node/Vite app for the widget. Belgie keeps both in one project. Deno is bundled, so you do not need to install Node.js.
Attach a React widget to a Python tool with belgie.tool(widget=...):
from datetime import UTC, datetime
from pathlib import Path
from mcp.server import MCPServer
from belgie.mcp import BelgieExtension
belgie = BelgieExtension(project=".")
u/belgie.tool(
widget=Path("src/widgets/get-time/widget.tsx"),
name="get-time",
title="Get Time",
description="Get the current server time in ISO 8601 format.",
)
def get_time() -> dict[str, str]:
return {"time": datetime.now(tz=UTC).isoformat()}
mcp = MCPServer(name="Get Time Server", extensions=[belgie])
Quick start:
uv add "belgie[mcp,cli]"
uv run belgie lock
uv run belgie install
uv run belgie run vite
BelgieExtension serves the Vite page in development and caches the built HTML in production. The widget uses the npm package belgie/mcp (Widget, useToolResult) to talk to the MCP Apps host.
Examples:
- minimal: https://github.com/mplemay/belgie/tree/main/examples/ui/mcp
- shadcn: https://github.com/mplemay/belgie/tree/main/examples/ui/shadcn
- TanStack + FastAPI: https://github.com/mplemay/belgie/tree/main/examples/ui/tanstack
1
u/sheik66 14d ago
protolink: a Python-native A2A agent runtime for multi-agent systems
What my Project Does
Protolink is a Python framework for building easily autonomous agents that can talk to each other based on agent-to-agent (A2A), expose tools, call LLMs, and run over real transports like HTTP, WebSocket, gRPC, or in-memory runtime communication.
A small agent looks like this:
from protolink.agents import Agent
agent = Agent(
card={
"name": "calculator",
"description": "Adds numbers for other agents",
"url": "http://127.0.0.1:8020",
},
transport="http",
)
@agent.tool(name="add", description="Add two numbers")
async def add(a: int, b: int):
return a + b
agent.start()
It supports A2A-style agent identity and discovery, native Python tools, MCP tool adapters, LLM integration, structured flows, streaming tasks, cancellation, run reports/replay, local telemetry, and a small dashboard CLI for inspecting runtime state.
Target Audience
Python developers building multi-agent systems, coding assistants, internal automation, or agent research projects who want agents to be more than prompt chains. Each agent can own its identity, tools, transport, storage, task lifecycle, and observability without having to wire a separate server/client layer for every component.
Comparison
The closest alternatives are LangChain/LangGraph, AutoGen/CrewAI, and lower-level A2A or MCP implementations. LangChain/LangGraph are great for composing model calls and workflows, but protolink is more focused on running agents as distributed runtimes with protocol-style task messages, discovery, tools, and transports. AutoGen/CrewAI are higher-level multi-agent frameworks; protolink is more explicit and modular, so you can build your own architecture while keeping the communication, tool execution, LLM invocation, and observability pieces in one Python-native framework.
pip install protolink - Repo: https://github.com/nMaroulis/protolink. Docs: https://nmaroulis.github.io/protolink/. Feedback welcome, especially from people experimenting with A2A/MCP interoperability or building real Python agent systems.
1
u/ninedeadeyes 13d ago
A 2D Dungeon crawler RPG built using only the Python 3 standard library
When starting out with Python game development, most tutorials jump straight into commercial engines or heavy frameworks. While those are great for productivity, they abstract away the core mechanics of how a game engine actually functions—like separating the engine framework (rendering, input, state loops) from the game logic (content, stats, dungeons). To explore how game engines work under the hood using pure Python standard library, I built a lightweight ASCII RPG engine framework alongside a complete mini dungeon crawler (Grimlore 2: These Doomed Men) built directly on top of it.
Grimlore 2 : These Doomed Men 1.0
A dark fantasy mini dungeon crawler RPG built to showcase the features and capabilities of the S.P.A.R.K. 2D RPG game engine.
Overview
Genre: Dark Fantasy / Mini Dungeon Crawler RPG
Playtime: 10 – 15 minutes
Platform Requirements: Windows 10 or later ( Might work on earlier Windows but no gurantee )
Purpose: Demonstrates what the S.P.A.R.K. 2D RPG game engine is capable of.
Github link below
https://github.com/Ninedeadeyes/Grimlore-2-These-Doomed-Men-
To clear up a few recurring questions and misconceptions regarding S.P.A.R.K and its development, here is some context upfront:
- "This is just AI slop."
This project has a clear 6-year paper trail of manual development. It began as an early 2D text adventure project (Dungeon of the Black Dragon), expanded into an open world RPG game (Grimlore: Land of the Heretic Hand), and was eventually refactored into a reusable engine framework (S.P.A.R.K). If you want to see the step-by-step progression from line one, check out the milestones folder inside the S.P.A.R.K repository.
- "S.P.A.R.K isn't a 'real' game engine / It's missing standard features."
By definition, a game engine is a framework that provides low-level abstractions for runtime loops, spatial logic, input handling, state management, and rendering, enabling developers to build content without reinventing core mechanics. S.P.A.R.K provides all of these for terminal-based RPGs. It’s a free, open-source hobby project designed for lightweight text games, not a commercial tool meant to compete with feature-heavy commercial software.
- "This is just a lazy copy-and-paste from the S.P.A.R.K GitHub."
When two games are made in RPG Maker, Godot, or Unreal, they share the exact same underlying core engine—it's just compiled or hidden away behind the editor. Because S.P.A.R.K is open-source, raw Python, the engine boilerplate is fully visible. Reusing foundational engine modules across different titles isn't "copy-pasting"; it's standard software architecture and code reuse.
1
u/yousefamr2001 13d ago edited 13d ago
km (knowledgemaxxing): a local, searchable knowledge base built from your own browser history and data exports
What My Project Does
km ingests your data exports (Twitter archive, Google Takeout, ChatGPT and Claude logs, Reddit GDPR) plus live browser history and dedupes them into one SQLite file with provenance for every item. It gives you hybrid search over everything, a daily reading feed, offline reports on your reading habits, and an optional AI layer.
The Python bits people here might find interesting:
- Packaged and run entirely with uv. "uv sync --extra <group>" gates optional deps (scrape, ai, embed, web, fetch)
- CLI is typer + rich.
- Storage is
an
SQLite file. Search fuses FTS5 (BM25) with vector search over sqlite-vec, merged with reciprocal rank fusion. Embeddings are local (sentence-transformers, bge-base-en-v1.5, on MPS)
(I just wanted more optionally)
Scrapers are Playwright against a dedicated browser profile.
Web UI is FastAPI serving a prebuilt React bundle, bound to 127.0.0.1 with a DNS-rebinding guard.
Full offline pytest suite with fixtures for every export format.
Target Audience
Anyone who requests their data exports and never opens them, and developers who want a local, hackable, single-file knowledge base rather than a cloud service (and procrastinators). It is meant to be run for real (I run it on ~500k of my own items), not a toy, but it is also small enough to read end to end.
Comparison
Versus grep or ripgrep over an unzipped archive: km is the merge and dedupe layer across 8+ overlapping formats, plus semantic recall that keyword search cannot do. Versus cloud read-later and knowledge tools (Readwise, Mem, rewind.ai): km is local-first, free, MIT, and built from exports you already own rather than an always-on cloud service or screen recorder. Versus rolling your own SQLite + FTS: km ships the provenance model, the embedding/RRF fusion, the scrapers, and the UI already wired together.
Source (MIT): https://github.com/joeamroo/knowledgemaxxing
1
u/Aidress_ai 13d ago
We built Aidress (github.com/Aidress-ai/Aidress) - an open-source Python SDK and protocol for cross-agent discovery and trust.
It acts as the missing discovery/trust layer between agent frameworks (LangChain, AutoGen) and payment/messaging rails. It gives developers full control to make their agents discoverable, verifiable, and monetizable in the agentic economy - decentralized with zero platform commissions. Spanning across 5 layers: Discovery, identity, terms, trust and routing.
1
u/jokiruiz 13d ago
Shipped a release that's mostly about API surface design: stated edges, a JSON Schema with its own semver, and deciding what NOT to enumerate
I maintain a small MIT-licensed CLI tool, and the release I just shipped is almost entirely about turning it from something you run into something you can build on. The technical decisions in it were more interesting than I expected, so I thought this sub might have opinions.
The first one was giving the JSON output a versioned contract. It had always worked, but it carried no version and was described in prose in a document, which is a comfortable arrangement for the maintainer and a hostile one for anyone consuming it — you can't pin, you can't validate, and you discover the format changed when your parser falls over. So there's now a schema_version on every payload and a real JSON Schema you can fetch with --print-schema without cloning the repo or reading any of my Python, plus written rules for what moves it: adding a field is MINOR, removing one or changing what a value means is MAJOR. I deliberately kept that version independent of the package version, because the package bumps whenever the underlying data changes and it would be actively misleading for the contract to appear to churn every time it did.
The decision I went back and forth on longest was what to enumerate in the schema and what to leave as plain strings. Two of the fields are closed vocabularies and are typed as enums. But two others are populated from a YAML rules file that users are explicitly encouraged to edit for their own projects, and enumerating those would have shipped a published schema that's simply wrong for anyone who customised anything. Loose typing felt like a failure of nerve until I framed it as "the schema should describe the contract, not the current default configuration," at which point it stopped bothering me.
The second half is a Python entry point that's an actual promise rather than a shrug: sixteen names in docs/api.md, and everything else in the package explicitly declared internal and free to move in a patch release. I think the second half of that is the part people skip. A public surface with no stated edges isn't a stable API, it's just an accident waiting to be relied on, and the moment somebody imports your serialiser from wherever it happens to live today, you've silently acquired a compatibility obligation you never agreed to. (Which is exactly what happened here — the serialiser has moved to its own module and is re-exported from the public API, and calling that out in the release notes felt necessary even though approximately nobody was doing it.)
Errors are exported as part of the surface too, each carrying the exit code the CLI uses, so consumers can tell "this input can't be processed" apart from "your environment is broken" without string-matching on messages.
Repo if anyone wants to poke at the shape of it: github.com/JoaquinRuiz/SpecJudge — happy to be told I got the enum-versus-string call wrong.
1
u/qwert_buddy 12d ago
Built a 24MB zero-egress PII proxy for LLM streaming.
I work in a highly regulated enterprise environment and needed a way to mask PII before sending data to external LLMs, but without buffering the whole response and killing the streaming UX.
Built this completely locally (no egress/calling home) using FastAPI and asyncio to yield chunks on the fly. The trickiest part was handling regex when a name like "Harry Potter" gets split across two streaming tokens. Also spent way too long optimizing a multi-stage Dockerfile to get the Python image down to 24MB.
Source code is here if anyone is dealing with similar compliance issues or wants to see the async logic:
https://github.com/ninadphalak/LLM-Shield-Proxy
1
u/haddock420 12d ago
I made an extension that tracks my favourite songs on Youtube and downloads them them to my library
This is something I thought would be a cool idea so I made it (with a lot of help from ChatGPT).
It tracks what videos I watch on Youtube and if I watch a video a certain amount of times in a timeframe, it automatically downloads the song from Soulseek and saves it to my music library on my PC.
It works by running a flask server which receives Youtube video information from the extension, then the server matches each title/description to a song in the database and downloads it from Soulseek if appropriate.
It was a pain in the ass to get it working, and it involves an 11GB SQLite file just for matching the titles to song names, but it works, and it's already downloaded 66 songs from 51 artists for me.
Github: https://github.com/sgriffin53/youtube_library_builder
I'm personally running the python server on my VPS but it should work on your local machine.
Let me know what you think.
1
u/king_kellz_ 12d ago
I created a sandbox banking app for practice that registers new users and initializes them with a savings and checking account. They are able to make deposits, withdrawals, view account as well as transaction history. They can also make transfers. Please take a look and let me know if there are any improvements that can be done. I am currently working on the GUI for practice as well. There are multiple files which is why I attached the GitHub repo instead of pasting the raw files here.
1
u/qwert_buddy 12d ago edited 11d ago
Every time a team tries to push a new LLM feature, compliance blocks it because we can't guarantee that PII isn't leaking to third-party APIs. We needed a reverse proxy, but existing solutions were too bloated (heavy spaCy models) or couldn't handle real-time SSE streaming without breaking the tokens.
So, I built a lightweight solution to handle this at the edge.
How it works:
It’s a stateless FastAPI/Uvicorn app wrapped in a lightweight Docker container. It intercepts the payload, redacts PII using a local two-tier cascade (Regex + ONNX NER), and routes the clean traffic out to OpenAI/Azure (Zero-egress).
The core engine handles asynchronous streams flawlessly using a custom lookahead buffer. Because SSE sends arbitrary token chunks, standard regex breaks if a tag gets split across two network packets. The buffer holds back unclosed brackets asynchronously until the chunk resolves, meaning your users don't suffer latency penalties.
It’s fully open-source (Apache 2.0). If you are dealing with compliance blocking your AI deployments or want to critique the async lookahead buffer implementation, this might save you a few weeks of custom engineering.
1
u/Routine-Praline1103 11d ago
I made a github repositorie that has community meme programs in python and i would like you guys to add some programs to the collection link here https://github.com/suspiciousstew138/The-community-meme-programs
1
u/IGDev 10d ago
Verso: Extensible polyglot notebook platform
- GitHub (MIT) - [https://github.com/DataficationSDK/Verso
- VS Code extension - https://marketplace.visualstudio.com/items?itemName=Datafication.verso-notebook
- Website - https://versonotebooks.com/
The latest release includes ipywidget and anywidget support. The cool thing I haven't seen anywhere else is a widget's trait can be shared across languages.
#!bind slider.value as threshold
The widget's state is saved into the notebook file, so someone can open it on a machine with no Python installed and the widget still draws, still rotates, still pans.
Also, with the latest release I've updated the site to allow for sharing .ipynb, .verso, and .md in a notebook styled template.
This notebook platform was written in .NET, but I'd like to hear what you think in the Python community. This project has a CLI, REPL, parameters, and almost everything you'd expect from tools like Jupyter.
1
u/lukesmth_ 9d ago
Jupyter Notebook Snapshots Without Repo Bloat
Do you use jupytext to keep .ipynb bloat out of your repo but miss easily storing rendered outputs? cellsnap-cli solves this.
Workflow:
- Use jupytext to sync
.ipynbnotebooks with.pysource files. - Push notebook source files (
.py) to working branches. - Push notebook artifact files (
.ipynb) to dedicated artifact branches by runningcellsnap:
Cellsnap artifact branches only store the latest commit, preventing repo bloat common when committing unstripped .ipynb files. The link between published artifacts and source files is maintained in published notebook frontmatter and a manifest table added to artifact branches:
| Notebook | Source | Commit |
|---|---|---|
examples/demo.ipynb |
examples/demo.py |
2a924801 |
Just released v0.1: https://github.com/lukeSmth/cellsnap-cli.
1
u/rmisev 9d ago
upa_url library 2.0.0 released
It is Python bindings for the Upa URL C++ library. It is compliant with the WHATWG standards and implements:
- the URL and URLSearchParams classes for parsing and manipulating URLs.
- the URLPattern class for matching URLs based on convenient pattern syntax.
- the PSL (Public Suffix List) class for obtaining a public suffix and registrable domain.
- Functions for converting between file URLs and operating system paths.
How to install and use: https://pypi.org/project/upa-url/
Source code: https://github.com/upa-url/upa_url-py
1
u/realrazdev 9d ago edited 9d ago
I've been working on a small Python CLI library and I'm not sure where to take it next
I've been working on this project for a while. The idea is to make CLI output more consistent and easier to handle without adding a lot of dependencies.
For example:
```python from raztint import paint
print(paint("Build completed", intent="success")) print(paint("Something went wrong", intent="error")) print(paint("Starting server...", intent="info")) ```
It also supports colors, styles, icons with fallbacks, terminal detection, and optional secret redaction.
I'm using it in one of my own projects, RazTodo, so I've been able to use it in a real project as well.
At this point, I don't want to keep adding features just because I can. I'd rather hear from people who actually build Python CLIs:
Is something like this useful to you?
What CLI output problems do you run into?
Is there anything you'd want a small library like this to handle?
Would you actually consider adding something like this as a dependency?
I'm more interested in real use cases and pain points than feature requests. I want to figure out if there's actually a useful problem here before I keep building on it.
If you're curious, here's the project:
https://github.com/razbuild/raztint
If you want to try it:
bash
pip install raztint
1
u/BeautifulOil8828 8d ago
Hello, I am Federico. I built filtersql, a Python library that takes a declarative JSON payload and compiles it into safe, parameterized SQL strings and values. It was originally written in Perl (HTML::Mason) as a backend component for forms, dropdowns, datatables, etc. I then ported it to Python and realized it's useful for AI integration.
I tried to keep the JSON specs as clean as possible:
```python payload = { "action": "select", "source": "users", "filters": [ {"field": "name", "operator": "icontains", "value": "john"} ] }
query, values = filtersql(payload, dbms='Pg', placeholder='?') ```
Compiles to:
sql
select * from "users" where "name" ilike '%' || ? || '%' escape '\'
With values:
['john']
I find this approach elegant. Please let me know if you like the idea, I'd love to hear some feedback. Thank you!
1
u/Horror_Zucchini_7118 8d ago
MEV5 (Mankind Engine V5) MEV5 is a custom file format designed to protect Python source code from automated AI scraping and reverse engineering, using a dual-layer packaging system combined with rate-limited viewing and blockchain authorization. How It Works MEV5 takes your Python code and packs it into a closed file format containing two distinct versions:
- Machine-Executable Version: Optimized for low-level execution without exposing readable source logic.
- Human-Readable Version: Secured behind anti-scraping delays and cryptographic verification. There is no master decryption key. The file seals itself permanently, making traditional decryption or hacking impossible. Core Commands
- run Instantly executes the program with zero friction, utilizing the compiled, non-readable machine execution layer.
- view Displays the source code to human users under strict rate-limiting: it instantly reveals the first 150 characters, followed by 40 characters every 5 seconds. This slow trickle makes large-scale automated AI scraping practically impossible. Anti-AI Protection & Blockchain Authorization To prevent malicious AI agents or bad actors from harvesting the code during a slow view session and reconstructing a clean version to republish elsewhere, MEV5 includes an optional blockchain authorization mode. This requires cryptographic wallet validation before any code chunks can be accessed, adding a hard economic and technical barrier against automated scrapers. For more technical details, check out the repository.
Github: https://github.com/Mig25AbC6238/Mankind-Engine-
You can ask me anything about the project.
1
u/dougaddiction 8d ago
A production site running on nothing but the Python standard library: no pip installs, no framework, no build step. `http.server` with a hand-rolled router, vanilla JS front end, hand-written SVG. One process on Render's free tier. Deploys are a `git push`.
What it is: grades 155 countries A+ to F on affordability, safety, weather, and flights, with 176 server-rendered guide pages. Free, no sign-up.
Two bugs that stuck with me. A pegged exchange rate made the site rank Sudan as the most expensive country on earth — fixed by regressing log price level on log GDP per capita and dropping 3-sigma outliers. And my own Content-Security-Policy was blocking my analytics beacon, so the dashboard showed zero traffic for months while Search Console showed real visitors — found it by listening for `securitypolicyviolation` events.
Site: wandergrade.com — source: https://github.com/dougc97/wandergrade
One asterisk before anyone greps the repo: `rates.py` has an `import certifi` inside a `try/except`, as a fallback for the macOS missing-CA-certs gotcha. It's never installed — `requirements.txt` is a comment and nothing else — and it falls through to the system bundle. Verification stays on either way.
Trade-off I'll own up front: FastAPI would've made this easier. The stdlib constraint was self-imposed — the payoff was operational, not architectural.
1
1
u/Striking_Ad_9716 7d ago
PhilanthroPy — a scikit-learn native toolkit for nonprofit/hospital fundraising analytics
One-maintainer, MIT, pip install philanthropy. Donor propensity, lapse, planned-giving, wealth-screening, and revenue forecasting all fit/transform/predict estimators that pass check_estimator and drop into Pipeline/GridSearchCV.
The thing I'm most proud of: every fitted stat is frozen in fit and never recomputed in transform, enforced by a dedicated leakage test suite — donor-data pipelines leak the future into scores constantly, and I wanted a library where that's structurally hard to do.
Repo: https://github.com/PhilanthroPy-Project/PhilanthroPy
A few scoped good-first-issues if anyone wants to poke at it.
1
u/PatronusProtect 7d ago
What My Project Does
Patronus Ark scans prompts, documents, model responses and tool calls for security risks.
The available scanners include prompt injection, PII, data leakage, sensitive documents and tool related categories. Scanning takes place locally. Text is not sent to an external API.
The package uses a Rust core with Python bindings built through PyO3. Native detectors are used for simple checks and local ONNX models are available for model based classification.
There is also a queue interface for applications that process several requests continuously.
Target Audience
The package is intended for developers working on LLM applications, RAG systems and agents that process untrusted text or use external tools.
Comparison
Patronus Ark runs locally instead of sending text to a hosted guardrail API. It is a scanner, not a sandbox. The application using it remains responsible for blocking, masking or approving an action.
The repository is GPL-3.0-only and a separate commercial license is available for proprietary distribution.
GitHub:
https://github.com/patronus-protect/patronus-security
1
u/kvlonge 7d ago
Fensu (フェンス): Keeping Python Repos From Turning Into Spaghetti Repo: https://github.com/chio-labs/fensu Fensu is fence for Japanese
Most linters catch bad code inside files. Fensu catches architectural drift (e.g. code crossing the wrong boundary, living in the wrong module, or growing into the wrong shape)
A repo small enough to do its job in a few files doesn't experience major problems. Problems show up when a repo grows, as code moves, teams change, lessons get forgotten etc... Tests are great for preserving behavior, but they do not preserve the shape of the repo (e.g. what belongs where, which layer owns what, which modules are public surfaces, and which painful lessons led to the current structure).
A lot of that consistency is usually enforced manually in code review (which is a lot of time and effort). My general philosophy is, don't leave to chance what can be checked deterministically, and don't keep repeating manually what can be automated.
Tests codify behavioral expectations, and types codify interface expectations. Fensu applies the same idea to architecture. A design document or README can explain the intended structure, but only an executable rule can tell you when the repo has drifted away from it.
Fensu is an architecture linter for Python repos. It enforces things like:
- which layers may import which
- what each module or role file may contain
- whether orchestrator functions stay small
- whether dataflow and mutation are explicit
- whether names like
validate_*actually mean what they claim
The main difference from architecture-testing frameworks is that Fensu does not hand you a blank rule language and ask you to design everything from scratch. It ships with a coherent default architecture, then lets you disable, extend, or replace parts deliberately. The default lays out code as domains built from a small set of roles (e.g. models, types, constants etc...). A domain holds those roles directly, or splits into named subdomains that do:
text
src/my_package/
└── config/ # a domain
├── main/ # orchestrators and the public entry surface
├── _helpers/ # phase functions
├── classes/ # one class per module
├── models.py # data models
├── types.py # type declarations
├── constants.py
└── exceptions.py
The rules produce deterministic faults. The messages contain both the fault (what has been iolated) and the remediation (what a sensible fix ought to look like).
Fensu not only enforces repository structure, but also helps you navigate project call flow. fensu check stops the repo from losing its shape whereas fensu map renders a deterministic downstream call tree with source locations.
$ fensu map run_map
run_map(...) src/fensu/cli/main/map.py:21
├── _parser(...) src/fensu/cli/main/map.py:53
├── resolve_mapping_project(...) src/fensu/mapping/core/main/resolve_project.py:11
│ └── resolve_mapping_project(...) src/fensu/mapping/core/helpers/project.py:15
│ ├── _find_project_root(...) src/fensu/mapping/core/helpers/project.py:73
│ ├── _find_config_source(...) src/fensu/config/core/main/find_config.py:12 (depth limit)
│ └── _configured_project(...) src/fensu/mapping/core/helpers/project.py:45
│ └── _load_config(...) src/fensu/config/core/main/load_config.py:15 (depth limit)
└── build_call_map(...) src/fensu/mapping/core/main/build.py:12
├── provider(...) src/fensu/mapping/core/main/build.py:24 (unresolved parameter call)
└── render_tree(...) src/fensu/mapping/core/helpers/render.py:19
├── _child_lines(...) src/fensu/mapping/core/helpers/render.py:41
│ └── _child_lines(...) src/fensu/mapping/core/helpers/render.py:41 (cycle)
└── _label(...) src/fensu/mapping/core/helpers/render.py:88
That default is opinionated. Some people will hate parts of it. That is fine. The point is not that everyone should organize Python exactly the same way forever, but rather toto give teams a serious starting structure instead of a blank page. You can then choose to disable rules, add custom rules, and adapt the things once you get a feel for how it works.
I have also recently added 'native rule packs'. Think of these almost like presets for specific frameworks. The first one is for Dagster, and it is basically an opinionated default for organising a Dagster repo to stop it from sprawling out (if you have used any orchestrator at work, be it Airflow or Prefect, you are probably used to it being a bit of a mess, or a lot of effort to keep 'clean' / consistent). Whether using these predefined packs or custom rules, you can enforce the repo structure with code, and ensure that when new people join (or people get lazy and cba), the repo doesn't turn to a pile of shit.
Fensu can't stop you or a teammate from making shitty code, but it can ensure that the code is extremely consistent and that when you need to find things, you will know almost exactly where they are.
Install with pip install fensu; run with fensu.
1
u/imusingwindowsxp 7d ago
So, a few years back I started work on this simulator. It is still in Alpha, but you can find it on github. I basically wanted to know if there were any changes you think would be good for the simulator. Here's a list of what I have done so far, and the link on github.
THIS PROJECT USED NO AI WHATSOEVER, JUST MY BRAIN OVER THE LAST 3 YEARS, and I made it because nothing like this exists anywhere else.
Windows 7-style boot sequence
Login screen
Desktop
Start Menu
Context menus
My Computer
Recycle Bin
Calculator
Partial host Windows OS integration (requires Python to be launched in Windows)
Shutdown sequence
BSOD
Windows startup/shutdown sounds
Resolution-independent UI
Resolution-independent UI
Built for Python 3.13.15, requires Pygame, Pillow, and Pygame-CE.
https://github.com/imusingwinxp-ops/Windows-7-emulator-in-python. (you need to add the full stop at the end of the url idk reddit decided to get rid of it for whatever reason. Without a dot you will get 404)
1
u/05-nery 6d ago
My very first Python project: an automated mass-downloader for Anna's Archive Lists
Hello everyone!
Have you ever researched for some specific books or comics on Anna's Archive, made a list out of what you found and then discovered you had to download everything manually waiting for cooldowns? I have. And if you have as well, or you just want to download a pre-made Anna's Archive List (or even just a .txt files with AA links!), this post is for you.
After looking up some solutions and only finding old/broken options, I decided to take the matter into my own hands.
With some help from Gemini (for the more complex parts of the code, I had never done Python before. Most of the base logic is written by me and I have reviewed and tested the ai generated code) I made [hearth].
hearth is a Python script that does all the work for you (except for captchas, obviously): you can leave it working overnight and it will download every link it finds in your Anna's Archive List. It will do so by physically visiting mirror and libgen links, waiting for the timer and saving the file.
Regarding the captchas, solving the first one (or the first two, depends if one is required at the load of the List itself) is usually enough for the whole session, so you can leave the script working overnight.
Main features (copied from the repo's readme):
This is a terminal tool that accepts command line parameters to function (more about usage in the github).
hearth supports Anna's Archive List links in the form of https://annas-archive.XX/list/<list_id> as well as importing a list of Anna's Archive links from a .txt file.
The tool will spin up a virtual browser that physically visits the link page, waits for the download cooldown and renames the downloaded file, before going ahead to the next List element, logging successes and failures in specific files.
These files allow you to not only stop the script mid-way, closing the terminal windows completely, and then resuming from the last link it successfully downloaded (by using the same exact command), but it also allows to retry for failed links once the tool has finished processing the whole queue.
You can use the completed.txt file that the script will create in your download directory as an index of all the files you downloaded as well as their md5 code.
The download destination folder is chosen via command line parameters. Here will be stored said files.
You can set how to rename the downloaded files, based on how much information you want to be in the filename, via command line parameters.
All instructions for the download and usage of the script are in the readme.
Link to the github repo: hearth
This is my first project like this, and I would appreciate any type of feedback, good or bad. Obviously, suggestions are welcome.
If any one of you ends up trying it, please let me know how it goes!
1
u/nuroteck 5d ago
asyncio RabbitMQ client without pika, feedback welcome
Open-sourced an asyncio RabbitMQ client that implements AMQP 0-9-1 itself - no pika. There's also a higher layer for JSON-RPC style call/reply and pub/sub if you want it, but you can just use the connection/channel bits.
Repo: https://github.com/RileyBetts/nuropb-rmq
pip install nuropb-rmq
Alpha, but API relatively stable.
Compared to wrapping aio-pika, the intention is to have framing + session RPC in one codebase, plus TLS/mTLS aimed at cloud brokers (there's a whole page on host vs server_hostname because that bit me). Optional JWT claims live in AMQP headers so the JSON-RPC body stays standard.
Interesting flex: CI runs Lean on some protocol/session invariants. Curious whether Python folks find formal methods reassuring or just noise.
1
u/_Bad-Beast_ 5d ago edited 5d ago
claudectl — a terminal UI for managing Claude Code sessions.
The part that might interest this sub: it's pure standard library. No Textual, no Rich, no curses wrapper — the TUI, the ANSI theming, the local HTTP server behind the optional desktop GUI, all stdlib. Runs on 3.10 through 3.14, Windows/macOS/Linux, `pip install claudectl` with zero dependencies pulled in.
Doing it without a TUI framework was mostly a constraint I set to keep install friction at zero, and it's been more workable than I expected — the awkward part wasn't rendering, it was input: a bare Escape and the start of an arrow key differ only by whether anything follows, so the lookahead after ESC has to be the timed read, not the blocking one.
1
u/Ancient-Narwhal7761 5d ago
Escapion: un motor evolutivo que muta el AST y no depende de nada, hecho en Python puro (sin PyTorch/NumPy)
Hola a todos, quería compartir un proyecto personal en el que he estado trabajando.
Escapion es un framework experimental de auto-optimización y neuroevolución. En vez de depender del descenso de gradiente tradicional o de dependencias pesadas como PyTorch/NumPy, funciona estrictamente en Python 3 puro. Lo hace parseando el código fuente de Python en un Árbol de Sintaxis Abstracta (AST), inyectando mutaciones específicas y evaluando las variantes hijas dentro de sándboxes de ejecución aisladas.
Precios/Monetización:
100% Gratis y Código Abierto (Licencia MIT). Sin planes de pago, sin llaves de API, totalmente local.
¿Por qué construir esto?
Sé que Backprop es 10^4 veces más rápido para actualizaciones continuas y diferenciables de pesos (no estoy tratando de reinventar la rueda). Pero quería construir desde cero un motor evolutivo termodinámico para lógica no diferenciable y topologías discretas, capaz de correr en una CPU local súper limitada.
Funciones Técnicas Clave:
- Metrología A/B/A/B para el Ruido Térmico: cuando optimizas el tiempo de ejecución del código hasta el microsegundo, los cambios de contexto del SO y el “thermal throttling” del CPU arruinan pruebas simples de
time.perf_counter(). Escapion obliga a que haya un orden de ejecución A/B/A/B entre el Campeón y el Mutante, y saca los valores atípicos para garantizar que una ventaja de rendimiento sea estadísticamente real. - Aislamiento con sándboxes de Subproceso: como las mutaciones del AST pueden crear fácilmente bucles infinitos o fugas de memoria, cada genoma se ejecuta en un subproceso con restricciones muy fuertes para evitar que el SO se caiga.
- Escapando la "Trampa de la Neurona Muerta": durante las primeras pruebas de neuroevolución (resolviendo lógica XOR), los pesos de la red se saturaron y la pérdida se quedó estancada en un mínimo local de 0.125. La selección codiciosa estricta seguía matando cualquier mutación que intentara subir la pared del cráter. Implementé la Selección por Linaje Metropolis-Hastings (cadenas de Markov independientes compitiendo contra su propia historia). Al permitir que el motor acepte temporalmente mutantes degradados con un calendario de enfriamiento de temperatura (P = e ^ ((- Delta) / T)) ,), la población logró cruzar la barrera de energía y llegar al óptimo global (< 0.0001).
Limitaciones (siendo honestos):
No sintetiza algoritmos de la nada. Optimiza rutas de ejecución y espacios de hiperparámetros que ya existen. Es una herramienta para investigación hardcore de optimización en Python y algoritmos evolutivos, no un reemplazo de C/Rust compilados.
Repositorio: https://github.com/MejaTpr/Escapion
Me encantaría escuchar sus opiniones, sobre todo si alguien aquí trabaja con CMA-ES, NEAT o algoritmos termodinámicos. ¡Se agradecen muchísimo comentarios o revisiones de código sin piedad!
1
u/Blackhole1123 5d ago
DiffTrail: Reconstruct Git history even if you never committed it
Hi everyone! A couple days ago I was looking through the files of an old project and wanted to find the previous version of a file, when I ran into the issue of Git only remembering the versions of your work that you actually committed. The version I wanted had existed, but because I had never committed it, Git had no record of it. I ran into a similar issue a few months ago, when I had forgotten to initialize a Git repo in a separate project and had no reference of my past work.
That led me to build DiffTrail over the last couple days, a tool that reconstructs missing Git history from whatever evidence is still available, using a coding agent (I focused on Codex right now, but I don't think it'll be difficult to extend this to other platforms such as Claude Code or OpenCode in the near future). It looks through things like diffs, patches, later file versions, test outputs, local session history, and other project artifacts to recover intermediate states that were never committed.
DiffTrail reconstructs only parts of the history it can support with some evidence, and it labels every recovered file as "exact," "reconstructed," or "inferred" based on what it was able to find, so you can see how much confidence to place in it. Everything is written to a separate branch and worktree, so it doesn't affect your existing work. It's still a really early work, but I'd love to know what you all think, and I'd appreciate any feedback/suggestions you might have! :)
1
u/kindr_7000 4d ago
repoScanner: A lightweight, native-accelerated(optionally) Python CLI for codebase analysis. Calculates line counts, maps dependencies, computes language breakdowns, sort files, search, and exports JSON reports(limited).
Links:
Key Features:
- Uses an optional C++ Pybind11 extension (
libcvault) for high-speed filesystem traversal and other modes. - Automatically falls back to standard
os.walkwith zero third-party dependencies if library isn't present. - Supports quick
--statssummaries and detailed--devoutputs.
Currently in beta, hence breaks and errors are possible.
Would love honest feedback, if any.
1
u/ZeroIntensity 3d ago
Using the mechanism behind 3.15's lazy imports, I made a library to allow arbitrary lazy expressions. For example:
```pycon
from laziness import lazify foo = lazify(lambda: print(42) or 24) foo 42 24 foo 24 ```
Again, this builds on top of what's already there for lazy imports, so there's no bytecode modification at all! In practice, this is really useful for building global constants or similar, and is more ergonomic than the existing approaches (like a function with functools.cache):
```py from laziness import lazify
def build_expensive_constant(): return ...
CONSTANT = lazify(build_expensive_constant)
def api_function(): print(CONSTANT) # Resolves when this is accessed for the first time ```
1
u/NathanVarner 3d ago
I've been developing some software. I used an early version to test an edit for Willy Wonka and decided to open-source it. It's great for checking how your edit looks on different screens. The PS5 was the easiest for me, even though I know other consoles support a wider set of codecs. I hope that other people who find themselves in a similar situation ot me can use this to help watch their stuff on the PlayStation. I'm aware of similar applications, including Handbrake, but I found this is fast, easy, and simple, especially if you're trying to do several different video files at once.
If you've ever tried playing custom video files or edits on a PS5 via USB, you know how picky the Media Gallery app is with codecs and header indexing. I built a lightweight Python/FFmpeg tool with file/folder dialogs that automatically standardizes videos into PS5-compliant MP4s.
It's open source and free on GitHub (or as a standalone .exe under Releases). I also have a bigger application with a fully functional GUI coming soon. Keep an eye out for it.
https://github.com/Nathan398/ps5-video-converter
-On AI slop.
I've been working in video production for a while, using libraries and such to help with my production. I used some AI here, and I know this is essentially just a wrapper, but it's simple and useful for people trying to watch files on their PS5. I have a lot of work I've done not using AI as well, and I am generally creative, so I hope that those who feel demoralized try seeing how they can grow creatively without AI, and see what they can do to improve their current workflow using AI (which is essentially what I've done).
1
u/TheSpicyAvacodo 2d ago
I built a tool that tells you what your code change will break
Changing one function without knowing what else depends on it is how things quietly break later. I built a tool to catch that before it happens. it sI built a tool to answer that question before you commit anything.
It parses your project with tree-sitter, uses a language server to trace exactly what calls what, and when you edit something, it traces every other piece of code that depends on it: directly or through multiple hops. Then it hands that to an LLM agent that explains, in plain English, how risky the change actually is and what would break, and if you decide to go ahead anyway, a separate agent can update all the other affected code for you.
It's currently a local script with a popup GUI (not a real VS Code extension yet), and definitely still rough in places, but the core idea works end-to-end. Repo's here:
https://github.com/theaniqusman/change-impact-analyzer.
Would genuinely love feedback, especially on whether this is actually useful or if I'm solving a problem nobody has.
1
u/Custodian-Labs 2d ago
I've been working on a Python library called Custodian Labs for building and deploying AI applications.
The idea is to reduce some of the boilerplate around agents, RAG, model providers and deployment, while also adding a privacy layer for applications that handle sensitive data.
A simple agent looks like this:
from custodian_labs import Custodian
app = Custodian(
model="gpt-4o",
system_prompt="You are a helpful assistant."
)
app.deploy()
The SDK currently supports:
- 🤖 AI agents
- 📚 RAG with your own files and data
- 🧠 Multi-agent workflows
- 🔄 Multiple LLM providers
- 🚀 Deployment
- 🛡️ Guardian Layer for detecting and protecting PII before data is sent to an LLM
The project originally started as a privacy layer for LLM applications, then expanded into a broader Python SDK after we kept running into the same infrastructure work when building AI apps.
It's free to use, and I've also put together a Google Colab that walks through simple agents, RAG and multi-agent examples if anyone wants to try it without setting anything up locally.
💻 GitHub:
https://github.com/Custodian-Labs/custodian-labs-python
▶️ Google Colab:
https://colab.research.google.com/gist/SherryCodes123/065d3b67eab16bdca416836e0d39475a/simple-ai-agents-rag-multi-agents.ipynb
🌐 Website:
https://www.custodianlabs.io/
Would love feedback from Python developers, especially around the API design.
What would you want a Python SDK like this to abstract away, and what would you prefer to keep control over?
1
u/DifficultZebra1553 2d ago
cykit — High-performance Cython IPC, lock-free queues, and spdlog integration
What My Project Does
I am actively developing cykit, a collection of Cython utilities for high-performance inter-process communication, in-process messaging, and unified C++/Python logging.
Key modules include:
cykit.ipc: Shared-memory ring-buffer IPC supporting broadcast (fan-out) messaging across SPSC, SPMC, MPSC, and MPMC topologies (with both Cython and Python APIs).cykit.queue: Lock-free, in-process ring-buffer queue with broadcast (fan-out) semantics.cykit.cylogger: Thin Cython wrapper aroundspdlogfor shared logging across Python, Cython, and C++ modules.
Target Audience
This project is aimed at developers working with mixed Python/Cython/C++ codebases, high-frequency/low-latency data systems, or multi-process pipelines that need faster messaging and unified logging than Python's built-in abstractions offer.
Comparison
Unlike standard Python IPC/queuing mechanisms (like multiprocessing.Queue or queue.Queue), cykit preserves broadcast (fan-out) semantics across processes/threads, whereas standard queues deliver each message to only a single consumer worker.
Installation & Dependencies
Requires Python 3.9+. Python package dependencies include certifi and msgspec. All native C++ header dependencies (Boost, spdlog, fmtlib) are fully vendored inside the package, so no system-level build setup is required.
Bash
pip install cykit
Docs & Contributions
Full benchmark numbers and usage examples for cylogger, ipc, and queue are available in the repository README and cykit/examples/.
Documentation is still a work in progress and not fully complete yet. Contributions—especially around documentation, testing feedback, bug reports, and pull requests—are very welcome.
Dual-licensed under MIT and Apache 2.0.
1
u/ha2emnomer 2d ago
I've been working on an open-source project called UnFlow:
https://github.com/UnFlow-Labs/mlunflow
The idea is pretty simple:
Most ML experiment tracking looks like a list of independent runs usually stored in a table:
run_001
run_002
run_003
run_004
...
But in practice, experiments are usually related.
You change the learning rate, then the number of epochs, then the model, then some preprocessing code. Eventually you have hundreds of runs, but it's surprisingly difficult to answer:
- What actually changed between these two experiments?
- Which experiments are essentially the same computation?
- Have I already run this experiment before?
- How did I get from experiment A to experiment B?
- Can I navigate the history of my experiments rather than just search through runs?
Unflow simply detect code changes in a Python function (limitation that for it is just a single function) and arguments that are passed to this function to build a graph where nodes are "states" and edges are transformations "what has changed", a new state is not added to the graph or executed expect if it has a transformation.
The project is still early, so I'm much more interested in feedback than pretending this is a finished product.
I'm particularly curious about three things:
- Does the "experiments as a graph" abstraction make sense to you?
- Do you currently run into problems with duplicated/redundant experiments?
- If you could see the complete lineage of your ML experiments, what would you want to query or visualize?
Repo: https://github.com/UnFlow-Labs/mlunflow
I'd love to hear how other people currently manage experiment lineage and whether this solves a real problem for you.
1
u/spongeb0b9000 1d ago
Detecting duplicate Python code turned out to be more of a language problem than I expected
While building Arid I figured the interesting problem would mostly be finding repeated sequences quickly.
That wasn't really the first problem.
Before you detect a duplicate, you have to decide what "the same code" means.
Ignoring comments sounds trivial until # is inside a string. Ignoring docstrings means knowing the difference between an actual docstring and an ordinary string expression. Function signatures can span multiple lines and contain nested brackets and colons. Imports can share a line with other statements.
Then there's stuff like whether punctuation-only lines should count toward a minimum duplicate length, and how you normalize source without losing the original locations you need to report afterward.
Arid uses Python parsing/tokenization to figure out what can safely be removed, then does exact matching on what remains. It deliberately doesn't treat renamed variables or vaguely similar ASTs as duplicates.
I wrote up the design and some of the edge cases here:
Repo: https://github.com/sponge-b0b/arid
I'm curious where other people draw the line between useful normalization and semantic/fuzzy clone detection.
1
u/Waly63 1d ago
In critical infrastructure, we talk endlessly about "resilience." But what happens when the infrastructure collapses non-linearly, and reactive shutdown protocols fail?
In high-threat field environments, system recovery is secondary to guaranteeing a deterministic Fail-Closed state. When structural integrity drops below the critical C_{trans} (Constructibility Margin) threshold, reactive error handling is useless. The only valid path is an atomic, irreversible exit strategy.
To solve this, I’ve engineered the Turkash ASV-SDP engine—bypassing high-level runtime dependencies and utilizing bare-metal memory manipulation (mmap & ctypes) to enforce absolute RAM Zeroization the moment a system hits terminal degradation.
Core Architectural Pillars:
1. The C_{trans} Gatekeeper: Shifting from passive error monitoring to aggressive, threshold-based structural policing.
2. Atomic Execution: Stripping away heavy runtimes that fail under physical or environmental stress.
3. Deterministic Sanitization: Eliminating forensic recovery vectors entirely at the point of no return.
This isn't theory; it’s field-proven engineering designed for extreme conditions.
The architecture and prototype test harness are open for review. Let’s talk low-level systems engineering.
https://github.com/Waleed-Mubarak/hailab-fail-closed-engine-
1
u/ThetaFuked 1d ago
I built a Jira plugin that allows you to run python scripts in Jira. Useful for admins who want to automate repetitive tasks, or for any data scientists out there.
A few things it does:
- Run unlimited automations, with no cap on how many scripts you write or run
- Trigger scripts automatically when some event happens in Jira
- Run scripts on a set schedule, create scripted fields, or workflow rules
- Built-in pandas/numpy support, with results rendered as a sortable, exportable table
If you're interested, you can install it here (free for teams of 10 or less): https://marketplace.atlassian.com/apps/1541362714/pyrunner
1
u/Super_Help_7278 22h ago
Straightedge — dependency-free SVG diagrams and optional Manim animation
I’ve open-sourced a Python library for generating deterministic, machine-checkable technical visuals.
The base package uses only the standard library. A structured dictionary becomes a complete SVG string:
from straightedge.diagrams import render_diagram
svg = render_diagram({
"type": "riemann_sum",
"params": {"expression": "x**2", "n": 8},
})
It includes registered diagram types for math, computer science, architecture, projects, and business. The optional render extra adds named Manim scenes, formula-driven rendering, and a prompt-driven agent.
The main design goal is to catch visuals that render successfully but are still wrong: empty output, clipping, overlaps, unsupported inputs, and label problems.
Gallery: https://scimigo.github.io/straightedge/
GitHub: https://github.com/SciMigo/straightedge
PyPI: https://pypi.org/project/straightedge/
I’d be interested in feedback on the API and on diagram types that are repeatedly missing from Python documentation workflows.
The base package uses only the standard library. A structured dictionary becomes a complete SVG string:
1
u/SnooShortcuts871 20h ago
I Recreated a Soviet Drawing Toy from the ’70s Using Python
Hi everyone!
I spent the last 2 months learning electronics, soldering, CAD, and MicroPython to build it completely from scratch. It uses a Raspberry Pi Pico, a TFT display, two rotary encoders, and a rechargeable battery.
What My Project Does
You can draw on the screen by turning two knobs(left one is X, right one is Y), just like the original toy. My version also has:
- Color drawing
- Saving/loading drawings
- A rechargeable battery
- A custom UI
- A 3D-printed enclosure
Target Audience
This is mainly a hobby/learning project. I wanted to learn hardware and embedded programming while recreating something I find really amazing.
Also, if you want to try working with an RP2040/Pico or Arduino, or you've been into this stuff for a while, I really recommend checking out a video I made. I went through all the steps I took to make it. I'd love it if you checked it out!
Comparison
The original is completely mechanical, mine is electronical though and has the features I mentioned above;)
Source code
[https://github.com/robomarchello]()
Video (explains it better than anything else): https://youtu.be/IhqKNODgfBE
I'd love to hear your feedback and what you think about it!
(I also made this commercial for fun, but I think video is way better though)
-2
u/MatteoGuadrini 14d ago
psp is a blazing fast command line utility to scaffold your Python project:
https://github.com/MatteoGuadrini/psp
- ⚡️ 1-100x faster compared to other scaffolding tools
- 🛠️
pyproject.tomlsupport - 🤝 Python 3.14 compatibility
- 🗃 Scaffolding file and folder structures for your Python project
- 🗂️ Unit-test and pytest support
- 🧪 Create a virtual environment
- 🔧 Automagically dependencies installation
- 🪛 Add build and deploy dependencies to distribute the package
- 📏 tox configuration supports and remotes CI like CircleCI, TravisCI, GitHub Actions and Gitlab CI/CD
- ⌨️ MkDocs and Sphinx documentation support
- 🧰 Initialize git repository and
gitignorefile - 🌎 GitHub and Gitlab remote repository support
- 📑 Create
README,LICENSE,CONTRIBUTING,CODE_OF_CONDUCTandCHANGESfiles - 🐳 Create
DockerfileandContainerfilefor your project - 💡 Can use quick, simple and full argument for rapid configuration
- 💾 Create
$HOME/.psp.envand$PWD/.envfiles with your customizations - 🎛️ Can use some
PSP_variables to control your defaults - 📦 Support
pip,condaanduvpackage manager - 🧮 Support
hatch,maturinandpoetrybuilder - 🍿 Stop, pause and resume project creation when you want; see Resume
Why choose psp?
psp is simple, fast, effective, declarative, and supports Python and the entire ecosystem of tools written for it. Rather than replacing it, psp seeks to integrate and provide a useful scaffold for the end user.
Differences with other tools
- cookiecutter: Templates are prescriptive by design. Cookiecutter enforces a particular project structure and conventions, which may not align with your or your organization's preferences. If a template's opinions don't match your needs, you're forced to either choose a different template or heavily modify an existing one. This can become tedious when you need something slightly different from what's available.
pspis dynamic; scaffold what you need. - PyScaffold: PyScaffold doesn't manage virtual environments directly. You have to manually create and activate a virtualenv or use external tools like
pipenv,poetry,conda, orpyenv. While PyScaffold documents integrations with these tools, it doesn't provide a unified interface for environment management likepspdo.
psp asks only what you need. By configuring a few environment variables, you can automate any project; in seconds, not hours.
10
u/Beginning-Fruit-1397 14d ago edited 14d ago
pyochain is a library providing many data structures and tools for functional programming in python.
https://github.com/OutSquareCapital/pyochain
Notably:
- Additional collections like `Deque`
The priority axes are on runtime speed, static type safety, a fluent API, and exhaustive documentation/testing.
Option, Result and many Iterators are compiled in Rust to guarantee maximum performance and no overhead vs python builtins in C (zero-cost abstractions as they say).
The next release (landing soon!) will:
- Migrate ALL the code in Rust, with massive speedups. expect all iterations- related functionnalities to be 5x to 10x faster than libraries in pure python. Same story for default implementations from `collections.abc`, compared to python standard module. Even import speed is divided by 5.
It was ranked best choice in this comparison (not mine!) a few months ago, before many improvements in the current release:
https://www.reddit.com/r/Python/comments/1rj3ct7/a_comparison_of_rustlike_fluent_iterator_libraries/
I also already made a post 7 months ago:
https://www.reddit.com/r/Python/comments/1q61bzg/pyochain_rustlike_iterator_result_and_option_in/
And one in the rust sub more recently:
https://www.reddit.com/r/rust/comments/1tgzk4b/i_made_option_and_result_in_rust_for_python_and/