規劃你的工具

使用 Claude Code 進行軟體開發

Dani Zysman

AI Curriculum Manager @ DataCamp

從 API 到 CLI

兩種工具、同一份資料:Web API vs CLI 報表器

使用 Claude Code 進行軟體開發

Music Analytics Reporter

python reporter.py --artist "AC/DC" --format json --output report.json

recraft: half: 開發者在白板上勾勒含資料庫與檔案輸出的 CLI 工具架構

使用 Claude Code 進行軟體開發

為何選 CLI?

recraft: CLI 工具連接自動化、管線、指令稿與測試

  • 可指令化:自動化重複工作
  • 可組合:可與其他工具串接
  • 可併入管線:支援 CI/CD 系統
使用 Claude Code 進行軟體開發

規劃:事前 vs 事後

流程圖:Init → Explore → Plan → Code

使用 Claude Code 進行軟體開發

規劃工作階段

> /plan
> think about designing reporter.py: artist statistics from Chinook 
(albums, tracks, duration, revenue), exported as JSON or CSV
Plan: reporter.py CLI Tool

Arguments: --artist, --format (json/csv), --output
Data: Query Chinook for albums, tracks, duration, revenue
Validation: Check artist exists before querying
Errors: Handle DB connection failures, missing artists
Output: Write to file or stdout if no --output given
Exit codes: 0 = success, 1 = error
Tests: test_reporter.py covering core functions and edge cases
使用 Claude Code 進行軟體開發

Claude 的規格書

========================================
MUSIC ANALYTICS REPORTER - SPECIFICATION
========================================
Arguments:    --artist, --format, --output
Validation:   Check artist exists before query
Errors:       Handle DB connection, file permissions
Formats:      JSON (default), CSV
Exit codes:   0 = success, 1 = error

「Plan 模式 + 延伸思考 = 清晰藍圖」

使用 Claude Code 進行軟體開發

技能匯聚

excalidraw: 技能從第 1 章到第 4 章的進展

使用 Claude Code 進行軟體開發

一起來練習吧!

使用 Claude Code 進行軟體開發

Preparing Video For Download...