Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add context tokens to api response #91

Merged
merged 9 commits into from
Oct 4, 2024
Merged

add context tokens to api response #91

merged 9 commits into from
Oct 4, 2024

Conversation

CornHusker89
Copy link
Contributor

No description provided.

@CornHusker89 CornHusker89 changed the title added context tokens to api response add context tokens to api response Oct 1, 2024
Copy link
Member

@smallketchup82 smallketchup82 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

first pass just looking at the diff. juggle through these for now. i'll test later

galaxygpt/ContextManager.cs Outdated Show resolved Hide resolved
galaxygpt/AiClient.cs Outdated Show resolved Hide resolved
galaxygpt-api/Types/AskQuestion/AskResponse.cs Outdated Show resolved Hide resolved
galaxygpt-api/Program.cs Outdated Show resolved Hide resolved
@smallketchup82
Copy link
Member

smallketchup82 commented Oct 1, 2024

as an added fyi, we can probably skip tokenizing stuff ourselves and can use openai-dotnet

https://github.com/openai/openai-dotnet/blob/main/src/Custom/Chat/ChatTokenUsage.cs

should be available in the return of CompleteChatAsync i think

@smallketchup82
Copy link
Member

looks good to me otherwise

@smallketchup82 smallketchup82 merged commit d107d8c into main Oct 4, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants