diff options
| author | Bryan Morgan <[email protected]> | 2025-06-23 23:37:07 -0400 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-06-23 23:37:07 -0400 |
| commit | f7caca5f941c7ab1f4c25f2d117b2217703e7d79 (patch) | |
| tree | 9b2321a194861e32d9aa83f53f053083c6034a0d /docs/cli/token-caching.md | |
| parent | 0abd2a644e947b7794dd68615d5d3d1553b0b5fd (diff) | |
Updated README.md (#1367)
Diffstat (limited to 'docs/cli/token-caching.md')
| -rw-r--r-- | docs/cli/token-caching.md | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/docs/cli/token-caching.md b/docs/cli/token-caching.md new file mode 100644 index 00000000..17e103e1 --- /dev/null +++ b/docs/cli/token-caching.md @@ -0,0 +1,14 @@ +# Token Caching and Cost Optimization + +Gemini CLI automatically optimizes API costs through token caching when using API key authentication (Gemini API key or Vertex AI). This feature reuses previous system instructions and context to reduce the number of tokens processed in subsequent requests. + +**Token caching is available for:** + +- API key users (Gemini API key) +- Vertex AI users (with project and location setup) + +**Token caching is not available for:** + +- OAuth users (Google Personal/Enterprise accounts) - the Code Assist API does not support cached content creation at this time + +You can view your token usage and cached token savings using the `/stats` command. When cached tokens are available, they will be displayed in the stats output. |
