淘宝客网站建设多少钱,广告型网站,百度统计代码,自己做一个商城网站怎么做前言
deepseekAI助手。它具有聊天机器人功能#xff0c;可以与用户进行自然语言交互#xff0c;回答问题、提供建议和帮助解决问题。DeepSeek 的特点包括#xff1a;
强大的语言理解能力#xff1a;能够理解和生成自然语言#xff0c;与用户进行流畅的对话。多领域知识可以与用户进行自然语言交互回答问题、提供建议和帮助解决问题。DeepSeek 的特点包括
强大的语言理解能力能够理解和生成自然语言与用户进行流畅的对话。多领域知识涵盖科技、文化、历史等多个领域的知识能够回答各种类型的问题。持续学习系统会不断学习和优化提高回答的准确性和相关性。安全隐私注重用户数据的安全和隐私保护遵守相关法律法规。
DeepSeek 旨在通过先进的人工智能技术为用户提供高效、便捷的服务提升工作和生活的效率。
创建一键部署deepseek自动化脚本
自动化脚本系统支持 Centos/Redhaht/RockyLinux/AlmaLinux/OracleLinux 8,9,10ubuntu(20,22,24)debian(11,12)suse(12,15)ollama 命令文档参考参考2参考3ollama download WindowsLinuxmac所有下载deepseek Models 官网地址Chatbox 连接deepseek api工具下载ollama 端口11434 需要自定义更改28行变量即可28-32行环境变量需要自定义的更改ollama 安装目录/opt/ollamadeepseek 模型下载目录位置/opt/ollama/modelsollama 服务位置/usr/lib/systemd/system/ollama.service环境变量位置~/.bashrc
vim /deepseek_install.sh
#!/bin/bash
# -*- coding: utf-8 -*-
# Author: CIASM
# update 2025/02/21!
# 系统支持 Centos/Redhaht/RockyLinux/AlmaLinux/OracleLinux 8,9,10ubuntu(20,22,24)debian(11,12)suse(12,15)# ollama文档参考
https://github.com/ollama/ollama
https://ollama.readthedocs.io/quickstart/
https://ollama.cadn.net.cn/quickstart.html#google_vignette# ollama download
https://ollama.com/download/windows
https://ollama.com/download/mac
https://ollama.com/download/linux
https://github.com/ollama/ollama/releases#deepseek Models
https://ollama.com/library# download chatboxai
https://chatboxai.app/zh#download
!# variable
OLLAMA_PORT11434
ollama_prefix/opt/ollama
ollama_contentsollama
ollama_modelsmodels
opt_prefix/opt# ollama download variable
ollama_urlhttps://github.com/ollama/ollama/releases/download/v0.5.11
ollama_tgzollama-linux-amd64.tgzinstall_basics() {# Check if the script is being run as root
if [ $(id -u) ! 0 ]; thenecho This script must be run as root.exit 1
fiif [[ -f /etc/os-release ]]; thenOS$(cat /etc/*release* | grep ^ID | cut -d -f2- | tr -d )VERSION$(awk -F /VERSION_ID/{print $2} /etc/os-release | tr -d ) #VERSION$( grep -oE VERSION_ID[^] /etc/os-release | cut -d -f2) elseecho -e \033[31mThis script only supports $OS $VERSION...\033[0mexit 1
fi# Check the ollama version
if ! [ -d $ollama_prefix ]; thenecho -e \033[32m Installing ollama for $OS $VERSION...\033[0mcase $VERSION in# CentOS/RedHat/oracle/RockLinux/AlmaLinux 8 install 8|8.1|8.2|8.3|8.4|8.5|8.6|8.7|8.8|8.9|8.10)echo Installing basics...yum install -y http://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpmyum install -y net-tools wget curlecho firewall prometheus port configfirewall_port_up# install ollamainstall_ollama;;# CentOS/RedHat/oracle/RockLinux/AlmaLinux 9 install9.0|9.1|9.2|9.3|9.4|9.5|9.6|9.7|9.8|9.9|9.10) echo Installing basics...yum install -y http://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpmyum install -y net-tools wget curlecho firewall prometheus port configfirewall_port_up# install ollamainstall_ollama;;# CentOS/RedHat/oracle/RockLinux/AlmaLinux 10 install10.0|10.1|10.2|10.2|10.3|10.4|10.5|10.6|10.7|10.8|10.9|10.10) echo Installing basics...yum install -y http://dl.fedoraproject.org/pub/epel/epel-release-latest-10.noarch.rpmyum install -y net-tools wget curlecho firewall prometheus port configfirewall_port_up# install ollamainstall_ollama;;# openEuler 20222324 Linux install20.03|22.03|23.03|24.03) echo add epel repoopenEuler_epel_repoecho firewall prometheus port configfirewall_port_upecho Installing basics...yum install -y net-tools wget curl# install ollamainstall_ollama;;# ubuntu 20,21,22,23,24 Linux install20.04|21.04|22.04|23.04|24.04)echo Disable system standbysystemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.targetecho Pop-up blocksed -i $ a\export DEBIAN_FRONTENDnoninteractive /etc/profilesource /etc/profileecho install Base Packageapt-get updateapt-get install -y firewalld curl net-tools vimapt-get install -y git wgetecho firewall prometheus port configfirewall_port_up# install ollamainstall_ollama;;# Debian 10,11.1210|11|12)echo Disable system standbysystemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.targetecho Pop-up blocksed -i $ a\export DEBIAN_FRONTENDnoninteractive /etc/profilesource /etc/profileecho install Base Packageapt-get updateapt-get install -y firewalld curl net-tools vimapt-get install -y git wget# install ollamainstall_ollama;;# SUSE 12 install12.?)echo Installing basics...SUSEConnect -p sle-sdk/12.5/x86_64zypper in -y curl net-toolsecho firewall sql server portsed -i /^FW_SERVICES_EXT_TCP/ s/\(.*\)/\1 $OLLAMA_PORT/ /etc/sysconfig/SuSEfirewall2systemctl restart SuSEfirewall2.service# install ollamainstall_ollama;;# SUSE 15 install15.?)echo Installing basics...zypper install -y net-tools net-tools-deprecatedrpm -ivh https://ftp.lysator.liu.se/pub/opensuse/distribution/leap/15.6/repo/oss/x86_64/net-tools-deprecated-2.0git20170221.479bb4a-3.11.x86_64.rpmzypper in -y firewalld curl echo firewall ollama port configfirewall_port_up# install ollamainstall_ollama;;*)echo -e \033[31m Unsupported $OS $VERSION...\033[0m exit 1;;
esacecho -e \033[32m ollama for $OS $VERSION successfully installed...\033[0m
elseecho -e \033[33m ollama for $OS $VERSION already installed...\033[0m
fi}# Obtain the system version number
VERSION_ID$(cat /etc/os-release | grep ^VERSION_ID | cut -d -f2 | tr -d )# openEuler 20.03 22.03 23.03 24.03 add epel 8,9
openEuler_epel_repo (){if [[ $VERSION_ID ~ ^2[2-4]\.03$ ]]; thenrepo_version9
elif [[ $VERSION_ID 20.03 ]]; thenrepo_version8
fiecho openEuler add epel repo
cat EOF/etc/yum.repos.d/epel.repo
[epel]
nameepel
baseurlhttps://dl.fedoraproject.org/pub/epel/${repo_version}/Everything/x86_64/
enabled1
gpgcheck0
priority1
EOF
}# firewall port up
firewall_port_up (){
echo firewall ollama port
systemctl enable --now firewalld
firewall-cmd --zonepublic --add-port$OLLAMA_PORT/tcp --permanent firewall-cmd --reload
}# install ollama
install_ollama (){echo download ollama
wget -N -P $opt_prefix $ollama_url/$ollama_tgzecho Unzip installation ollama
mkdir -p $opt_prefix/{$ollama_contents,$ollama_models}
tar -zxf $opt_prefix/$ollama_tgz -C $ollama_prefix
rm -rf $opt_prefix/$ollama_tgzecho ollama environment variable
echo export PATH$ollama_prefix/bin:$PATH ~/.bashrc
echo export PATH$ollama_prefix/lib:$PATH ~/.bashrc
echo export OLLAMA_HOST0.0.0.0:$OLLAMA_PORT ~/.bashrc
source ~/.bashrcecho create ollama server
cat EOF/usr/lib/systemd/system/ollama.service
[Unit]
DescriptionOllama Service
Afternetwork-online.target[Service]
EnvironmentOLLAMA_HOST0.0.0.0:$OLLAMA_PORT
EnvironmentOLLAMA_ORIGINS*
EnvironmentOLLAMA_MODELS$ollama_prefix/models
ExecStart$ollama_prefix/bin/ollama serve
Userroot
Grouproot
Restartalways
RestartSec3[Install]
WantedBydefault.target
EOFecho start ollama
systemctl daemon-reload
systemctl start ollama
systemctl enable ollamaecho download deepseek model
$ollama_prefix/bin/ollama run deepseek-r1:8b
}main (){install_basics
}main
执行一键部署deepseek
ln -sf bash /bin/sh 切换bash
bash /deepseek_install.sh
ollama api访问接口测试
正式环境不要对外开放 chatbox 连接deepseek
chatbox 下载有很多的你也可以尝试使用其它的方式接入模型提供方ollama apiapi 域名你的主机IP和端口模型你部署的模型选择 与deepseek ai 对话