zeta: Send up diagnostics with prediction requests (#24384)

This PR makes it so we send up the diagnostic groups as additional data
with the edit prediction request.

We're not yet making use of them, but we are recording them so we can
use them later (e.g., to train the model).

Release Notes:

- N/A

---------

Co-authored-by: Nathan <nathan@zed.dev>
This commit is contained in:
Marshall Bowers
2025-02-06 18:07:26 +00:00
committed by GitHub
co-authored by Nathan
parent 13089d7ec6
commit 09967ac3d0
16 changed files with 145 additions and 31 deletions
+13
View File
@@ -166,6 +166,19 @@ pub struct LocalLspStore {
}
impl LocalLspStore {
/// Returns the running language server for the given ID. Note if the language server is starting, it will not be returned.
pub fn running_language_server_for_id(
&self,
id: LanguageServerId,
) -> Option<&Arc<LanguageServer>> {
let language_server_state = self.language_servers.get(&id)?;
match language_server_state {
LanguageServerState::Running { server, .. } => Some(server),
LanguageServerState::Starting(_) => None,
}
}
fn start_language_server(
&mut self,
worktree_handle: &Entity<Worktree>,