mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-25 16:26:51 +08:00
Fix: type check for chunks (#12164)
### What problem does this PR solve? Fix: type check for chunks ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
@ -105,6 +105,9 @@ class Tokenizer(ProcessBase):
|
||||
|
||||
async def _invoke(self, **kwargs):
|
||||
try:
|
||||
chunks = kwargs.get("chunks")
|
||||
kwargs["chunks"] = [c for c in chunks if c is not None]
|
||||
|
||||
from_upstream = TokenizerFromUpstream.model_validate(kwargs)
|
||||
except Exception as e:
|
||||
self.set_output("_ERROR", f"Input error: {str(e)}")
|
||||
|
||||
Reference in New Issue
Block a user