Skip to content

Commit 93d7e38

Browse files
committed
fix: better instructions to LLM
1 parent 3a5f6f1 commit 93d7e38

2 files changed

Lines changed: 11 additions & 7 deletions

File tree

flet_ui.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def main(self, page: ft.Page):
2626
self.page = page
2727

2828
# Configure the page
29-
page.title = "סוכן חיפוש"
29+
page.title = "איתוריא"
3030
page.theme_mode = ft.ThemeMode.LIGHT
3131
page.window.width = 1000
3232
page.window.height = 800

tantivy_search_agent.py

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,13 @@ def get_query_instructions(self) -> str:
2424
2525
2626
1. Boolean Operators:
27-
- Multiple words default to AND operation
27+
2828
- AND: term1 AND term2 (both required)
2929
- OR: term1 OR term2 (either term)
30+
- Multiple words default to OR operation
3031
- AND takes precedence over OR
3132
- Example: security AND (cloud OR network)
33+
- cloud network = cloud OR network
3234
3335
2. Required/Excluded Terms:
3436
- Required (+): +term (must contain)
@@ -39,11 +41,12 @@ def get_query_instructions(self) -> str:
3941
3. Phrase Search:
4042
- Use quotes: "exact phrase"
4143
- Both single/double quotes work
42-
- Escape quotes with \
44+
- Escape quotes with \\"
4345
- Slop operator: "term1 term2"~N
44-
- use lop operator only for terms inside quotes
46+
- use slop operator only for terms inside quotes
4547
- Prefix matching: "start of phrase"*
46-
- Example: title:"cloud security"~2
48+
- Example: "cloud security"~2
49+
- the above will find "cloud framework and security "
4750
4851
4. Set Operations:
4952
- IN operator: field IN [value1 value2]
@@ -53,12 +56,13 @@ def get_query_instructions(self) -> str:
5356
5. Wildcards:
5457
- ? for single character
5558
- * for any number of characters
56-
- Example: title:sec?rity cloud*
59+
- Example: sec?rity cloud*
5760
5861
6. Special Features:
5962
- All docs: *
6063
- Boost terms: term^2.0 (positive numbers only)
61-
64+
- Example: security^2.0 cloud
65+
- the above will boost security by 2.0
6266
6367
Query Examples:
6468
1. Basic: security AND cloud

0 commit comments

Comments
 (0)