microsoft / microsoft/TypeChat
Get API-Information on usage etc
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 8.7k
- Forks
- 414
- Avg merge
- 3h 8m
- Merged PRs (30d)
- 3
Description
From my understanding you currently only get the answer and a success flag back.
For me it would be quite interesting to also get information on tokens used etc (which OpenAI provides for example).
Is there a way to get that information out or does this need modification in the code? Would be happy to support, just need a little guidance on where to start.
This is the information on usage you get back when using the openAI-API
"usage":{
"prompt_tokens":13,
"completion_tokens":7,
"total_tokens":20
},
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file, test, or entry point is named. Start by tracing how provider responses are handled and whether usage metadata is currently discarded. Done means exposing token counts or equivalent usage information alongside the answer and success flag, with coverage for the OpenAI-style usage object.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- ai, api
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100