You
Small service, limited time. Which one first?
ChatGPT
Logs with structure, because they answer "what happened" for incidents you did not anticipate. Metrics come next for the handful of numbers you would page on. Traces are worth it once a request crosses more than two services.
Tool steps: 3 (reasoning summary, call to python, execution output)
reasoning summary
Checked the query plan, then compared index options.
call to python
rows = run_sql("EXPLAIN (ANALYZE) SELECT ...")
print(rows[:3])execution output
Seq Scan on events (cost=0.00..812431.00 rows=41203122 width=16)
Rows Removed by Filter: 38996878
Planning Time: 0.214 ms
Execution Time: 11842.663 ms