Commit graph

149 commits

Author SHA1 Message Date
Max
b9a912b7d9 Enhance member invitation management and related functionality
- Introduced invitation_id handling for member management, allowing for unique identification of pending invitations.
- Added methods to create, update, and remove members by invitation_id, improving the invitation workflow.
- Updated member data structures and API responses to include invitation-related fields, enhancing clarity and usability.
- Implemented tests for invitation ID operations, ensuring robust validation and error handling.
- Refactored team access checks to streamline member management processes.
2025-09-23 17:47:43 +08:00
Max
a2df75b6e2 Enhance member model to support robot members and their configurations
- Updated the member model to include a new member_type field, allowing differentiation between human and robot members.
- Added fields specific to robot members, including robot_name, robot_description, and robot_avatar, to capture essential information.
- Introduced robot configuration fields such as robot_config, agents, tools, and data_access_permissions for enhanced functionality.
- Implemented scheduling and automation features for robots, including is_active_robot, schedule_config, and activity_frequency.
- Enhanced indexing to support efficient queries for robot members and their activities, improving overall system performance.
2025-09-16 10:00:04 +08:00
Max
580f3683e2 Refactor user and model structures to enhance organization and role management
- Reorganized models by replacing the assistant and chat models with a new agent structure, including assistant, chat, and history models.
- Updated user model relationships to reflect changes in role and type references, ensuring consistency with the new model structure.
- Removed obsolete organization and user role models, streamlining the overall architecture.
- Adjusted system model mappings to incorporate new member and role models, enhancing clarity in user management.
2025-09-16 09:35:18 +08:00
Max
5a23afb22c Add organization_user model and enhance relationships in existing models
- Introduced the organization_user model to manage relationships between organizations and users.
- Updated organization and user models to include new relationships for managing memberships and ownerships.
- Refactored system and test model mappings to incorporate the new organization_user model, ensuring consistency across the application.
2025-09-04 17:32:39 +08:00
Max
d9c593728e Add organization model and enhance user model indexing
- Introduced the organization model with associated data structure and methods for asset management.
- Updated user model to include new indexing on locale and zoneinfo for improved internationalization queries.
- Refactored system and test model mappings to include the new organization model, ensuring consistency across the application.
2025-09-04 17:17:16 +08:00
Max
71f7dcbbad Enhance job management and category handling
- Introduced field lists for job, category, execution, and log queries to streamline data retrieval.
- Updated ListJobs, GetJob, GetCategories, and ListLogs functions to utilize new field lists for improved query efficiency.
- Enhanced job creation logic to set default values for enabled status, ensuring new jobs are active by default.
- Added category name resolution in job retrieval, enriching job data with associated category names.
- Improved error handling and logging throughout job and category management processes for better traceability.
2025-09-02 18:36:14 +08:00
Max
58f830b7b6 Enhance job and category management with unique ID generation
- Introduced unique ID generation for jobs, categories, and executions using gonanoid, improving ID handling and reducing collisions.
- Updated SaveJob and SaveCategory functions to utilize new ID generation methods, ensuring consistent and unique identifiers.
- Enhanced job creation logic to allow for category name handling, enabling automatic category ID assignment based on provided names.
- Refactored ensureCategoryExists to check for existing categories by name, streamlining category management during job operations.
- Improved error handling and logging for ID generation and category retrieval processes, ensuring better traceability and reliability.
2025-09-02 16:57:23 +08:00
Max
a1869726d5 Enhance job execution and management features
- Implemented execution options to allow priority settings and shared data for job executions.
- Introduced new execution types for processes and commands, improving flexibility in job handling.
- Updated job and execution models to include new fields for execution options and priority.
- Refactored job submission logic to support context-aware execution, enhancing error handling and process management.
- Improved test coverage for job execution scenarios, ensuring robust validation of new features.
2025-09-01 12:26:29 +08:00
Max
38f86aa77b Implement job management functionality and update job model
- Added new job management functions: Once, Cron, and Daemon for creating jobs with different scheduling types.
- Introduced methods for job manipulation, including Start, Cancel, and various setters for job properties.
- Updated job model to reflect changes in the job execution process type, renaming "process_type" to "mode" and adjusting enum values to uppercase.
- Removed obsolete interfaces and types related to job management, streamlining the codebase.
2025-08-31 11:59:16 +08:00
Max
1664355401 Add job-related models to bindata and update system models
- Added new models for job management: category, execution, job, and log.
- Updated bindata.go to include paths for the new job models.
- Modified model.go and utils.go to register the new job models in system and test mappings, ensuring they are accessible in the application.
2025-08-30 17:43:08 +08:00
Max
28bbed7908 Enhance collection and document management in API
- Introduced readonly field for collections and documents to indicate if they are read-only.
- Updated ListCollections endpoint to support pagination and filtering by various parameters, including keywords, status, and system flags.
- Enhanced query capabilities with dynamic field selection and sorting options for collections.
- Refactored GetCollections to ListCollections for improved clarity in functionality.
- Updated API response structures to reflect new filtering and sorting features, ensuring better data access and management.
2025-08-29 18:02:37 +08:00
Max
91d67d3b54 Enhance collection management and segment handling in the API
- Added GetCollection endpoint to retrieve collections by ID, including error handling for missing IDs and uninitialized knowledge base.
- Updated CreateCollectionConfig to use more descriptive field names for embedding provider and option IDs.
- Refactored UpdateSegments function to improve validation and error handling, ensuring document IDs and segment texts are properly checked.
- Introduced new request structures for updating votes, scores, and weights for segments, enhancing the API's capabilities.
- Removed the outdated vote handling file to streamline the codebase.
2025-08-20 18:25:28 +08:00
Max
57082d1d42 Enhance document management by adding file ID support and updating related fields
- Introduced `file_id` field in the document model to link documents with their corresponding files in the attachment system.
- Updated `AddFileProcess` to include `file_id` in the response, improving document tracking.
- Modified `GetDocument` function to support the new `file_id` field in document retrieval.
- Removed the unused `ScrollDocuments` endpoint to streamline the API.
- Improved error handling and response structure for document-related operations.
2025-08-15 10:47:06 +08:00
Max
b2f0ef2a67 Update asset modification timestamps and enhance chunking options configuration
- Updated modification timestamps for various asset files to reflect recent changes.
- Modified chunking options to include new parameters: Separator and EnableDebug, with default values set.
- Enhanced the Options method in Structured and Semantic providers to handle additional properties from the option map, improving flexibility in configuration.
- Added new fields in the document model for converter and fetcher option IDs, allowing for better integration with provider configurations.
2025-08-14 10:06:05 +08:00
Max
6acea5b004 Refactor extractor to extraction provider and update related configurations
- Renamed extractor provider to extraction provider across the codebase for consistency and clarity.
- Updated references in configuration files, provider factories, and asset management to reflect the new terminology.
- Removed the extractor provider implementation and associated test files, streamlining the provider structure.
- Adjusted test cases and documentation to align with the new extraction provider framework.
2025-08-13 16:32:30 +08:00
Max
c9fdb2c01c Update asset modification timestamps and add support for application/octet-stream in attachment.local.yao
- Updated modification timestamps for various asset files to reflect recent changes.
- Added support for "application/octet-stream" MIME type in the attachment.local.yao file to enhance file upload capabilities.
2025-08-13 11:12:52 +08:00
Max
bab6eec3c3 Refactor knowledge base model structure to support new collection and document formats
- Replaced the existing kb.mod.yao file with two new files: collection.mod.yao and document.mod.yao, enhancing the organization of knowledge base models.
- Updated references in system and test models to reflect the new structure, ensuring compatibility with the updated model paths.
- Adjusted asset loading functions to accommodate the new model files, improving the overall asset management system.
2025-08-12 17:20:45 +08:00
Max
eb1bf43d61 Refactor provider schemas to utilize bindata for enhanced localization support
- Updated Schema methods for various providers (OpenAI, Fastembed, MCP, OCR, Office, UTF8, Video, Vision, Whisper) to retrieve schemas from bindata, improving localization capabilities.
- Removed outdated JSON files for embedding, extractor, and fetcher providers, streamlining the data structure.
- Enhanced the overall provider management by ensuring schemas are dynamically loaded based on locale, facilitating better multi-language support.
2025-08-10 15:51:34 +08:00
Max
0251bdc8d7 Add provider management functionality and enhance schema retrieval
- Implemented GetProviders and GetProvider methods to retrieve providers based on type and ID, improving the knowledge base's provider management capabilities.
- Enhanced the Schema methods for chunking providers to retrieve schemas from bindata, ensuring better integration with the overall system.
- Updated OpenAPI routes to include endpoints for provider management, allowing for easier access to provider information via HTTP requests.
2025-08-09 11:23:51 +08:00
Max
392b6bee1b Enhance user management functionality with IP tracking and scope retrieval
- Added `last_login_ip` field to the user model to track the IP address of the last login.
- Updated `UpdateUserLastLogin` method to accept an IP address parameter for logging.
- Introduced `GetUserWithScopes` method to retrieve user information along with associated scopes and permissions.
- Modified `LoginThirdParty` and `LoginByUserID` functions to include IP address handling during login processes.
- Improved user provider interface to reflect the new methods and parameters, enhancing overall user management capabilities.
2025-08-03 18:30:34 +08:00
Max
8992cb9130 Update model options to include permission field for user-related models
- Added "permission": true to the option field in user, user_role, user_type, user_oauth_account, and dsl models, enhancing permission management capabilities.
- This change ensures consistency across user-related models and improves the overall functionality of the user management system.
2025-08-03 15:59:14 +08:00
Max
e3e4b1bb77 Implement MFA functionality in user management
- Added Multi-Factor Authentication (MFA) capabilities to the user provider, including methods for generating MFA secrets, enabling/disabling MFA, and verifying MFA codes.
- Introduced MFA configuration options, allowing customization of issuer, algorithm, digits, and recovery codes.
- Enhanced error handling for MFA operations, providing clear feedback for failures.
- Updated user model to include MFA-related fields and improved database interactions for MFA management.
- Refactored existing user provider methods to integrate MFA functionality seamlessly.
2025-08-02 21:08:37 +08:00
Max
46c8fb7786 Update asset metadata timestamps and remove obsolete index from user_type model
- Updated timestamps for various asset metadata to reflect recent changes.
- Removed the obsolete index for role relationships from the user_type model, streamlining the database schema.
2025-08-02 11:02:59 +08:00
Max
6b53086e53 Add user role and type models, update user model fields
- Introduced user_role and user_type models to enhance user management capabilities.
- Updated user model fields to reference role and type identifiers, improving clarity and compliance with relational standards.
- Adjusted asset metadata timestamps and system/test model mappings to include new models, ensuring consistency across the application.
2025-08-02 10:53:59 +08:00
Max
ea4a492974 Add user_oauth_account model and update asset metadata
- Introduced the user_oauth_account model to enhance user authentication capabilities.
- Updated asset metadata timestamps for various files to reflect recent changes.
- Ensured consistency in the system and test models by including the new user_oauth_account model in both configurations.
2025-08-02 10:39:25 +08:00
Max
ae2b267aa1 Update user model and remove obsolete test file
- Refactored the user model to align with OIDC standards, including renaming fields for clarity and compliance.
- Updated field descriptions and added new fields for enhanced user profile management.
- Removed the obsolete test file for user-related functionality to streamline the codebase and eliminate redundancy.
2025-08-02 10:13:34 +08:00
Max
070ff59225 Enhance attachment management with file storage improvements
- Refactored the attachment manager to support file uploads with a new storage path and improved metadata handling.
- Implemented chunked uploads and direct content retrieval, enhancing performance and flexibility.
- Updated the file management API to include comprehensive operations for file uploads, downloads, and metadata management.
- Added support for multiple storage backends, including local and S3, with improved error handling and validation.
- Enhanced test coverage for file operations, ensuring reliability and consistency across different storage implementations.
2025-07-26 19:25:41 +08:00
Max
2f13dbbffb Enhance attachment model and add local uploader support
- Introduced a new `Groups` field in the `Attachment` struct to support categorization of attachments.
- Integrated `types.MetaInfo` into `ManagerOption` for improved metadata handling.
- Added a local uploader for attachments, enabling file uploads from a specified local path.
- Updated asset management functions to reflect changes in file metadata and structure.
2025-07-25 18:15:51 +08:00
Max
b76afe23bf Add Knowledge Base configuration and integration with GraphRag
- Introduced a new configuration structure for the Knowledge Base, supporting vector and graph database configurations.
- Implemented JSON parsing methods for loading configurations from files and converting them to JSON format.
- Enhanced the Knowledge Base instance to integrate with GraphRag, allowing for dynamic configuration of vector and graph stores.
- Added feature detection capabilities to determine available functionalities based on the current configuration.
- Updated the Knowledge Base loading process to read from a specified configuration file, improving flexibility and usability.
2025-07-23 17:07:38 +08:00
Max
fa58bf42dc Enhance test for Load function by adding data store cleanup
- Implemented a cleanup step in the TestLoad function to remove the data store created during tests, ensuring a clean test environment.
- Added error handling for the Load function to improve robustness and provide feedback in case of failures.
2025-07-20 12:03:25 +08:00
Max
5d3c03db1f Update OAuth store management and enhance cache configurations
- Added support for a new OAuth data store in the system store management, allowing for better organization and retrieval of OAuth-related data.
- Updated the OAuth cache store configuration to increase the cache size from 4096 to 8192, improving performance and storage capacity.
- Enhanced test utilities to include the new OAuth store, ensuring comprehensive testing coverage for the updated store management features.
2025-07-20 11:47:57 +08:00
Max
8523170992 Implement system store management and enhance store loading functionality
- Introduced a new system store management feature, allowing for the loading of predefined system stores such as cache and OAuth client stores.
- Added a `loadSystemStores` function to handle the loading of system stores with variable replacement for configuration paths.
- Enhanced the `Load` function to include the loading of system stores, improving the overall store management process.
- Updated test utilities to support loading system stores for testing, ensuring comprehensive coverage and functionality.
- Refactored the `replaceVars` function to facilitate variable replacement in JSON strings, enhancing flexibility in store configurations.
2025-07-20 11:23:00 +08:00
Max
fb20eb54c5 Add user model integration and enhance OAuth user provider
- Introduced a new user model `yao/models/user.mod.yao` to support user management functionalities.
- Updated the OAuth service to utilize the new `DefaultUser` provider, enhancing user authentication and management capabilities.
- Refactored user retrieval methods to align with the new user model structure, ensuring compatibility and improved functionality.
- Added token management methods to the user provider interface, streamlining token handling processes.
- Enhanced test utilities to include the new user model for comprehensive testing coverage.
2025-07-18 11:31:39 +08:00
Max
bd95ac0604 Enhance DSL data handling and model structure
- Introduced a new fmtRow function to format row data for DSL info, improving data consistency and readability.
- Updated the Inspect and List methods to utilize the fmtRow function for better data representation.
- Added new fields for 'readonly' and 'built_in' in the DSL model, allowing for more detailed metadata management.
- Enhanced the Create and Update methods to handle the new fields, ensuring proper data storage and retrieval.
- Updated the ListOptions struct to include a Pattern field for file name matching, improving search capabilities.
2025-07-15 18:28:01 +08:00
Max
c74916296a Enhance model definitions and loading process for system models
- Added new system models for assistant, attachment, audit, chat, config, dsl, history, and kb with metadata including tags, built-in status, read-only attributes, and sort order.
- Refactored the model loading process to include a dedicated function for loading system models, improving organization and maintainability.
- Updated the application loading logic to set a default prefix for system tables, ensuring consistent naming conventions.
- Improved error handling during model loading and migration processes for better reliability.
2025-07-15 16:33:14 +08:00
Max
f55fc7b374 ⚠️ BREAKING: Rename XGen to CUI and update license terms
1. Major Changes:
   - Migrate all XGen references to CUI
   - Update project naming conventions across codebase

2. License Updates:
   - Revise open source license terms
   - Update copyright and usage conditions

This is a breaking change that requires updates in dependent projects.
2025-05-18 12:16:45 +08:00
Max
4c7b1547e8 fix: Update asset metadata and improve error handling in Agent class
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Enhanced error handling in the Agent class in libsui/agent.ts by providing more descriptive error messages for rejected promises.
- Improved message parsing error handling to ensure clearer feedback on failures.
2025-05-09 10:50:49 +08:00
Max
c44c332334 feat: Update asset metadata and enhance Assistant API functionality
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Refactored the Assistant API to improve result handling and streamline message processing.
- Removed unused stream handling code in the Assistant, simplifying the execution flow.
- Enhanced the Agent class in libsui/agent.ts to better manage message states and improve error handling.
2025-05-09 10:27:31 +08:00
Max
712bb99ab1 feat: Enhance context management and update asset metadata in SUI
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Improved context handling in the API by adding support for silent mode, history visibility, and client type.
- Refactored assistant ID usage to ensure consistent access to the default assistant across various methods.
- Enhanced the Agent class in libsui/agent.ts to manage silent mode and history visibility settings effectively.
2025-05-08 20:05:39 +08:00
Max
afc2971830 Update asset metadata and enhance Agent class functionality in SUI
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Enhanced the Agent class in libsui/agent.ts by adding type tracking for message processing, improving message creation logic based on type changes.
- Improved event handling in the Agent class to streamline message processing and enhance user interactions.
2025-05-08 12:21:07 +08:00
Max
54e291b804 Update asset metadata and enhance Agent class functionality in SUI
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Enhanced the Agent class in libsui/agent.ts by adding context management and a cancel method for better resource handling.
- Improved type definitions and event handling in the Agent class to streamline message processing and enhance user interactions.
2025-05-07 15:07:52 +08:00
Max
83bdab3499 feat: Enhance context management and agent functionality in SUI
- Added support for assistant ID in context handling to improve user-specific interactions.
- Updated asset metadata in bindata.go to reflect recent changes in modification times.
- Enhanced the Agent class in libsui/agent.ts with improved type definitions for the Call method, ensuring better type safety and clarity in asynchronous operations.
- Improved event handling in the Agent class to manage message completion more effectively.
2025-05-06 19:24:06 +08:00
Max
3b723fbce8 Update asset metadata and enhance event handling in SUI
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Enhanced event handling in libsui/index.ts to support parent component names for event binding, improving flexibility and error handling.
2025-05-06 12:42:40 +08:00
Max
01c524be54 fix: Update asset metadata and enhance route handling in SUI
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Enhanced route handling in libsui/index.ts to support optional route parameters, improving flexibility in component rendering.
- Added initialization for sub-components within the rendering process, enhancing component lifecycle management and error handling.
2025-05-05 18:11:47 +08:00
Max
d894f0a1e9 feat: Update asset metadata and enhance Agent class in SDK
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Enhanced the Agent class in libsui/agent.ts with improved type definitions and event handling.
- Introduced new interfaces for message structures and event handlers, streamlining message processing.
- Refactored the Call method to better manage message states and improve error handling.
2025-05-05 16:18:57 +08:00
Max
d731296b94 refactor: Clean up and standardize code formatting in bindata.go
- Reorganized import statements for consistency.
- Removed unnecessary blank lines and standardized indentation for better readability.
- Updated map initialization syntax for improved clarity and uniformity.
2025-05-05 14:53:05 +08:00
Max
595709f834 # Enhanced Yao AI Agent SDK
Improved the Yao AI Agent SDK with better type definitions and error handling.

## Key Updates
- Added typed interfaces for attachments and messages
- Optimized attachment handling (only send when present)
- Enhanced error handling with specific error messages
- Improved event system for message streaming
- Added comprehensive TypeScript definitions
2025-05-05 12:48:58 +08:00
Max
f0a4a8d4ea Remove deprecated storage and import API definitions 2024-11-06 09:16:30 +08:00
Max
3074a8e432 libsui $Query class to support multiple elements in constructor 2024-10-09 11:26:37 +08:00
Max
776d22a443 update bindata 2024-10-01 07:50:32 +08:00