khoj 1.26.5.dev34__py3-none-any.whl → 1.26.5.dev35__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. khoj/database/adapters/__init__.py +13 -20
  2. khoj/database/admin.py +2 -0
  3. khoj/database/management/commands/change_default_model.py +182 -0
  4. khoj/database/migrations/0072_entry_search_model.py +24 -0
  5. khoj/database/models/__init__.py +2 -0
  6. khoj/interface/compiled/404/index.html +1 -1
  7. khoj/interface/compiled/_next/static/chunks/{3678-ef0d20e267e9f010.js → 7883-b1305ec254213afe.js} +2 -2
  8. khoj/interface/compiled/_next/static/chunks/app/agents/{page-2beaba7c9bb750bd.js → page-adbf3cd470da248f.js} +1 -1
  9. khoj/interface/compiled/_next/static/chunks/app/automations/{page-9b5c77e0b0dd772c.js → page-d3edae545a1b5393.js} +1 -1
  10. khoj/interface/compiled/_next/static/chunks/app/chat/{page-151232d8417a1ea1.js → page-460d262a3ef77503.js} +1 -1
  11. khoj/interface/compiled/_next/static/chunks/app/factchecker/{page-798904432c2417c4.js → page-c8e5bd563a8155eb.js} +1 -1
  12. khoj/interface/compiled/_next/static/chunks/app/{page-db4e38a5255af7ad.js → page-337bba1c554d0742.js} +1 -1
  13. khoj/interface/compiled/_next/static/chunks/app/search/{page-ab2995529ece3140.js → page-a5c277eff207959e.js} +1 -1
  14. khoj/interface/compiled/_next/static/chunks/app/settings/page-60097571dd9f9d37.js +1 -0
  15. khoj/interface/compiled/_next/static/chunks/app/share/chat/{page-6a01e07fb244c10c.js → page-97c4e60105009649.js} +1 -1
  16. khoj/interface/compiled/_next/static/chunks/{webpack-313247d7eb764923.js → webpack-35c06f544e18305f.js} +1 -1
  17. khoj/interface/compiled/_next/static/css/4cae6c0e5c72fb2d.css +1 -0
  18. khoj/interface/compiled/_next/static/css/afd3d45cc65d55d8.css +1 -0
  19. khoj/interface/compiled/agents/index.html +1 -1
  20. khoj/interface/compiled/agents/index.txt +2 -2
  21. khoj/interface/compiled/automations/index.html +1 -1
  22. khoj/interface/compiled/automations/index.txt +2 -2
  23. khoj/interface/compiled/chat/index.html +1 -1
  24. khoj/interface/compiled/chat/index.txt +2 -2
  25. khoj/interface/compiled/factchecker/index.html +1 -1
  26. khoj/interface/compiled/factchecker/index.txt +2 -2
  27. khoj/interface/compiled/index.html +1 -1
  28. khoj/interface/compiled/index.txt +2 -2
  29. khoj/interface/compiled/search/index.html +1 -1
  30. khoj/interface/compiled/search/index.txt +2 -2
  31. khoj/interface/compiled/settings/index.html +1 -1
  32. khoj/interface/compiled/settings/index.txt +2 -2
  33. khoj/interface/compiled/share/chat/index.html +1 -1
  34. khoj/interface/compiled/share/chat/index.txt +2 -2
  35. khoj/processor/content/text_to_entries.py +4 -2
  36. khoj/routers/api.py +3 -2
  37. khoj/routers/api_model.py +0 -33
  38. khoj/routers/helpers.py +0 -9
  39. khoj/search_type/text_search.py +6 -2
  40. {khoj-1.26.5.dev34.dist-info → khoj-1.26.5.dev35.dist-info}/METADATA +1 -1
  41. {khoj-1.26.5.dev34.dist-info → khoj-1.26.5.dev35.dist-info}/RECORD +46 -44
  42. khoj/interface/compiled/_next/static/chunks/app/settings/page-3e9cf5ed5ace4310.js +0 -1
  43. khoj/interface/compiled/_next/static/css/80bd6301fc657983.css +0 -1
  44. khoj/interface/compiled/_next/static/css/b70402177a7c3207.css +0 -1
  45. /khoj/interface/compiled/_next/static/{7viHIza-WalEOzloM67l4 → GH1Wb7mTB8D7ZsHW6iRF6}/_buildManifest.js +0 -0
  46. /khoj/interface/compiled/_next/static/{7viHIza-WalEOzloM67l4 → GH1Wb7mTB8D7ZsHW6iRF6}/_ssgManifest.js +0 -0
  47. {khoj-1.26.5.dev34.dist-info → khoj-1.26.5.dev35.dist-info}/WHEEL +0 -0
  48. {khoj-1.26.5.dev34.dist-info → khoj-1.26.5.dev35.dist-info}/entry_points.txt +0 -0
  49. {khoj-1.26.5.dev34.dist-info → khoj-1.26.5.dev35.dist-info}/licenses/LICENSE +0 -0
