Allow /workflow and step resolution prompts to be overridden (#15892)
This will help us as we hit issues with the /workflow and step resolution. We can override the baked-in prompts and make tweaks, then import our refinements back into the source tree when we're ready. Release Notes: - N/A
This commit is contained in:
parent
c8f1358629
commit
990774247e
14 changed files with 196 additions and 104 deletions
|
@ -2,6 +2,7 @@ use crate::{
|
|||
assistant_settings::{AssistantDockPosition, AssistantSettings},
|
||||
humanize_token_count,
|
||||
prompt_library::open_prompt_library,
|
||||
prompts::PromptBuilder,
|
||||
slash_command::{
|
||||
default_command::DefaultSlashCommand,
|
||||
docs_command::{DocsSlashCommand, DocsSlashCommandArgs},
|
||||
|
@ -315,14 +316,17 @@ impl PickerDelegate for SavedContextPickerDelegate {
|
|||
impl AssistantPanel {
|
||||
pub fn load(
|
||||
workspace: WeakView<Workspace>,
|
||||
prompt_builder: Arc<PromptBuilder>,
|
||||
cx: AsyncWindowContext,
|
||||
) -> Task<Result<View<Self>>> {
|
||||
cx.spawn(|mut cx| async move {
|
||||
let context_store = workspace
|
||||
.update(&mut cx, |workspace, cx| {
|
||||
ContextStore::new(workspace.project().clone(), cx)
|
||||
let project = workspace.project().clone();
|
||||
ContextStore::new(project, prompt_builder.clone(), cx)
|
||||
})?
|
||||
.await?;
|
||||
|
||||
workspace.update(&mut cx, |workspace, cx| {
|
||||
// TODO: deserialize state.
|
||||
cx.new_view(|cx| Self::new(workspace, context_store, cx))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue