Open inverted-capital opened 2 months ago
Use the zod schemas to generate json schemas on the fly, and use that as the manifest object which is attached to the api.
This library https://github.com/anatine/zod-plugins/tree/main/packages/zod-openapi generates the json schemas that can be sent off to openai.
Best to use https://www.npmjs.com/package/zod-to-json-schema as this is recommended by openai: https://github.com/openai/openai-node/blob/HEAD/helpers.md#integrate-with-zod
If the agent checker had a platform manifest that represented the version of the platform, and listed all the isolate functions available, then it can attempt to update the agents each time there is a platform update.
We should auto generate semver based on how these schemas change, and indicate the changes to the api in a changelog.
This would detect when the isolate api had changed, which means the agents may need to upgrade.
An upgrade bot could upgrade agents automatically.
The manifest is what the creatorbot uses to know what functions are best to use.