惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园 - Franky
有赞技术团队
有赞技术团队
宝玉的分享
宝玉的分享
雷峰网
雷峰网
Hugging Face - Blog
Hugging Face - Blog
V
V2EX
大猫的无限游戏
大猫的无限游戏
博客园 - 司徒正美
D
Docker
T
The Blog of Author Tim Ferriss
罗磊的独立博客
博客园 - 叶小钗
酷 壳 – CoolShell
酷 壳 – CoolShell
Blog — PlanetScale
Blog — PlanetScale
月光博客
月光博客
J
Java Code Geeks
Jina AI
Jina AI
博客园 - 【当耐特】
C
Check Point Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
腾讯CDC
Last Week in AI
Last Week in AI
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
V
Visual Studio Blog

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
From AI Code Generation to AI System Investigation
Jonathan Mil · 2026-05-23 · via DEV Community

I Released AI DB Investigator - A Skill for Structured Database Analysis

AI is very good at generating answers.

But when it comes to database problems, raw answers are not enough.

A slow query, a missing index, a suspicious schema, a broken relation, or an unclear data model usually cannot be solved by guessing. These problems require investigation.

That is why I released AI DB Investigator.

GitHub repo:
https://github.com/miller-28/skill-ai-db-investigator

What is AI DB Investigator?

AI DB Investigator is a skill designed to help AI analyze databases in a more structured way.

Instead of asking an AI model a broad question like:

Why is my database slow?

The goal is to guide the model into a more disciplined investigation flow.

A good database investigation usually requires several steps:

  1. Understand the schema.
  2. Identify important tables and relationships.
  3. Look at indexes.
  4. Inspect query patterns.
  5. Detect possible bottlenecks.
  6. Separate symptoms from root causes.
  7. Suggest safe, practical improvements.

AI DB Investigator is built around that idea.

Not magic.
Not guessing.
A structured investigation process.

Why I built it

I have spent many years working with production systems, especially around backend architecture, PostgreSQL, Redis, APIs, and distributed flows.

One thing becomes clear after enough production experience:

Database problems are rarely isolated.

A performance issue may look like a slow query, but the real cause may be:

  • a missing composite index
  • a bad join pattern
  • an overloaded table
  • unnecessary eager loading
  • poor pagination
  • wrong data modeling
  • missing constraints
  • too much logic happening in the wrong layer
  • data growth that changed the original assumptions

The database does not fail loudly at first.

It whispers.

Then it slows down.

Then it becomes the center of the fire.

So I wanted a skill that helps AI behave less like a random answer generator and more like a careful technical investigator.

The idea behind the skill

The core idea is simple:

AI should not only answer database questions.
It should investigate them.

That means the AI should slow down and ask the right technical questions before jumping to conclusions.

For example:

  • What database engine is being used?
  • What is the schema?
  • Which tables are involved?
  • Is this about performance, correctness, design, migrations, or reliability?
  • Are there indexes?
  • Are there foreign keys?
  • Is the query using OFFSET pagination?
  • Are there N+1 query patterns?
  • Is the data volume small, medium, or already production-scale?
  • Is the issue caused by the database, the application, or both?

This is the difference between generic AI assistance and operational AI assistance.

What this skill is useful for

AI DB Investigator can help with:

  • database schema review
  • PostgreSQL investigation
  • query analysis
  • index suggestions
  • performance bottleneck detection
  • database design review
  • migration reasoning
  • relationship mapping
  • production debugging
  • explaining suspicious DB behavior
  • turning vague DB problems into structured diagnostic steps

It is especially useful when the problem is not yet clearly defined.

Sometimes the real value is not the final answer.

Sometimes the value is forcing the investigation into the right shape.

Why this matters for AI-assisted development

A lot of AI development today focuses on generation:

  • generate code
  • generate tests
  • generate docs
  • generate APIs
  • generate UI

That is useful.

But production work is not only generation.

Production work is also diagnosis.

A senior engineer spends a lot of time asking:

  • What is really happening here?
  • What changed?
  • Where is the pressure?
  • What assumption is now false?
  • What is safe to change?
  • What should not be touched?
  • What is the smallest useful fix?

That mindset is hard to capture with a generic prompt.

A skill gives the AI a repeatable operating pattern.

That is the direction I find interesting: not only using AI to write code faster, but teaching AI how to approach technical systems with discipline.

Small tool, larger direction

This is not meant to be a huge framework.

It is intentionally focused.

The purpose is to encode a specific kind of engineering judgment into a reusable form.

For me, this is part of a larger shift:

Developers are moving from writing every line manually
to designing, directing, and refining intelligent workflows.

The developer becomes less of a typist and more of an orchestrator.

But orchestration only works when the AI has structure.

Without structure, AI improvises.

With structure, AI can investigate.

Repository

The project is available here:

https://github.com/miller-28/skill-ai-db-investigator

Feedback, ideas, issues, and suggestions are welcome.

Especially around:

  • PostgreSQL investigation flows
  • schema analysis
  • query review patterns
  • useful diagnostic prompts
  • real-world DB debugging examples

Final thought

Database work rewards patience.

The best answers usually come after the right questions.

AI DB Investigator is my attempt to give AI a better path through that process.

Not just to answer.

To investigate.