Foundry-Local icon indicating copy to clipboard operation
Foundry-Local copied to clipboard

Token counts from chat completions

Open natke opened this issue 6 months ago • 2 comments

Discussed in https://github.com/microsoft/Foundry-Local/discussions/45

Originally posted by Justinius May 8, 2025 Has anyone been able to get the token counts back from a completion? I'm following the example and getting a response but the usage field is always null for me.

Any thoughts or ideas?

AB#66026

natke avatar Jun 20 '25 23:06 natke

Duplicate of #115

samuel100 avatar Jun 23 '25 21:06 samuel100

I am also wondering if it is possible to get the token usage returned from Foundry Local. Both VS Code AI toolkit and the Windows AI Dev Gallery app return the token usage stats if you run a foundry model in them, but I cannot find any way to get it outside of those Microsoft apps.

addisokw avatar Oct 07 '25 18:10 addisokw