-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deno Compatibility #188
Comments
It works "deno run main.ts" main.ts
But when I am trying to build with deno-esbuild, it seems to not support npm specifiers and therefore would be better if I could import modelfusion package directly from deno.land
|
As a temporary solution, following works:
|
@7flash thanks for reporting the issue! I'm not too familiar with Deno. From your report, my sense is that ideally modelfusion should work with deno-esbuild. Can you tell me the error that you encountered w/ deno-esbuild? regarding deno.land, is that a separate pkg registry i would need to upload to? |
The issue evanw/esbuild#3506 seemed to be resolved by using jspm and though it works for simple case it fails when trying to register tools because of another issue with zod colinhacks/zod#2991
|
colinhacks/zod#2991 is not a Zod error. ModelFusion contains something called See https://github.com/lgrammel/modelfusion/blob/main/src/core/schema/ZodSchema.ts The error message points to a potential issue with |
Is there are a way to provide directy my json schema instead of zod? Because I am building kind of visual editor based on modelfusion where user ends up describing his tools in json format anyway |
@7flash yes, you can use This will not do any validation on the structure of the result tho, just cast it (which could be wrong at runtime). You can also implement your own schema and json schema acccessor, see https://github.com/lgrammel/modelfusion/blob/main/src/core/schema/Schema.ts and https://github.com/lgrammel/modelfusion/blob/main/src/core/schema/JsonSchemaProducer.ts for the relevant interfaces (they both need to be implemented in a single object / class). That way, you can use other JSON validations like Validbot. Please note that ModelFusion uses Zod internally for validations that are not related to user-defined schemas. PS: I've added an |
@lgrammel that's amazing, and here just recorded a demo of visual agent editor I am building with modelfusion: https://youtu.be/V-rI_ughijw |
Pretty cool! Do you have an open source project or a website? I have started a showcase section on the ModelFusion website, when the project is mature and available, this might be a good fit. |
Yes it's here https://github.com/galaxydo/galaxy-polkadot |
Awesome - feel free to send a pull request. The "story teller" example in the showcase shows what needs to be added (section & separate page) |
No description provided.
The text was updated successfully, but these errors were encountered: