Revert summarizing file content until we can be more intelligent about what we send
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
parent
66af1707a1
commit
5cf92980f0
2 changed files with 23 additions and 8 deletions
|
@ -578,10 +578,7 @@ impl AssistantPanel {
|
|||
|
||||
let codegen_kind = codegen.read(cx).kind().clone();
|
||||
let user_prompt = user_prompt.to_string();
|
||||
let prompt = cx.background().spawn(async move {
|
||||
let language_name = language_name.as_deref();
|
||||
generate_content_prompt(user_prompt, language_name, &buffer, range, codegen_kind)
|
||||
});
|
||||
|
||||
let mut messages = Vec::new();
|
||||
let mut model = settings::get::<AssistantSettings>(cx)
|
||||
.default_open_ai_model
|
||||
|
@ -597,6 +594,11 @@ impl AssistantPanel {
|
|||
model = conversation.model.clone();
|
||||
}
|
||||
|
||||
let prompt = cx.background().spawn(async move {
|
||||
let language_name = language_name.as_deref();
|
||||
generate_content_prompt(user_prompt, language_name, &buffer, range, codegen_kind)
|
||||
});
|
||||
|
||||
cx.spawn(|_, mut cx| async move {
|
||||
let prompt = prompt.await;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue