perf: add outlink usage (#4691)

* update doc

* perf: add outlink usage

* feat: jina provider
This commit is contained in:
Archer
2025-04-28 10:41:32 +08:00
committed by GitHub
parent cc01aa4ab8
commit bf14506603
9 changed files with 76 additions and 21 deletions

View File

@@ -3,14 +3,14 @@ import { MongoOutLink } from './schema';
import { FastGPTProUrl } from '../../common/system/constants';
import { ChatHistoryItemResType } from '@fastgpt/global/core/chat/type';
export const addOutLinkUsage = async ({
export const addOutLinkUsage = ({
shareId,
totalPoints
}: {
shareId: string;
totalPoints: number;
}) => {
MongoOutLink.findOneAndUpdate(
return MongoOutLink.findOneAndUpdate(
{ shareId },
{
$inc: { usagePoints: totalPoints },