Recent Posts all posts

Python's os.environ vs os.getenv

posted in Python
Environment variables are key-value pairs that exist in the operating system's environment and can be accessed by programs running on that system. They are a way to configure applications without hardcoding values directly into the source code. Python provides several ways to work with environment variables through the os module. Two common methods are os.environ and os.getenv. While they might seem similar, they have different use cases and behaviors. Let's explore the differences and when to use each method effectively.

Trigonometric Identities the Euler Way

posted in Mathematics
I have always believed that mathematics is about thinking rather than memorizing. The trigonometric identities were among the things we were told to memorize at school, and not only I struggled with that but I also actively rebelled against this approach. For me, mathematics is fundamentally about having a minimal but sufficient set of definitions and axioms, understanding them deeply, and then deriving everything else from these foundations. During one of my Complex Analysis lectures in my undergraduate Applied Mathematics studies, I was introduced to Euler's formula. When I discovered how it could be used to derive some of the most important trigonometric identities, I was more than relieved. I could finally derive the identities easily whenever I needed them, instead of relying on rote memorization, or panicking about my failure to memorize them.

NanoNets OCR for Handwritten Notes

posted in Machine Learning
Nanonets has released Nanonets-OCR-s, a state-of-the-art small 3B image-to-markdown OCR model that goes far beyond traditional text extraction. The model is available on Hugging Face and integrated with their docext tool for immediate use. Medium post can be found here.

A Job Postings Tool: A Guide to MLX-LM Server and Tool Use with the OpenAI Client

posted in Machine Learning
Building intelligent applications that can interact with real-world data requires more than just Large Language Models (LLMs), it requires the ability to call external functions and tools. Tool calling transforms a conversational LLM into an agent that can execute code, query APIs, and perform tasks. In this blog post, we are going to create a job search assistant using the MLX-LM Server, connect it to the OpenAI client , and utilise the Qwen3-8B model’s tool‐calling abilities. We are going to build a tool that scrapes job postings from DEV.BG, a popular Bulgarian job board, and provides intelligent responses about available positions.

Thinking Backwards: The "Reversal Blessing" in LLM Multiple-Choice Reasoning

posted in Machine Learning
Most modern languages are written from left to right, thus we assume that thinking from left to right is the most natural way to process information expressed with these languages. This is particularly true for Large Language Models (LLMs) which are typically trained to predict the next word in a sequence, known as left-to-right (L2R) language models. But what if, for certain tasks, thinking backward could actually be better?