Agno's TextReader, MarkdownReader and FieldLabeledCSVReader now decode only bytes and accept text as it is. They used to decode every input as bytes, so a text stream raised an error inside the reader, which caught it and handed you an empty list:
from io import StringIO
from agno.knowledge.reader.text_reader import TextReader
documents = TextReader(chunk=False).read(StringIO("Refunds are processed within 5 business days."))
# Before: []
# Now: one document with the textasync_read() works the same way, with or without chunking. The readers still decode binary streams with their configured encoding, UTF-8 by default.
Learn more about readers, the Markdown reader and the field-labeled CSV reader in the documentation.
Frequently asked questions
TextReader, MarkdownReader and FieldLabeledCSVReader always decoded their input as bytes. A text stream raised an error inside the reader, which caught it and returned an empty list. The three readers now accept text as it is.
Yes. TextReader, MarkdownReader and FieldLabeledCSVReader read a StringIO or a text-mode file with read() and async_read(), with or without chunking.
Agno readers decode binary streams with the reader's configured encoding, which is UTF-8 by default.




