son-logic-engine 0.2.4__tar.gz → 0.2.5__tar.gz
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.
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/Cargo.lock +1 -1
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/Cargo.toml +1 -1
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/PKG-INFO +22 -5
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/README.md +21 -4
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/pyproject.toml +1 -1
- son_logic_engine-0.2.4/encoding_map.json +0 -29
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/sample_data/README.md +0 -0
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/sample_data/anscombe.json +0 -0
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/sample_data/california_housing_test.csv +0 -0
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/sample_data/california_housing_train.csv +0 -0
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/sample_data/mnist_test.csv +0 -0
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/sample_data/mnist_train_small.csv +0 -0
- {son_logic_engine-0.2.4 → son_logic_engine-0.2.5}/src/lib.rs +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: son_logic_engine
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.5
|
|
4
4
|
Summary: High-performance Rust search engine for RAG systems
|
|
5
5
|
Author-email: Son <sonbuwin@gmail.com>
|
|
6
6
|
Requires-Python: >=3.7
|
|
@@ -37,11 +37,28 @@ The core search function. Returns a list of records (as JSON strings) ranked by
|
|
|
37
37
|
- `mapping`: The mapping object from `load_mapping`.
|
|
38
38
|
- `field_name`: (Optional) The specific key in your dictionary to search within.
|
|
39
39
|
|
|
40
|
-
###
|
|
41
|
-
|
|
40
|
+
### Python-side Utility: `slg.print(raw_results: list)`
|
|
41
|
+
This is a *notebook-defined helper function* designed to pretty-print the JSON results returned by `loc` in a readable format within a Python environment. It is not part of the core Rust library distributed via PyPI.
|
|
42
|
+
|
|
42
43
|
```python
|
|
43
|
-
|
|
44
|
-
|
|
44
|
+
# Example of how you might define and use a similar helper in Python
|
|
45
|
+
import json
|
|
46
|
+
|
|
47
|
+
def slg_print_helper(raw_results):
|
|
48
|
+
if not raw_results:
|
|
49
|
+
print("Không tìm thấy kết quả nào.")
|
|
50
|
+
return
|
|
51
|
+
for i, item_json in enumerate(raw_results):
|
|
52
|
+
try:
|
|
53
|
+
data_obj = json.loads(item_json)
|
|
54
|
+
print(f"[Hạng {i+1}]")
|
|
55
|
+
print(json.dumps(data_obj, indent=4, ensure_ascii=False))
|
|
56
|
+
print("---" * 10)
|
|
57
|
+
except Exception as e:
|
|
58
|
+
print(f"Lỗi khi giải mã kết quả thứ {i+1}: {e}")
|
|
59
|
+
|
|
60
|
+
# Assuming `slg` is imported and `raw_results` are from `slg.loc`
|
|
61
|
+
# slg_print_helper(raw_results)
|
|
45
62
|
```
|
|
46
63
|
|
|
47
64
|
## 🔒 Security & Contact
|
|
@@ -29,11 +29,28 @@ The core search function. Returns a list of records (as JSON strings) ranked by
|
|
|
29
29
|
- `mapping`: The mapping object from `load_mapping`.
|
|
30
30
|
- `field_name`: (Optional) The specific key in your dictionary to search within.
|
|
31
31
|
|
|
32
|
-
###
|
|
33
|
-
|
|
32
|
+
### Python-side Utility: `slg.print(raw_results: list)`
|
|
33
|
+
This is a *notebook-defined helper function* designed to pretty-print the JSON results returned by `loc` in a readable format within a Python environment. It is not part of the core Rust library distributed via PyPI.
|
|
34
|
+
|
|
34
35
|
```python
|
|
35
|
-
|
|
36
|
-
|
|
36
|
+
# Example of how you might define and use a similar helper in Python
|
|
37
|
+
import json
|
|
38
|
+
|
|
39
|
+
def slg_print_helper(raw_results):
|
|
40
|
+
if not raw_results:
|
|
41
|
+
print("Không tìm thấy kết quả nào.")
|
|
42
|
+
return
|
|
43
|
+
for i, item_json in enumerate(raw_results):
|
|
44
|
+
try:
|
|
45
|
+
data_obj = json.loads(item_json)
|
|
46
|
+
print(f"[Hạng {i+1}]")
|
|
47
|
+
print(json.dumps(data_obj, indent=4, ensure_ascii=False))
|
|
48
|
+
print("---" * 10)
|
|
49
|
+
except Exception as e:
|
|
50
|
+
print(f"Lỗi khi giải mã kết quả thứ {i+1}: {e}")
|
|
51
|
+
|
|
52
|
+
# Assuming `slg` is imported and `raw_results` are from `slg.loc`
|
|
53
|
+
# slg_print_helper(raw_results)
|
|
37
54
|
```
|
|
38
55
|
|
|
39
56
|
## 🔒 Security & Contact
|
|
@@ -5,7 +5,7 @@ build-backend = "maturin"
|
|
|
5
5
|
|
|
6
6
|
[project]
|
|
7
7
|
name = "son_logic_engine"
|
|
8
|
-
version = "0.2.
|
|
8
|
+
version = "0.2.5" # Cập nhật trực tiếp lên 0.2.5
|
|
9
9
|
description = "High-performance Rust search engine for RAG systems"
|
|
10
10
|
authors = [{name = "Son", email = "sonbuwin@gmail.com"}]
|
|
11
11
|
readme = "README.md"
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"a": 0.1,
|
|
3
|
-
"b": 0.2,
|
|
4
|
-
"c": 0.3,
|
|
5
|
-
"d": 0.4,
|
|
6
|
-
"e": 0.5,
|
|
7
|
-
"f": 0.6,
|
|
8
|
-
"g": 0.7,
|
|
9
|
-
"h": 0.8,
|
|
10
|
-
"i": 0.9,
|
|
11
|
-
"j": 1.0,
|
|
12
|
-
"k": 1.1,
|
|
13
|
-
"l": 1.2,
|
|
14
|
-
"m": 1.3,
|
|
15
|
-
"n": 1.4,
|
|
16
|
-
"o": 1.5,
|
|
17
|
-
"p": 1.6,
|
|
18
|
-
"q": 1.7,
|
|
19
|
-
"r": 1.8,
|
|
20
|
-
"s": 1.9,
|
|
21
|
-
"t": 2.0,
|
|
22
|
-
"u": 2.1,
|
|
23
|
-
"v": 2.2,
|
|
24
|
-
"w": 2.3,
|
|
25
|
-
"x": 2.4,
|
|
26
|
-
"y": 2.5,
|
|
27
|
-
"z": 2.6,
|
|
28
|
-
" ": 0.0
|
|
29
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|