This repository was archived by the owner on Sep 30, 2024. It is now read-only.
[Backport 5.1] cody-gateway, sourcegraph: disable code completions for OpenAI (#55624)#55689
Merged
Conversation
Using OpenAI for Cody code completions is currently [untested and unsupported](https://sourcegraph.slack.com/archives/CN4FC7XT4/p1690986792111129?thread_ts=1690931810.610299&cid=CN4FC7XT4). Despite this, we have [at least one customer generating very large numbers of OpenAI code completions requests](https://sourcegraph.slack.com/archives/C03JR7S7KRP/p1691438665847449?thread_ts=1689373762.522179&cid=C03JR7S7KRP) - enough to get us [rate limited by OpenAI](https://sourcegraph.sentry.io/issues/4372449189/?alert_rule_id=14416305&alert_type=issue&project=4505201451270144). This change: - Makes Cody Gateway reject OpenAI code completions requests (responding with 501 not implemented) - Prevents Sourcegraph from generating OpenAI code completion requests CI --------- Co-authored-by: Erik Seliger <erikseliger@me.com> (cherry picked from commit 151f43f)
michaellzc
approved these changes
Aug 9, 2023
eseliger
approved these changes
Aug 9, 2023
Contributor
bobheadxi
referenced
this pull request
Aug 9, 2023
Just backported this: https://github.com/sourcegraph/sourcegraph/pull/55689 ## Test plan n/a
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #55624, created manually
Using OpenAI for Cody code completions is currently untested and unsupported. Despite this, we have at least one customer generating very large numbers of OpenAI code completions
requests
This change:
CI
Co-authored-by: Erik Seliger erikseliger@me.com
(cherry picked from commit 151f43f)
Test plan