from core.agent import EdenAgent

print("=" * 60)
print("TESTING EDEN'S TOOL USAGE")
print("=" * 60)

eden = EdenAgent(model="llama3.1:8b")

# Test 1: Ask Eden to check what files exist
print("\n1. Asking Eden to list files:")
response = eden.chat("Please list the files in the current directory. Actually execute the list_files tool.")
print(f"Eden: {response[:300]}...")

# Test 2: Ask Eden to read a file
print("\n2. Asking Eden to read README:")
response = eden.chat("Can you read the README.md file and tell me what this project is about?")
print(f"Eden: {response[:300]}...")

# Test 3: Ask Eden to create a file
print("\n3. Asking Eden to create a test file:")
response = eden.chat("Please create a file called 'eden_test.txt' with the content 'Eden can write files!'")
print(f"Eden: {response[:300]}...")

# Verify it was created
print("\n4. Checking if file was created:")
response = eden.chat("Did you successfully create that file? Check if eden_test.txt exists.")
print(f"Eden: {response[:300]}...")

eden.save_session("tool_test")
print("\n✅ TOOL TEST COMPLETE")
