sourcegraph / cody

Type less, code more: Cody is an AI code assistant that uses advanced search and codebase context to help you write and fix code.
https://cody.dev
Apache License 2.0
2.3k stars 219 forks source link

Autocomplete: add `x-cody-resolved-model` to completion events #4565

Closed valerybugakov closed 1 month ago

valerybugakov commented 1 month ago

Since we have the streaming cancellation propagation issue, we can not rely on the Cody Gateway per model latencies to understand the E2E performance. To clarify the exact model used for every completion, we can use the x-cody-resolved-model header and add this information to client-side logs.

Test plan

Updated unit tests. To verify manually: