from r2r import R2RClient
client = R2RClient(base_url=os.environ.get("SCIPHI_CLOUD_URL"))
messages = [
{"role": "user", "content": "What was Aristotle's main contribution to philosophy?"},
{"role": "assistant", "content": "Aristotle made numerous significant contributions to philosophy, but one of his main contributions was in the field of logic and reasoning. He developed a system of formal logic, which is considered the first comprehensive system of its kind in Western philosophy. This system, often referred to as Aristotelian logic or term logic, provided a framework for deductive reasoning and laid the groundwork for scientific thinking."},
{"role": "user", "content": "Can you elaborate on how this influenced later thinkers?"}
]
result = client.agent(
messages=messages,
vector_search_settings={"use_hybrid_search":True},
rag_generation_config={"model": "openai/gpt-4o", "temperature": 0.7}
)
print(result['choices'][0]['message']['content'])