All of these functions were not working since it needs a special trick
to call javscript async function within lua:
https://github.com/ceifa/wasmoon/issues/22
The proper trick for allowing async function was added.
Also added missing awaits for similarity search.
You can use following lua trigger to test out the behaviour:
```lua
listenEdit("editOutput", function(triggerId, data)
local res = similarity(triggerId, data, {"happy", "angry", "sad"}):await()
return res[1]
end)
```
Note you need https://github.com/kwaroran/RisuAI/pull/572 to test this
out since low level access is disabled for lua right now.
# PR Checklist
- [ ] Did you check if it works normally in all models? *ignore this
when it dosen't uses models*
- [ ] Did you check if it works normally in all of web, local and node
hosted versions? if it dosen't, did you blocked it in those versions?
- [ ] Did you added a type def?
# Description
It appears that the current date time formatting in CBS is not working
as intended, I also added a format for the day of the week (`ddd` and
`dddd`), please review if this is appropriate.
# PR Checklist
- [ ] Did you check if it works normally in all models? *ignore this
when it dosen't uses models*
- [ ] Did you check if it works normally in all of web, local and node
hosted versions? if it dosen't, did you blocked it in those versions?
- [ ] Did you added a type def?
# Description
Currently, some of the operators in the trigger block seem to be working
in reverse.
# PR Checklist
- [ ] Did you check if it works normally in all models? *ignore this
when it dosen't uses models*
- [ ] Did you check if it works normally in all of web, local and node
hosted versions? if it dosen't, did you blocked it in those versions?
- [ ] Did you added a type def?
# Description
When running `npm install` followed by `npm run build` in the Node
version, the build process fails with multiple errors indicating that
various Svelte components and stores are not defined.
- Updated `server.bat` to use `pnpm install`, `pnpm run build`, and
`pnpm run runserver`.
- Updated `server.sh` to use `pnpm install`, `pnpm run build`, and `pnpm
run runserver`.
---
The errors encountered when using `npm install` in the Node version
include:
- 'loadedStore' is not defined
- 'WelcomeRisu' is not defined
- 'settingsOpen' is not defined
- 'Settings' is not defined
- 'GridChars' is not defined
- 'DynamicGUI' is not defined
- 'Sidebar' is not defined
- 'sideBarStore' is not defined
- 'ChatScreen' is not defined
- 'alertStore' is not defined
- 'AlertComp' is not defined
- 'showRealmInfoStore' is not defined
- 'RealmPopUp' is not defined
- 'ShowRealmFrameStore' is not defined
- 'RealmFrame' is not defined
These errors are resolved by using `pnpm install` as the package
manager.
# PR Checklist
- [ ] Did you check if it works normally in all models? *ignore this
when it dosen't uses models*
- [ ] Did you check if it works normally in all of web, local and node
hosted versions? if it dosen't, did you blocked it in those versions?
- [ ] Did you added a type def?
# Description
While implementing a specific behavior through CBS, I encountered
limitations during handling first message. Therefore, I aim to modify
the effect of certain keywords to accommodate a broader range of cases.
The changes have been tested and presented no issues. However, I kindly
request your review from a structural design perspective to ensure
adequacy.