Skip to content

[Bug]: When the knowledge graph is enabled, retrieval testing throw error: JSONDecodeError('Expecting value: line 1 column 1 (char 0)') #4874

Open
@tevooli

Description

@tevooli

Is there an existing issue for the same bug?

  • I have checked the existing issues.

RAGFlow workspace code commit ID

v0.16.0

RAGFlow image version

v0.16.0 full

Other environment information

system chat model: qwen-max

Actual behavior

ragflow-server  | 2025-02-11 14:42:02,509 INFO     15 POST http://es01:9200/ragflow_1f7c4da4e82a11ef85130242ac1b0006/_search [status:200 duration:0.008s]
ragflow-server  | 2025-02-11 14:42:02,511 ERROR    15 Expecting value: line 1 column 1 (char 0)
ragflow-server  | Traceback (most recent call last):
ragflow-server  |   File "/ragflow/api/apps/chunk_app.py", line 311, in retrieval_test
ragflow-server  |     ck = settings.kg_retrievaler.retrieval(question,
ragflow-server  |   File "/ragflow/graphrag/search.py", line 251, in retrieval
ragflow-server  |     "Description": json.loads(rel["description"]).get("description", "")
ragflow-server  |   File "/usr/lib/python3.10/json/__init__.py", line 346, in loads
ragflow-server  |     return _default_decoder.decode(s)
ragflow-server  |   File "/usr/lib/python3.10/json/decoder.py", line 337, in decode
ragflow-server  |     obj, end = self.raw_decode(s, idx=_w(s, 0).end())
ragflow-server  |   File "/usr/lib/python3.10/json/decoder.py", line 355, in raw_decode
ragflow-server  |     raise JSONDecodeError("Expecting value", s, err.value) from None
ragflow-server  | json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
ragflow-server  | 2025-02-11 14:42:02,513 INFO     15 172.30.0.6 - - [11/Feb/2025 14:42:02] "POST /v1/chunk/retrieval_test HTTP/1.1" 200 -

Expected behavior

No response

Steps to reproduce

1. create knowledge base, configuration:
  
  Document language: Chinese
  Embedding model: BAAI/bge-large-zh-v1.5
  Chunk method: General
  Page rank: 0
  Auto-keyword: 0
  Auto-question: 0
  Chunk token number: 512
  Delimiters: \n!?;。;!?
  Layout recognition & OCR: DeepDOC
  Excel to HTML: false
  Use RAPTOR to enhance retrieval: false
  Extract knowledge graph: true
  ENtity types: organization, person, geo, event, category
  Method: Light
  Entity resolution: true
  Community reports generation: false
  Tag set: null
  
2. upload a document
3. Retrieval testing, and enable `Use knowledge graph`

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    🐞 bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions