Skip to content

programmerplatmerah/deepseek-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

Deepseek API Tutorial

This repository provides a simple guide to setting up and using the Deepseek API with Ollama, LangChain, and FastAPI.

Prerequisites

Before you begin, ensure you have the following installed:

  • Python (3.8+ recommended)
  • Pip (Python package manager)

Installation Steps

1. Install Ollama

Download and install Ollama from here.

2. Pull the Deepseek Model

Open a terminal or command prompt and run:

ollama pull deepseek-r1:8b

3. Install Required Python Packages

Run the following commands to install necessary dependencies:

pip install -qU langchain-openai
pip install -qU langchain-ollama
pip install -qU fastapi

4. Run the FastAPI Server

Start the FastAPI server by running:

uvicorn main:app --reload

5. Test the API

Open your browser and navigate to:

http://127.0.0.1:8000/translate/{word_to_translate}

Replace {word_to_translate} with the English word you want to translate.

License

This project is open-source and available under the MIT License.

Contributing

Feel free to fork this repository and submit pull requests with improvements or bug fixes.

Contact

For questions or support, open an issue on GitHub or contact me at ig @programmerplatmerah

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages