Stay in this wizard while you implement
Use the eight build steps when you know the current stage and want the next concrete prompt, checks, and project targets.
Open the build stepsModule 04
Vibe coding with Codex
This module turns Codex practice into a real product build. You will use Flask for the backend, HTMX as the primary frontend library, SortableJS for drag-and-drop, and SQLite for persistence. The page is structured like a wizard so you can move from scaffold to ship without guessing the next prompt.
Reference split
The wizard tells you what to build next. The reference page tells you how to use Codex, prompts, and commands around each step without losing control.
Use the eight build steps when you know the current stage and want the next concrete prompt, checks, and project targets.
Open the build stepsUse the companion reference when you need prompt usage rules, CLI commands, slash commands, and a cleaner operating checklist.
参考分工
这个向导负责告诉你下一步该构建什么。参考页负责告诉你在每一步周围应该怎样使用 Codex、提示词和命令,而不是一路失控地乱改。
当你已经知道当前处在第几步,并且需要下一条具体提示词、验证点和项目目标时,就直接用这八步向导。
打开构建步骤当你需要提示词用法、CLI 命令、slash 命令,以及更清晰的操作清单时,去配套参考页。
MVP scope
Do not add auth, real-time sync, or a SPA build step in version one. The goal is a clean local product with crisp CRUD flows and persistent drag-and-drop.
One board page with default lanes such as Backlog, In Progress, and Done.
Create lanes, create tasks, edit tasks, and delete tasks without leaving the board.
Every lane and task keeps a stable position value in SQLite so reloads are reliable.
Users can reorder tasks in a lane and move tasks across lanes with minimal client JS.
Seed data, setup instructions, and a few tests make the project reusable after the first build.
MVP 范围
第一版不要加登录、实时同步,也不要引入 SPA 构建链。目标是一个本地就能顺畅运行的产品, 拥有清晰的 CRUD 流程和可持久化的拖拽排序。
先做一个主板页面,默认包含 Backlog、In Progress、Done 这样的基础列。
允许在看板内直接创建列、创建任务、编辑任务和删除任务,不需要跳页。
每个 lane 与 task 都要在 SQLite 中保存稳定的 position 值,刷新后顺序不乱。
用户可以在同列内重排任务,也可以跨列拖动,而且前端 JS 要尽量少。
补上种子数据、运行说明和少量测试,让项目在第一次构建之后还能继续复用。
Stack choice
For a Flask-first product, the best primary frontend library here is HTMX: it keeps the app server-rendered, removes the need for a frontend build pipeline, and stays easy for Codex to iterate on. SortableJS is the small specialist piece for drag and drop.
Use Flask for routing, Jinja templates, simple CLI commands, and a tiny operational surface.
HTMX handles fragment updates cleanly. SortableJS handles the one thing HTMX should not fake: drag-and-drop ordering.
SQLite is enough for a single-user or local MVP, keeps setup friction low, and is perfect for early Codex-driven reps.
技术栈选择
对一个 Flask 主导的产品来说,这里的最佳主前端库是 HTMX:它能保持应用以服务端渲染为主, 省掉前端构建流水线,也更容易让 Codex 逐步迭代。至于拖拽排序,则交给小而专用的 SortableJS。
用 Flask 负责路由、Jinja 模板、简单 CLI 命令和尽量小的运行面。
HTMX 负责优雅的局部更新;SortableJS 则专门处理 HTMX 不该硬凑的拖拽排序行为。
对单用户或本地 MVP 来说,SQLite 足够、低门槛,而且很适合前期用 Codex 快速迭代。
Wizard
Each step gives you a goal, concrete verification points, and a copy-ready prompt for Codex. Do not jump ahead until the current step actually runs.
Choose a build step
Step 01
Start by forcing structure. A calm project tree is worth more than a fancy first feature.
What this step should produce
What to verify
Codex prompt
In this empty repo, scaffold an MVP kanban todo app using Flask, HTMX as the primary frontend library, SortableJS for drag-and-drop, and SQLite for persistence. Create a simple structure with app.py, db.py, schema.sql, templates/, static/, instance/, and requirements.txt. Keep the stack minimal, no React or frontend build step. First give me a short plan, then implement the skeleton and a placeholder board page that runs locally.
向导
每一步都给你目标、验证点,以及可以直接复制给 Codex 的提示词。当前一步没有真正跑通前,不要急着跳到下一步。
选择构建步骤
步骤 01
第一件事是强迫结构清晰。一个冷静的项目树,比花哨的第一个功能更值钱。
这一阶段要产出什么
这一阶段要验证什么
Codex 提示词
在这个空仓库里,帮我脚手架一个 MVP 级别的 kanban todo 应用:后端用 Flask,主前端库用 HTMX,拖拽用 SortableJS,持久化用 SQLite。请建立 app.py、db.py、schema.sql、templates/、static/、instance/ 和 requirements.txt 这样的简洁结构。保持栈最小,不要引入 React 或前端构建链。先给我一个短计划,再完成脚手架,并做出一个本地能跑的看板占位页。
Project map
The tighter your file map and route contract are, the less thrash you will get during the build.
app.py
db.py
schema.sql
requirements.txt
templates/
base.html
board.html
partials/
lane.html
task_card.html
task_form.html
static/
board.css
board.js
instance/
kanban.sqlite3
lanes( id, name, position, created_at ) tasks( id, lane_id, title, description, priority, due_date, position, created_at, updated_at ) GET / POST /lanes POST /tasks POST /tasks/<id>/edit POST /tasks/<id>/delete POST /tasks/reorder
项目蓝图
文件地图和路由契约越清楚,构建过程中的来回返工就越少。
app.py
db.py
schema.sql
requirements.txt
templates/
base.html
board.html
partials/
lane.html
task_card.html
task_form.html
static/
board.css
board.js
instance/
kanban.sqlite3
lanes( id, name, position, created_at ) tasks( id, lane_id, title, description, priority, due_date, position, created_at, updated_at ) GET / POST /lanes POST /tasks POST /tasks/<id>/edit POST /tasks/<id>/delete POST /tasks/reorder
Ship checks
Act as a senior full-stack engineer reviewing this Flask + HTMX + SQLite kanban app. Tighten the templates, remove duplication, make sure the SortableJS reorder logic is resilient, and keep the stack minimal. After changes, run the highest-value checks you can and summarize any remaining risks or tradeoffs.
python -m venv .venv source .venv/bin/activate pip install -r requirements.txt flask --app app init-db flask --app app seed-demo flask --app app run --debug pytest
交付检查
请以资深全栈工程师的视角 review 这个 Flask + HTMX + SQLite 的 kanban 应用。收紧模板结构,移除重复,确保 SortableJS 的 reorder 逻辑足够稳健,同时保持技术栈最小。完成修改后,运行你认为最高价值的检查,并总结剩余风险或取舍。
python -m venv .venv source .venv/bin/activate pip install -r requirements.txt flask --app app init-db flask --app app seed-demo flask --app app run --debug pytest
Module close
Once the Kanban app works, replay the same wizard logic on another CRUD product and keep improving your Codex prompts from evidence.
Back to the homepage模块收尾
当这个 Kanban 应用跑通后,再把同样的向导逻辑套到另一个 CRUD 产品上,并根据证据继续迭代你的 Codex 提示词。
回到首页