---
title: "Claude Code best practices"
answer: "Coolhand ingests Claude Code sessions from the transcripts saved on disk, not by intercepting API calls in real time. Latency and temperature are never present because the transcript format does not record them; prompts, responses, token counts, and tool use are all captured once a session ends."
category: "Coding agents"
tags: ["claude-code","coding-agents"]
published: 2026-08-30T13:57:53Z
updated: 2026-08-30T13:57:53Z
canonical_url: https://coolhandlabs.com/help/claude-code-best-practices
index_url: https://coolhandlabs.com/help.md
---

# Claude Code best practices

Coolhand ingests Claude Code sessions from the transcripts saved on disk, not by intercepting API calls in real time. Latency and temperature are never present because the transcript format does not record them; prompts, responses, token counts, and tool use are all captured once a session ends.

---

## Logs come from session transcripts, not live API interception

Claude Code saves session transcripts locally. Coolhand ingests these after the fact — not in real time. As a result, latency and temperature are never available (they are not captured in the transcript format).

---

## Unique fields not present in other providers

**Background Agent** — set to `true` when every user turn in the session contains only tool results (no human-typed text). Indicates the session was driven by an automated agent rather than a person. Background-agent sessions are excluded from Claude Code expertise scoring.

**User Turn Count** — the number of turns where a human typed something (tool-result-only turns are not counted). A value of `1` means the whole session ran on a single prompt. Useful for tracking how much human guidance a task requires over time.

---

## Caching

Cache metadata is captured from the session transcript. Both **Cached Input Tokens** and **Cache Creation Tokens** are populated when the transcript includes them. Prompt caching is particularly effective in Claude Code sessions because the accumulated context (conversation history, tool definitions) is large and stable across turns within a session.

---

## Structured outputs

Not applicable — Claude Code logs are session transcripts, not direct API calls you configure.

---

## Reasoning tokens

Not separated from output tokens — same behavior as [Anthropic Best Practices](https://coolhandlabs.com/help/anthropic-api-best-practices.md). Thinking content appears in the **Thinking Response** field when present, but the token count is rolled into the regular output token count.

---

## Latency

Always blank. Session transcripts do not include per-turn timing information.


---

Related:
- [Claude Cowork best practices](https://coolhandlabs.com/help/claude-cowork-best-practices.md)
- [GitHub Copilot best practices](https://coolhandlabs.com/help/github-copilot-best-practices.md)
- [Prompt engineering best practices](https://coolhandlabs.com/help/prompt-engineering-best-practices.md)
- [Anthropic API best practices](https://coolhandlabs.com/help/anthropic-api-best-practices.md)

[← All help articles](https://coolhandlabs.com/help.md) · [Coding agents](https://coolhandlabs.com/help/category/coding-agents.md)