@@ -466,18 +466,26 @@ async def set_user_github_config(user: KhojUser, pat_token: str, repos: list):
466
466
  return config
467
467
 
468
468
 
469
- def get_user_search_model_or_default(user=None):
470
- if user and UserSearchModelConfig.objects.filter(user=user).exists():
471
- return UserSearchModelConfig.objects.filter(user=user).first().setting
469
+ def get_default_search_model() -> SearchModelConfig:
470
+ default_search_model = SearchModelConfig.objects.filter(name="default").first()
472
471
 
473
- if SearchModelConfig.objects.filter(name="default").exists():
474
- return SearchModelConfig.objects.filter(name="default").first()
472
+ if default_search_model:
473
+ return default_search_model
475
474
  else:
476
475
  SearchModelConfig.objects.create()
477
476
 
478
477
  return SearchModelConfig.objects.first()
479
478
 
480
479
 
480
+ def get_user_default_search_model(user: KhojUser = None) -> SearchModelConfig:
481
+ if user:
482
+ user_search_model = UserSearchModelConfig.objects.filter(user=user).first()
483
+ if user_search_model:
484
+ return user_search_model.setting
485
+
486
+ return get_default_search_model()
487
+
488
+
481
489
  def get_or_create_search_models():
482
490
  search_models = SearchModelConfig.objects.all()
483
491
  if search_models.count() == 0:
@@ -487,21 +495,6 @@ def get_or_create_search_models():
487
495
  return search_models
488
496
 
489
497
 
490
- async def aset_user_search_model(user: KhojUser, search_model_config_id: int):
491
- config = await SearchModelConfig.objects.filter(id=search_model_config_id).afirst()
492
- if not config:
493
- return None
494
- new_config, _ = await UserSearchModelConfig.objects.aupdate_or_create(user=user, defaults={"setting": config})
495
- return new_config
496
-
497
-
498
- async def aget_user_search_model(user: KhojUser):
499
- config = await UserSearchModelConfig.objects.filter(user=user).prefetch_related("setting").afirst()
500
- if not config:
501
- return None
502
- return config.setting
503
-
504
-
505
498
  class ProcessLockAdapters:
506
499
  @staticmethod
507
500
  def get_process_lock(process_name: str):
khoj/database/admin.py CHANGED
@@ -126,6 +126,7 @@ class EntryAdmin(admin.ModelAdmin):
126
126
  "created_at",
127
127
  "updated_at",
128
128
  "user",
129
+ "agent",
129
130
  "file_source",
130
131
  "file_type",
131
132
  "file_name",
@@ -135,6 +136,7 @@ class EntryAdmin(admin.ModelAdmin):
135
136
  list_filter = (
136
137
  "file_type",
137
138
  "user__email",
139
+ "search_model__name",
138
140
  )
139
141
  ordering = ("-created_at",)
140
142
 
