Spaces:
Sleeping
Sleeping
Update agent.py
Browse files2 unmodified lines3456789101112131415162 unmodified linesfrom smolagents import TransformersModelclass GaiaAgent:def __init__(self, model_id: str = "HuggingFaceH4/zephyr-7b-beta"): # <-- CHANGE MODEL HEREself.llm_model = TransformersModel(model_id=model_id,# For Zephyr (a causal LM), the default `AutoModelForCausalLM` works,# and `task="text-generation"` is appropriate for the pipeline.task="text-generation",# You might need device_map="auto" if you hit memory issues or have GPU:# device_map="auto")self.agent = CodeAgent(2 unmodified lines3456789101112132 unmodified linesfrom smolagents import TransformersModelclass GaiaAgent:def __init__(self, model_id: str = "google/gemma-2b-it"): # <-- CHANGE MODEL HEREself.llm_model = TransformersModel(model_id=model_id,task="text-generation",# device_map="auto" # Can keep this, accelerate will manage)self.agent = CodeAgent(
agent.py+3-6