Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/archie0732/healthy-diet-ai-agent
/ functions
Functions
406 in github.com/archie0732/healthy-diet-ai-agent
⨍
Functions
406
◇
Types & classes
17
↓ 25 callers
Function
getRequiredFunction
( value: unknown, name: string )
src/server/agentRuntime.test.ts:8
↓ 20 callers
Function
getStorage
()
src/storage/runtime.ts:19
↓ 19 callers
Function
sendSSE
( res: Pick<Response, 'write'>, data: object, eventName?: string )
src/server/sse.ts:16
↓ 13 callers
Function
isRetryableGoogleFailure
(error: unknown)
src/server/modelRouting.ts:66
↓ 12 callers
Function
loadDefaultAgentConfig
()
src/config/agentConfig.ts:152
↓ 10 callers
Function
addNode
( cache: KnowledgeGraphCache, label: string, nodeType: GraphNodeType, documentId: string, sourceType
src/server/knowledgeGraph.ts:293
↓ 10 callers
Function
resolveKnowledgeRuntimeConfig
( config: Pick<AgentConfig, 'rag'> )
agent_skills/file_tools.ts:163
↓ 9 callers
Function
safeLower
(value: string)
src/server/knowledgeGraph.ts:136
↓ 8 callers
Function
readCache
()
src/server/knowledgeGraph.ts:657
↓ 8 callers
Function
shorten
(text: string, max = 120)
agent_skills/db_tools.ts:49
↓ 7 callers
Function
appendStreamChunk
( existing: string, incoming: string )
src/server/agentRuntime.ts:49
↓ 7 callers
Function
buildAgentModelAttemptPlan
( modelSource: ChatModelSource, hasGoogleKey: boolean )
src/server/agentRuntime.ts:520
↓ 7 callers
Function
buildPreferredProviderOrder
( modelSource: ChatModelSource, hasGoogleKey: boolean )
src/server/modelRouting.ts:17
↓ 7 callers
Function
getAiApiUrl
(options?: { isDocker?: boolean })
src/server/aiRuntime.ts:23
↓ 7 callers
Function
normalizeWhitespace
(value: string)
scripts/sync-mohw-clarifications.ts:35
↓ 7 callers
Function
requireAdminIdentity
(req: Request, res: Response)
src/server/ragDocuments.ts:274
↓ 7 callers
Function
resolveAbsolutePath
(rootDir: string, relativePath: string)
src/server/ragDocuments.ts:86
↓ 7 callers
Function
resolvePathFromConfigDir
(configDir: string, configPathValue: string)
src/config/agentConfig.ts:93
↓ 7 callers
Function
toArrayUnique
(values: T[])
src/server/knowledgeGraph.ts:135
↓ 7 callers
Function
toStatusText
(value: unknown, maxLength = 220)
src/server/httpRuntime.ts:66
↓ 6 callers
Function
buildResponseFormatInstructions
( responseStyle: AgentConfig['responseStyle'] )
src/server/agentRuntime.ts:230
↓ 6 callers
Function
clampKnowledgeTopK
( requestedTopK: number | undefined, config: Pick<AgentConfig, 'rag'> )
agent_skills/file_tools.ts:322
↓ 6 callers
Function
invokeWithModelRouting
({ modelSource, googleApiKey, onStatus, invokeProvider, }: { modelSource: ChatModelSource; googleA
src/server/agentRuntime.ts:569
↓ 6 callers
Function
normalizeWhitespace
(value: string)
agent_skills/file_tools.ts:53
↓ 6 callers
Function
parseRagSearchPayload
( payload: unknown, config: Pick<AgentConfig, 'rag'>, )
src/server/ragSearch.ts:41
↓ 5 callers
Function
addEvidenceAndEdge
( cache: KnowledgeGraphCache, params: { sourceNode: KnowledgeGraphNode; targetNode: KnowledgeGraph
src/server/knowledgeGraph.ts:321
↓ 5 callers
Function
formatSSEMessage
(data: object, eventName?: string)
src/server/sse.ts:3
↓ 5 callers
Function
inferMimeType
(extension: string)
src/server/ragDocuments.ts:54
↓ 5 callers
Function
loadAgentRuntimeSkillsIndexText
(config: Pick<AgentConfig, 'agent'>)
src/server/agentRuntime.ts:288
↓ 5 callers
Function
loadDocumentOr404
( repository: RagDocumentsRepository, req: Request, res: Response, )
src/server/ragDocuments.ts:447
↓ 5 callers
Function
sanitizeAssistantStreamingText
(message: string)
src/server/agentRuntime.ts:155
↓ 5 callers
Function
toDocumentItem
(document: RagDocumentRecord)
src/server/ragDocuments.ts:366
↓ 4 callers
Function
buildSummaryPersistenceGuard
(input: { current_user_message: string; current_assistant_reply: string; })
agent_skills/conversation_summary_tool.ts:74
↓ 4 callers
Function
createRequestId
()
src/server/httpRuntime.ts:11
↓ 4 callers
Function
fetchExistingRoomSummaryEntries
( threadId: string, userId?: string )
src/serverHandlers.ts:391
↓ 4 callers
Function
findTerms
(sentence: string, terms: string[])
src/server/knowledgeGraph.ts:191
↓ 4 callers
Method
getUserProfile
(userId: string)
src/storage/types.ts:114
↓ 4 callers
Function
hashText
(value: string)
src/server/knowledgeGraph.ts:134
↓ 4 callers
Method
insertChatHistory
(input: ChatHistoryInsertInput)
src/storage/types.ts:110
↓ 4 callers
Function
isCapabilityQuestion
(message: string)
src/server/agentRuntime.ts:327
↓ 4 callers
Function
loadAgentConfig
(configPath: string)
src/config/agentConfig.ts:146
↓ 4 callers
Function
mapDocumentRow
(row: Record<string, unknown>)
src/storage/supabase/adapter.ts:23
↓ 4 callers
Function
normalizeTitle
(value: string, fallbackText: string)
src/serverHandlers.ts:140
↓ 4 callers
Function
normalizeWhitespace
(value: string)
agent_skills/fetch_web.ts:17
↓ 4 callers
Function
parsePositiveInt
(raw: string | undefined)
scripts/sync-mohw-clarifications.ts:49
↓ 4 callers
Function
pickGoogleApiKey
()
src/server/modelRouting.ts:13
↓ 4 callers
Function
resolveMohwNewsSyncEnabled
( configMohwEnabled: AgentConfig['features']['mohwEnabled'], envValue?: string | null, )
src/server/mohwConfig.ts:14
↓ 4 callers
Function
sanitizeListField
(value: string | undefined)
src/server/profileApproval.ts:168
↓ 3 callers
Function
buildKnowledgeCorpus
(config: Pick<AgentConfig, 'rag'>)
agent_skills/file_tools.ts:185
↓ 3 callers
Function
buildRawConfig
(overrides?: Partial<Record<string, unknown>>)
src/config/agentConfig.test.ts:31
↓ 3 callers
Function
clearPendingApprovalByThread
(threadId: string)
src/server/profileApproval.ts:140
↓ 3 callers
Function
collectLeafText
($: ReturnType<typeof load>, selector: string)
src/server/mohwNews.ts:139
↓ 3 callers
Method
createKnowledgeDocument
(record: KnowledgeDocumentRecord)
src/storage/types.ts:120
↓ 3 callers
Function
emptyCache
()
src/server/knowledgeGraph.ts:124
↓ 3 callers
Method
ensureReady
()
src/storage/types.ts:109
↓ 3 callers
Function
evaluateMode
( queries: EvaluationQueryV2[], chunks: RAGChunk[], deprecatedKeys: Set<string>, judgmentsMap: Map<str
experiments/version_aware_rag/scripts/run_retrieval_eval.ts:148
↓ 3 callers
Function
extractDocumentGraph
(cache: KnowledgeGraphCache, document: KnowledgeSourceDocument)
src/server/knowledgeGraph.ts:368
↓ 3 callers
Function
extractTitle
(markdown: string, fallback: string)
agent_skills/file_tools.ts:135
↓ 3 callers
Function
fetchHtml
(url: string, timeoutMs: number)
scripts/sync-mohw-clarifications.ts:132
↓ 3 callers
Function
formatDurationMs
(startAt: number)
src/server/httpRuntime.ts:14
↓ 3 callers
Function
getChunkText
(content: unknown)
src/server/agentRuntime.ts:106
↓ 3 callers
Method
getDocument
(documentId: string)
src/server/ragDocuments.test.ts:17
↓ 3 callers
Function
hasAnyProfileField
(fields: ProfileUpdateFields)
src/server/profileApproval.ts:58
↓ 3 callers
Function
invalidateKnowledgeSearchCache
()
agent_skills/file_tools.ts:41
↓ 3 callers
Function
loadKnowledgeConfig
()
agent_skills/file_tools.ts:251
↓ 3 callers
Function
mapJobRow
(row: Record<string, unknown>)
src/storage/supabase/adapter.ts:48
↓ 3 callers
Function
normalizeWhitespace
(value: string)
src/server/mohwNews.ts:45
↓ 3 callers
Function
normalizeWhitespace
(value: string)
src/server/knowledgeIngestion.ts:48
↓ 3 callers
Function
normalizeWhitespace
(value: string)
src/server/ragDocuments.ts:30
↓ 3 callers
Function
parseJsonArray
(value: unknown)
src/storage/sqlite/adapter.ts:18
↓ 3 callers
Function
parseJsonSafe
(value: string)
src/server/profileApproval.ts:66
↓ 3 callers
Function
parseJsonSafe
(value: string)
agent_skills/conversation_summary_tool.ts:15
↓ 3 callers
Function
parseRoomSummaryIndex
(rawSummary: unknown)
src/server/roomSummaryIndex.ts:51
↓ 3 callers
Function
pruneDocumentFromCache
(cache: KnowledgeGraphCache, documentId: string)
src/server/knowledgeGraph.ts:491
↓ 3 callers
Function
readManifest
()
src/server/mohwNews.ts:210
↓ 3 callers
Function
readOptionalFile
(...filePaths: string[])
src/server/agentRuntime.ts:364
↓ 3 callers
Function
readTextFileSafe
(absolutePath: string)
agent_skills/file_tools.ts:58
↓ 3 callers
Function
requireAdminIdentity
(req: Request, res: Response)
src/server/knowledgeGraph.ts:154
↓ 3 callers
Function
resolveAgentRuntimePromptPaths
( config: Pick<AgentConfig, 'agent'> )
src/server/agentRuntime.ts:276
↓ 3 callers
Function
retrieveTopK
( query: EvaluationQueryV2, chunks: RAGChunk[], deprecatedKeys: Set<string>, mode: 'append-only' | 're
experiments/version_aware_rag/scripts/run_retrieval_eval.ts:95
↓ 3 callers
Function
sanitizeAssistantVisibleText
(message: string)
src/server/agentRuntime.ts:144
↓ 3 callers
Function
sanitizeContentBlock
(text: string)
src/server/mohwNews.ts:130
↓ 3 callers
Function
shouldFallbackSummarizeTurn
(input: { userMessage: string; assistantReply: string; })
src/serverHandlers.ts:382
↓ 3 callers
Function
splitIntoParagraphChunks
(text: string, maxChunkChars: number)
agent_skills/file_tools.ts:94
↓ 3 callers
Function
summarizeRoomSummaryIndex
(entries: RoomSummaryIndexEntry[])
src/server/roomSummaryIndex.ts:73
↓ 3 callers
Function
toPosixRelative
(absolutePath: string)
agent_skills/file_tools.ts:55
↓ 3 callers
Method
updateChatHistoryReply
(input: { chatHistoryId: string; aiReply: string })
src/storage/types.ts:111
↓ 3 callers
Method
updateKnowledgeDocument
( documentId: string, patch: Partial<KnowledgeDocumentRecord> )
src/storage/types.ts:121
↓ 3 callers
Method
upsertChatRoom
(input: ChatRoomUpsertInput)
src/storage/types.ts:112
↓ 3 callers
Function
writeTempConfig
(config: unknown)
src/config/agentConfig.test.ts:22
↓ 2 callers
Function
attemptInsert
(row: Record<string, unknown>)
agent_skills/db_tools.ts:72
↓ 2 callers
Function
buildApprovalProposalItems
(fields: ProfileUpdateFields)
src/server/profileApproval.ts:196
↓ 2 callers
Function
buildCallModelResponseStylePromptLines
( responseStyle: AgentConfig['responseStyle'] )
src/server/agentRuntime.ts:258
↓ 2 callers
Function
buildCapabilitiesSummary
({ toolNames, skillsIndex, }: { toolNames: string[]; skillsIndex: string; })
src/server/agentRuntime.ts:386
↓ 2 callers
Function
buildLegacySummaryIndexEntry
({ legacySummary, createdAt = '', }: { legacySummary: string; createdAt?: string; })
src/server/roomSummaryIndex.ts:31
↓ 2 callers
Function
buildPreviewResponse
( document: RagDocumentRecord, previewKind: 'text' | 'unsupported', content: string, truncated: boolea
src/server/ragDocuments.ts:381
↓ 2 callers
Function
buildResponseStylePromptSection
( responseStyle: AgentConfig['responseStyle'] )
src/server/agentRuntime.ts:254
↓ 2 callers
Function
buildSummarizer
(summaryMaxTokens: number)
agent_skills/fetch_web.ts:96
↓ 2 callers
Function
buildSummaryResult
(summary: string)
agent_skills/vision_model.ts:36
↓ 2 callers
Function
cleanupExpiredApprovals
()
src/server/profileApproval.ts:119
next →
1–100 of 406, ranked by callers