from llama_index.core import (
    SimpleDirectoryReader, 
    VectorStoreIndex, 
    set_global_handler
)
import phoenix as px

px.launch_app()
set_global_handler("arize_phoenix")

documents = SimpleDirectoryReader('pliki').load_data()
index = VectorStoreIndex.from_documents(documents)
qe = index.as_query_engine()
response = qe.query("Opowiedz mi o starożytnym Rzymie.")
print(response)

input("Naciśnij <ENTER>, aby wyjść...")
