Add logic for closed beta LLM models (#16482)
Release Notes: - N/A --------- Co-authored-by: Marshall <marshall@zed.dev>
This commit is contained in:
parent
41fc6d0885
commit
b5bd8a5c5d
9 changed files with 104 additions and 47 deletions
|
@ -20,6 +20,8 @@ pub struct LlmTokenClaims {
|
|||
#[serde(default)]
|
||||
pub github_user_login: Option<String>,
|
||||
pub is_staff: bool,
|
||||
#[serde(default)]
|
||||
pub has_llm_closed_beta_feature_flag: bool,
|
||||
pub plan: rpc::proto::Plan,
|
||||
}
|
||||
|
||||
|
@ -30,6 +32,7 @@ impl LlmTokenClaims {
|
|||
user_id: UserId,
|
||||
github_user_login: String,
|
||||
is_staff: bool,
|
||||
has_llm_closed_beta_feature_flag: bool,
|
||||
plan: rpc::proto::Plan,
|
||||
config: &Config,
|
||||
) -> Result<String> {
|
||||
|
@ -46,6 +49,7 @@ impl LlmTokenClaims {
|
|||
user_id: user_id.to_proto(),
|
||||
github_user_login: Some(github_user_login),
|
||||
is_staff,
|
||||
has_llm_closed_beta_feature_flag,
|
||||
plan,
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue