Spaces:
Sleeping
Sleeping
sync
Browse files1 unmodified line234567559 unmodified lines567568569570571572573574575671 unmodified lines12471248124912501251125212531 unmodified lineSmolagents-based GAIA Evaluation AgentUses CodeAgent with custom tools for web search, file processing, and calculationsSupports both local and remote models"""import os559 unmodified linesos.environ.pop("SAMBANOVA_API_KEY", None)os.environ.pop("FIREWORKS_API_KEY", None)return InferenceClientModel(model_id=self.model_config["llm_model"],token=get_hf_token())except Exception as e:671 unmodified linesif len(query) > 250:print(f"⚠️ Query too long ({len(query)} chars), truncating...")# Extract the most important keywordsimport rewords = query.split()# Keep only the first few key words to stay under limittruncated_query = " ".join(words[:10]) # Usually enough1 unmodified line2345678559 unmodified lines568569570571572573574575576577578579580581671 unmodified lines1253125412551256125712581 unmodified lineSmolagents-based GAIA Evaluation AgentUses CodeAgent with custom tools for web search, file processing, and calculationsSupports both local and remote modelsVersion: 2.0.1-hf-only"""import os559 unmodified linesos.environ.pop("SAMBANOVA_API_KEY", None)os.environ.pop("FIREWORKS_API_KEY", None)print(f"🔒 FORCING HF-INFERENCE PROVIDER (v2.0.1)")print(f"🔒 Model: {self.model_config['llm_model']}")print(f"🔒 Provider: hf-inference (FORCED)")return InferenceClientModel(model_id=self.model_config["llm_model"],token=get_hf_token(),provider="hf-inference")except Exception as e:671 unmodified linesif len(query) > 250:print(f"⚠️ Query too long ({len(query)} chars), truncating...")# Extract the most important keywordswords = query.split()# Keep only the first few key words to stay under limittruncated_query = " ".join(words[:10]) # Usually enough
hf_agent.py+7-2