Spaces:
Sleeping
Sleeping
File size: 738 Bytes
75c7554 71a770c 75c7554 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | import axios from 'axios'
const api = axios.create({
baseURL: '/api',
timeout: 600000, // 10 min – long evaluations
})
export const getHealth = () => api.get('/health').then(r => r.data)
export const getModels = () => api.get('/models').then(r => r.data.models)
export const getTasks = () => api.get('/tasks').then(r => r.data.tasks)
export const runEpisode = (body) => api.post('/run-episode', body).then(r => r.data)
export const runEvaluate = (body) => api.post('/evaluate', body).then(r => r.data)
export const runLLM = (evalResult, provider = "GEMINI", model_name = null) =>
api.post('/llm-analyze', { evaluation: evalResult, provider, model_name }).then(r => r.data)
export default api
|