feat(ui,api): strip board redesign - island, rail by day, context view, server search, vault graph
This commit is contained in:
@@ -3,6 +3,7 @@ import type {
|
||||
AgentsResponse,
|
||||
AuditPage,
|
||||
BusEvent,
|
||||
ContextResponse,
|
||||
ConversationInfo,
|
||||
ConversationSummary,
|
||||
EntriesPage,
|
||||
@@ -11,10 +12,12 @@ import type {
|
||||
LimitsResponse,
|
||||
MemoryFile,
|
||||
MemoryTree,
|
||||
SearchResponse,
|
||||
SessionsResponse,
|
||||
TokenRow,
|
||||
UsageGroup,
|
||||
UsageResponse,
|
||||
VaultGraph,
|
||||
} from "./types";
|
||||
|
||||
const TRAILING_SLASHES = /\/+$/;
|
||||
@@ -182,6 +185,23 @@ export class ApiClient {
|
||||
return this.get(`/api/conversations/${id}/history`);
|
||||
}
|
||||
|
||||
context(id: string, prompt = false): Promise<ContextResponse> {
|
||||
return this.get(`/api/conversations/${id}/context`, {
|
||||
prompt: prompt ? 1 : undefined,
|
||||
});
|
||||
}
|
||||
|
||||
vaultGraph(paths: string[], limit?: number): Promise<VaultGraph> {
|
||||
const search = new URLSearchParams();
|
||||
for (const path of paths) {
|
||||
search.append("path", path);
|
||||
}
|
||||
if (limit) {
|
||||
search.set("limit", String(limit));
|
||||
}
|
||||
return this.get(`/api/vault/graph?${search.toString()}`);
|
||||
}
|
||||
|
||||
entries(
|
||||
id: string,
|
||||
params?: { subpath?: string; offset?: number; limit?: number }
|
||||
@@ -283,6 +303,10 @@ export class ApiClient {
|
||||
return this.post("/api/conversations", body);
|
||||
}
|
||||
|
||||
search(q: string, limit?: number): Promise<SearchResponse> {
|
||||
return this.get("/api/search", { limit, q });
|
||||
}
|
||||
|
||||
sessions(): Promise<SessionsResponse> {
|
||||
return this.get("/api/sessions");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user