diff --git a/.env.sample b/.env.sample new file mode 100644 index 0000000..6c9dea1 --- /dev/null +++ b/.env.sample @@ -0,0 +1,6 @@ +BASE_URL= +DB_HOST= +DB_PORT=5432 +DB_NAME= +DB_USER= +DB_PASSWORD= diff --git a/README.md b/README.md index a0b25d7..fea5a33 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,17 @@ -# NX AI +## Python NX AI -> FastAPI/Python/Postgres/tsvector. Production ready Python FastAPI/Postgres app for [NX](https://goldlabel.pro?s=nx-ai) AI services and more +> FastAPI/Python/Postgres/tsvector. +Open Source, production ready Python FastAPI/Postgres app for [NX](https://goldlabel.pro?s=python-nx-ai) -## Install & use +#### Use + +`uvicorn app.main:app` + +#### Install + +Create an environment file and add Postgres credentials etc + +`cp .env.sample .env` ```bash # Create and activate a virtual environment @@ -12,15 +21,10 @@ source venv/bin/activate # Windows: venv\Scripts\activate # Install dependencies pip install -r requirements.txt -# Start the development server +# Start development server uvicorn app.main:app --reload ``` -```sh -uvicorn app.main:app -pytest -``` - The API is at . [localhost](http://localhost:8000) | [Public RESTful API](https://nx-ai.onrender.com) @@ -33,13 +37,12 @@ The API is at . - **Pytest** — testing framework - **HTTPX / TestClient** - FastAPI automatically generates interactive documentation: - Swagger UI: - ReDoc: -## Structure +#### Structure ``` app/ @@ -55,7 +58,7 @@ requirements.txt ``` -## Endpoints +#### Endpoints | Method | Path | Description | |--------|-----------|---------------------------------| diff --git a/app/__init__.py b/app/__init__.py index 95cf70f..a3388b2 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -1,4 +1,4 @@ """NX AI - FastAPI/Python/Postgres/tsvector""" # Current Version -__version__ = "1.0.4" +__version__ = "1.0.6" diff --git a/requirements.txt b/requirements.txt index c06408c..432be90 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,3 +4,4 @@ httpx>=0.27.0 pytest>=8.1.0 python-dotenv>=1.0.0 psycopg2-binary>=2.9.0 +python-multipart>=0.0.20