Spaces:
Runtime error
Runtime error
sssss
Browse files- my_tools.py +3 -1
my_tools.py
CHANGED
|
@@ -5,10 +5,12 @@ from duckduckgo_search import DDGS
|
|
| 5 |
import wikipedia
|
| 6 |
from llama_index.core.tools import FunctionTool
|
| 7 |
from llama_index.core.agent import ReActAgent
|
| 8 |
-
from llama_index.
|
| 9 |
from llama_index.core.callbacks import CallbackManager, LlamaDebugHandler
|
| 10 |
import google.generativeai as genai
|
| 11 |
|
|
|
|
|
|
|
| 12 |
# --- Gemini LLM personalizado ---
|
| 13 |
class GeminiLLM(LLM):
|
| 14 |
def __init__(self, model="models/gemini-1.5-flash-latest"):
|
|
|
|
| 5 |
import wikipedia
|
| 6 |
from llama_index.core.tools import FunctionTool
|
| 7 |
from llama_index.core.agent import ReActAgent
|
| 8 |
+
from llama_index.llms.base import ChatMessage, LLMMetadata, LLM
|
| 9 |
from llama_index.core.callbacks import CallbackManager, LlamaDebugHandler
|
| 10 |
import google.generativeai as genai
|
| 11 |
|
| 12 |
+
print("LlamaIndex version:", llama_index.__version__)
|
| 13 |
+
|
| 14 |
# --- Gemini LLM personalizado ---
|
| 15 |
class GeminiLLM(LLM):
|
| 16 |
def __init__(self, model="models/gemini-1.5-flash-latest"):
|