Spaces:
Sleeping
Sleeping
|
Download README.md from abstikatech/AbstikaAI: direct link, hf CLI and curl.
- Browser
- Download file 1.43 kB
-
https://huggingface.co/spaces/abstikatech/AbstikaAI/resolve/main/README.md
- Command line
-
hf download hf://spaces/abstikatech/AbstikaAI/README.md
-
curl -L -o README.md https://huggingface.co/spaces/abstikatech/AbstikaAI/resolve/main/README.md
1.43 kB
metadata
title: AbstikaTestLLM
emoji: 🐨
colorFrom: blue
colorTo: pink
sdk: docker
pinned: false
license: mit
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
FastAPI Sample Project
This is a simple FastAPI application with sample GET and POST endpoints for testing.
Features
- GET /: Returns a greeting message.
- POST /items/: Accepts a JSON body with
nameanddescriptionfields and returns the item.
Requirements
Installation & Running Locally
- Install dependencies:
pip install -r requirements.txt - Start the server:
uvicorn main:app --reload - Open your browser at http://127.0.0.1:8000
API Examples
GET /
curl http://127.0.0.1:8000/
POST /items/
curl -X POST "http://127.0.0.1:8000/items/" -H "Content-Type: application/json" -d '{"name": "Sample Item", "description": "A test item."}'
Docker Usage
- Build the Docker image:
docker build -t fastapi-sample . - Run the container:
docker run -p 7860:7860 fastapi-sample - The app will be available at http://localhost:7860
For more information, see the FastAPI documentation.