Spaces:
Runtime error
Runtime error
File size: 933 Bytes
af098e9 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
GNU nano 8.3 ossy1.py
import gradio as gr
import requests
import json
import os
from dotenv import load_dotenv
# Load environment variables for API key
load_dotenv()
# Get API key from environment variables - this is now hidden from users
OPENROUTER_API_KEY = os.environ.get("OPENROUTER_API_KEY", "")
if not OPENROUTER_API_KEY:
print("Warning: OPENROUTER_API_KEY not found in environment variables.")
print("Please set it before running the app or the app won't function.")
def answer_bible_question(question, temperature=0.7, max_tokens=1000):
"""
Send a Bible question to the DeepSeek model via OpenRouter API
and return the response.
"""
[ Read 176 lines ]
^G Help ^O Write Out ^F Where Is ^K Cut ^T Execute ^C Location
^X Exit ^R Read File ^\ Replace ^U Paste ^J Justify ^/ Go To Line
|