Skip to content

Enhance CI workflow, implement async features, and refactor code#8

Merged
zTgx merged 6 commits intomainfrom
dev
Apr 5, 2026
Merged

Enhance CI workflow, implement async features, and refactor code#8
zTgx merged 6 commits intomainfrom
dev

Conversation

@zTgx
Copy link
Copy Markdown
Contributor

@zTgx zTgx commented Apr 5, 2026

No description provided.

zTgx added 6 commits April 5, 2026 15:00
Add dev branch to push and pull_request triggers in CI workflow.
Enable RUST_BACKTRACE for better debugging.
Update cargo commands to use --all-features flag.
Enhance fmt job to check all files with --all flag.
Improve clippy job with --all-targets and --all-features flags.
Add OPENAI_API_KEY environment variable to test job.
Include documentation generation and release build checks.

feat(builder): implement comprehensive EngineBuilder with new configuration options

Add detailed documentation with examples for EngineBuilder.
Introduce new methods: with_openai, with_model, with_endpoint, with_top_k.
Add preset modes: fast() and precise() for different performance configurations.
Implement configuration priority system with multiple override levels.
Add comprehensive test coverage for builder functionality.

refactor(engine): update indexing API to use IndexContext and async methods

Replace index_with_options with unified index method using IndexContext.
Introduce IndexContext enum for different document sources (path, content, bytes).
Make all workspace-related methods async for better error handling.
Update query methods to use async get_structure calls.
Add example usage of different indexing approaches in documentation.

feat(index_context): create unified indexing context for document sources

Implement IndexContext with support for file paths, content strings, and binary data.
Add IndexSource enum with Path, Content, and Bytes variants.
Provide helper methods: with_name, with_options, with_mode.
Include comprehensive documentation and examples.
Add trait implementations and extensive test coverage.
…operations

- Import IndexContext in all example files to replace direct path indexing
- Update client.index() calls to use IndexContext::from_path() wrapper
- Convert synchronous remove() calls to async remove().await?
- Update index_with_options() to use IndexContext with options
- Make get_structure() call asynchronous with .await
- Update import statements to include IndexContext alongside existing imports
- Convert all workspace operations to async/await pattern
- Replace synchronous Workspace with AsyncWorkspace throughout
- Update examples to use async workspace methods
- Add proper error handling with BuildError type annotations

BREAKING CHANGE: All workspace operations are now async and require
.await calls. Existing synchronous code will need to be updated.

feat(client): make EngineBuilder.build() asynchronous

- Change EngineBuilder::build() method to async fn
- Update all examples to await the build operation
- Convert workspace initialization to async pattern
- Update documentation examples to use async/await

refactor(client): remove RwLock from workspace client

- Replace Arc<RwLock<Workspace>> with Arc<AsyncWorkspace>
- Update all workspace client methods to async implementations
- Remove synchronous locking patterns in favor of async safety
- Simplify thread safety model with async workspace abstractions
BREAKING CHANGE: Removed AsyncWorkspace in favor of unified Workspace
that provides async functionality directly.

- Replace all AsyncWorkspace references with Workspace across the codebase
- Update examples to use Workspace instead of AsyncWorkspace
- Modify client builder, engine, and workspace modules accordingly
- Update pipeline executor and persist stage to use new Workspace type
- Export Workspace instead of AsyncWorkspace in public API

This change simplifies the storage API by removing the distinction between
sync and async workspace implementations, as Workspace now provides
async capabilities natively.
- Reformat multi-line function calls to improve readability across
  multiple files including markdownflow.rs, storage_backend.rs,
  storage_workspace.rs, engine.rs, session.rs, workspace.rs,
  persist.rs, and lib.rs
- Reorder import statements alphabetically to maintain consistent
  code style
- Move re-export of workspace types from storage mod.rs to end of
  file to follow proper module organization
- Remove 'dev' branch from push trigger
- Remove 'dev' branch from pull_request trigger
- Keep CI workflow running only on main branch
@zTgx zTgx merged commit 0b1a0e9 into main Apr 5, 2026
3 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant