File tree Expand file tree Collapse file tree 4 files changed +16
-4
lines changed
Expand file tree Collapse file tree 4 files changed +16
-4
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ title : Farmingo API
3+ emoji : 🌾
4+ colorFrom : green
5+ colorTo : blue
6+ sdk : docker
7+ pinned : false
8+ license : mit
9+ short_description : Farmingo API (FastAPI) deployed as a Docker Space.
10+ ---
11+
12+
113## Files
214
315* ` api.py ` — main FastAPI application. Must define ` app = FastAPI() ` at module level and expose the inference endpoint.
Original file line number Diff line number Diff line change 1919
2020# Internal imports
2121
22- from schema import (
22+ from api . schema import (
2323 CropPriceInput ,
2424 CropPriceOutput ,
2525 WeatherSoilData ,
2828 DiseaseResponse
2929)
3030
31- from authorization import validate_api_key
31+ from api . authorization import validate_api_key
3232
33- from logic import (
33+ from api . logic import (
3434 reverse_geocode_state ,
3535 fetch_open_meteo ,
3636 compute_features ,
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ <h2>Farmingo Crop Recommendation</h2>
1313 < pre id ="error " style ="color:red; "> </ pre >
1414
1515 < script >
16- const API_BASE = "http ://127.0.0.1:8000 " ;
16+ const API_BASE = "https ://swapcodes-farmingo.hf.space " ;
1717
1818 function log ( msg ) {
1919 document . getElementById ( "log" ) . textContent += msg + "\n" ;
You can’t perform that action at this time.
0 commit comments