mirror of
https://github.com/memohai/Memoh.git
synced 2026-04-27 07:16:19 +09:00
feat: file attachment input
This commit is contained in:
+3
-2
@@ -37,14 +37,15 @@ export const createAgent = ({
|
||||
})
|
||||
|
||||
const generateUserPrompt = (input: AgentInput) => {
|
||||
const images = input.attachments.filter(attachment => attachment.type === 'image')
|
||||
const files = input.attachments.filter(attachment => attachment.type === 'file')
|
||||
const text = user(input.query, {
|
||||
contactId: identity.contactId,
|
||||
contactName: identity.contactName,
|
||||
platform: currentPlatform,
|
||||
date: new Date(),
|
||||
attachments: files,
|
||||
})
|
||||
const images = input.attachments.filter(attachment => attachment.type === 'image')
|
||||
// const files = input.attachments.filter(attachment => attachment.type === 'file')
|
||||
const userMessage: UserModelMessage = {
|
||||
role: 'user',
|
||||
content: [
|
||||
|
||||
Reference in New Issue
Block a user