Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Building KaizenSQL - My Dev Journey

说明与用途

KaizenSQL 是一个基于 Go 的 CLI 工具,使用 Groq LLM 分析 SQL 代码,支持导师、性能和安全三种模式,并通过 Bubbletea 添加动画横幅。

问题

Create a fast, pleasant-to-use CLI tool that analyzes SQL code and provides AI-powered feedback in multiple modes (Mentor, Performance, Security).

结果

KaizenSQL delivers quick, AI-enhanced SQL analysis with a user-friendly CLI interface, supporting mentor guidance, performance insights, and security checks, all while maintaining speed and token limits.

工作流

  • 1. Implemented file/directory reading in Go.
  • 2. Integrated Groq API using Go-OpenAI client.
  • 3. Defined three modes with distinct system prompts.
  • 4. Added command-line flags for mode selection.
  • 5. Handled token limits by setting MaxCompletionTokens.
  • 6. Added animated banner using Bubbletea and Ascii Motion.
  • 7. Tested and iterated on performance and error handling.

证据

KaizenSQL is a CLI tool written in Go, it analyzes SQL code and supports three modes Mentor/Performance/Security.

来源

I chose another LLM provider for this project. That is Groq API, it has a generous limit to use it properly as a sandbox for testing your AI interactions.

来源

I added a Mentor mode, its value is that it does not solve the problem, but guides you a clue so that you can find the answer yourself.

来源

The fix? just to set the limit explicitly, that's ok for this little project's scope

来源

After some googling I found bubbletea (a TUI framework), this awesome open-source solution was the speedtrack I was looking for.

来源

  • 记录日期: 2026-10-11T00:55:53.927Z