@@ -0,0 +1,182 @@
1
+ import logging
2
+ from typing import List
3
+
4
+ from django.core.management.base import BaseCommand
5
+ from django.db import transaction
6
+ from django.db.models import Count, Q
7
+ from tqdm import tqdm
8
+
9
+ from khoj.database.adapters import get_default_search_model
10
+ from khoj.database.models import (
11
+ Agent,
12
+ Entry,
13
+ KhojUser,
14
+ SearchModelConfig,
15
+ UserSearchModelConfig,
16
+ )
17
+ from khoj.processor.embeddings import EmbeddingsModel
18
+
19
+ logging.basicConfig(level=logging.INFO)
20
+ logger = logging.getLogger(__name__)
21
+
22
+
23
+ class Command(BaseCommand):
24
+ help = "Convert all existing Entry objects to use a new default Search model."
25
+
26
+ def add_arguments(self, parser):
27
+ # Pass default SearchModelConfig ID
28
+ parser.add_argument(
29
+ "--search_model_id",
30
+ action="store",
31
+ help="ID of the SearchModelConfig object to set as the default search model for all existing Entry objects and UserSearchModelConfig objects.",
32
+ required=True,
33
+ )
34
+
35
+ # Set the apply flag to apply the new default Search model to all existing Entry objects and UserSearchModelConfig objects.
36
+ parser.add_argument(
37
+ "--apply",
38
+ action="store_true",
39
+ help="Apply the new default Search model to all existing Entry objects and UserSearchModelConfig objects. Otherwise, only display the number of Entry objects and UserSearchModelConfig objects that will be affected.",
40
+ )
41
+
42
+ def handle(self, *args, **options):
43
+ @transaction.atomic
44
+ def regenerate_entries(entry_filter: Q, embeddings_model: EmbeddingsModel, search_model: SearchModelConfig):
45
+ entries = Entry.objects.filter(entry_filter).all()
46
+ compiled_entries = [entry.compiled for entry in entries]
47
+ updated_entries: List[Entry] = []
48
+ try:
49
+ embeddings = embeddings_model.embed_documents(compiled_entries)
50
+
51
+ except Exception as e:
52
+ logger.error(f"Error embedding documents: {e}")
53
+ return
54
+
55
+ for i, entry in enumerate(tqdm(entries)):
56
+ entry.embeddings = embeddings[i]
57
+ entry.search_model_id = search_model.id
58
+ updated_entries.append(entry)
59
+
60
+ Entry.objects.bulk_update(updated_entries, ["embeddings", "search_model_id", "file_path"])
61
+
62
+ search_model_config_id = options.get("search_model_id")
63
+ apply = options.get("apply")
64
+
65
+ logger.info(f"SearchModelConfig ID: {search_model_config_id}")
66
+ logger.info(f"Apply: {apply}")
67
+
68
+ embeddings_model = dict()
69
+
70
+ search_models = SearchModelConfig.objects.all()
71
+ for model in search_models:
72
+ embeddings_model.update(
73
+ {
74
+ model.name: EmbeddingsModel(
75
+ model.bi_encoder,
76
+ model.embeddings_inference_endpoint,
77
+ model.embeddings_inference_endpoint_api_key,
78
+ query_encode_kwargs=model.bi_encoder_query_encode_config,
79
+ docs_encode_kwargs=model.bi_encoder_docs_encode_config,
80
+ model_kwargs=model.bi_encoder_model_config,
81
+ )
82
+ }
83
+ )
84
+
85
+ new_default_search_model_config = SearchModelConfig.objects.get(id=search_model_config_id)
86
+ logger.info(f"New default Search model: {new_default_search_model_config}")
87
+ user_search_model_configs_to_update = UserSearchModelConfig.objects.exclude(
88
+ setting_id=search_model_config_id
89
+ ).all()
90
+ logger.info(f"Number of UserSearchModelConfig objects to update: {user_search_model_configs_to_update.count()}")
91
+
92
+ for user_config in user_search_model_configs_to_update:
93
+ affected_user = user_config.user
94
+ entry_filter = Q(user=affected_user)
95
+ relevant_entries = Entry.objects.filter(entry_filter).all()
96
+ logger.info(f"Number of Entry objects to update for user {affected_user}: {relevant_entries.count()}")
97
+
98
+ if apply:
99
+ try:
100
+ regenerate_entries(
101
+ entry_filter,
102
+ embeddings_model[new_default_search_model_config.name],
103
+ new_default_search_model_config,
104
+ )
105
+ user_config.setting = new_default_search_model_config
106
+ user_config.save()
107
+
108
+ logger.info(
109
+ f"Updated UserSearchModelConfig object for user {affected_user} to use the new default Search model."
110
+ )
111
+ logger.info(
112
+ f"Updated {relevant_entries.count()} Entry objects for user {affected_user} to use the new default Search model."
113
+ )
114
+
115
+ except Exception as e:
116
+ logger.error(f"Error embedding documents: {e}")
117
+
118
+ logger.info("----")
119
+
120
+ # There are also plenty of users who have indexed documents without explicitly creating a UserSearchModelConfig object. You would have to migrate these users as well, if the default is different from search_model_config_id.
121
+ current_default = get_default_search_model()
122
+ if current_default.id != new_default_search_model_config.id:
123
+ users_without_user_search_model_config = KhojUser.objects.annotate(
124
+ user_search_model_config_count=Count("usersearchmodelconfig")
125
+ ).filter(user_search_model_config_count=0)
126
+
127
+ logger.info(f"Number of User objects to update: {users_without_user_search_model_config.count()}")
128
+ for user in users_without_user_search_model_config:
129
+ entry_filter = Q(user=user)
130
+ relevant_entries = Entry.objects.filter(entry_filter).all()
131
+ logger.info(f"Number of Entry objects to update for user {user}: {relevant_entries.count()}")
132
+
133
+ if apply:
134
+ try:
135
+ regenerate_entries(
136
+ entry_filter,
137
+ embeddings_model[new_default_search_model_config.name],
138
+ new_default_search_model_config,
139
+ )
140
+
141
+ UserSearchModelConfig.objects.create(user=user, setting=new_default_search_model_config)
142
+
143
+ logger.info(
144
+ f"Created UserSearchModelConfig object for user {user} to use the new default Search model."
145
+ )
146
+ logger.info(
147
+ f"Updated {relevant_entries.count()} Entry objects for user {user} to use the new default Search model."
148
+ )
149
+ except Exception as e:
150
+ logger.error(f"Error embedding documents: {e}")
151
+ else:
152
+ logger.info("Default is the same as search_model_config_id.")
153
+
154
+ all_agents = Agent.objects.all()
155
+ logger.info(f"Number of Agent objects to update: {all_agents.count()}")
156
+ for agent in all_agents:
157
+ entry_filter = Q(agent=agent)
158
+ relevant_entries = Entry.objects.filter(entry_filter).all()
159
+ logger.info(f"Number of Entry objects to update for agent {agent}: {relevant_entries.count()}")
160
+
161
+ if apply:
162
+ try:
163
+ regenerate_entries(
164
+ entry_filter,
165
+ embeddings_model[new_default_search_model_config.name],
166
+ new_default_search_model_config,
167
+ )
168
+ logger.info(
169
+ f"Updated {relevant_entries.count()} Entry objects for agent {agent} to use the new default Search model."
170
+ )
171
+ except Exception as e:
172
+ logger.error(f"Error embedding documents: {e}")
173
+ if apply and current_default.id != new_default_search_model_config.id:
174
+ # Get the existing default SearchModelConfig object and update its name
175
+ current_default.name = f"prev_default_{current_default.id}"
176
+ current_default.save()
177
+
178
+ # Update the new default SearchModelConfig object's name
179
+ new_default_search_model_config.name = "default"
180
+ new_default_search_model_config.save()
181
+ if not apply:
182
+ logger.info("Run the command with the --apply flag to apply the new default Search model.")
@@ -0,0 +1,24 @@
1
+ # Generated by Django 5.0.8 on 2024-10-21 21:09
2
+
3
+ import django.db.models.deletion
4
+ from django.db import migrations, models
5
+
6
+
7
+ class Migration(migrations.Migration):
8
+ dependencies = [
9
+ ("database", "0071_subscription_enabled_trial_at_and_more"),
10
+ ]
11
+
12
+ operations = [
13
+ migrations.AddField(
14
+ model_name="entry",
15
+ name="search_model",
16
+ field=models.ForeignKey(
17
+ blank=True,
18
+ default=None,
19
+ null=True,
20
+ on_delete=django.db.models.deletion.SET_NULL,
21
+ to="database.searchmodelconfig",
22
+ ),
23
+ ),
24
+ ]
@@ -449,6 +449,7 @@ class UserVoiceModelConfig(BaseModel):
449
449
  setting = models.ForeignKey(VoiceModelOption, on_delete=models.CASCADE, default=None, null=True, blank=True)
