Posts

#python #pdf #rag

LiteParse: Fast, Structured PDF Data Extraction with Python

If you build AI pipelines that read PDFs, you already know the dilemma: some parsers are fast but lose structure, while others preserve quality but increase latency.

LiteParse is an open-source parser from the LlamaIndex ecosystem designed for speed + useful structure in local workflows.

Why LiteParse matters for RAG

In RAG, extraction quality is not just about extracting text. It is about preserving signals that improve retrieval and reasoning:

Ler mais
#aws #s3 #cloud

AWS S3 Files: Mount Your Bucket as a File System and Lower Your Costs

If you’ve ever had to maintain a separate EFS just to give your EC2 or Lambda instances file-system-style access to data that already lives in S3, you know how frustrating that duplication is. You pay twice, sync manually, and still deal with eventual consistency headaches.

AWS just shipped a fix for that: S3 Files.

What Is S3 Files?

S3 Files is a new AWS service that makes S3 buckets accessible as native file systems using NFS v4.1+. Instead of treating your bucket as a key-value store accessed via s3:// URLs, you mount it like a regular directory and use normal POSIX operations: ls, cp, cat, echo >, anything.

Ler mais
#python #pep #d-strings

Python D-Strings: The End of Multiline String Mess

If you have ever needed to write a multiline string inside a function or class in Python, you know things get awkward fast.

PEP 822 proposes d-strings (short for dedent) for Python 3.15 — a new syntax that automatically strips indentation from multiline strings. That is the whole idea.

The problem they solve

Say you need to build a text block inside a function:

1
2
3
4
5
6
7
def generate_email(name: str) -> str:
    return textwrap.dedent(f"""\
        Hello, {name}!

        Your registration has been confirmed.
        Thanks for signing up.
    """)

The options we have today are all awkward:

Ler mais
#python #uv #package-manager

UV: Stop Suffering with Python Dependencies

If you still use pip + venv + pip-tools (or Poetry) and feel your Python workflow has become too heavy, it is time to look at uv.

uv is a tool from Astral (the same company behind Ruff) for:

  • managing dependencies
  • creating and syncing virtual environments
  • pinning versions with a lockfile
  • running scripts and commands in isolation
  • managing Python projects with a modern developer experience

The promise is straightforward: be dramatically faster without sacrificing reproducibility.

Ler mais
#ai #llm #prompt-engineering

Caveman Skill: How to Reduce Tokens (and Costs) in AI Agents

If you’ve ever automated tasks with LLMs in production, you know exactly where it hurts: responses that are too long for simple tasks.

In many engineering routines, you don’t need three paragraphs of pleasantries to find out if there’s a bug in a function. You need:

  • quick diagnosis;
  • minimal context;
  • recommended action.

That’s the problem that Caveman solves very well.

What Is Caveman?

Caveman is a skill/plugin for AI agents (like Claude Code and Copilot) that forces an extremely direct response style — less fluff, fewer tokens.

Ler mais
#python #alembic #sqlmodel

Alembic and SQLModel: Database Migrations in Python

If you’ve worked with databases in Python, you’ve probably felt the pain of managing schema changes. Add a column here, modify a type there, create an index somewhere else… and suddenly you no longer know what the actual state of your database is. Even worse: how do you ensure all environments (development, staging, production) are in sync?

The combination of SQLModel and Alembic solves this problem elegantly, bringing type safety with Pydantic, the robustness of SQLAlchemy, and version control for your database migrations. In this article, you’ll learn how to configure and use these two powerful tools together.

Ler mais
#ai #llm #gemma

Gemma 4: AI in Your Pocket — LLMs Finally Running Natively on Smartphones

Imagine having a language model with capabilities comparable to GPT-4 running natively on your smartphone, without depending on the internet, paid APIs, or cloud servers. Sounds like science fiction? Not anymore. Last week, Google did something that no other FANG company had the courage to do: it released Gemma 4, a truly free LLM under the Apache 2.0 license. And the most impressive part? It’s incredibly small — small enough to run on your phone or Raspberry Pi, but with intelligence comparable to models that normally require datacenter GPUs.

Ler mais
#dagster #python #data-engineering

Dagster: Thinking About Data as Assets

If you work in data engineering, you’ve probably grown tired of thinking about pipelines as a sequence of tasks: Extract → Transform → Load. But what if I told you that’s not the best way to model your data? Dagster revolutionized how we think about data orchestration with a simple yet powerful concept: Software-Defined Assets.

The Problem with Traditional ETL

In the traditional ETL model, we think in terms of processes:

Ler mais
#python #mcp #ai

FastMCP: Create MCP Servers in Minutes, Not Hours

Have you ever tried to create an MCP server and found yourself drowning in dozens of config files, complex boilerplate, and hours of debugging before getting your first tool working? Developing and testing MCP servers needs to be fast — agile iteration is critical when experimenting with AI agents. That’s exactly where FastMCP comes in.

The Problem: MCP Complexity Kills Velocity

Even with AI-generated code (vibe coding), implementing MCP from scratch means understanding dozens of concepts before testing your first tool:

Ler mais
#ai #llm #prompting

Prompt Engineering: Techniques Every Developer Should Know

If you’re developing with AI in 2026 and still haven’t mastered prompting techniques, you’re leaving 70% of LLM capability on the table. I’m not exaggerating — the difference between a well-structured prompt and a generic one can be the difference between a mediocre response and a production-level solution.

After working on various projects involving LLMs, I’ve noticed that most developers underestimate the power of a good prompt. Let’s change that today.

Ler mais
#programming #education

CS50: The Best Programming Course That Exists

If there is one course that completely changed how I think about programming, it’s CS50: Introduction to Computer Science from Harvard. And the best part? It’s completely free.

After taking dozens of paid courses throughout my career, I can say with full certainty: CS50 is better than 99% of paid courses I’ve seen out there. And when I talk about Brazilian courses, none of them come close.

What Makes CS50 So Special?

CS50 is not just another programming course. It’s a complete learning experience that teaches you not just how to program, but how to think like a computer scientist.

Ler mais
#ai #development #vibe-coding

Vibe Coding: The Danger of Blindly Relying on AI to Code

It’s 2am. Your phone vibrates with that specific pattern you configured for production alerts. In a decade of on-call duty, you’ve learned that nothing good happens at 2am. The alert message confirms your fears: unusual network traffic, suspicious IP addresses. The new AI-generated payment processing code, deployed just hours earlier, is failing spectacularly.

This is the real (though fictional) story documented in the article “No Vibe Coding While I’m On Call”, which exposes the dangers of a trend sweeping the tech industry: vibe coding.

Ler mais
#python #security #supply-chain

Protecting Your Python Projects Against Supply Chain Attacks

If you follow security news in Python, you’ve probably heard about the recent attacks that compromised several popular libraries on PyPI. Legitimate packages were hijacked, malicious versions were published, and developers around the world installed compromised code without even realizing it.

The scariest part? This can happen to any of us, at any time.

What’s Happening?

In recent months, we’ve seen an alarming increase in “supply chain” attacks in the Python ecosystem:

Ler mais
#postgresql #database #data-engineering

Stop Overcomplicating: PostgreSQL Is All You Need in 2026

Think of your database like your house. Your house has a living room, bedroom, bathroom, kitchen, and garage. Each room serves a different purpose. But they’re all under the same roof, connected by hallways and doors. You don’t build a separate restaurant just because you need to cook. You don’t build a commercial garage across town just to park your car.

That’s what PostgreSQL is. A house with many rooms. Full-text search, vectors, time series, queues — all under the same roof.

Ler mais
#duckdb #data-engineering #analytics

You Don't Need a Data Warehouse: DuckDB Is Enough

Let me guess: you have data in CSV or Parquet in S3, or maybe in a local folder. And someone in your company has already suggested that you need a “modern data warehouse” like Snowflake or BigQuery. After all, “we need to scale,” “we need performance,” “we need an enterprise solution.”

And with that comes: VPC configuration, credential management, IAM policies, cost control, query optimization, table partitioning, and a bill that can easily reach thousands of dollars per month.

Ler mais
#python #ai #apis

MCP Brasil: Connecting AI to 41 Brazilian Public APIs

Imagine being able to ask an AI agent “What were the 10 largest federal government contracts in 2024?” or “What is the trend of the Selic rate over the last 12 months?” and receive precise answers based on official Brazilian government data. This is now possible with MCP Brasil, an open-source project that connects AI agents like Claude, GPT, and GitHub Copilot to 41 Brazilian public APIs.

What is MCP Brasil?

MCP Brasil is a MCP Server (Model Context Protocol) that offers structured access to Brazilian government data through 326 tools, covering 11 thematic areas:

Ler mais
#python #llm #ai

Generating Texts with References Using LLMs

Text generation with large language models (LLMs) has revolutionized how we create content. However, one of the biggest challenges is ensuring that the generated information is verifiable and reliable. In this article, I’ll show a universal technique for generating any type of structured content with verifiable references, combining advanced search (Tavily) with LLMs. I’ll use biographies as a practical example, but the technique applies to reports, articles, analyses, and any other fact-based content.

Ler mais
#python #dagster #data

Dask, Dagster, and Coiled for Production Data Processing at OnlineApp

In this article I’ll show a simple integration between Dagster and Dask+Coiled. We’ll discuss how this turned a common problem — processing a large set of files monthly — into a really easy task.

The User and the Problem

Hi 👋, my name is Lucas, I’m the leader of the data science and data engineering team at OnlineApp, a B2B company serving the Brazilian market.

Every month, the Brazilian government publishes a large set of CSV files with information about Brazilian companies, which we use to better understand our market. We have many internal services that want to read this data, but before that’s possible, we need to preprocess it a bit:

Ler mais
#ai

Artificial Intelligence and the End of Cyberbullying: The TikTok Bubble Effect

Artificial intelligence (AI) permeates almost every aspect of modern life, from voice recognition and language translation systems to online product recommendation algorithms and social media content.

With the advancement of AI, social networks have become much more personalized and isolated platforms, where each user’s experience is shaped by their own interests and behaviors. A clear example of this is TikTok, which uses AI to create this individualized “bubble” for each user.

Ler mais
#blog

Why I Refused a PhD Opportunity at a Federal University

Like every undergraduate student in Brazil, I was always encouraged to dream of pursuing an academic career. After all, that’s one of the most “respected” paths in our country: everyone wants to be called “Dr.” — a field where, in many areas, the title is sometimes valued more than practical experience.

However, recently, I refused a PhD proposal at one of the largest federal universities in the country and decided to take a different path. And honestly, I’m glad I made that decision.

Ler mais
#python #dbt #database

Goodbye DBT: How to Orchestrate Your Database with Dagster Assets

Managing table and view schemas in databases with traceability (version control) and reliability is a problem that many tools have tried to solve over the years. In the world of software development, the most common approach today is to use some kind of ORM (Object-Relational Mapping), which maps data structures in your code (usually classes) to tables in the database.

Some famous examples are: Entity Framework in C#, SQLAlchemy in Python, and Prisma in Node.js.

Ler mais
#ai

DAN: The New and Most Dangerous Security Vulnerability in ChatGPT

One of the main concerns of the company behind ChatGPT, OpenAI, and perhaps the biggest concern among companies developing “chatbot” tools, is the responses generated by their models — ensuring their reliability and impartiality. Unfortunately, due to the nature of how the model was built, this type of moderation is extremely difficult to implement, according to the creators themselves:

“Although we have made efforts to make the model refuse inappropriate requests, sometimes it responds to harmful instructions or exhibits biased behavior. We are using a moderation API to warn or block certain types of unsafe content, but we expect there to be some false negatives and positives for now. We look forward to collecting user feedback to help our ongoing work to improve this system.” - OpenAI

Ler mais
#python #data

Great Expectations: Validate Your Data Quality with Expectations

Everyone knows that ensuring and validating data quality is still an extremely laborious task in most cases, and that’s the problem Great Expectations aims to solve. Today we’ll talk about this incredible data quality tool.

