module references clean
This commit is contained in:
parent
dd48e0f009
commit
8e63357190
2 changed files with 7 additions and 26 deletions
|
|
@ -159,6 +159,8 @@ class ChatManager:
|
||||||
"duration": (datetime.now(UTC) - datetime.fromisoformat(workflow.startedAt)).total_seconds()
|
"duration": (datetime.now(UTC) - datetime.fromisoformat(workflow.startedAt)).total_seconds()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Get user language from service
|
||||||
|
userLanguage = self.service.user.language
|
||||||
|
|
||||||
# Prepare messages for AI context
|
# Prepare messages for AI context
|
||||||
messages = [
|
messages = [
|
||||||
|
|
@ -188,7 +190,7 @@ class ChatManager:
|
||||||
})
|
})
|
||||||
|
|
||||||
# Generate feedback using AI
|
# Generate feedback using AI
|
||||||
feedback = await self.callAi(messages, produceUserAnswer=True, temperature=0.7)
|
feedback = await self.service.callAi(messages, produceUserAnswer=True, temperature=0.7)
|
||||||
|
|
||||||
return feedback
|
return feedback
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,23 +1,4 @@
|
||||||
- all AI calls to route over self service (AI basic, ai special, ai...) and to streamline
|
Prompt for task definition:
|
||||||
|
|
||||||
- integrate, then remove:
|
|
||||||
callAi(prompt, context) -> str
|
|
||||||
callAi4Image(prompt, context, imageData)-> str
|
|
||||||
_callAiBasic
|
|
||||||
_callAiAdvanced
|
|
||||||
|
|
||||||
in manageChat
|
|
||||||
- not to manipulate workflow or messages --> to use functions from servicechatclass
|
|
||||||
- to add CRUD for tasks to workflow
|
|
||||||
- to move methods to methods class
|
|
||||||
|
|
||||||
- service object to define correctly
|
|
||||||
- folder workflow modules --> solve problems types
|
|
||||||
|
|
||||||
|
|
||||||
Procedure for task generation:
|
|
||||||
|
|
||||||
- prompt input:
|
|
||||||
- original user input (summary)
|
- original user input (summary)
|
||||||
- prompt for task to do
|
- prompt for task to do
|
||||||
- method list
|
- method list
|
||||||
|
|
@ -33,12 +14,10 @@ Procedure for task generation:
|
||||||
- as parameter only to use available items of documentReference and connectionReference or resultLabel of a previous method.action
|
- as parameter only to use available items of documentReference and connectionReference or resultLabel of a previous method.action
|
||||||
- required result format: json for TaskResult, nothing else
|
- required result format: json for TaskResult, nothing else
|
||||||
|
|
||||||
- result parsing:
|
|
||||||
- execute task actions by using data references stepwise, all documents in TaskResults to save as ChatDocuments, to be available for next action.
|
|
||||||
|
|
||||||
|
TODO
|
||||||
TODO:
|
- result parsing: execute task actions by using data references stepwise, all documents in TaskResults to save as ChatDocuments, to be available for next action.
|
||||||
- action output filename to be available as TaskResult with name to reference object and ChatDocument list
|
- action execution: to use conversion functions, user DocumentReference and ConnectionReference
|
||||||
|
|
||||||
|
|
||||||
service (ServiceContainer)
|
service (ServiceContainer)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue