# CostState

> **Class** in `deepagents_code`

📖 [View in docs](https://reference.langchain.com/python/deepagents-code/cost_tracking/CostState)

Agent state extended with the cumulative thread-cost channel.

## Signature

```python
CostState()
```

## Extends

- `ResumeState`

---

[View source on GitHub](https://github.com/langchain-ai/deepagents/blob/e4c1ffe9ee63d7854147de490ca27495ef157a7b/libs/code/deepagents_code/cost_tracking.py#L2762)