Introduction

The “Great Expectations” library: built in Python, is a powerful tool for data validation. It allows you to define expectations about what your data should look like and then verify that those expectations are met. This serves to ensure data quality before proceeding with analysis or modeling.

Ler mais
#python #ai

Analyzing Facial Microexpressions in Python

You’ve probably heard of facial microexpressions — the idea is that from them we can extract valuable information about how a person is thinking, feeling, and what they plan to do.

Recent innovations in computer vision and deep learning algorithms have led to a flood of models that can be used to extract facial landmarks, action units, and facial microexpressions with speed and precision.

Today we’ll explore one of these solutions in Python.

Ler mais
#python #dagster #coiled

This Will Be the End of Spark! Dask & Coiled — The Easiest Way to Create Clusters in Python

I was recently working on the architecture of a new data pipeline project, everything was going well, until the worst nightmare of every data engineer working with Pandas happened: my dataset was simply too large to fit in memory (it contained about 100 GB).

The solution to this type of problem is already well known in the data world (and appropriate for my context): clustering! But a question arose…

image

Ler mais
#python #ai #data

5 Books Every Data Scientist Should Read

Have you ever struggled to choose good books related to the data universe? Have you been disappointed by a book whose content seemed copied from Wikipedia? Well, I have!

That’s why, after many nights of disappointing reads and dozens of frustrating purchases, I decided to put together this top 5 with the best books I’ve ever read that, in my opinion, are the best in the data field.

1 - Hands-On Machine Learning with Scikit-Learn, Keras & TensorFlow

image

Ler mais
#python #api #data

How to Validate and Handle JSON in Python

We’ve all had to deal with JSON data at least once, whether using an API or reading directly from a file. And as a consequence, I believe most of us have encountered errors related to data quality or formatting in it.

In this article I’ll share two approaches I like to use when working with this type of data in Python.

For our tests we’ll use the PokéAPI.

image

Consider that we have the following function below.

Ler mais
#data #ai #dashboard

How to Do an Exploratory Analysis on a Product Sales Dataset

We’ve all felt a little lost when we have to analyze product sales data. In this article I’ll show some techniques I like to use when I encounter this type of analysis.

Understand Your Data

The most important thing for any type of data analysis is understanding the context: what the data represents and what each column or field means. In a perfect hypothetical world, this information will be provided to you by some stakeholder (interested party, or client).

Ler mais
#management

Scrum Makes No Sense for Data Scientists

I know the title is provocative, but I believe it’s necessary to foster discussion — and it also summarizes the central idea of this article quite well: Scrum makes no sense for data scientists, and you shouldn’t force them to use it.

“Scrum is a lightweight framework that helps people, teams, and organizations generate value through adaptive solutions for complex problems.” - Scrum Guide

Is Scrum bad?

That’s a good question. In my opinion, based on my experience: I don’t believe it’s a bad agile methodology, but I also don’t believe it’s perfect, nor the silver bullet for all organization and management problems in IT, as its community tends to sell it. I also have my reservations about its efficiency in large projects where some ceremonies end up causing more harm than good.

Ler mais
#sql #database #data

ClickHouse: The Fastest Database in the World You Probably Don't Know

Dealing with problems analyzing large volumes of data is no novelty for anyone today. But many people don’t know that solutions already exist for this problem. One of them is the ClickHouse database. In this article we’ll look at the two main categories of existing databases and also go deeper into how ClickHouse works.

As mentioned earlier, today there are two major classifications for databases:

OLTP

Online Transaction Processing.

image

Ler mais
#docker #python #git

Goodbye Airflow, Hello Dagster

On August 9, 2022, Dagster finally announced the release of its version 1.0, indicating that the orchestrator is finally production-ready. But what is Dagster? According to them:

“Build and deploy data pipelines with extraordinary speed. The cloud-native orchestrator for the entire development lifecycle, with built-in lineage and observability, a declarative programming model, and best-in-class testability.”

Sounds promising. Let’s run some tests with a simple example. Say we have the following pipeline:

Ler mais