Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

chore: improve defaults

Louis Beaumontbf01bffddaf8
diff --git a/screenpipe-app-tauri/components/example-search-cards.tsx b/screenpipe-app-tauri/components/example-search-cards.tsx
index 07c770d7e..a20886715 100644
--- a/screenpipe-app-tauri/components/example-search-cards.tsx
+++ b/screenpipe-app-tauri/components/example-search-cards.tsx
@@ -29,7 +29,7 @@ const exampleSearches: ExampleSearch[] = [
title: "summarize my mails",
contentType: "ocr",
windowName: "gmail",
- limit: 30,
+ limit: 25,
minLength: 50,
startDate: new Date(new Date().setHours(0, 0, 0, 0)), // since midnight local time
},
@@ -47,12 +47,12 @@ export function ExampleSearchCards({ onSelect }: ExampleSearchCardsProps) {
switch (title) {
case "summarize last hour meeting":
return <Search className="mr-2 h-4 w-4" />;
- case "summarize by mail":
+ case "summarize my mails":
return <Mail className="mr-2 h-4 w-4" />;
- case "time spent on apps last hour":
+ case "time spent last hour":
return <Clock className="mr-2 h-4 w-4" />;
default:
- return null;
+ return <Search className="mr-2 h-4 w-4" />; // default icon
}
};
diff --git a/screenpipe-app-tauri/components/search-chat.tsx b/screenpipe-app-tauri/components/search-chat.tsx
index 7191cefeb..2209f5c9d 100644
--- a/screenpipe-app-tauri/components/search-chat.tsx
+++ b/screenpipe-app-tauri/components/search-chat.tsx
@@ -474,13 +474,14 @@ export function SearchChat() {
const handleSearch = async (newOffset = 0, overrides: any = {}) => {
setHasSearched(true);
- setShowExamples(false); // Add this line
+ setShowExamples(false);
setIsLoading(true);
setOffset(newOffset);
setProgress(0);
setChatMessages([]);
scrollToBottom();
setResults([]);
+ setSimilarityThreshold(1); // Reset similarity threshold to 1
posthog.capture("search", {
contentType: overrides.contentType || contentType,
@@ -770,7 +771,7 @@ export function SearchChat() {
<div className="flex flex-wrap items-center gap-4 mb-4">
<div className="flex-grow space-y-2">
<div className="flex items-center space-x-2">
- <Label htmlFor="start-date">start date (local time)</Label>
+ <Label htmlFor="start-date">start date</Label>
<TooltipProvider>
<Tooltip>
<TooltipTrigger asChild>
@@ -791,7 +792,7 @@ export function SearchChat() {
<div className="flex-grow space-y-2">
<div className="flex items-center space-x-2">
- <Label htmlFor="end-date">end date (local time)</Label>
+ <Label htmlFor="end-date">end date</Label>
<TooltipProvider>
<Tooltip>
<TooltipTrigger asChild>
@@ -811,7 +812,7 @@ export function SearchChat() {
</div>
</div>
- <div className="flex space-x-2 justify-center">
+ <div className="flex mt-8 space-x-2 justify-center">
<Badge
variant="outline"
className="cursor-pointer hover:bg-secondary"
@@ -1054,13 +1055,13 @@ export function SearchChat() {
</Dialog>
{isLoading ? (
- <div className="my-12 flex justify-center">
+ <div className="my-8 flex justify-center">
<Loader2 className="h-8 w-8 animate-spin" />
</div>
) : (
showExamples &&
results.length === 0 && (
- <div className="my-12 flex justify-center">
+ <div className="my-8 flex justify-center">
<ExampleSearchCards onSelect={handleExampleSelect} />
</div>
)
diff --git a/screenpipe-app-tauri/lib/hooks/use-settings.tsx b/screenpipe-app-tauri/lib/hooks/use-settings.tsx
index 6f08b4937..eb322ebef 100644
--- a/screenpipe-app-tauri/lib/hooks/use-settings.tsx
+++ b/screenpipe-app-tauri/lib/hooks/use-settings.tsx
@@ -155,8 +155,6 @@ export function useSettings() {
const savedDataDir = (await store!.get<string>("dataDir")) || "";
const savedDisableAudio =
(await store!.get<boolean>("disableAudio")) || false;
- const savedIgnoredWindows =
- (await store!.get<string[]>("ignoredWindows")) || [];
const savedIncludedWindows =
(await store!.get<string[]>("includedWindows")) || [];
const savedAiUrl =
@@ -181,6 +179,32 @@ export function useSettings() {
model: "llama3.2:1b-instruct-q4_K_M",
port: 11438,
};
+ const currentPlatform = await platform();
+ const defaultIgnoredWindows =
+ currentPlatform === "macos" // TODO: windows and linux
+ ? [
+ "bit",
+ ".env",
+ "Item-0",
+ "App Icon Window",
+ "Battery",
+ "Shortcuts",
+ "WiFi",
+ "BentoBox",
+ "Clock",
+ "Dock",
+ "DeepL",
+ ]
+ : [];
+
+ const savedIgnoredWindows = await store!.get<string[]>(
+ "ignoredWindows"
+ );
+ const finalIgnoredWindows =
+ savedIgnoredWindows && savedIgnoredWindows.length > 0
+ ? savedIgnoredWindows
+ : defaultIgnoredWindows;
+
setSettings({
openaiApiKey: savedKey,
deepgramApiKey: savedDeepgramKey,
@@ -199,7 +223,7 @@ export function useSettings() {
port: savedPort,
dataDir: savedDataDir,
disableAudio: savedDisableAudio,
- ignoredWindows: savedIgnoredWindows,
+ ignoredWindows: finalIgnoredWindows,
includedWindows: savedIncludedWindows,
aiUrl: savedAiUrl,
aiMaxContextChars: savedAiMaxContextChars,