Skip to content

Commit f4e2190

Browse files
committed
agent: history and recent conversations per workspace
1 parent deacd3e commit f4e2190

File tree

10 files changed

+396
-85
lines changed

10 files changed

+396
-85
lines changed

Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/agent/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ util.workspace = true
7171
uuid.workspace = true
7272
watch.workspace = true
7373
web_search.workspace = true
74+
workspace.workspace = true
7475
zed_env_vars.workspace = true
7576
zstd.workspace = true
7677

crates/agent/src/agent.rs

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1269,7 +1269,8 @@ mod internal_tests {
12691269
let project = Project::test(fs.clone(), [], cx).await;
12701270
let text_thread_store =
12711271
cx.new(|cx| assistant_text_thread::TextThreadStore::fake(project.clone(), cx));
1272-
let history_store = cx.new(|cx| HistoryStore::new(text_thread_store, cx));
1272+
let history_store =
1273+
cx.new(|cx| HistoryStore::new(text_thread_store, HistoryScope::global(), cx));
12731274
let agent = NativeAgent::new(
12741275
project.clone(),
12751276
history_store,
@@ -1331,7 +1332,8 @@ mod internal_tests {
13311332
let project = Project::test(fs.clone(), [], cx).await;
13321333
let text_thread_store =
13331334
cx.new(|cx| assistant_text_thread::TextThreadStore::fake(project.clone(), cx));
1334-
let history_store = cx.new(|cx| HistoryStore::new(text_thread_store, cx));
1335+
let history_store =
1336+
cx.new(|cx| HistoryStore::new(text_thread_store, HistoryScope::global(), cx));
13351337
let connection = NativeAgentConnection(
13361338
NativeAgent::new(
13371339
project.clone(),
@@ -1407,7 +1409,8 @@ mod internal_tests {
14071409

14081410
let text_thread_store =
14091411
cx.new(|cx| assistant_text_thread::TextThreadStore::fake(project.clone(), cx));
1410-
let history_store = cx.new(|cx| HistoryStore::new(text_thread_store, cx));
1412+
let history_store =
1413+
cx.new(|cx| HistoryStore::new(text_thread_store, HistoryScope::global(), cx));
14111414

14121415
// Create the agent and connection
14131416
let agent = NativeAgent::new(
@@ -1480,7 +1483,8 @@ mod internal_tests {
14801483
let project = Project::test(fs.clone(), [path!("/a").as_ref()], cx).await;
14811484
let text_thread_store =
14821485
cx.new(|cx| assistant_text_thread::TextThreadStore::fake(project.clone(), cx));
1483-
let history_store = cx.new(|cx| HistoryStore::new(text_thread_store, cx));
1486+
let history_store =
1487+
cx.new(|cx| HistoryStore::new(text_thread_store, HistoryScope::global(), cx));
14841488
let agent = NativeAgent::new(
14851489
project.clone(),
14861490
history_store.clone(),

0 commit comments

Comments
 (0)