450
450
 
451
451
 
452
+ # TODO Delete this model once all users have been migrated to the server's default settings
452
453
  class UserSearchModelConfig(BaseModel):
453
454
  user = models.OneToOneField(KhojUser, on_delete=models.CASCADE)
454
455
  setting = models.ForeignKey(SearchModelConfig, on_delete=models.CASCADE)
@@ -535,6 +536,7 @@ class Entry(BaseModel):
535
536
  url = models.URLField(max_length=400, default=None, null=True, blank=True)
536
537
  hashed_value = models.CharField(max_length=100)
537
538
  corpus_id = models.UUIDField(default=uuid.uuid4, editable=False)
539
+ search_model = models.ForeignKey(SearchModelConfig, on_delete=models.SET_NULL, default=None, null=True, blank=True)
538
540
 
539
541
  def save(self, *args, **kwargs):
540
542
  if self.user and self.agent:
@@ -1 +1 @@
1
- <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" href="/_next/static/media/0e790e04fd40ad16-s.p.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/_next/static/css/467a524c75e7d7c0.css" data-precedence="next"/><link rel="stylesheet" href="/_next/static/css/76d55eb435962b19.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-313247d7eb764923.js"/><script src="/_next/static/chunks/fd9d1056-2b978342deb60015.js" async=""></script><script src="/_next/static/chunks/7023-a5bf5744d19b3bd3.js" async=""></script><script src="/_next/static/chunks/main-app-6d6ee3495efe03d4.js" async=""></script><meta name="robots" content="noindex"/><meta http-equiv="Content-Security-Policy" content="default-src &#x27;self&#x27; https://assets.khoj.dev; media-src * blob:; script-src &#x27;self&#x27; https://assets.khoj.dev &#x27;unsafe-inline&#x27; &#x27;unsafe-eval&#x27;; connect-src &#x27;self&#x27; blob: https://ipapi.co/json ws://localhost:42110; style-src &#x27;self&#x27; https://assets.khoj.dev &#x27;unsafe-inline&#x27; https://fonts.googleapis.com; img-src &#x27;self&#x27; data: blob: https://*.khoj.dev https://*.googleusercontent.com https://*.google.com/ https://*.gstatic.com; font-src &#x27;self&#x27; https://assets.khoj.dev https://fonts.gstatic.com; child-src &#x27;none&#x27;; object-src &#x27;none&#x27;;"/><title>404: This page could not be found.</title><title>Khoj AI - Home</title><meta name="description" content="Your Second Brain."/><link rel="manifest" href="/static/khoj.webmanifest" crossorigin="use-credentials"/><meta property="og:title" content="Khoj AI - Home"/><meta property="og:description" content="Your Second Brain."/><meta property="og:url" content="https://app.khoj.dev/"/><meta property="og:site_name" content="Khoj AI"/><meta property="og:image" content="https://assets.khoj.dev/khoj_lantern_256x256.png"/><meta property="og:image:width" content="256"/><meta property="og:image:height" content="256"/><meta property="og:image" content="https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png"/><meta property="og:image:width" content="1200"/><meta property="og:image:height" content="630"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary_large_image"/><meta name="twitter:title" content="Khoj AI - Home"/><meta name="twitter:description" content="Your Second Brain."/><meta name="twitter:image" content="https://assets.khoj.dev/khoj_lantern_256x256.png"/><meta name="twitter:image:width" content="256"/><meta name="twitter:image:height" content="256"/><meta name="twitter:image" content="https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png"/><meta name="twitter:image:width" content="1200"/><meta name="twitter:image:height" content="630"/><link rel="icon" href="/static/assets/icons/khoj_lantern.ico"/><link rel="apple-touch-icon" href="/static/assets/icons/khoj_lantern_256x256.png"/><meta name="next-size-adjust"/><script src="/_next/static/chunks/polyfills-78c92fac7aa8fdd8.js" noModule=""></script></head><body class="__className_e594dd"><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><script src="/_next/static/chunks/webpack-313247d7eb764923.js" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0]);self.__next_f.push([2,null])</script><script>self.__next_f.push([1,"1:HL[\"/_next/static/media/0e790e04fd40ad16-s.p.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n2:HL[\"/_next/static/css/467a524c75e7d7c0.css\",\"style\"]\n3:HL[\"/_next/static/css/76d55eb435962b19.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"4:I[95751,[],\"\"]\n6:I[39275,[],\"\"]\n7:I[61343,[],\"\"]\nd:I[76130,[],\"\"]\n8:{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"}\n9:{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"}\na:{\"display\":\"inline-block\"}\nb:{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0}\ne:[]\n"])</script><script>self.__next_f.push([1,"0:[\"$\",\"$L4\",null,{\"buildId\":\"7viHIza-WalEOzloM67l4\",\"assetPrefix\":\"\",\"urlParts\":[\"\",\"_not-found\",\"\"],\"initialTree\":[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],\"initialSeedData\":[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{},[[\"$L5\",[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null],null],null]},[null,[\"$\",\"$L6\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\",\"/_not-found\",\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"notFoundStyles\":\"$undefined\"}]],null]},[[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/467a524c75e7d7c0.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/76d55eb435962b19.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[[\"$\",\"meta\",null,{\"httpEquiv\":\"Content-Security-Policy\",\"content\":\"default-src 'self' https://assets.khoj.dev; media-src * blob:; script-src 'self' https://assets.khoj.dev 'unsafe-inline' 'unsafe-eval'; connect-src 'self' blob: https://ipapi.co/json ws://localhost:42110; style-src 'self' https://assets.khoj.dev 'unsafe-inline' https://fonts.googleapis.com; img-src 'self' data: blob: https://*.khoj.dev https://*.googleusercontent.com https://*.google.com/ https://*.gstatic.com; font-src 'self' https://assets.khoj.dev https://fonts.gstatic.com; child-src 'none'; object-src 'none';\"}],[\"$\",\"body\",null,{\"className\":\"__className_e594dd\",\"children\":[\"$\",\"$L6\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$8\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$9\",\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":\"$a\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$b\",\"children\":\"This page could not be found.\"}]}]]}]}]],\"notFoundStyles\":[]}]}]]}]],null],null],\"couldBeIntercepted\":false,\"initialHead\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],\"$Lc\"],\"globalErrorComponent\":\"$d\",\"missingSlots\":\"$We\"}]\n"])</script><script>self.__next_f.push([1,"c:[[\"$\",\"meta\",\"0\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}],[\"$\",\"meta\",\"1\",{\"charSet\":\"utf-8\"}],[\"$\",\"title\",\"2\",{\"children\":\"Khoj AI - Home\"}],[\"$\",\"meta\",\"3\",{\"name\":\"description\",\"content\":\"Your Second Brain.\"}],[\"$\",\"link\",\"4\",{\"rel\":\"manifest\",\"href\":\"/static/khoj.webmanifest\",\"crossOrigin\":\"use-credentials\"}],[\"$\",\"meta\",\"5\",{\"property\":\"og:title\",\"content\":\"Khoj AI - Home\"}],[\"$\",\"meta\",\"6\",{\"property\":\"og:description\",\"content\":\"Your Second Brain.\"}],[\"$\",\"meta\",\"7\",{\"property\":\"og:url\",\"content\":\"https://app.khoj.dev/\"}],[\"$\",\"meta\",\"8\",{\"property\":\"og:site_name\",\"content\":\"Khoj AI\"}],[\"$\",\"meta\",\"9\",{\"property\":\"og:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_256x256.png\"}],[\"$\",\"meta\",\"10\",{\"property\":\"og:image:width\",\"content\":\"256\"}],[\"$\",\"meta\",\"11\",{\"property\":\"og:image:height\",\"content\":\"256\"}],[\"$\",\"meta\",\"12\",{\"property\":\"og:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png\"}],[\"$\",\"meta\",\"13\",{\"property\":\"og:image:width\",\"content\":\"1200\"}],[\"$\",\"meta\",\"14\",{\"property\":\"og:image:height\",\"content\":\"630\"}],[\"$\",\"meta\",\"15\",{\"property\":\"og:type\",\"content\":\"website\"}],[\"$\",\"meta\",\"16\",{\"name\":\"twitter:card\",\"content\":\"summary_large_image\"}],[\"$\",\"meta\",\"17\",{\"name\":\"twitter:title\",\"content\":\"Khoj AI - Home\"}],[\"$\",\"meta\",\"18\",{\"name\":\"twitter:description\",\"content\":\"Your Second Brain.\"}],[\"$\",\"meta\",\"19\",{\"name\":\"twitter:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_256x256.png\"}],[\"$\",\"meta\",\"20\",{\"name\":\"twitter:image:width\",\"content\":\"256\"}],[\"$\",\"meta\",\"21\",{\"name\":\"twitter:image:height\",\"content\":\"256\"}],[\"$\",\"meta\",\"22\",{\"name\":\"twitter:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png\"}],[\"$\",\"meta\",\"23\",{\"name\":\"twitter:image:width\",\"content\":\"1200\"}],[\"$\",\"meta\",\"24\",{\"name\":\"twitter:image:height\",\"content\":\"630\"}],[\"$\",\"link\",\"25\",{\"rel\":\"icon\",\"href\":\"/static/assets/icons/khoj_lantern.ico\"}],[\"$\",\"link\",\"26\",{\"rel\":\"apple-touch-icon\",\"href\":\"/static/assets/icons/khoj_lantern_256x256.png\"}],[\"$\",\"meta\",\"27\",{\"name\":\"next-size-adjust\"}]]\n"])</script><script>self.__next_f.push([1,"5:null\n"])</script></body></html>
1
+ <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="preload" href="/_next/static/media/0e790e04fd40ad16-s.p.woff2" as="font" crossorigin="" type="font/woff2"/><link rel="stylesheet" href="/_next/static/css/467a524c75e7d7c0.css" data-precedence="next"/><link rel="stylesheet" href="/_next/static/css/76d55eb435962b19.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-35c06f544e18305f.js"/><script src="/_next/static/chunks/fd9d1056-2b978342deb60015.js" async=""></script><script src="/_next/static/chunks/7023-a5bf5744d19b3bd3.js" async=""></script><script src="/_next/static/chunks/main-app-6d6ee3495efe03d4.js" async=""></script><meta name="robots" content="noindex"/><meta http-equiv="Content-Security-Policy" content="default-src &#x27;self&#x27; https://assets.khoj.dev; media-src * blob:; script-src &#x27;self&#x27; https://assets.khoj.dev &#x27;unsafe-inline&#x27; &#x27;unsafe-eval&#x27;; connect-src &#x27;self&#x27; blob: https://ipapi.co/json ws://localhost:42110; style-src &#x27;self&#x27; https://assets.khoj.dev &#x27;unsafe-inline&#x27; https://fonts.googleapis.com; img-src &#x27;self&#x27; data: blob: https://*.khoj.dev https://*.googleusercontent.com https://*.google.com/ https://*.gstatic.com; font-src &#x27;self&#x27; https://assets.khoj.dev https://fonts.gstatic.com; child-src &#x27;none&#x27;; object-src &#x27;none&#x27;;"/><title>404: This page could not be found.</title><title>Khoj AI - Home</title><meta name="description" content="Your Second Brain."/><link rel="manifest" href="/static/khoj.webmanifest" crossorigin="use-credentials"/><meta property="og:title" content="Khoj AI - Home"/><meta property="og:description" content="Your Second Brain."/><meta property="og:url" content="https://app.khoj.dev/"/><meta property="og:site_name" content="Khoj AI"/><meta property="og:image" content="https://assets.khoj.dev/khoj_lantern_256x256.png"/><meta property="og:image:width" content="256"/><meta property="og:image:height" content="256"/><meta property="og:image" content="https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png"/><meta property="og:image:width" content="1200"/><meta property="og:image:height" content="630"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary_large_image"/><meta name="twitter:title" content="Khoj AI - Home"/><meta name="twitter:description" content="Your Second Brain."/><meta name="twitter:image" content="https://assets.khoj.dev/khoj_lantern_256x256.png"/><meta name="twitter:image:width" content="256"/><meta name="twitter:image:height" content="256"/><meta name="twitter:image" content="https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png"/><meta name="twitter:image:width" content="1200"/><meta name="twitter:image:height" content="630"/><link rel="icon" href="/static/assets/icons/khoj_lantern.ico"/><link rel="apple-touch-icon" href="/static/assets/icons/khoj_lantern_256x256.png"/><meta name="next-size-adjust"/><script src="/_next/static/chunks/polyfills-78c92fac7aa8fdd8.js" noModule=""></script></head><body class="__className_e594dd"><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><script src="/_next/static/chunks/webpack-35c06f544e18305f.js" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0]);self.__next_f.push([2,null])</script><script>self.__next_f.push([1,"1:HL[\"/_next/static/media/0e790e04fd40ad16-s.p.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n2:HL[\"/_next/static/css/467a524c75e7d7c0.css\",\"style\"]\n3:HL[\"/_next/static/css/76d55eb435962b19.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"4:I[95751,[],\"\"]\n6:I[39275,[],\"\"]\n7:I[61343,[],\"\"]\nd:I[76130,[],\"\"]\n8:{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"}\n9:{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"}\na:{\"display\":\"inline-block\"}\nb:{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0}\ne:[]\n"])</script><script>self.__next_f.push([1,"0:[\"$\",\"$L4\",null,{\"buildId\":\"GH1Wb7mTB8D7ZsHW6iRF6\",\"assetPrefix\":\"\",\"urlParts\":[\"\",\"_not-found\",\"\"],\"initialTree\":[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],\"initialSeedData\":[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{},[[\"$L5\",[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null],null],null]},[null,[\"$\",\"$L6\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\",\"/_not-found\",\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"notFoundStyles\":\"$undefined\"}]],null]},[[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/467a524c75e7d7c0.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/76d55eb435962b19.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[[\"$\",\"meta\",null,{\"httpEquiv\":\"Content-Security-Policy\",\"content\":\"default-src 'self' https://assets.khoj.dev; media-src * blob:; script-src 'self' https://assets.khoj.dev 'unsafe-inline' 'unsafe-eval'; connect-src 'self' blob: https://ipapi.co/json ws://localhost:42110; style-src 'self' https://assets.khoj.dev 'unsafe-inline' https://fonts.googleapis.com; img-src 'self' data: blob: https://*.khoj.dev https://*.googleusercontent.com https://*.google.com/ https://*.gstatic.com; font-src 'self' https://assets.khoj.dev https://fonts.gstatic.com; child-src 'none'; object-src 'none';\"}],[\"$\",\"body\",null,{\"className\":\"__className_e594dd\",\"children\":[\"$\",\"$L6\",null,{\"parallelRouterKey\":\"children\",\"segmentPath\":[\"children\"],\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$8\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$9\",\"children\":\"404\"}],[\"$\",\"div\",null,{\"style\":\"$a\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$b\",\"children\":\"This page could not be found.\"}]}]]}]}]],\"notFoundStyles\":[]}]}]]}]],null],null],\"couldBeIntercepted\":false,\"initialHead\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],\"$Lc\"],\"globalErrorComponent\":\"$d\",\"missingSlots\":\"$We\"}]\n"])</script><script>self.__next_f.push([1,"c:[[\"$\",\"meta\",\"0\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}],[\"$\",\"meta\",\"1\",{\"charSet\":\"utf-8\"}],[\"$\",\"title\",\"2\",{\"children\":\"Khoj AI - Home\"}],[\"$\",\"meta\",\"3\",{\"name\":\"description\",\"content\":\"Your Second Brain.\"}],[\"$\",\"link\",\"4\",{\"rel\":\"manifest\",\"href\":\"/static/khoj.webmanifest\",\"crossOrigin\":\"use-credentials\"}],[\"$\",\"meta\",\"5\",{\"property\":\"og:title\",\"content\":\"Khoj AI - Home\"}],[\"$\",\"meta\",\"6\",{\"property\":\"og:description\",\"content\":\"Your Second Brain.\"}],[\"$\",\"meta\",\"7\",{\"property\":\"og:url\",\"content\":\"https://app.khoj.dev/\"}],[\"$\",\"meta\",\"8\",{\"property\":\"og:site_name\",\"content\":\"Khoj AI\"}],[\"$\",\"meta\",\"9\",{\"property\":\"og:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_256x256.png\"}],[\"$\",\"meta\",\"10\",{\"property\":\"og:image:width\",\"content\":\"256\"}],[\"$\",\"meta\",\"11\",{\"property\":\"og:image:height\",\"content\":\"256\"}],[\"$\",\"meta\",\"12\",{\"property\":\"og:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png\"}],[\"$\",\"meta\",\"13\",{\"property\":\"og:image:width\",\"content\":\"1200\"}],[\"$\",\"meta\",\"14\",{\"property\":\"og:image:height\",\"content\":\"630\"}],[\"$\",\"meta\",\"15\",{\"property\":\"og:type\",\"content\":\"website\"}],[\"$\",\"meta\",\"16\",{\"name\":\"twitter:card\",\"content\":\"summary_large_image\"}],[\"$\",\"meta\",\"17\",{\"name\":\"twitter:title\",\"content\":\"Khoj AI - Home\"}],[\"$\",\"meta\",\"18\",{\"name\":\"twitter:description\",\"content\":\"Your Second Brain.\"}],[\"$\",\"meta\",\"19\",{\"name\":\"twitter:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_256x256.png\"}],[\"$\",\"meta\",\"20\",{\"name\":\"twitter:image:width\",\"content\":\"256\"}],[\"$\",\"meta\",\"21\",{\"name\":\"twitter:image:height\",\"content\":\"256\"}],[\"$\",\"meta\",\"22\",{\"name\":\"twitter:image\",\"content\":\"https://assets.khoj.dev/khoj_lantern_logomarktype_1200x630.png\"}],[\"$\",\"meta\",\"23\",{\"name\":\"twitter:image:width\",\"content\":\"1200\"}],[\"$\",\"meta\",\"24\",{\"name\":\"twitter:image:height\",\"content\":\"630\"}],[\"$\",\"link\",\"25\",{\"rel\":\"icon\",\"href\":\"/static/assets/icons/khoj_lantern.ico\"}],[\"$\",\"link\",\"26\",{\"rel\":\"apple-touch-icon\",\"href\":\"/static/assets/icons/khoj_lantern_256x256.png\"}],[\"$\",\"meta\",\"27\",{\"name\":\"next-size-adjust\"}]]\n"])</script><script>self.__next_f.push([1,"5:null\n"])</script></body></html>