Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -9,7 +9,6 @@ headers = {
|
|
9 |
"Content-Type": "application/json"
|
10 |
}
|
11 |
|
12 |
-
# Updated sample log with frequencies
|
13 |
SAMPLE_LOG = """
|
14 |
2025-04-12 10:01 UTC | 40.7N, 74.0W | Frequency: 14.5 GHz | Signal Strength: 85% | Message: Routine check, systems OK.
|
15 |
2025-04-12 10:02 UTC | 40.8N, 74.1W | Frequency: 14.7 GHz | Signal Strength: 60% | Message: Noise detected, possible interference.
|
@@ -24,10 +23,10 @@ def analyze_log(log_text):
|
|
24 |
"messages": [
|
25 |
{
|
26 |
"role": "user",
|
27 |
-
"content": "Analyze this satellite radio log and summarize in bullet points:\n- Issues (e.g., low signal, noise, interference)\n- High-priority messages (e.g., emergencies)\n- Key details (
|
28 |
}
|
29 |
],
|
30 |
-
"max_completion_tokens":
|
31 |
"temperature": 0.5
|
32 |
}
|
33 |
try:
|
|
|
9 |
"Content-Type": "application/json"
|
10 |
}
|
11 |
|
|
|
12 |
SAMPLE_LOG = """
|
13 |
2025-04-12 10:01 UTC | 40.7N, 74.0W | Frequency: 14.5 GHz | Signal Strength: 85% | Message: Routine check, systems OK.
|
14 |
2025-04-12 10:02 UTC | 40.8N, 74.1W | Frequency: 14.7 GHz | Signal Strength: 60% | Message: Noise detected, possible interference.
|
|
|
23 |
"messages": [
|
24 |
{
|
25 |
"role": "user",
|
26 |
+
"content": "Analyze this satellite radio log and summarize in bullet points. Ensure frequencies are included in issues (if relevant) and key details:\n- Issues (e.g., low signal, noise, interference with frequency)\n- High-priority messages (e.g., emergencies)\n- Key details (coordinates, times, frequencies, signal strengths)\nLog:\n" + log_text
|
27 |
}
|
28 |
],
|
29 |
+
"max_completion_tokens": 400, # Increased to avoid cutoff
|
30 |
"temperature": 0.5
|
31 |
}
|
32 |
try:
|