Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Houloude9IOfficial/OllamaSearchAPI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📚 Ollama Library API Proxy

A simple proxy API that fetches, parses, and caches data from ollama.com.

🔧 Documentation

🕒 Note: All responses are cached for 6 hours by default.


Setup Instructions

  1. Rename the environment file
    Rename example.env to .env.

  2. Configure your environment
    Open the .env file and customize the values as needed, such as:

    • API URL
    • Cache duration
    • Enable static website mode
  3. Install dependencies
    Run the following command to install all required Python packages:

    pip install -r requirements.txt
  4. Run the API

    ollama_library_api.py

    Or if you're getting errors:

    uvicorn ollama_library_api:app --host 0.0.0.0 --port 5115 --reload

Example .env

# CODE version of the app
CODE_VERSION=1.3.0_Release

# Base URL of Ollama
OLLAMA_COM_BASE_URL=https://ollama.com

# Your API URL
CURRENT_BASE_URL=https://example.com

# If running a static website
STATIC_WEBSITE=False

# Cache duration in hours
CACHE_EXPIRE_AFTER=6

🔍 Example Endpoints

📊 Library Namespace


👤 User-Specific Queries


🔎 Search & Model Info


🧱 Blobs & Digests


🧑 Credits

💡 Tip: Use these endpoints to build your own Ollama-powered dashboards, tools, or integrations effortlessly.