Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Hoshinonyaruko/Gensokyo-llm
/ functions
Functions
763 in github.com/Hoshinonyaruko/Gensokyo-llm
⨍
Functions
763
◇
Types & classes
203
↓ 286 callers
Function
Printf
(format string, v ...interface{})
fmtf/fmtf.go:80
↓ 81 callers
Method
Close
()
server/server.go:240
↓ 64 callers
Function
GetSettingFromFilename
GetSettingFromFilename 用于获取配置文件中的特定设置
prompt/prompt.go:259
↓ 59 callers
Function
Sprintf
(format string, v ...interface{})
fmtf/fmtf.go:100
↓ 58 callers
Function
ErrorWrapper
(err error, code string, statusCode int)
relay/adaptor/openai/util.go:5
↓ 41 callers
Function
Fprintf
Fprintf 包装了fmt.Fprintf,并将格式化的消息同时记录到日志。 w 是写入对象,应该实现了io.Writer接口(如http.ResponseWriter)。 format 是格式字符串,v 是对应的参数列表。
fmtf/fmtf.go:89
↓ 38 callers
Function
Errorf
Errorf 创建一个错误消息并记录该消息到日志文件。 它返回一个包含格式化错误信息的error,如果格式字符串中包含了 %w 指令,则还会包装一个错误。
fmtf/fmtf.go:109
↓ 35 callers
Function
GetGroupContext
获取GroupContext
config/config.go:1213
↓ 32 callers
Method
addMessage
(msg structs.Message)
applogic/app.go:24
↓ 31 callers
Function
GetUsePrivateSSE
获取UsePrivateSSE
config/config.go:884
↓ 30 callers
Function
Println
(v ...interface{})
fmtf/fmtf.go:74
↓ 27 callers
Function
GetuseSse
获取useSse
config/config.go:100
↓ 22 callers
Function
GetMessagesExcludingSystem
返回除了 "system" 角色之外的所有消息 GetMessagesExcludingSystem returns a list of messages that are not of "system" role, randomly selecting from options separated
prompt/prompt.go:205
↓ 22 callers
Function
SysError
(s string)
common/logger/logger.go:55
↓ 20 callers
Function
GetPromptkeyboard
GetPromptkeyboard 获取Promptkeyboard,如果超过3个成员则随机选择3个
config/config.go:894
↓ 19 callers
Function
SendGroupMessage
(groupID int64, userID int64, message string, selfid string, promptstr string)
utils/utils.go:258
↓ 18 callers
Function
CheckWordOUT
改写后的函数,接受word参数,并返回处理结果
acnode/acnode.go:354
↓ 17 callers
Function
GetPromptMarksLength
获取 PromptMarksLength
config/config.go:1667
↓ 17 callers
Function
SendPrivateMessage
(UserID int64, message string, selfid string, promptstr string)
utils/utils.go:1437
↓ 15 callers
Function
GetHttpPaths
获取HttpPaths
config/config.go:228
↓ 15 callers
Function
SendPrivateMessageSSE
(UserID int64, message structs.InterfaceBody, promptstr string, selfid string)
utils/utils.go:1736
↓ 14 callers
Function
GetMemoryListMD
获取MemoryListMD
config/config.go:1317
↓ 14 callers
Function
GetMemoryLoadCommand
获取MemoryLoadCommand
config/config.go:1267
↓ 14 callers
Function
SendGroupMessageSP
(groupID string, userID string, message string, selfid string, promptstr string)
utils/utils.go:368
↓ 14 callers
Function
SendPrivateMessageSP
(UserID string, message string, selfid string, promptstr string)
utils/utils.go:1544
↓ 14 callers
Function
SendPrivateMessageSSESP
(UserID string, message structs.InterfaceBody, promptstr string, selfid string)
utils/utils.go:1846
↓ 13 callers
Function
GenerateUUID
()
utils/utils.go:117
↓ 13 callers
Function
GetBaseURLByUserID
GetBaseURLByUserID 通过 user_id 获取 baseURL
utils/utils.go:110
↓ 13 callers
Function
GetHttpPath
获取getHttpPath
config/config.go:154
↓ 13 callers
Function
GetPathToken
获取PathToken
config/config.go:1579
↓ 13 callers
Function
GetPrintHanming
获取PrintHanming
config/config.go:1025
↓ 12 callers
Function
ConvertTraditionalToSimplified
ConvertTraditionalToSimplified converts traditional Chinese to simplified Chinese.
utils/t2s.go:27
↓ 12 callers
Function
GetSensitiveModeType
获取SensitiveModeType
config/config.go:790
↓ 11 callers
Method
FetchCustomRecord
(userID int64, fields ...string)
applogic/promptstr.go:66
↓ 11 callers
Method
Init
()
relay/adaptor/interface.go:12
↓ 11 callers
Method
InsertCustomTableRecord
(userID int64, promptStr string, promptStrStat int, strs ...string)
applogic/promptstr.go:13
↓ 11 callers
Method
getHistory
(conversationID, parentMessageID string)
applogic/app.go:425
↓ 10 callers
Function
GetEnhancedQA
获取 EnhancedQA
config/config.go:1735
↓ 10 callers
Function
GetNoEmoji
获取NoEmoji
config/config.go:3445
↓ 10 callers
Function
GetRestoreCommand
获取RestoreCommand
config/config.go:874
↓ 10 callers
Function
Int
(env string, defaultValue int)
common/env/helper.go:15
↓ 10 callers
Function
RemoveEmojis
RemoveEmojis 函数用于移除文本中的所有 emoji 表情符号
utils/utils.go:3288
↓ 10 callers
Function
ReplaceTextOut
ReplaceTextOut 使用给定的替换对列表对文本进行替换
utils/utils.go:3268
↓ 10 callers
Function
removeTrailingCRLFs
removeTrailingCRLFs 移除字符串末尾的所有CRLF换行符
utils/utils.go:1969
↓ 9 callers
Function
Contains
contains 检查一个字符串切片是否包含一个特定的字符串
utils/utils.go:155
↓ 9 callers
Function
GetPort
获取GetPort
config/config.go:134
↓ 9 callers
Function
GetTimestamp
()
common/helper/time.go:8
↓ 9 callers
Function
IPWhiteList
获取IPWhiteList
config/config.go:218
↓ 9 callers
Function
IsSelfIDExists
IsSelfIDExists 检查一个 ID 是否存在于全局切片中
server/server.go:57
↓ 9 callers
Function
SendMessageBySelfID
发信息给client
server/server.go:223
↓ 8 callers
Function
GetApiType
获取Api类型
config/config.go:276
↓ 8 callers
Function
GetHunyuanType
获取HunyuanType
config/config.go:646
↓ 8 callers
Function
GetLotus
获取getLotus
config/config.go:164
↓ 8 callers
Function
GetReverseUserPrompt
获取ReverseUserPrompt
config/config.go:810
↓ 8 callers
Function
ReverseString
ReverseString 颠倒给定字符串中的字符顺序
utils/utils.go:1994
↓ 8 callers
Method
createConversation
(conversationID string)
applogic/app.go:19
↓ 7 callers
Function
GetFirstA
获取FirstA
config/config.go:677
↓ 7 callers
Function
GetFirstQ
获取FirstQ
config/config.go:656
↓ 7 callers
Function
GetSecondA
获取SecondA
config/config.go:716
↓ 7 callers
Function
GetSecondQ
获取SecondQ
config/config.go:698
↓ 7 callers
Function
GetThirdA
获取ThirdA
config/config.go:752
↓ 7 callers
Function
GetThirdQ
获取ThirdQ
config/config.go:734
↓ 7 callers
Function
LogToFile
独立的文件日志记录函数
fmtf/fmtf.go:42
↓ 7 callers
Function
SystemPrompt
获取SystemPrompt
config/config.go:198
↓ 6 callers
Function
AddMessageID
AddMessageID 为指定user_id添加新的消息ID
utils/utils.go:2973
↓ 6 callers
Function
ExtractEventDetails
取出ai回答
utils/utils.go:223
↓ 6 callers
Function
GetFirstSystemMessageStruct
GetFirstSystemMessage returns the first message that is of "system" role.
prompt/prompt.go:180
↓ 6 callers
Function
GetHunyuanStreamModeration
获取HunyuanStreamModeration值
config/config.go:2916
↓ 6 callers
Function
GetSplitByPuntuations
获取SplitByPuntuations
config/config.go:532
↓ 6 callers
Function
GetUseCache
获取UseCache,增加可选参数支持动态配置查询
config/config.go:941
↓ 6 callers
Function
RemoveBracketsContent
RemoveBracketsContent 接收一个字符串,并移除所有[[...]]的内容
utils/utils.go:2007
↓ 6 callers
Function
SendSSEPrivateMessage
SendSSEPrivateMessage 分割并发送消息的核心逻辑,直接遍历字符串
utils/utils.go:2247
↓ 6 callers
Function
SendSSEPrivateMessageSP
SendSSEPrivateMessage 分割并发送消息的核心逻辑,直接遍历字符串
utils/utils.go:2304
↓ 5 callers
Function
AddMessageIDSP
AddMessageID 为指定user_id添加新的消息ID
utils/utils.go:2989
↓ 5 callers
Function
DoRequestHelper
(a Adaptor, c *gin.Context, requestBody io.Reader)
relay/adaptor/common.go:23
↓ 5 callers
Function
Done
(c *gin.Context)
common/render/render.go:28
↓ 5 callers
Function
GetSelfPath
获取GetSelfPath
config/config.go:144
↓ 5 callers
Function
GetVectorSensitiveFilter
获取VectorSensitiveFilter
config/config.go:1115
↓ 5 callers
Function
GetWenxinAccessToken
获取WenxinAccessToken
config/config.go:286
↓ 5 callers
Function
ObjectData
(c *gin.Context, object interface{})
common/render/render.go:19
↓ 5 callers
Method
ProcessPromptMarks
(userID int64, QorA string, promptStr *string)
applogic/promptstr.go:130
↓ 5 callers
Function
SetEventStreamHeaders
(c *gin.Context)
common/gin.go:47
↓ 5 callers
Function
SetupCommonRequestHeader
(c *gin.Context, req *http.Request)
relay/adaptor/common.go:15
↓ 5 callers
Function
String
(env string, defaultValue string)
common/env/helper.go:37
↓ 5 callers
Method
StringContent
()
relay/model/message.go:16
↓ 5 callers
Function
StringData
(c *gin.Context, str string)
common/render/render.go:12
↓ 5 callers
Method
sendMemoryResponse
(msg structs.OnebotGroupMessage, response string, promptstr string)
applogic/memory.go:437
↓ 5 callers
Method
sendMemoryResponseSP
(msg structs.OnebotGroupMessageS, response string, promptstr string)
applogic/memory.go:450
↓ 4 callers
Method
CalculateTextEmbedding
(text string)
applogic/embeddings.go:25
↓ 4 callers
Function
ClearMessage
(conversationID string)
applogic/gensokyo.go:1335
↓ 4 callers
Function
GetAllowedLanguages
GetAllowedLanguages 返回允许的语言列表
config/config.go:1135
↓ 4 callers
Function
GetBlacklistResponseMessages
BlacklistResponseMessages 返回语言拦截响应消息列表
config/config.go:1187
↓ 4 callers
Function
GetCacheK
获取CacheK
config/config.go:1035
↓ 4 callers
Function
GetCacheN
获取CacheN
config/config.go:1045
↓ 4 callers
Function
GetHideExtraLogs
获取隐藏日志
config/config.go:1559
↓ 4 callers
Function
GetIgnoreExtraTips
获取IgnoreExtraTips
config/config.go:820
↓ 4 callers
Function
GetMdPromptKeyboardAtGroup
群内md气泡
config/config.go:2177
↓ 4 callers
Function
GetMemoryCommand
获取MemoryCommand
config/config.go:1257
↓ 4 callers
Function
GetMemoryTitle
请你为我将我所输入的对话浓缩总结为一个标题
applogic/memory.go:24
↓ 4 callers
Function
GetNewConversationCommand
获取NewConversationCommand
config/config.go:1277
next →
1–100 of 763, ranked by callers