----------------------
Yes, you can use multiple
result_type
with
LlamaParse
. The
result_type
parameter in
LlamaParse
determines the format of the parsed data. The two available options are "markdown" and "text".
Here is an example of how you can use it:
from llama_parse import LlamaParse
# Load data as markdown
docs_markdown = LlamaParse(result_type="markdown").load_data("./apple_2021_10k.pdf")
# Load data as text
docs_text = LlamaParse(result_type="text").load_data("./apple_2021_10k.pdf")
In the above code,
docs_markdown
will contain the parsed data in markdown format, while
docs_text
will contain the parsed data in plain text format.
Please note that you need to replace
"./apple_2021_10k.pdf"
with the actual path to your PDF file.
Sources:
- LlamaIndex > En > Latest > Examples > Llm > set up parser ()
- LlamaIndex > En > Latest > Understanding > Agent > Enhancing with LlamaParse Part 1 ()
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------