#❌ Error processing 20200206_10-K_edgar_data_875657_0001437749-20-001842_item1.txt: 'NoneType' object

5 messages · Page 1 of 1 (latest)

pliant pasture
#

Not an OR issue

upper imp
#

I tried to simply replace the txt file with string "Hello world!", the error was still there.

With string "Hello World" there my input couldn't be empty, that's why I'm thinking maybe OR is returnining with empty response for some reason.

ocean imp
#
file_content = "Hello World!"

completion = client.chat.completions.create(
                    model="deepseek/deepseek-chat:free",
                    messages=[
                        {
                            "role": "user",
                            "content": f"""Extract all       sentences related to employees from the given text. \ 
                                            - Return only the extracted sentences.\
                                            - Do not include indexes, explanations, or additional text.\
                                            - If no employee-related sentences are found, return exactly: NaN.\
                                            Text: {file_content}"""
                        }
                    ], temperature=0,
                )
                employee_section = completion.choices[0].message.content.strip()

ocean imp
#

this is an error in your code