Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSONDecodeError in Knowledge Curation Module - Expecting Value: Line 1 Column 1 (char 0) #305

Open
dennicLiu opened this issue Jan 16, 2025 · 0 comments

Comments

@dennicLiu
Copy link

Description:
A JSONDecodeError occurs during the execution of the run_knowledge_curation_module in the knowledge_storm library. The error message indicates that the code attempted to parse an empty or invalid JSON response from an external API (likely Serper API). The error arises when trying to decode the response using response.json().

Steps to Reproduce:

  1. Input Topic Name: [Provide the topic name used for the knowledge curation]

  2. Execution Command: Run the script run_storm_wiki_deepseek.py with the appropriate arguments.

  3. Error Encountered: The script fails with the following error traceback:

    requests.exceptions.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
    
  4. Output Files: [Attach all output files generated for this topic as a zip file]

Expected Behavior:
The knowledge curation module should successfully retrieve and parse data from the external API without encountering JSON decoding errors.

Actual Behavior:
The script fails with a JSONDecodeError due to an empty or invalid JSON response.

Environment:

  • OS: macOS (as inferred from the file paths)
  • Python Version: 3.11
  • Libraries/Packages:
    • knowledge_storm
    • requests
    • dspy
  • External API: Serper API (or similar)

Additional Context:
The error occurs in the serper_runner method of the rm.py file, specifically when trying to parse the API response using response.json(). The issue seems to be related to the API returning an empty or invalid response.


Note: Please provide the input topic name and any generated output files to help further diagnose the issue. Additionally, include details about the external API being used (e.g., Serper API) and any relevant configuration settings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant