feat: Enhance wiki extraction and configuration options

- Introduced extraction granularity settings in the wiki configuration, allowing users to control the level of detail in entity and concept extraction (focused, standard, exhaustive).
- Updated the UI to reflect these new options, including tooltips for better user guidance.
- Refactored the knowledge base editor to support the new extraction granularity feature, ensuring a seamless user experience.
- Improved the backend logic for wiki ingest tasks to utilize the new granularity settings, enhancing the accuracy of extracted content.
- Added tests to validate the new extraction granularity functionality and ensure robust performance across different configurations.
This commit is contained in:
wizardchen
2026-04-22 20:27:19 +08:00
parent 623add89f1
commit a8a3d9e694
23 changed files with 2110 additions and 174 deletions
@@ -123,8 +123,8 @@ func (s *KnowledgePostProcessService) Handle(ctx context.Context, task *asynq.Ta
}
}
// 6. Spawn Wiki Ingest Task if wiki indexing is enabled in IndexingStrategy and auto ingest is on
if kb.IndexingStrategy.WikiEnabled && kb.WikiConfig != nil && kb.WikiConfig.AutoIngest && len(textChunks) > 0 {
// 6. Spawn Wiki Ingest Task if wiki indexing is enabled in IndexingStrategy
if kb.IndexingStrategy.WikiEnabled && len(textChunks) > 0 {
EnqueueWikiIngest(ctx, s.taskEnqueuer, s.redisClient, payload.TenantID, payload.KnowledgeBaseID, payload.KnowledgeID)
logger.Infof(ctx, "[KnowledgePostProcess] Enqueued wiki ingest task for %s", payload.KnowledgeID)
}