Closed bamhill closed 6 hours ago
Hey @bamhill! I'm here to help you with bugs, questions, and becoming a contributor. Let's tackle this issue together while we wait for a human maintainer.
The error you're encountering, "1 validation error for documentcontext score input should be a valid number," suggests that the documentcontext score
is expected to be a numerical value, but it is currently None
. This can happen if the score is missing in the metadata when creating DocumentContext
objects or if the index_node_id
is not found in the document_score_list
[1].
To resolve this issue, ensure that the score is correctly retrieved and assigned a valid numerical value in the metadata or document score list. You might need to check the data source or logic that populates these scores to ensure they are not missing or incorrectly set to None
.
To continue talking to Dosu, mention @dosu.
Self Checks
Dify version
Version 0.9.1
Cloud or Self Hosted
Self Hosted (Docker)
Steps to reproduce
When the question involves the content in the knowledge base, it will report: 1 validation error for documentcontext score input should be a valid number [type=float_type, input_value=None, input_type=NoneType] For further information visit https://errors.pydantic.dev/2.8/v/float_type
✔️ Expected Behavior
No response
❌ Actual Behavior
No response