--- title: Template Final Assignment emoji: 🕵🏻‍♂️ colorFrom: indigo colorTo: indigo sdk: gradio sdk_version: 5.25.2 python_version: 3.11 app_file: app.py pinned: false hf_oauth: true # optional, default duration is 8 hours/480 minutes. Max duration is 30 days/43200 minutes. hf_oauth_expiration_minutes: 480 --- # SmolaAgents Course Final Assignment This application is a demonstration of creating a robust agent system with monitoring and tracing capabilities. ## Features - **Multi-Agent System**: Uses a manager agent to orchestrate a specialized web agent. - **Advanced Models**: Leverages Qwen and DeepSeek models through HuggingFace's Inference API. - **Gradio Interface**: Simple UI for agent interaction and evaluation. - **Comprehensive Tracing**: Integrated observability through Langfuse and Phoenix. ## Tracing and Monitoring The application includes a modular tracing system that supports both: ### Langfuse - Cloud-based LLM observability platform - Configure with environment variables: - `LANGFUSE_PUBLIC_KEY` - `LANGFUSE_SECRET_KEY` - `LANGFUSE_HOST` (defaults to EU region) ### Arize Phoenix - Local, open-source LLM observability tool - Start the Phoenix UI with: ``` python -m phoenix.server.main serve ``` - View traces at http://localhost:6006 You can configure which tracing system to use: ```python # Use Langfuse (default) initialize_tracing(provider="langfuse") # Use Phoenix initialize_tracing(provider="phoenix") ``` Due to limitations in the OpenTelemetry integration, only one provider can be active at a time. Simply choose the provider that best meets your needs. Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference