High-performance Rust search engine for RAG systems
Project description
son-logic-engine
High-performance search filter for RAG systems written in Rust, designed for speed and accuracy with Vietnamese text.
🚀 Features
- Rust Core: Blazing fast processing for large datasets.
- Polymorphic Input: Supports
List[str],Dict, or nestedList[Dict]. - Field Filtering: Optimize search speed by targeting specific columns.
- Unicode Support: Native handling of Vietnamese characters and custom character mappings.
🛠 Installation
pip install son-logic-engine
📖 API Reference
1. load_mapping(path: str)
Loads the character weight mapping from a JSON file. This is required for the search logic to compute character-based relevance.
import son_logic_engine as slg
mapping = slg.load_mapping('path/to/mapping.json')
2. loc(query: str, database: Any, mapping: dict, field_name: str = None)
The core search function. Returns a list of records (as JSON strings) ranked by relevance to the query.
query: The search term.database: Your data (List of strings or List of Dictionaries).mapping: The mapping object fromload_mapping.field_name: (Optional) The specific key in your dictionary to search within.
3. print(raw_results: list)
A utility function to decode and pretty-print the JSON results returned by loc.
results = slg.loc("search term", data, mapping)
slg.print(results)
🔒 Security & Contact
The underlying search algorithm and character weight logic are proprietary. For access to standard mapping files or custom integration, please contact:
📩 Email: sonbuwin@gmail.com
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file son_logic_engine-0.2.3.tar.gz.
File metadata
- Download URL: son_logic_engine-0.2.3.tar.gz
- Upload date:
- Size: 7.1 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1afa9107a4a4170685fdf325ac35a60d93382fe70545998887ab4d10155adf65
|
|
| MD5 |
95c83938060a95d98a130a98fd2c1b46
|
|
| BLAKE2b-256 |
f9f4742860e59e33564c382591351beb7eb798e43174955f117e839459f193e9
|
File details
Details for the file son_logic_engine-0.2.3-cp312-cp312-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: son_logic_engine-0.2.3-cp312-cp312-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 317.3 kB
- Tags: CPython 3.12, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d8b00b5fae167bd6f00138bf09c0d55c8f959fa9fa33a673583b8a04d50fa2db
|
|
| MD5 |
2fce7dc972360b21772d918f8c5ba6a1
|
|
| BLAKE2b-256 |
784a487e16bc854221dfea317f163bc1c09b78dd14281b0eedf0947e345a7bc4
|