8000 Add support for using tinysearch as a library from Rust by mre · Pull Request #184 · tinysearch/tinysearch · GitHub
[go: up one dir, main page]

Skip to content

Conversation

@mre
Copy link
Member
@mre mre commented Aug 26, 2025

This refactoring extends the public API while maintaining backward compatibility with existing CLI functionality:

  • Created api module with Post trait and a BasicPost implementation for flexible post types
  • Added TinySearch struct with builder pattern for configuration and search operations
  • Moved public API types to dedicated module with additional rustdoc documentation
  • Added complete library usage examples for basic and advanced use cases

Closes #183

mre added 4 commits August 31, 2025 16:24
…tation

This refactoring introduces a clean, well-documented public API while maintaining backward compatibility with existing CLI functionality:

- Created api module with Post trait and BasicPost implementation for flexible post types
- Added TinySearch struct with builder pattern for configuration and search operations
- Moved public API types to dedicated module with comprehensive rustdoc documentation
- Added complete library usage examples for basic and advanced use cases
- Created detailed LIBRARY_USAGE.md documentation with migration guide
- Updated dependencies to support library functionality
- Maintained full CLI compatibility and all existing functionality
- Added concise library usage section to README
- Marked library API as experimental with API stability warning
- Removed separate LIBRARY_USAGE.md file
- Referenced example directories for detailed usage
… for better indexing and search capabilities
- Updated test_generate_filters to use String::new() instead of None for metadata
- This fixes CI compilation error where PostId expects String but test provided Option<String>
- All tests now pass with the new HashMap<String, String> metadata format
@mre mre merged commit f6644f3 into master Sep 1, 2025
10 checks passed
@mre mre deleted the tinysearch-api branch September 1, 2025 11:48
@mre mre added the enhancement New feature or request label Sep 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[SUGGESTION] - Add docs on how to implement this in rust code

2 participants

0