Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
# Professor AI Feynman: A Multi-Agent Tool for Learning Anything the Feynman way.
|
2 |
-
# Jaward Sesay - Microsoft AI Agent Hackathon Submission
|
3 |
import os
|
4 |
import json
|
5 |
import re
|
@@ -57,7 +57,7 @@ class Slide(BaseModel):
|
|
57 |
class SlidesOutput(BaseModel):
|
58 |
slides: list[Slide]
|
59 |
|
60 |
-
# Search
|
61 |
def search_web(query: str, serpapi_key: str) -> str:
|
62 |
try:
|
63 |
params = {
|
@@ -1206,8 +1206,6 @@ js_code = """
|
|
1206 |
with gr.Blocks(
|
1207 |
title="Agent Feynman",
|
1208 |
css="""
|
1209 |
-
h1 {text-align: center}
|
1210 |
-
h2 {text-align: center}
|
1211 |
#lecture-container {font-family: 'Times New Roman', Times, serif;}
|
1212 |
#slide-content {font-size: 48px; line-height: 1.2;}
|
1213 |
#form-group {box-shadow: 0 0 2rem rgba(0, 0, 0, .14) !important; border-radius: 30px; font-weight: 900; color: #000; background-color: white;}
|
@@ -1230,11 +1228,11 @@ with gr.Blocks(
|
|
1230 |
lecture_type = gr.Dropdown(["Conference", "University", "High school"], label="Audience", value="University")
|
1231 |
api_service = gr.Dropdown(
|
1232 |
choices=[
|
|
|
1233 |
"OpenAI-gpt-4o-2024-08-06",
|
1234 |
"Anthropic-claude-3-sonnet-20240229",
|
1235 |
"Google-gemini-1.5-flash",
|
1236 |
"Ollama-llama3.2",
|
1237 |
-
"Azure AI Foundry"
|
1238 |
],
|
1239 |
label="Model",
|
1240 |
value="Google-gemini-1.5-flash"
|
|
|
1 |
# Professor AI Feynman: A Multi-Agent Tool for Learning Anything the Feynman way.
|
2 |
+
# Jaward Sesay - Microsoft AI Agent Hackathon Submission April 2025
|
3 |
import os
|
4 |
import json
|
5 |
import re
|
|
|
57 |
class SlidesOutput(BaseModel):
|
58 |
slides: list[Slide]
|
59 |
|
60 |
+
# Search tool using SerpApi
|
61 |
def search_web(query: str, serpapi_key: str) -> str:
|
62 |
try:
|
63 |
params = {
|
|
|
1206 |
with gr.Blocks(
|
1207 |
title="Agent Feynman",
|
1208 |
css="""
|
|
|
|
|
1209 |
#lecture-container {font-family: 'Times New Roman', Times, serif;}
|
1210 |
#slide-content {font-size: 48px; line-height: 1.2;}
|
1211 |
#form-group {box-shadow: 0 0 2rem rgba(0, 0, 0, .14) !important; border-radius: 30px; font-weight: 900; color: #000; background-color: white;}
|
|
|
1228 |
lecture_type = gr.Dropdown(["Conference", "University", "High school"], label="Audience", value="University")
|
1229 |
api_service = gr.Dropdown(
|
1230 |
choices=[
|
1231 |
+
"Azure AI Foundry",
|
1232 |
"OpenAI-gpt-4o-2024-08-06",
|
1233 |
"Anthropic-claude-3-sonnet-20240229",
|
1234 |
"Google-gemini-1.5-flash",
|
1235 |
"Ollama-llama3.2",
|
|
|
1236 |
],
|
1237 |
label="Model",
|
1238 |
value="Google-gemini-1.5-flash"
|