mirror of
https://github.com/AIDotNet/AntSK.git
synced 2026-02-25 03:30:26 +08:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
06cdbb14d0 | ||
|
|
115e12257b | ||
|
|
533a47566b | ||
|
|
51ec2db3c3 | ||
|
|
3aa76e0662 | ||
|
|
755d2c2d4f | ||
|
|
bd27048237 | ||
|
|
01063f2d49 | ||
|
|
5a4f038da1 | ||
|
|
dd6e1a6d54 | ||
|
|
52e20396ad | ||
|
|
a8f48929e7 | ||
|
|
ae89fb5ec7 |
15
README.md
15
README.md
@@ -86,7 +86,7 @@ version: '3.8'
|
||||
services:
|
||||
antsk:
|
||||
container_name: antsk
|
||||
image: registry.cn-hangzhou.aliyuncs.com/AIDotNet/antsk:v0.5.0
|
||||
image: registry.cn-hangzhou.aliyuncs.com/AIDotNet/antsk:v0.6.0
|
||||
ports:
|
||||
- 5000:5000
|
||||
networks:
|
||||
@@ -204,13 +204,14 @@ This warehouse follows the [AntSK License](https://github.com/AIDotNet/AntSK?tab
|
||||
|
||||
This project follows the Apache 2.0 agreement, in addition to the following additional terms
|
||||
|
||||
1. This project can be used for commercial purposes, but it has the right to prohibit you from using it if it violates the following provisions
|
||||
|
||||
2. Without authorization, you are not allowed to modify AntSK's logo and title information
|
||||
1. **Free Commercial Use**: Users can use the software for commercial purposes without modifying the code.
|
||||
2. **Commercial License Required**: A commercial license is required if any of the following conditions are met:
|
||||
1. You modify, develop, or alter the software, including but not limited to changes to the application name, logo, code, or functionality.
|
||||
2. You provide multi-tenant services to enterprise customers with 10 or more users.
|
||||
3. You pre-install or integrate the software into hardware devices or products and bundle it for sale.
|
||||
4. You are engaging in large-scale procurement for government or educational institutions, especially involving security, data privacy, or other sensitive requirements.
|
||||
|
||||
4. Without authorization, you are not allowed to modify the copyright information at the bottom of the page
|
||||
|
||||
6. If you need authorization, you can contact WeChat: **xuzeyu91**
|
||||
3. If you need authorization, you can contact WeChat: **xuzeyu91**
|
||||
|
||||
If you plan to use AntSK in commercial projects, you need to ensure that you follow the following steps:
|
||||
|
||||
|
||||
15
README.zh.md
15
README.zh.md
@@ -100,7 +100,7 @@ version: '3.8'
|
||||
services:
|
||||
antsk:
|
||||
container_name: antsk
|
||||
image: registry.cn-hangzhou.aliyuncs.com/AIDotNet/antsk:v0.3.1
|
||||
image: registry.cn-hangzhou.aliyuncs.com/AIDotNet/antsk:v0.6.0
|
||||
ports:
|
||||
- 5000:5000
|
||||
networks:
|
||||
@@ -215,13 +215,14 @@ DB我使用的是CodeFirst模式,只要配置好数据库链接,表结构是
|
||||
|
||||
除以下附加条款外,该项目遵循Apache 2.0协议
|
||||
|
||||
1. 本项目可以用于商业目的,但如果违反以下规定,它有权禁止您使用
|
||||
1. **免费商用**:用户在不修改代码的情况下,可以免费用于商业目的。
|
||||
2. **商业授权**:如果您满足以下任意条件之一,需取得商业授权:
|
||||
1. 对本软件进行二次修改、开发(包括但不限于修改应用名称、logo、代码以及功能)。
|
||||
2. 为企业客户提供多租户服务,且该服务支持 10 人或以上的使用。
|
||||
3. 预装或集成到硬件设备或产品中进行捆绑销售。
|
||||
4. 政府或教育机构的大规模采购项目,特别是涉及安全、数据隐私等敏感需求时。
|
||||
|
||||
2. 未经授权,您不允许修改AntSK的徽标和标题信息
|
||||
|
||||
3. 未经授权,您不能修改页面底部的版权信息
|
||||
|
||||
4. 如果您需要授权,可以联系微信:xuzeyu91
|
||||
3. 如果您需要授权,可以联系微信:xuzeyu91
|
||||
|
||||
如果您打算在商业项目中使用AntSK,您需要确保遵守以下步骤:
|
||||
|
||||
|
||||
@@ -3,9 +3,9 @@ version: '3.8'
|
||||
services:
|
||||
antsk:
|
||||
container_name: antsk
|
||||
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.5.5
|
||||
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.6.0
|
||||
# 如果需要pytorch环境需要使用下面这个镜像,镜像比较大
|
||||
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.5.5
|
||||
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.6.0
|
||||
ports:
|
||||
- 5000:5000
|
||||
networks:
|
||||
|
||||
@@ -16,7 +16,7 @@ services:
|
||||
- 18889:18889
|
||||
restart: unless-stopped
|
||||
antskpg:
|
||||
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/pg:v0.5.0
|
||||
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/pg:v0.5.0
|
||||
container_name: antskpg
|
||||
restart: always
|
||||
ports: # 生产环境建议不要暴露
|
||||
@@ -32,9 +32,9 @@ services:
|
||||
- ./pg/data:/var/lib/postgresql/data
|
||||
antsk:
|
||||
container_name: antsk
|
||||
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.5.5
|
||||
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.6.0
|
||||
# 如果需要pytorch环境需要使用下面这个镜像,镜像比较大
|
||||
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.5.5
|
||||
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.6.0
|
||||
ports:
|
||||
- 5000:5000
|
||||
networks:
|
||||
|
||||
@@ -10,6 +10,6 @@ namespace AntSK.Domain.Domain.Interface
|
||||
public interface IOllamaService
|
||||
{
|
||||
public event LogMessageHandler LogMessageReceived;
|
||||
Task StartOllama(string modelName);
|
||||
Task OllamaPull(string modelName);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace AntSK.Domain.Domain.Service
|
||||
LogMessageReceived?.Invoke(message);
|
||||
}
|
||||
|
||||
public async Task StartOllama(string modelName)
|
||||
public async Task OllamaPull(string modelName)
|
||||
{
|
||||
Console.OutputEncoding = Encoding.UTF8;
|
||||
var cmdTask = Task.Factory.StartNew(() =>
|
||||
@@ -35,7 +35,7 @@ namespace AntSK.Domain.Domain.Service
|
||||
StartInfo = new ProcessStartInfo
|
||||
{
|
||||
FileName = "ollama",
|
||||
Arguments = "run " + modelName,
|
||||
Arguments = "pull " + modelName,
|
||||
UseShellExecute = false,
|
||||
RedirectStandardOutput = true,
|
||||
RedirectStandardError = true,
|
||||
|
||||
@@ -9,4 +9,4 @@ snowflake-arctic-embed:137m
|
||||
snowflake-arctic-embed:335m
|
||||
bge-m3
|
||||
bge-large:335m
|
||||
paraphrase-multilingual:278m
|
||||
paraphrase-multilingual:278m
|
||||
@@ -108,4 +108,4 @@ llama-pro:instruct
|
||||
everythinglm:13b
|
||||
llava-phi3:3.8b
|
||||
mistrallite:7b
|
||||
notus:7b
|
||||
notus:7b
|
||||
|
||||
@@ -170,6 +170,8 @@
|
||||
</Select>
|
||||
</InputGroup>
|
||||
<a href="https://ollama.com/library" target="_blank">获取更多模型</a>
|
||||
<br/>
|
||||
<span>可以在OllamaModelList.txt中进行修改</span>
|
||||
</FormItem>
|
||||
<FormItem Label="请求地址" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
|
||||
<Input Placeholder="http://localhost:11434/" @bind-Value="@context.EndPoint" AutoComplete="false" />
|
||||
@@ -179,7 +181,7 @@
|
||||
</FormItem>
|
||||
<FormItem Label="Ollama服务" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
|
||||
<InputGroup>
|
||||
<Button Type="primary" OnClick="StartOllamaService">启动</Button>
|
||||
<Button Type="primary" OnClick="StartOllamaService">下载模型</Button>
|
||||
</InputGroup>
|
||||
</FormItem>
|
||||
}
|
||||
@@ -200,6 +202,8 @@
|
||||
</Select>
|
||||
</InputGroup>
|
||||
<a href="https://ollama.com/library" target="_blank">获取更多模型</a>
|
||||
<br />
|
||||
<span>可以在OllamaEmbeddingModelList.txt中进行修改</span>
|
||||
</FormItem>
|
||||
<FormItem Label="请求地址" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
|
||||
<Input Placeholder="http://localhost:11434/" @bind-Value="@context.EndPoint" AutoComplete="false" />
|
||||
@@ -209,7 +213,7 @@
|
||||
</FormItem>
|
||||
<FormItem Label="Ollama服务" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
|
||||
<InputGroup>
|
||||
<Button Type="primary" OnClick="StartOllamaService">启动</Button>
|
||||
<Button Type="primary" OnClick="StartOllamaService">下载模型</Button>
|
||||
</InputGroup>
|
||||
</FormItem>
|
||||
}
|
||||
@@ -220,9 +224,8 @@
|
||||
@bind-Value="@context.ModelName"
|
||||
ValueProperty="c=>c"
|
||||
LabelProperty="c=>c">
|
||||
</Select>
|
||||
</Select>
|
||||
</FormItem>
|
||||
|
||||
<FormItem Label="Python路径" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
|
||||
<Popover ContentTemplate="@_content" Title="提示" Style="width:100%">
|
||||
<Input Placeholder="D:\Programs\Python\Python311\python311.dll" @bind-Value="@context.EndPoint" AutoComplete="false" />
|
||||
|
||||
@@ -317,7 +317,7 @@ namespace AntSK.Pages.Setting.AIModel
|
||||
|
||||
_ollamaService.LogMessageReceived -= CmdLogHandler;
|
||||
_ollamaService.LogMessageReceived += CmdLogHandler;
|
||||
_ollamaService.StartOllama(_aiModel.ModelName);
|
||||
_ollamaService.OllamaPull(_aiModel.ModelName);
|
||||
}
|
||||
|
||||
private void OnCancelPipInstall()
|
||||
|
||||
Reference in New Issue
Block a user